comments
Overview
Name | comments |
Type | Resource |
Id | github.pulls.comments |
Fields
Name | Datatype | Description |
---|---|---|
id | integer | The ID of the pull request review comment. |
_links | object | |
author_association | string | How the author is associated with the repository. |
body | string | The text of the comment. |
body_html | string | |
body_text | string | |
commit_id | string | The SHA of the commit to which the comment applies. |
created_at | string | |
diff_hunk | string | The diff of the line that the comment refers to. |
html_url | string | HTML URL for the pull request review comment. |
in_reply_to_id | integer | The comment ID to reply to. |
line | integer | The line of the blob to which the comment applies. The last line of the range for a multi-line comment |
node_id | string | The node ID of the pull request review comment. |
original_commit_id | string | The SHA of the original commit to which the comment applies. |
original_line | integer | The line of the blob to which the comment applies. The last line of the range for a multi-line comment |
original_position | integer | The index of the original line in the diff to which the comment applies. This field is deprecated; use original_line instead. |
original_start_line | integer | The first line of the range for a multi-line comment. |
path | string | The relative path of the file to which the comment applies. |
position | integer | The line index in the diff to which the comment applies. This field is deprecated; use line instead. |
pull_request_review_id | integer | The ID of the pull request review to which the comment belongs. |
pull_request_url | string | URL for the pull request that the review comment belongs to. |
reactions | object | |
side | string | The side of the diff to which the comment applies. The side of the last line of the range for a multi-line comment |
start_line | integer | The first line of the range for a multi-line comment. |
start_side | string | The side of the first line of the range for a multi-line comment. |
subject_type | string | The level at which the comment is targeted, can be a diff line or a file. |
updated_at | string | |
url | string | URL for the pull request review comment |
user | object | A GitHub user. |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get_review_comment | SELECT | comment_id, owner, repo | Provides details for a review comment. |
list_review_comments | SELECT | owner, pull_number, repo | Lists all review comments for a pull request. By default, review comments are in ascending order by ID. |
list_review_comments_for_repo | SELECT | owner, repo | Lists review comments for all pull requests in a repository. By default, review comments are in ascending order by ID. |
create_review_comment | INSERT | owner, pull_number, repo, data__body, data__commit_id, data__path | Creates a review comment in the pull request diff. To add a regular comment to a pull request timeline, see "Create an issue comment." We recommend creating a review comment using line , side , and optionally start_line and start_side if your comment applies to more than one line in the pull request diff.The position parameter is deprecated. If you use position , the line , side , start_line , and start_side parameters are not required.Note: 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 triggers notifications. Creating content too quickly using this endpoint may result in secondary rate limiting. See "Secondary rate limits" and "Dealing with secondary rate limits" for details. |
delete_review_comment | DELETE | comment_id, owner, repo | Deletes a review comment. |
create_reply_for_review_comment | EXEC | comment_id, owner, pull_number, repo, data__body | Creates a reply to a review comment for a pull request. For the comment_id , provide the ID of the review comment you are replying to. This must be the ID of a top-level review comment, not a reply to that comment. Replies to replies are not supported.This endpoint triggers notifications. Creating content too quickly using this endpoint may result in secondary rate limiting. See "Secondary rate limits" and "Dealing with secondary rate limits" for details. |
update_review_comment | EXEC | comment_id, owner, repo, data__body | Enables you to edit a review comment. |