get_pull_request_approval_states

CodeCommit.Client.get_pull_request_approval_states(**kwargs)

Gets information about the approval states for a specified pull request. Approval states only apply to pull requests that have one or more approval rules applied to them.

See also: AWS API Documentation

Request Syntax

response = client.get_pull_request_approval_states(
    pullRequestId='string',
    revisionId='string'
)
Parameters
  • pullRequestId (string) --

    [REQUIRED]

    The system-generated ID for the pull request.

  • revisionId (string) --

    [REQUIRED]

    The system-generated ID for the pull request revision.

Return type

dict

Returns

Response Syntax

{
    'approvals': [
        {
            'userArn': 'string',
            'approvalState': 'APPROVE'|'REVOKE'
        },
    ]
}

Response Structure

  • (dict) --

    • approvals (list) --

      Information about users who have approved the pull request.

      • (dict) --

        Returns information about a specific approval on a pull request.

        • userArn (string) --

          The Amazon Resource Name (ARN) of the user.

        • approvalState (string) --

          The state of the approval, APPROVE or REVOKE. REVOKE states are not stored.

Exceptions

  • CodeCommit.Client.exceptions.PullRequestDoesNotExistException
  • CodeCommit.Client.exceptions.InvalidPullRequestIdException
  • CodeCommit.Client.exceptions.PullRequestIdRequiredException
  • CodeCommit.Client.exceptions.InvalidRevisionIdException
  • CodeCommit.Client.exceptions.RevisionIdRequiredException
  • CodeCommit.Client.exceptions.EncryptionIntegrityChecksFailedException
  • CodeCommit.Client.exceptions.EncryptionKeyAccessDeniedException
  • CodeCommit.Client.exceptions.EncryptionKeyDisabledException
  • CodeCommit.Client.exceptions.EncryptionKeyNotFoundException
  • CodeCommit.Client.exceptions.EncryptionKeyUnavailableException