list_source_repository_branches

CodeCatalyst.Client.list_source_repository_branches(**kwargs)

Retrieves a list of branches in a specified source repository.

See also: AWS API Documentation

Request Syntax

response = client.list_source_repository_branches(
    spaceName='string',
    projectName='string',
    sourceRepositoryName='string',
    nextToken='string',
    maxResults=123
)
Parameters
  • spaceName (string) --

    [REQUIRED]

    The name of the space.

  • projectName (string) --

    [REQUIRED]

    The name of the project in the space.

  • sourceRepositoryName (string) --

    [REQUIRED]

    The name of the source repository.

  • nextToken (string) -- A token returned from a call to this API to indicate the next batch of results to return, if any.
  • maxResults (integer) -- The maximum number of results to show in a single call to this API. If the number of results is larger than the number you specified, the response will include a NextToken element, which you can use to obtain additional results.
Return type

dict

Returns

Response Syntax

{
    'nextToken': 'string',
    'items': [
        {
            'ref': 'string',
            'name': 'string',
            'lastUpdatedTime': datetime(2015, 1, 1),
            'headCommitId': 'string'
        },
    ]
}

Response Structure

  • (dict) --

    • nextToken (string) --

      A token returned from a call to this API to indicate the next batch of results to return, if any.

    • items (list) --

      Information about the source branches.

      • (dict) --

        Information about a branch of a source repository returned in a list of branches.

        • ref (string) --

          The Git reference name of the branch.

        • name (string) --

          The name of the branch.

        • lastUpdatedTime (datetime) --

          The time the branch was last updated, in coordinated universal time (UTC) timestamp format as specified in RFC 3339.

        • headCommitId (string) --

          The commit ID of the tip of the branch at the time of the request, also known as the head commit.

Exceptions

  • CodeCatalyst.Client.exceptions.ThrottlingException
  • CodeCatalyst.Client.exceptions.ConflictException
  • CodeCatalyst.Client.exceptions.ValidationException
  • CodeCatalyst.Client.exceptions.ServiceQuotaExceededException
  • CodeCatalyst.Client.exceptions.ResourceNotFoundException
  • CodeCatalyst.Client.exceptions.AccessDeniedException