Update a review comment for a pull request

PATCH {{baseUrl}}/repos/:owner/:repo/pulls/comments/:comment_id

Note: Multi-line comments on pull requests are currently in public beta and subject to change.

Enables you to edit a review comment.

Multi-line comment summary

Note: New parameters and response fields are available for developers to preview. During the preview period, these response fields may change without advance notice. Please see the blog post for full details.

Use the comfort-fade preview header and the line parameter to show multi-line comment-supported fields in the response.

If you use the comfort-fade preview header, your response will show:

  • For multi-line comments, values for start_line, original_start_line, start_side, line, original_line, and side.
  • For single-line comments, values for line, original_line, and side and a null value for start_line, original_start_line, and start_side.

If you don't use the comfort-fade preview header, multi-line and single-line comments will appear the same way in the response with a single position attribute. Your response will show:

  • For multi-line comments, the last line of the comment range for the position attribute.
  • For single-line comments, the diff-positioned way of referencing comments for the position attribute. For more information, see position in the input parameters table.

Request Body

{"body"=>"<string>"}

HEADERS

KeyDatatypeRequiredDescription
Content-Typestring

RESPONSES

status: OK

{&quot;url&quot;:&quot;https://api.github.com/repos/octocat/Hello-World/pulls/comments/1&quot;,&quot;pull_request_review_id&quot;:42,&quot;id&quot;:10,&quot;node_id&quot;:&quot;MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDEw&quot;,&quot;diff_hunk&quot;:&quot;@@ -16,33 +16,40 @@ public class Connection : IConnection...&quot;,&quot;path&quot;:&quot;file1.txt&quot;,&quot;position&quot;:1,&quot;original_position&quot;:4,&quot;commit_id&quot;:&quot;6dcb09b5b57875f334f61aebed695e2e4193db5e&quot;,&quot;original_commit_id&quot;:&quot;9c48853fa3dc5c1c3d6f1f1cd1f2743e72652840&quot;,&quot;in_reply_to_id&quot;:8,&quot;user&quot;:{&quot;login&quot;:&quot;octocat&quot;,&quot;id&quot;:1,&quot;node_id&quot;:&quot;MDQ6VXNlcjE=&quot;,&quot;avatar_url&quot;:&quot;https://github.com/images/error/octocat_happy.gif&quot;,&quot;gravatar_id&quot;:&quot;&quot;,&quot;url&quot;:&quot;https://api.github.com/users/octocat&quot;,&quot;html_url&quot;:&quot;https://github.com/octocat&quot;,&quot;followers_url&quot;:&quot;https://api.github.com/users/octocat/followers&quot;,&quot;following_url&quot;:&quot;https://api.github.com/users/octocat/following{/other_user}&quot;,&quot;gists_url&quot;:&quot;https://api.github.com/users/octocat/gists{/gist_id}&quot;,&quot;starred_url&quot;:&quot;https://api.github.com/users/octocat/starred{/owner}{/repo}&quot;,&quot;subscriptions_url&quot;:&quot;https://api.github.com/users/octocat/subscriptions&quot;,&quot;organizations_url&quot;:&quot;https://api.github.com/users/octocat/orgs&quot;,&quot;repos_url&quot;:&quot;https://api.github.com/users/octocat/repos&quot;,&quot;events_url&quot;:&quot;https://api.github.com/users/octocat/events{/privacy}&quot;,&quot;received_events_url&quot;:&quot;https://api.github.com/users/octocat/received_events&quot;,&quot;type&quot;:&quot;User&quot;,&quot;site_admin&quot;:false},&quot;body&quot;:&quot;Great stuff!&quot;,&quot;created_at&quot;:&quot;2011-04-14T16:00:49Z&quot;,&quot;updated_at&quot;:&quot;2011-04-14T16:00:49Z&quot;,&quot;html_url&quot;:&quot;https://github.com/octocat/Hello-World/pull/1#discussion-diff-1&quot;,&quot;pull_request_url&quot;:&quot;https://api.github.com/repos/octocat/Hello-World/pulls/1&quot;,&quot;author_association&quot;:&quot;NONE&quot;,&quot;_links&quot;:{&quot;self&quot;:{&quot;href&quot;:&quot;https://api.github.com/repos/octocat/Hello-World/pulls/comments/1&quot;},&quot;html&quot;:{&quot;href&quot;:&quot;https://github.com/octocat/Hello-World/pull/1#discussion-diff-1&quot;},&quot;pull_request&quot;:{&quot;href&quot;:&quot;https://api.github.com/repos/octocat/Hello-World/pulls/1&quot;}},&quot;start_line&quot;:1,&quot;original_start_line&quot;:1,&quot;start_side&quot;:&quot;RIGHT&quot;,&quot;line&quot;:2,&quot;original_line&quot;:2,&quot;side&quot;:&quot;RIGHT&quot;}