Struct roctogen::endpoints::pulls::Pulls [−][src]
pub struct Pulls<'api> { /* fields omitted */ }
Implementations
pub async fn check_if_merged_async(
&self,
owner: &str,
repo: &str,
pull_number: i32
) -> Result<(), PullsCheckIfMergedError>
pub async fn check_if_merged_async(
&self,
owner: &str,
repo: &str,
pull_number: i32
) -> Result<(), PullsCheckIfMergedError>
pub fn check_if_merged(
&self,
owner: &str,
repo: &str,
pull_number: i32
) -> Result<(), PullsCheckIfMergedError>
pub fn check_if_merged(
&self,
owner: &str,
repo: &str,
pull_number: i32
) -> Result<(), PullsCheckIfMergedError>
pub async fn create_async(
&self,
owner: &str,
repo: &str,
body: PostPullsCreate
) -> Result<PullRequest, PullsCreateError>
pub async fn create_async(
&self,
owner: &str,
repo: &str,
body: PostPullsCreate
) -> Result<PullRequest, PullsCreateError>
Create a pull request
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 GitHub’s products 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.
You can create a new pull request.
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.
pub fn create(
&self,
owner: &str,
repo: &str,
body: PostPullsCreate
) -> Result<PullRequest, PullsCreateError>
pub fn create(
&self,
owner: &str,
repo: &str,
body: PostPullsCreate
) -> Result<PullRequest, PullsCreateError>
Create a pull request
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 GitHub’s products 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.
You can create a new pull request.
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.
pub async fn create_reply_for_review_comment_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
comment_id: i32,
body: PostPullsCreateReplyForReviewComment
) -> Result<PullRequestReviewComment, PullsCreateReplyForReviewCommentError>
pub async fn create_reply_for_review_comment_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
comment_id: i32,
body: PostPullsCreateReplyForReviewComment
) -> Result<PullRequestReviewComment, PullsCreateReplyForReviewCommentError>
Create a reply for a review comment
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.
GitHub API docs for create_reply_for_review_comment
pub fn create_reply_for_review_comment(
&self,
owner: &str,
repo: &str,
pull_number: i32,
comment_id: i32,
body: PostPullsCreateReplyForReviewComment
) -> Result<PullRequestReviewComment, PullsCreateReplyForReviewCommentError>
pub fn create_reply_for_review_comment(
&self,
owner: &str,
repo: &str,
pull_number: i32,
comment_id: i32,
body: PostPullsCreateReplyForReviewComment
) -> Result<PullRequestReviewComment, PullsCreateReplyForReviewCommentError>
Create a reply for a review comment
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.
GitHub API docs for create_reply_for_review_comment
pub async fn create_review_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PostPullsCreateReview
) -> Result<PullRequestReview, PullsCreateReviewError>
pub async fn create_review_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PostPullsCreateReview
) -> Result<PullRequestReview, PullsCreateReviewError>
Create a review for a pull request
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.
Pull request reviews created in the PENDING
state do not include the submitted_at
property in the response.
Note: To comment on a specific line in a file, you need to first determine the position of that line in the diff. The GitHub REST API v3 offers the application/vnd.github.v3.diff
media type. To see a pull request diff, add this media type to the Accept
header of a call to the single 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.
GitHub API docs for create_review
pub fn create_review(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PostPullsCreateReview
) -> Result<PullRequestReview, PullsCreateReviewError>
pub fn create_review(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PostPullsCreateReview
) -> Result<PullRequestReview, PullsCreateReviewError>
Create a review for a pull request
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.
Pull request reviews created in the PENDING
state do not include the submitted_at
property in the response.
Note: To comment on a specific line in a file, you need to first determine the position of that line in the diff. The GitHub REST API v3 offers the application/vnd.github.v3.diff
media type. To see a pull request diff, add this media type to the Accept
header of a call to the single 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.
GitHub API docs for create_review
pub async fn create_review_comment_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PostPullsCreateReviewComment
) -> Result<PullRequestReviewComment, PullsCreateReviewCommentError>
pub async fn create_review_comment_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PostPullsCreateReviewComment
) -> Result<PullRequestReviewComment, PullsCreateReviewCommentError>
Create a review comment for a pull request
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.
You can still create a review comment using the position
parameter. When 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.
GitHub API docs for create_review_comment
pub fn create_review_comment(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PostPullsCreateReviewComment
) -> Result<PullRequestReviewComment, PullsCreateReviewCommentError>
pub fn create_review_comment(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PostPullsCreateReviewComment
) -> Result<PullRequestReviewComment, PullsCreateReviewCommentError>
Create a review comment for a pull request
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.
You can still create a review comment using the position
parameter. When 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.
GitHub API docs for create_review_comment
pub async fn delete_pending_review_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32
) -> Result<PullRequestReview, PullsDeletePendingReviewError>
pub async fn delete_pending_review_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32
) -> Result<PullRequestReview, PullsDeletePendingReviewError>
pub fn delete_pending_review(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32
) -> Result<PullRequestReview, PullsDeletePendingReviewError>
pub fn delete_pending_review(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32
) -> Result<PullRequestReview, PullsDeletePendingReviewError>
pub async fn delete_review_comment_async(
&self,
owner: &str,
repo: &str,
comment_id: i32
) -> Result<(), PullsDeleteReviewCommentError>
pub async fn delete_review_comment_async(
&self,
owner: &str,
repo: &str,
comment_id: i32
) -> Result<(), PullsDeleteReviewCommentError>
Delete a review comment for a pull request
Deletes a review comment.
GitHub API docs for delete_review_comment
pub fn delete_review_comment(
&self,
owner: &str,
repo: &str,
comment_id: i32
) -> Result<(), PullsDeleteReviewCommentError>
pub fn delete_review_comment(
&self,
owner: &str,
repo: &str,
comment_id: i32
) -> Result<(), PullsDeleteReviewCommentError>
Delete a review comment for a pull request
Deletes a review comment.
GitHub API docs for delete_review_comment
pub async fn dismiss_review_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
body: PutPullsDismissReview
) -> Result<PullRequestReview, PullsDismissReviewError>
pub async fn dismiss_review_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
body: PutPullsDismissReview
) -> Result<PullRequestReview, PullsDismissReviewError>
Dismiss a review for 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.
GitHub API docs for dismiss_review
pub fn dismiss_review(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
body: PutPullsDismissReview
) -> Result<PullRequestReview, PullsDismissReviewError>
pub fn dismiss_review(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
body: PutPullsDismissReview
) -> Result<PullRequestReview, PullsDismissReviewError>
Dismiss a review for 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.
GitHub API docs for dismiss_review
pub async fn get_async(
&self,
owner: &str,
repo: &str,
pull_number: i32
) -> Result<PullRequest, PullsGetError>
pub async fn get_async(
&self,
owner: &str,
repo: &str,
pull_number: i32
) -> Result<PullRequest, PullsGetError>
Get a pull request
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 GitHub’s products in the GitHub Help documentation.
Lists details of a pull request by providing its number.
When you get, create, or edit a pull request, GitHub creates a merge commit to test whether the pull request can be automatically merged into the base branch. This test commit is not added to the base branch or the head branch. You can review the status of the test commit using the mergeable
key. For more information, see “Checking mergeability of pull requests”.
The value of the mergeable
attribute can be true
, false
, or null
. If the value is null
, then GitHub has started a background job to compute the mergeability. After giving the job time to complete, resubmit the request. When the job finishes, you will see a non-null
value for the mergeable
attribute in the response. If mergeable
is true
, then merge_commit_sha
will be the SHA of the test merge commit.
The value of the merge_commit_sha
attribute changes depending on the state of the pull request. Before merging a pull request, the merge_commit_sha
attribute holds the SHA of the test merge commit. After merging a pull request, the merge_commit_sha
attribute changes depending on how you merged the pull request:
- If merged as a merge commit,
merge_commit_sha
represents the SHA of the merge commit. - If merged via a squash,
merge_commit_sha
represents the SHA of the squashed commit on the base branch. - If rebased,
merge_commit_sha
represents the commit that the base branch was updated to.
Pass the appropriate media type to fetch diff and patch formats.
pub fn get(
&self,
owner: &str,
repo: &str,
pull_number: i32
) -> Result<PullRequest, PullsGetError>
pub fn get(
&self,
owner: &str,
repo: &str,
pull_number: i32
) -> Result<PullRequest, PullsGetError>
Get a pull request
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 GitHub’s products in the GitHub Help documentation.
Lists details of a pull request by providing its number.
When you get, create, or edit a pull request, GitHub creates a merge commit to test whether the pull request can be automatically merged into the base branch. This test commit is not added to the base branch or the head branch. You can review the status of the test commit using the mergeable
key. For more information, see “Checking mergeability of pull requests”.
The value of the mergeable
attribute can be true
, false
, or null
. If the value is null
, then GitHub has started a background job to compute the mergeability. After giving the job time to complete, resubmit the request. When the job finishes, you will see a non-null
value for the mergeable
attribute in the response. If mergeable
is true
, then merge_commit_sha
will be the SHA of the test merge commit.
The value of the merge_commit_sha
attribute changes depending on the state of the pull request. Before merging a pull request, the merge_commit_sha
attribute holds the SHA of the test merge commit. After merging a pull request, the merge_commit_sha
attribute changes depending on how you merged the pull request:
- If merged as a merge commit,
merge_commit_sha
represents the SHA of the merge commit. - If merged via a squash,
merge_commit_sha
represents the SHA of the squashed commit on the base branch. - If rebased,
merge_commit_sha
represents the commit that the base branch was updated to.
Pass the appropriate media type to fetch diff and patch formats.
pub async fn get_review_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32
) -> Result<PullRequestReview, PullsGetReviewError>
pub async fn get_review_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32
) -> Result<PullRequestReview, PullsGetReviewError>
pub fn get_review(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32
) -> Result<PullRequestReview, PullsGetReviewError>
pub fn get_review(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32
) -> Result<PullRequestReview, PullsGetReviewError>
pub async fn get_review_comment_async(
&self,
owner: &str,
repo: &str,
comment_id: i32
) -> Result<PullRequestReviewComment, PullsGetReviewCommentError>
pub async fn get_review_comment_async(
&self,
owner: &str,
repo: &str,
comment_id: i32
) -> Result<PullRequestReviewComment, PullsGetReviewCommentError>
Get a review comment for a pull request
Provides details for a review comment.
GitHub API docs for get_review_comment
pub fn get_review_comment(
&self,
owner: &str,
repo: &str,
comment_id: i32
) -> Result<PullRequestReviewComment, PullsGetReviewCommentError>
pub fn get_review_comment(
&self,
owner: &str,
repo: &str,
comment_id: i32
) -> Result<PullRequestReviewComment, PullsGetReviewCommentError>
Get a review comment for a pull request
Provides details for a review comment.
GitHub API docs for get_review_comment
pub async fn list_async(
&self,
owner: &str,
repo: &str,
query_params: Option<impl Into<PullsListParams<'api>>>
) -> Result<Vec<PullRequestSimple>, PullsListError>
pub async fn list_async(
&self,
owner: &str,
repo: &str,
query_params: Option<impl Into<PullsListParams<'api>>>
) -> Result<Vec<PullRequestSimple>, PullsListError>
List pull requests
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 GitHub’s products in the GitHub Help documentation.
pub fn list(
&self,
owner: &str,
repo: &str,
query_params: Option<impl Into<PullsListParams<'api>>>
) -> Result<Vec<PullRequestSimple>, PullsListError>
pub fn list(
&self,
owner: &str,
repo: &str,
query_params: Option<impl Into<PullsListParams<'api>>>
) -> Result<Vec<PullRequestSimple>, PullsListError>
List pull requests
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 GitHub’s products in the GitHub Help documentation.
pub async fn list_comments_for_review_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
query_params: Option<impl Into<PullsListCommentsForReviewParams>>
) -> Result<Vec<ReviewComment>, PullsListCommentsForReviewError>
pub async fn list_comments_for_review_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
query_params: Option<impl Into<PullsListCommentsForReviewParams>>
) -> Result<Vec<ReviewComment>, PullsListCommentsForReviewError>
List comments for a pull request review
List comments for a specific pull request review.
GitHub API docs for list_comments_for_review
pub fn list_comments_for_review(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
query_params: Option<impl Into<PullsListCommentsForReviewParams>>
) -> Result<Vec<ReviewComment>, PullsListCommentsForReviewError>
pub fn list_comments_for_review(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
query_params: Option<impl Into<PullsListCommentsForReviewParams>>
) -> Result<Vec<ReviewComment>, PullsListCommentsForReviewError>
List comments for a pull request review
List comments for a specific pull request review.
GitHub API docs for list_comments_for_review
pub async fn list_commits_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListCommitsParams>>
) -> Result<Vec<Commit>, PullsListCommitsError>
pub async fn list_commits_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListCommitsParams>>
) -> Result<Vec<Commit>, PullsListCommitsError>
List commits on a pull request
Lists a maximum of 250 commits for a pull request. To receive a complete commit list for pull requests with more than 250 commits, use the List commits endpoint.
GitHub API docs for list_commits
pub fn list_commits(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListCommitsParams>>
) -> Result<Vec<Commit>, PullsListCommitsError>
pub fn list_commits(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListCommitsParams>>
) -> Result<Vec<Commit>, PullsListCommitsError>
List commits on a pull request
Lists a maximum of 250 commits for a pull request. To receive a complete commit list for pull requests with more than 250 commits, use the List commits endpoint.
GitHub API docs for list_commits
pub async fn list_files_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListFilesParams>>
) -> Result<Vec<DiffEntry>, PullsListFilesError>
pub async fn list_files_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListFilesParams>>
) -> Result<Vec<DiffEntry>, PullsListFilesError>
List pull requests files
Note: Responses include a maximum of 3000 files. The paginated response returns 30 files per page by default.
GitHub API docs for list_files
pub fn list_files(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListFilesParams>>
) -> Result<Vec<DiffEntry>, PullsListFilesError>
pub fn list_files(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListFilesParams>>
) -> Result<Vec<DiffEntry>, PullsListFilesError>
List pull requests files
Note: Responses include a maximum of 3000 files. The paginated response returns 30 files per page by default.
GitHub API docs for list_files
pub async fn list_requested_reviewers_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListRequestedReviewersParams>>
) -> Result<PullRequestReviewRequest, PullsListRequestedReviewersError>
pub async fn list_requested_reviewers_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListRequestedReviewersParams>>
) -> Result<PullRequestReviewRequest, PullsListRequestedReviewersError>
pub fn list_requested_reviewers(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListRequestedReviewersParams>>
) -> Result<PullRequestReviewRequest, PullsListRequestedReviewersError>
pub fn list_requested_reviewers(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListRequestedReviewersParams>>
) -> Result<PullRequestReviewRequest, PullsListRequestedReviewersError>
pub async fn list_review_comments_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListReviewCommentsParams<'api>>>
) -> Result<Vec<PullRequestReviewComment>, PullsListReviewCommentsError>
pub async fn list_review_comments_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListReviewCommentsParams<'api>>>
) -> Result<Vec<PullRequestReviewComment>, PullsListReviewCommentsError>
List review comments on a pull request
Lists all review comments for a pull request. By default, review comments are in ascending order by ID.
GitHub API docs for list_review_comments
pub fn list_review_comments(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListReviewCommentsParams<'api>>>
) -> Result<Vec<PullRequestReviewComment>, PullsListReviewCommentsError>
pub fn list_review_comments(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListReviewCommentsParams<'api>>>
) -> Result<Vec<PullRequestReviewComment>, PullsListReviewCommentsError>
List review comments on a pull request
Lists all review comments for a pull request. By default, review comments are in ascending order by ID.
GitHub API docs for list_review_comments
pub async fn list_review_comments_for_repo_async(
&self,
owner: &str,
repo: &str,
query_params: Option<impl Into<PullsListReviewCommentsForRepoParams<'api>>>
) -> Result<Vec<PullRequestReviewComment>, PullsListReviewCommentsForRepoError>
pub async fn list_review_comments_for_repo_async(
&self,
owner: &str,
repo: &str,
query_params: Option<impl Into<PullsListReviewCommentsForRepoParams<'api>>>
) -> Result<Vec<PullRequestReviewComment>, PullsListReviewCommentsForRepoError>
List review comments in a repository
Lists review comments for all pull requests in a repository. By default, review comments are in ascending order by ID.
GitHub API docs for list_review_comments_for_repo
pub fn list_review_comments_for_repo(
&self,
owner: &str,
repo: &str,
query_params: Option<impl Into<PullsListReviewCommentsForRepoParams<'api>>>
) -> Result<Vec<PullRequestReviewComment>, PullsListReviewCommentsForRepoError>
pub fn list_review_comments_for_repo(
&self,
owner: &str,
repo: &str,
query_params: Option<impl Into<PullsListReviewCommentsForRepoParams<'api>>>
) -> Result<Vec<PullRequestReviewComment>, PullsListReviewCommentsForRepoError>
List review comments in a repository
Lists review comments for all pull requests in a repository. By default, review comments are in ascending order by ID.
GitHub API docs for list_review_comments_for_repo
pub async fn list_reviews_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListReviewsParams>>
) -> Result<Vec<PullRequestReview>, PullsListReviewsError>
pub async fn list_reviews_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListReviewsParams>>
) -> Result<Vec<PullRequestReview>, PullsListReviewsError>
List reviews for a pull request
The list of reviews returns in chronological order.
GitHub API docs for list_reviews
pub fn list_reviews(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListReviewsParams>>
) -> Result<Vec<PullRequestReview>, PullsListReviewsError>
pub fn list_reviews(
&self,
owner: &str,
repo: &str,
pull_number: i32,
query_params: Option<impl Into<PullsListReviewsParams>>
) -> Result<Vec<PullRequestReview>, PullsListReviewsError>
List reviews for a pull request
The list of reviews returns in chronological order.
GitHub API docs for list_reviews
pub async fn merge_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PutPullsMerge
) -> Result<PullRequestMergeResult, PullsMergeError>
pub async fn merge_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PutPullsMerge
) -> Result<PullRequestMergeResult, PullsMergeError>
Merge a pull request
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.
pub fn merge(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PutPullsMerge
) -> Result<PullRequestMergeResult, PullsMergeError>
pub fn merge(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PutPullsMerge
) -> Result<PullRequestMergeResult, PullsMergeError>
Merge a pull request
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.
pub async fn remove_requested_reviewers_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: DeletePullsRemoveRequestedReviewers
) -> Result<PullRequestSimple, PullsRemoveRequestedReviewersError>
pub async fn remove_requested_reviewers_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: DeletePullsRemoveRequestedReviewers
) -> Result<PullRequestSimple, PullsRemoveRequestedReviewersError>
pub fn remove_requested_reviewers(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: DeletePullsRemoveRequestedReviewers
) -> Result<PullRequestSimple, PullsRemoveRequestedReviewersError>
pub fn remove_requested_reviewers(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: DeletePullsRemoveRequestedReviewers
) -> Result<PullRequestSimple, PullsRemoveRequestedReviewersError>
pub async fn request_reviewers_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PostPullsRequestReviewers
) -> Result<PullRequestSimple, PullsRequestReviewersError>
pub async fn request_reviewers_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PostPullsRequestReviewers
) -> Result<PullRequestSimple, PullsRequestReviewersError>
Request reviewers for a pull request
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.
GitHub API docs for request_reviewers
pub fn request_reviewers(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PostPullsRequestReviewers
) -> Result<PullRequestSimple, PullsRequestReviewersError>
pub fn request_reviewers(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PostPullsRequestReviewers
) -> Result<PullRequestSimple, PullsRequestReviewersError>
Request reviewers for a pull request
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.
GitHub API docs for request_reviewers
pub async fn submit_review_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
body: PostPullsSubmitReview
) -> Result<PullRequestReview, PullsSubmitReviewError>
pub async fn submit_review_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
body: PostPullsSubmitReview
) -> Result<PullRequestReview, PullsSubmitReviewError>
pub fn submit_review(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
body: PostPullsSubmitReview
) -> Result<PullRequestReview, PullsSubmitReviewError>
pub fn submit_review(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
body: PostPullsSubmitReview
) -> Result<PullRequestReview, PullsSubmitReviewError>
pub async fn update_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PatchPullsUpdate
) -> Result<PullRequest, PullsUpdateError>
pub async fn update_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PatchPullsUpdate
) -> Result<PullRequest, PullsUpdateError>
Update a pull request
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 GitHub’s products 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.
pub fn update(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PatchPullsUpdate
) -> Result<PullRequest, PullsUpdateError>
pub fn update(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PatchPullsUpdate
) -> Result<PullRequest, PullsUpdateError>
Update a pull request
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 GitHub’s products 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.
pub async fn update_branch_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PutPullsUpdateBranch
) -> Result<PutPullsUpdateBranchResponse202, PullsUpdateBranchError>
pub async fn update_branch_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PutPullsUpdateBranch
) -> Result<PutPullsUpdateBranchResponse202, PullsUpdateBranchError>
Update a pull request branch
Updates the pull request branch with the latest upstream changes by merging HEAD from the base branch into the pull request branch.
GitHub API docs for update_branch
pub fn update_branch(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PutPullsUpdateBranch
) -> Result<PutPullsUpdateBranchResponse202, PullsUpdateBranchError>
pub fn update_branch(
&self,
owner: &str,
repo: &str,
pull_number: i32,
body: PutPullsUpdateBranch
) -> Result<PutPullsUpdateBranchResponse202, PullsUpdateBranchError>
Update a pull request branch
Updates the pull request branch with the latest upstream changes by merging HEAD from the base branch into the pull request branch.
GitHub API docs for update_branch
pub async fn update_review_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
body: PutPullsUpdateReview
) -> Result<PullRequestReview, PullsUpdateReviewError>
pub async fn update_review_async(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
body: PutPullsUpdateReview
) -> Result<PullRequestReview, PullsUpdateReviewError>
Update a review for a pull request
Update the review summary comment with new text.
GitHub API docs for update_review
pub fn update_review(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
body: PutPullsUpdateReview
) -> Result<PullRequestReview, PullsUpdateReviewError>
pub fn update_review(
&self,
owner: &str,
repo: &str,
pull_number: i32,
review_id: i32,
body: PutPullsUpdateReview
) -> Result<PullRequestReview, PullsUpdateReviewError>
Update a review for a pull request
Update the review summary comment with new text.
GitHub API docs for update_review
pub async fn update_review_comment_async(
&self,
owner: &str,
repo: &str,
comment_id: i32,
body: PatchPullsUpdateReviewComment
) -> Result<PullRequestReviewComment, PullsUpdateReviewCommentError>
pub async fn update_review_comment_async(
&self,
owner: &str,
repo: &str,
comment_id: i32,
body: PatchPullsUpdateReviewComment
) -> Result<PullRequestReviewComment, PullsUpdateReviewCommentError>
Update a review comment for a pull request
Enables you to edit a review comment.
GitHub API docs for update_review_comment
pub fn update_review_comment(
&self,
owner: &str,
repo: &str,
comment_id: i32,
body: PatchPullsUpdateReviewComment
) -> Result<PullRequestReviewComment, PullsUpdateReviewCommentError>
pub fn update_review_comment(
&self,
owner: &str,
repo: &str,
comment_id: i32,
body: PatchPullsUpdateReviewComment
) -> Result<PullRequestReviewComment, PullsUpdateReviewCommentError>
Update a review comment for a pull request
Enables you to edit a review comment.
GitHub API docs for update_review_comment