Draft pull requests are available in public repositories with GitHub Free and GitHub Free for organizations, GitHub Pro, and legacy per-repository billing plans, and in public and private repositories with GitHub Team and GitHub Enterprise Cloud. For more information, see in the GitHub Help documentation.
To open or update a pull request in a public repository, you must have write access to the head or the source branch. For organization-owned repositories, you must be a member of the organization that owns the repository to open or update a pull request.
This endpoint triggers . Creating content too quickly using this endpoint may result in secondary rate limiting. For more information, see "" and "."
This endpoint supports the following custom media types. For more information, see "."
application/vnd.github.raw+json: Returns the raw markdown body. Response will includebody. This is the default if you do not pass any specific media type.application/vnd.github.text+json: Returns a text only representation of the markdown body. Response will includebody_text.application/vnd.github.html+json: Returns HTML rendered from the body's markdown. Response will includebody_html.application/vnd.github.full+json: Returns raw, text, and HTML representations. Response will includebody,body_text, andbody_html.