AWS CodeBuild

2019/12/13 - AWS CodeBuild - 5 new api methods

Changes  Update codebuild client to latest version

DeleteResourcePolicy (new) Link ¶

Deletes a resource policy that is identified by its resource ARN.

See also: AWS API Documentation

Request Syntax

client.delete_resource_policy(
    resourceArn='string'
)
type resourceArn:

string

param resourceArn:

[REQUIRED]

The ARN of the resource that is associated with the resource policy.

rtype:

dict

returns:

Response Syntax

{}

Response Structure

  • (dict) --

PutResourcePolicy (new) Link ¶

Stores a resource policy for the ARN of a Project or ReportGroup object.

See also: AWS API Documentation

Request Syntax

client.put_resource_policy(
    policy='string',
    resourceArn='string'
)
type policy:

string

param policy:

[REQUIRED]

A JSON-formatted resource policy. For more information, see Sharing a Project and Sharing a Report Group in the AWS CodeBuild User Guide.

type resourceArn:

string

param resourceArn:

[REQUIRED]

The ARN of the Project or ReportGroup resource you want to associate with a resource policy.

rtype:

dict

returns:

Response Syntax

{
    'resourceArn': 'string'
}

Response Structure

  • (dict) --

    • resourceArn (string) --

      The ARN of the Project or ReportGroup resource that is associated with a resource policy.

ListSharedReportGroups (new) Link ¶

Gets a list of report groups that are shared with other AWS accounts or users.

See also: AWS API Documentation

Request Syntax

client.list_shared_report_groups(
    sortOrder='ASCENDING'|'DESCENDING',
    sortBy='ARN'|'MODIFIED_TIME',
    nextToken='string',
    maxResults=123
)
type sortOrder:

string

param sortOrder:

The order in which to list shared report groups. Valid values include:

  • ASCENDING: List in ascending order.

  • DESCENDING: List in descending order.

type sortBy:

string

param sortBy:

The criterion to be used to list report groups shared with the current AWS account or user. Valid values include:

  • ARN: List based on the ARN.

  • MODIFIED_TIME: List based on when information about the shared report group was last changed.

type nextToken:

string

param nextToken:

During a previous call, the maximum number of items that can be returned is the value specified in maxResults. If there more items in the list, then a unique string called a nextToken is returned. To get the next batch of items in the list, call this operation again, adding the next token to the call. To get all of the items in the list, keep calling this operation with each subsequent next token that is returned, until no more next tokens are returned.

type maxResults:

integer

param maxResults:

The maximum number of paginated shared report groups per response. Use nextToken to iterate pages in the list of returned ReportGroup objects. The default value is 100.

rtype:

dict

returns:

Response Syntax

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

Response Structure

  • (dict) --

    • nextToken (string) --

      During a previous call, the maximum number of items that can be returned is the value specified in maxResults. If there more items in the list, then a unique string called a nextToken is returned. To get the next batch of items in the list, call this operation again, adding the next token to the call. To get all of the items in the list, keep calling this operation with each subsequent next token that is returned, until no more next tokens are returned.

    • reportGroups (list) --

      The list of ARNs for the report groups shared with the current AWS account or user.

      • (string) --

GetResourcePolicy (new) Link ¶

Gets a resource policy that is identified by its resource ARN.

See also: AWS API Documentation

Request Syntax

client.get_resource_policy(
    resourceArn='string'
)
type resourceArn:

string

param resourceArn:

[REQUIRED]

The ARN of the resource that is associated with the resource policy.

rtype:

dict

returns:

Response Syntax

{
    'policy': 'string'
}

Response Structure

  • (dict) --

    • policy (string) --

      The resource policy for the resource identified by the input ARN parameter.

ListSharedProjects (new) Link ¶

Gets a list of projects that are shared with other AWS accounts or users.

See also: AWS API Documentation

Request Syntax

client.list_shared_projects(
    sortBy='ARN'|'MODIFIED_TIME',
    sortOrder='ASCENDING'|'DESCENDING',
    maxResults=123,
    nextToken='string'
)
type sortBy:

string

param sortBy:

The criterion to be used to list build projects shared with the current AWS account or user. Valid values include:

  • ARN: List based on the ARN.

  • MODIFIED_TIME: List based on when information about the shared project was last changed.

type sortOrder:

string

param sortOrder:

The order in which to list shared build projects. Valid values include:

  • ASCENDING: List in ascending order.

  • DESCENDING: List in descending order.

type maxResults:

integer

param maxResults:

The maximum number of paginated shared build projects returned per response. Use nextToken to iterate pages in the list of returned Project objects. The default value is 100.

type nextToken:

string

param nextToken:

During a previous call, the maximum number of items that can be returned is the value specified in maxResults. If there more items in the list, then a unique string called a nextToken is returned. To get the next batch of items in the list, call this operation again, adding the next token to the call. To get all of the items in the list, keep calling this operation with each subsequent next token that is returned, until no more next tokens are returned.

rtype:

dict

returns:

Response Syntax

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

Response Structure

  • (dict) --

    • nextToken (string) --

      During a previous call, the maximum number of items that can be returned is the value specified in maxResults. If there more items in the list, then a unique string called a nextToken is returned. To get the next batch of items in the list, call this operation again, adding the next token to the call. To get all of the items in the list, keep calling this operation with each subsequent next token that is returned, until no more next tokens are returned.

    • projects (list) --

      The list of ARNs for the build projects shared with the current AWS account or user.

      • (string) --