Use the REST API to interact with pull request reviews.
Pull Request Reviews are groups of pull request review comments on a pull request, grouped together with a state and optional body comment.
Note
Most endpoints use Authorization: Bearer <YOUR-TOKEN> and Accept: application/vnd.github+json headers, plus X-GitHub-Api-Version: 2026-03-10. Curl examples below omit these standard headers for brevity.
GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews
Lists all reviews for a specified pull request. The list of reviews returns in chronological order.
This endpoint supports the following custom media types. For more information, see "Media types."
application/vnd.github-commitcomment.raw+json: Returns the raw markdown body. Response will include body. This is the default if you do not pass any specific media type.
application/vnd.github-commitcomment.text+json: Returns a text only representation of the markdown body. Response will include body_text.
application/vnd.github-commitcomment.html+json: Returns HTML rendered from the body's markdown. Response will include body_html.
application/vnd.github-commitcomment.full+json: Returns raw, text, and HTML representations. Response will include body, body_text, and body_html.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
pull_number (integer) (required)
The number that identifies the pull request.
per_page (integer)
The number of results per page (max 100). For more information, see "Using pagination in the REST API."
Default: 30
page (integer)
The page number of the results to fetch. For more information, see "Using pagination in the REST API."
Default: 1
Request:
curl -L \
-X GET \
https://api.github.com/repos/OWNER/REPO/pulls/PULL_NUMBER/reviews
Response schema (Status: 200):
Array of Pull Request Review:
id: required, integer, format: int64node_id: required, stringuser: required, any of:
name: string or nullemail: string or nulllogin: required, stringid: required, integer, format: int64node_id: required, stringavatar_url: required, string, format: urigravatar_id: required, string or nullurl: required, string, format: urihtml_url: required, string, format: urifollowers_url: required, string, format: urifollowing_url: required, stringgists_url: required, stringstarred_url: required, stringsubscriptions_url: required, string, format: uriorganizations_url: required, string, format: urirepos_url: required, string, format: urievents_url: required, stringreceived_events_url: required, string, format: uritype: required, stringsite_admin: required, booleanstarred_at: stringuser_view_type: stringbody: required, stringstate: required, stringhtml_url: required, string, format: uripull_request_url: required, string, format: uri_links: required, object:
html: required, object:
href: required, stringpull_request: required, object:
href: required, stringsubmitted_at: string, format: date-timecommit_id: required, string or nullbody_html: stringbody_text: stringauthor_association: required, string, enum: COLLABORATOR, CONTRIBUTOR, FIRST_TIMER, FIRST_TIME_CONTRIBUTOR, MANNEQUIN, MEMBER, NONE, OWNERPOST /repos/{owner}/{repo}/pulls/{pull_number}/reviews
Creates a review on a specified pull request.
This endpoint triggers notifications. Creating content too quickly using this endpoint may result in secondary rate limiting. For more information, see "Rate limits for the API" and "Best practices for using the REST API."
Pull request reviews created in the PENDING state are not submitted and therefore do not include the submitted_at property in the response. To create a pending review for a pull request, leave the event parameter blank. For more information about submitting a PENDING review, see "Submit a review for a pull request."
Note
To comment on a specific line in a file, you need to first determine the position of that line in the diff. To see a pull request diff, add the application/vnd.github.v3.diff media type to the Accept header of a call to the Get a pull request endpoint.
The position value equals the number of lines down from the first "@@" hunk header in the file you want to add a comment. The line just below the "@@" line is position 1, the next line is position 2, and so on. The position in the diff continues to increase through lines of whitespace and additional hunks until the beginning of a new file.
This endpoint supports the following custom media types. For more information, see "Media types."
application/vnd.github-commitcomment.raw+json: Returns the raw markdown body. Response will include body. This is the default if you do not pass any specific media type.
application/vnd.github-commitcomment.text+json: Returns a text only representation of the markdown body. Response will include body_text.
application/vnd.github-commitcomment.html+json: Returns HTML rendered from the body's markdown. Response will include body_html.
application/vnd.github-commitcomment.full+json: Returns raw, text, and HTML representations. Response will include body, body_text, and body_html.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
pull_number (integer) (required)
The number that identifies the pull request.
commit_id (string)
The SHA of the commit that needs a review. Not using the latest commit SHA may render your review comment outdated if a subsequent commit modifies the line you specify as the position. Defaults to the most recent commit in the pull request when you do not specify a value.
body (string)
Required when using REQUEST_CHANGES or COMMENT for the event parameter. The body text of the pull request review.
event (string)
The review action you want to perform. The review actions include: APPROVE, REQUEST_CHANGES, or COMMENT. By leaving this blank, you set the review action state to PENDING, which means you will need to submit the pull request review when you are ready.
Can be one of: APPROVE, REQUEST_CHANGES, COMMENT
comments (array of objects)
Use the following table to specify the location, destination, and contents of the draft review comment.
path (string) (required)position (integer)body (string) (required)line (integer)side (string)start_line (integer)start_side (string)200 - OK
403 - Forbidden
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X POST \
https://api.github.com/repos/OWNER/REPO/pulls/PULL_NUMBER/reviews \
-d '{
"commit_id": "ecdd80bb57125d7ba9641ffaa4d7d2c19d3f3091",
"body": "This is close to perfect! Please address the suggested inline change.",
"event": "REQUEST_CHANGES",
"comments": [
{
"path": "file.md",
"position": 6,
"body": "Please add more information here, and fix this typo."
}
]
}'
Response schema (Status: 200):
id: required, integer, format: int64node_id: required, stringuser: required, any of:
name: string or nullemail: string or nulllogin: required, stringid: required, integer, format: int64node_id: required, stringavatar_url: required, string, format: urigravatar_id: required, string or nullurl: required, string, format: urihtml_url: required, string, format: urifollowers_url: required, string, format: urifollowing_url: required, stringgists_url: required, stringstarred_url: required, stringsubscriptions_url: required, string, format: uriorganizations_url: required, string, format: urirepos_url: required, string, format: urievents_url: required, stringreceived_events_url: required, string, format: uritype: required, stringsite_admin: required, booleanstarred_at: stringuser_view_type: stringbody: required, stringstate: required, stringhtml_url: required, string, format: uripull_request_url: required, string, format: uri_links: required, object:
html: required, object:
href: required, stringpull_request: required, object:
href: required, stringsubmitted_at: string, format: date-timecommit_id: required, string or nullbody_html: stringbody_text: stringauthor_association: required, string, enum: COLLABORATOR, CONTRIBUTOR, FIRST_TIMER, FIRST_TIME_CONTRIBUTOR, MANNEQUIN, MEMBER, NONE, OWNERGET /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}
Retrieves a pull request review by its ID.
This endpoint supports the following custom media types. For more information, see "Media types."
application/vnd.github-commitcomment.raw+json: Returns the raw markdown body. Response will include body. This is the default if you do not pass any specific media type.
application/vnd.github-commitcomment.text+json: Returns a text only representation of the markdown body. Response will include body_text.
application/vnd.github-commitcomment.html+json: Returns HTML rendered from the body's markdown. Response will include body_html.
application/vnd.github-commitcomment.full+json: Returns raw, text, and HTML representations. Response will include body, body_text, and body_html.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
pull_number (integer) (required)
The number that identifies the pull request.
review_id (integer) (required)
The unique identifier of the review.
200 - OK
404 - Resource not found
Request:
curl -L \
-X GET \
https://api.github.com/repos/OWNER/REPO/pulls/PULL_NUMBER/reviews/REVIEW_ID
Response schema (Status: 200):
Same response schema as Create a review for a pull request.
PUT /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}
Updates the contents of a specified review summary comment.
This endpoint supports the following custom media types. For more information, see "Media types."
application/vnd.github-commitcomment.raw+json: Returns the raw markdown body. Response will include body. This is the default if you do not pass any specific media type.
application/vnd.github-commitcomment.text+json: Returns a text only representation of the markdown body. Response will include body_text.
application/vnd.github-commitcomment.html+json: Returns HTML rendered from the body's markdown. Response will include body_html.
application/vnd.github-commitcomment.full+json: Returns raw, text, and HTML representations. Response will include body, body_text, and body_html.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
pull_number (integer) (required)
The number that identifies the pull request.
review_id (integer) (required)
The unique identifier of the review.
body (string) (required)200 - OK
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X PUT \
https://api.github.com/repos/OWNER/REPO/pulls/PULL_NUMBER/reviews/REVIEW_ID \
-d '{
"body": "This is close to perfect! Please address the suggested inline change. And add more about this."
}'
Response schema (Status: 200):
Same response schema as Create a review for a pull request.
DELETE /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}
Deletes a pull request review that has not been submitted. Submitted reviews cannot be deleted.
This endpoint supports the following custom media types. For more information, see "Media types."
application/vnd.github-commitcomment.raw+json: Returns the raw markdown body. Response will include body. This is the default if you do not pass any specific media type.
application/vnd.github-commitcomment.text+json: Returns a text only representation of the markdown body. Response will include body_text.
application/vnd.github-commitcomment.html+json: Returns HTML rendered from the body's markdown. Response will include body_html.
application/vnd.github-commitcomment.full+json: Returns raw, text, and HTML representations. Response will include body, body_text, and body_html.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
pull_number (integer) (required)
The number that identifies the pull request.
review_id (integer) (required)
The unique identifier of the review.
200 - OK
404 - Resource not found
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X DELETE \
https://api.github.com/repos/OWNER/REPO/pulls/PULL_NUMBER/reviews/REVIEW_ID
Response schema (Status: 200):
Same response schema as Create a review for a pull request.
GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/comments
Lists comments for a specific pull request review.
This endpoint supports the following custom media types. For more information, see "Media types."
application/vnd.github-commitcomment.raw+json: Returns the raw markdown body. Response will include body. This is the default if you do not pass any specific media type.
application/vnd.github-commitcomment.text+json: Returns a text only representation of the markdown body. Response will include body_text.
application/vnd.github-commitcomment.html+json: Returns HTML rendered from the body's markdown. Response will include body_html.
application/vnd.github-commitcomment.full+json: Returns raw, text, and HTML representations. Response will include body, body_text, and body_html.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
pull_number (integer) (required)
The number that identifies the pull request.
review_id (integer) (required)
The unique identifier of the review.
per_page (integer)
The number of results per page (max 100). For more information, see "Using pagination in the REST API."
Default: 30
page (integer)
The page number of the results to fetch. For more information, see "Using pagination in the REST API."
Default: 1
200 - OK
404 - Resource not found
Request:
curl -L \
-X GET \
https://api.github.com/repos/OWNER/REPO/pulls/PULL_NUMBER/reviews/REVIEW_ID/comments
Response schema (Status: 200):
Array of Legacy Review Comment:
url: required, string, format: uripull_request_review_id: required, integer or null, format: int64id: required, integer, format: int64node_id: required, stringdiff_hunk: required, stringpath: required, stringposition: required, integer or nulloriginal_position: required, integercommit_id: required, stringoriginal_commit_id: required, stringin_reply_to_id: integeruser: required, any of:
name: string or nullemail: string or nulllogin: required, stringid: required, integer, format: int64node_id: required, stringavatar_url: required, string, format: urigravatar_id: required, string or nullurl: required, string, format: urihtml_url: required, string, format: urifollowers_url: required, string, format: urifollowing_url: required, stringgists_url: required, stringstarred_url: required, stringsubscriptions_url: required, string, format: uriorganizations_url: required, string, format: urirepos_url: required, string, format: urievents_url: required, stringreceived_events_url: required, string, format: uritype: required, stringsite_admin: required, booleanstarred_at: stringuser_view_type: stringbody: required, stringcreated_at: required, string, format: date-timeupdated_at: required, string, format: date-timehtml_url: required, string, format: uripull_request_url: required, string, format: uriauthor_association: required, string, enum: COLLABORATOR, CONTRIBUTOR, FIRST_TIMER, FIRST_TIME_CONTRIBUTOR, MANNEQUIN, MEMBER, NONE, OWNER_links: required, object:
self: required, Link:
href: required, stringhtml: required, Link (see above)pull_request: required, Link (see above)body_text: stringbody_html: stringreactions: Reaction Rollup:
url: required, string, format: uritotal_count: required, integer+1: required, integer-1: required, integerlaugh: required, integerconfused: required, integerheart: required, integerhooray: required, integereyes: required, integerrocket: required, integerside: string, enum: LEFT, RIGHT, default: "RIGHT"start_side: string or null, enum: LEFT, RIGHT, null, default: "RIGHT"line: integeroriginal_line: integerstart_line: integer or nulloriginal_start_line: integer or nullsubject_type: string, enum: line, filePUT /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/dismissals
Dismisses a specified review on a pull request.
Note
To dismiss a pull request review on a protected branch, you must be a repository administrator or be included in the list of people or teams who can dismiss pull request reviews.
This endpoint supports the following custom media types. For more information, see "Media types."
application/vnd.github-commitcomment.raw+json: Returns the raw markdown body. Response will include body. This is the default if you do not pass any specific media type.
application/vnd.github-commitcomment.text+json: Returns a text only representation of the markdown body. Response will include body_text.
application/vnd.github-commitcomment.html+json: Returns HTML rendered from the body's markdown. Response will include body_html.
application/vnd.github-commitcomment.full+json: Returns raw, text, and HTML representations. Response will include body, body_text, and body_html.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
pull_number (integer) (required)
The number that identifies the pull request.
review_id (integer) (required)
The unique identifier of the review.
message (string) (required)
The message for the pull request review dismissal
event (string)
Can be one of: DISMISS
200 - OK
404 - Resource not found
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X PUT \
https://api.github.com/repos/OWNER/REPO/pulls/PULL_NUMBER/reviews/REVIEW_ID/dismissals \
-d '{
"message": "You are dismissed",
"event": "DISMISS"
}'
Response schema (Status: 200):
Same response schema as Create a review for a pull request.
POST /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/events
Submits a pending review for a pull request. For more information about creating a pending review for a pull request, see "Create a review for a pull request."
This endpoint supports the following custom media types. For more information, see "Media types."
application/vnd.github-commitcomment.raw+json: Returns the raw markdown body. Response will include body. This is the default if you do not pass any specific media type.
application/vnd.github-commitcomment.text+json: Returns a text only representation of the markdown body. Response will include body_text.
application/vnd.github-commitcomment.html+json: Returns HTML rendered from the body's markdown. Response will include body_html.
application/vnd.github-commitcomment.full+json: Returns raw, text, and HTML representations. Response will include body, body_text, and body_html.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
pull_number (integer) (required)
The number that identifies the pull request.
review_id (integer) (required)
The unique identifier of the review.
body (string)
The body text of the pull request review
event (string) (required)
The review action you want to perform. The review actions include: APPROVE, REQUEST_CHANGES, or COMMENT. When you leave this blank, the API returns HTTP 422 (Unrecognizable entity) and sets the review action state to PENDING, which means you will need to re-submit the pull request review using a review action.
Can be one of: APPROVE, REQUEST_CHANGES, COMMENT
200 - OK
403 - Forbidden
404 - Resource not found
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X POST \
https://api.github.com/repos/OWNER/REPO/pulls/PULL_NUMBER/reviews/REVIEW_ID/events \
-d '{
"body": "Here is the body for the review.",
"event": "REQUEST_CHANGES"
}'
Response schema (Status: 200):
Same response schema as Create a review for a pull request.