Skip to main content

Cette version de GitHub Enterprise Server ne sera plus disponible le 2026-08-25. Les versions abandonnées ne sont pas prises en charge. Aucune publication de correctifs n’est effectuée, même pour les problèmes de sécurité critiques. Pour de meilleures performances, une sécurité améliorée et de nouvelles fonctionnalités dans GitHub Enterprise Server, consultez Overview du processus de mise à niveau. Pour obtenir de l’aide sur la mise à niveau, GitHub Support Entreprise.

Using query parameters to create a pull request

Use query parameters to create custom URLs that open pull requests with pre-filled titles, descriptions, labels, and more.

You can add query parameters to a compare URL to open a pull request with pre-populated fields. For pull request templates, see Création d’un modèle de pull request pour votre dépôt.

ParameterPurposeExample
quick_pullOpens the "Open a pull request" page for the compared branches.https://github.com/octo-org/octo-repo/compare/main...my-branch?quick_pull=1
titleAdds a pull request title. Use + for spaces.https://github.com/octo-org/octo-repo/compare/main...my-branch?quick_pull=1&labels=bug&title=Bug+fix
bodyAdds text to the pull request body. Use + for spaces.https://github.com/octo-org/octo-repo/compare/main...my-branch?quick_pull=1&title=Bug+fix&body=Describe+the+fix.
labelsAdds one or more labels. Separate multiple labels with commas.https://github.com/octo-org/octo-repo/compare/main...my-branch?quick_pull=1&labels=help+wanted,bug
milestoneAdds a milestone. Use + for spaces.https://github.com/octo-org/octo-repo/compare/main...my-branch?quick_pull=1&milestone=testing+milestones
assigneesAssigns the pull request to one or more users. Separate multiple users with commas.https://github.com/octo-org/octo-repo/compare/main...my-branch?quick_pull=1&assignees=octocat
projectsAdds the pull request to a project.https://github.com/octo-org/octo-repo/compare/main...my-branch?quick_pull=1&title=Bug+fix&projects=octo-org/1
templateAdds a pull request template from a PULL_REQUEST_TEMPLATE subdirectory in the root, docs/, or .github/ directory.https://github.com/octo-org/octo-repo/compare/main...my-branch?quick_pull=1&template=issue_template.md

You must have permission to complete the equivalent action to use its query parameter. For example, you must have permission to add labels to use labels. See Rôles de dépôt pour une organisation.

Invalid query parameters or insufficient permissions return a 404 Not Found error. URLs that exceed the server limit return a 414 URI Too Long error.