Jump to Content

New API Documentation - Developer Preview Available

We are excited to announce the developer preview of our new API documentation for AWS SDK for JavaScript v3. Please follow instructions on the landing page to leave us your feedback.

Class UpdatePipelineCommandProtected

Updates a specified pipeline with edits or changes to its structure. Use a JSON file with the pipeline structure and UpdatePipeline to provide the full structure of the pipeline. Updating the pipeline increases the version number of the pipeline by 1.

Example

Use a bare-bones client and the command you need to make an API call.

import { CodePipelineClient, UpdatePipelineCommand } from "@aws-sdk/client-codepipeline"; // ES Modules import
// const { CodePipelineClient, UpdatePipelineCommand } = require("@aws-sdk/client-codepipeline"); // CommonJS import
const client = new CodePipelineClient(config);
const input = { // UpdatePipelineInput
pipeline: { // PipelineDeclaration
name: "STRING_VALUE", // required
roleArn: "STRING_VALUE", // required
artifactStore: { // ArtifactStore
type: "S3", // required
location: "STRING_VALUE", // required
encryptionKey: { // EncryptionKey
id: "STRING_VALUE", // required
type: "KMS", // required
},
},
artifactStores: { // ArtifactStoreMap
"<keys>": {
type: "S3", // required
location: "STRING_VALUE", // required
encryptionKey: {
id: "STRING_VALUE", // required
type: "KMS", // required
},
},
},
stages: [ // PipelineStageDeclarationList // required
{ // StageDeclaration
name: "STRING_VALUE", // required
blockers: [ // StageBlockerDeclarationList
{ // BlockerDeclaration
name: "STRING_VALUE", // required
type: "Schedule", // required
},
],
actions: [ // StageActionDeclarationList // required
{ // ActionDeclaration
name: "STRING_VALUE", // required
actionTypeId: { // ActionTypeId
category: "Source" || "Build" || "Deploy" || "Test" || "Invoke" || "Approval", // required
owner: "AWS" || "ThirdParty" || "Custom", // required
provider: "STRING_VALUE", // required
version: "STRING_VALUE", // required
},
runOrder: Number("int"),
configuration: { // ActionConfigurationMap
"<keys>": "STRING_VALUE",
},
outputArtifacts: [ // OutputArtifactList
{ // OutputArtifact
name: "STRING_VALUE", // required
},
],
inputArtifacts: [ // InputArtifactList
{ // InputArtifact
name: "STRING_VALUE", // required
},
],
roleArn: "STRING_VALUE",
region: "STRING_VALUE",
namespace: "STRING_VALUE",
},
],
},
],
version: Number("int"),
},
};
const command = new UpdatePipelineCommand(input);
const response = await client.send(command);
// { // UpdatePipelineOutput
// pipeline: { // PipelineDeclaration
// name: "STRING_VALUE", // required
// roleArn: "STRING_VALUE", // required
// artifactStore: { // ArtifactStore
// type: "S3", // required
// location: "STRING_VALUE", // required
// encryptionKey: { // EncryptionKey
// id: "STRING_VALUE", // required
// type: "KMS", // required
// },
// },
// artifactStores: { // ArtifactStoreMap
// "<keys>": {
// type: "S3", // required
// location: "STRING_VALUE", // required
// encryptionKey: {
// id: "STRING_VALUE", // required
// type: "KMS", // required
// },
// },
// },
// stages: [ // PipelineStageDeclarationList // required
// { // StageDeclaration
// name: "STRING_VALUE", // required
// blockers: [ // StageBlockerDeclarationList
// { // BlockerDeclaration
// name: "STRING_VALUE", // required
// type: "Schedule", // required
// },
// ],
// actions: [ // StageActionDeclarationList // required
// { // ActionDeclaration
// name: "STRING_VALUE", // required
// actionTypeId: { // ActionTypeId
// category: "Source" || "Build" || "Deploy" || "Test" || "Invoke" || "Approval", // required
// owner: "AWS" || "ThirdParty" || "Custom", // required
// provider: "STRING_VALUE", // required
// version: "STRING_VALUE", // required
// },
// runOrder: Number("int"),
// configuration: { // ActionConfigurationMap
// "<keys>": "STRING_VALUE",
// },
// outputArtifacts: [ // OutputArtifactList
// { // OutputArtifact
// name: "STRING_VALUE", // required
// },
// ],
// inputArtifacts: [ // InputArtifactList
// { // InputArtifact
// name: "STRING_VALUE", // required
// },
// ],
// roleArn: "STRING_VALUE",
// region: "STRING_VALUE",
// namespace: "STRING_VALUE",
// },
// ],
// },
// ],
// version: Number("int"),
// },
// };

Param

UpdatePipelineCommandInput

Returns

UpdatePipelineCommandOutput

See

Throws

InvalidActionDeclarationException (client fault)

The action declaration was specified in an invalid format.

Throws

InvalidBlockerDeclarationException (client fault)

Reserved for future use.

Throws

InvalidStageDeclarationException (client fault)

The stage declaration was specified in an invalid format.

Throws

InvalidStructureException (client fault)

The structure was specified in an invalid format.

Throws

LimitExceededException (client fault)

The number of pipelines associated with the Amazon Web Services account has exceeded the limit allowed for the account.

Throws

ValidationException (client fault)

The validation was specified in an invalid format.

Throws

CodePipelineServiceException

Base exception class for all service exceptions from CodePipeline service.

Hierarchy

Constructors

Properties

middlewareStack: MiddlewareStack<UpdatePipelineCommandInput, UpdatePipelineCommandOutput>

Methods