list_pull_requests

list_pull_requests(**kwargs)

Returns a list of pull requests for a specified repository. The return list can be refined by pull request status or pull request author ARN.

See also: AWS API Documentation

Request Syntax

response = client.list_pull_requests(
    repositoryName='string',
    authorArn='string',
    pullRequestStatus='OPEN'|'CLOSED',
    nextToken='string',
    maxResults=123
)
Parameters
  • repositoryName (string) --

    [REQUIRED]

    The name of the repository for which you want to list pull requests.

  • authorArn (string) -- Optional. The Amazon Resource Name (ARN) of the user who created the pull request. If used, this filters the results to pull requests created by that user.
  • pullRequestStatus (string) -- Optional. The status of the pull request. If used, this refines the results to the pull requests that match the specified status.
  • nextToken (string) -- An enumeration token that, when provided in a request, returns the next batch of the results.
  • maxResults (integer) -- A non-zero, non-negative integer used to limit the number of returned results.
Return type

dict

Returns

Response Syntax

{
    'pullRequestIds': [
        'string',
    ],
    'nextToken': 'string'
}

Response Structure

  • (dict) --

    • pullRequestIds (list) --

      The system-generated IDs of the pull requests.

      • (string) --
    • nextToken (string) --

      An enumeration token that allows the operation to batch the next results of the operation.

Exceptions

  • CodeCommit.Client.exceptions.InvalidPullRequestStatusException
  • CodeCommit.Client.exceptions.InvalidAuthorArnException
  • CodeCommit.Client.exceptions.AuthorDoesNotExistException
  • CodeCommit.Client.exceptions.RepositoryNameRequiredException
  • CodeCommit.Client.exceptions.InvalidRepositoryNameException
  • CodeCommit.Client.exceptions.RepositoryDoesNotExistException
  • CodeCommit.Client.exceptions.InvalidMaxResultsException
  • CodeCommit.Client.exceptions.InvalidContinuationTokenException
  • CodeCommit.Client.exceptions.EncryptionIntegrityChecksFailedException
  • CodeCommit.Client.exceptions.EncryptionKeyAccessDeniedException
  • CodeCommit.Client.exceptions.EncryptionKeyDisabledException
  • CodeCommit.Client.exceptions.EncryptionKeyNotFoundException
  • CodeCommit.Client.exceptions.EncryptionKeyUnavailableException