AWS CodePipeline

2016/07/05 - AWS CodePipeline - 1 new 1 updated api methods

PutApprovalResult (new) Link ¶

Provides the response to a manual approval request to AWS CodePipeline. Valid responses include Approved and Rejected.

Request Syntax

client.put_approval_result(
    pipelineName='string',
    stageName='string',
    actionName='string',
    result={
        'summary': 'string',
        'status': 'Approved'|'Rejected'
    },
    token='string'
)
type pipelineName

string

param pipelineName

[REQUIRED]

The name of the pipeline that contains the action.

type stageName

string

param stageName

[REQUIRED]

The name of the stage that contains the action.

type actionName

string

param actionName

[REQUIRED]

The name of the action for which approval is requested.

type result

dict

param result

[REQUIRED]

Represents information about the result of the approval request.

  • summary (string) -- [REQUIRED]

    The summary of the current status of the approval request.

  • status (string) -- [REQUIRED]

    The response submitted by a reviewer assigned to an approval action request.

type token

string

param token

The system-generated token used to identify a unique approval request. The token for each open approval request can be obtained using the GetPipelineState action and is used to validate that the approval request corresponding to this token is still valid.

rtype

dict

returns

Response Syntax

{
    'approvedAt': datetime(2015, 1, 1)
}

Response Structure

  • (dict) --

    Represents the output of a put approval result action.

    • approvedAt (datetime) --

      The timestamp showing when the approval or rejection was submitted.

GetPipelineState (updated) Link ¶
Changes (response)
{'stageStates': {'actionStates': {'latestExecution': {'lastUpdatedBy': 'string',
                                                      'token': 'string'}}}}

Returns information about the state of a pipeline, including the stages and actions.

Request Syntax

client.get_pipeline_state(
    name='string'
)
type name

string

param name

[REQUIRED]

The name of the pipeline about which you want to get information.

rtype

dict

returns

Response Syntax

{
    'pipelineName': 'string',
    'pipelineVersion': 123,
    'stageStates': [
        {
            'stageName': 'string',
            'inboundTransitionState': {
                'enabled': True|False,
                'lastChangedBy': 'string',
                'lastChangedAt': datetime(2015, 1, 1),
                'disabledReason': 'string'
            },
            'actionStates': [
                {
                    'actionName': 'string',
                    'currentRevision': {
                        'revisionId': 'string',
                        'revisionChangeId': 'string',
                        'created': datetime(2015, 1, 1)
                    },
                    'latestExecution': {
                        'status': 'InProgress'|'Succeeded'|'Failed',
                        'summary': 'string',
                        'lastStatusChange': datetime(2015, 1, 1),
                        'token': 'string',
                        'lastUpdatedBy': 'string',
                        'externalExecutionId': 'string',
                        'externalExecutionUrl': 'string',
                        'percentComplete': 123,
                        'errorDetails': {
                            'code': 'string',
                            'message': 'string'
                        }
                    },
                    'entityUrl': 'string',
                    'revisionUrl': 'string'
                },
            ],
            'latestExecution': {
                'pipelineExecutionId': 'string',
                'status': 'InProgress'|'Failed'|'Succeeded'
            }
        },
    ],
    'created': datetime(2015, 1, 1),
    'updated': datetime(2015, 1, 1)
}

Response Structure

  • (dict) --

    Represents the output of a get pipeline state action.

    • pipelineName (string) --

      The name of the pipeline for which you want to get the state.

    • pipelineVersion (integer) --

      The version number of the pipeline.

      Note

      A newly-created pipeline is always assigned a version number of 1 .

    • stageStates (list) --

      A list of the pipeline stage output information, including stage name, state, most recent run details, whether the stage is disabled, and other data.

      • (dict) --

        Represents information about the state of the stage.

        • stageName (string) --

          The name of the stage.

        • inboundTransitionState (dict) --

          The state of the inbound transition, which is either enabled or disabled.

          • enabled (boolean) --

            Whether the transition between stages is enabled (true) or disabled (false).

          • lastChangedBy (string) --

            The ID of the user who last changed the transition state.

          • lastChangedAt (datetime) --

            The timestamp when the transition state was last changed.

          • disabledReason (string) --

            The user-specified reason why the transition between two stages of a pipeline was disabled.

        • actionStates (list) --

          The state of the stage.

          • (dict) --

            Represents information about the state of an action.

            • actionName (string) --

              The name of the action.

            • currentRevision (dict) --

              Represents information about the version (or revision) of an action.

              • revisionId (string) --

                The system-generated unique ID that identifies the revision number of the action.

              • revisionChangeId (string) --

                The unique identifier of the change that set the state to this revision, for example a deployment ID or timestamp.

              • created (datetime) --

                The date and time when the most recent version of the action was created, in timestamp format.

            • latestExecution (dict) --

              Represents information about the run of an action.

              • status (string) --

                The status of the action, or for a completed action, the last status of the action.

              • summary (string) --

                A summary of the run of the action.

              • lastStatusChange (datetime) --

                The last status change of the action.

              • token (string) --

                The system-generated token used to identify a unique approval request. The token for each open approval request can be obtained using the GetPipelineState command and is used to validate that the approval request corresponding to this token is still valid.

              • lastUpdatedBy (string) --

                The ARN of the user who last changed the pipeline.

              • externalExecutionId (string) --

                The external ID of the run of the action.

              • externalExecutionUrl (string) --

                The URL of a resource external to AWS that will be used when running the action, for example an external repository URL.

              • percentComplete (integer) --

                A percentage of completeness of the action as it runs.

              • errorDetails (dict) --

                The details of an error returned by a URL external to AWS.

                • code (string) --

                  The system ID or error number code of the error.

                • message (string) --

                  The text of the error message.

            • entityUrl (string) --

              A URL link for more information about the state of the action, such as a deployment group details page.

            • revisionUrl (string) --

              A URL link for more information about the revision, such as a commit details page.

        • latestExecution (dict) --

          Information about the latest execution in the stage, including its ID and status.

          • pipelineExecutionId (string) --

            The ID of the pipeline execution associated with the stage.

          • status (string) --

            The status of the stage, or for a completed stage, the last status of the stage.

    • created (datetime) --

      The date and time the pipeline was created, in timestamp format.

    • updated (datetime) --

      The date and time the pipeline was last updated, in timestamp format.