Skip to content
v2.278.0

PipelineTriggerDeclarationProperty ​

Struct External

Represents information about the specified trigger configuration, such as the filter criteria and the source stage for the action that contains the trigger.

This is only supported for the CodeStarSourceConnection action type. > When a trigger configuration is specified, default change detection for repository and branch commits is disabled.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_codepipeline as codepipeline } from 'aws-cdk-lib';
const pipelineTriggerDeclarationProperty: codepipeline.CfnPipeline.PipelineTriggerDeclarationProperty = {
  providerType: 'providerType',

  // the properties below are optional
  gitConfiguration: {
    sourceActionName: 'sourceActionName',

    // the properties below are optional
    pullRequest: [{
      branches: {
        excludes: ['excludes'],
        includes: ['includes'],
      },
      events: ['events'],
      filePaths: {
        excludes: ['excludes'],
        includes: ['includes'],
      },
    }],
    push: [{
      branches: {
        excludes: ['excludes'],
        includes: ['includes'],
      },
      filePaths: {
        excludes: ['excludes'],
        includes: ['includes'],
      },
      tags: {
        excludes: ['excludes'],
        includes: ['includes'],
      },
    }],
  },
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_codepipeline as codepipeline

pipeline_trigger_declaration_property = codepipeline.CfnPipeline.PipelineTriggerDeclarationProperty(
    provider_type="providerType",

    # the properties below are optional
    git_configuration=codepipeline.CfnPipeline.GitConfigurationProperty(
        source_action_name="sourceActionName",

        # the properties below are optional
        pull_request=[codepipeline.CfnPipeline.GitPullRequestFilterProperty(
            branches=codepipeline.CfnPipeline.GitBranchFilterCriteriaProperty(
                excludes=["excludes"],
                includes=["includes"]
            ),
            events=["events"],
            file_paths=codepipeline.CfnPipeline.GitFilePathFilterCriteriaProperty(
                excludes=["excludes"],
                includes=["includes"]
            )
        )],
        push=[codepipeline.CfnPipeline.GitPushFilterProperty(
            branches=codepipeline.CfnPipeline.GitBranchFilterCriteriaProperty(
                excludes=["excludes"],
                includes=["includes"]
            ),
            file_paths=codepipeline.CfnPipeline.GitFilePathFilterCriteriaProperty(
                excludes=["excludes"],
                includes=["includes"]
            ),
            tags=codepipeline.CfnPipeline.GitTagFilterCriteriaProperty(
                excludes=["excludes"],
                includes=["includes"]
            )
        )]
    )
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.codepipeline.*;

PipelineTriggerDeclarationProperty pipelineTriggerDeclarationProperty = PipelineTriggerDeclarationProperty.builder()
        .providerType("providerType")

        // the properties below are optional
        .gitConfiguration(GitConfigurationProperty.builder()
                .sourceActionName("sourceActionName")

                // the properties below are optional
                .pullRequest(List.of(GitPullRequestFilterProperty.builder()
                        .branches(GitBranchFilterCriteriaProperty.builder()
                                .excludes(List.of("excludes"))
                                .includes(List.of("includes"))
                                .build())
                        .events(List.of("events"))
                        .filePaths(GitFilePathFilterCriteriaProperty.builder()
                                .excludes(List.of("excludes"))
                                .includes(List.of("includes"))
                                .build())
                        .build()))
                .push(List.of(GitPushFilterProperty.builder()
                        .branches(GitBranchFilterCriteriaProperty.builder()
                                .excludes(List.of("excludes"))
                                .includes(List.of("includes"))
                                .build())
                        .filePaths(GitFilePathFilterCriteriaProperty.builder()
                                .excludes(List.of("excludes"))
                                .includes(List.of("includes"))
                                .build())
                        .tags(GitTagFilterCriteriaProperty.builder()
                                .excludes(List.of("excludes"))
                                .includes(List.of("includes"))
                                .build())
                        .build()))
                .build())
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.CodePipeline;

var pipelineTriggerDeclarationProperty = new PipelineTriggerDeclarationProperty {
    ProviderType = "providerType",

    // the properties below are optional
    GitConfiguration = new GitConfigurationProperty {
        SourceActionName = "sourceActionName",

        // the properties below are optional
        PullRequest = new [] { new GitPullRequestFilterProperty {
            Branches = new GitBranchFilterCriteriaProperty {
                Excludes = new [] { "excludes" },
                Includes = new [] { "includes" }
            },
            Events = new [] { "events" },
            FilePaths = new GitFilePathFilterCriteriaProperty {
                Excludes = new [] { "excludes" },
                Includes = new [] { "includes" }
            }
        } },
        Push = new [] { new GitPushFilterProperty {
            Branches = new GitBranchFilterCriteriaProperty {
                Excludes = new [] { "excludes" },
                Includes = new [] { "includes" }
            },
            FilePaths = new GitFilePathFilterCriteriaProperty {
                Excludes = new [] { "excludes" },
                Includes = new [] { "includes" }
            },
            Tags = new GitTagFilterCriteriaProperty {
                Excludes = new [] { "excludes" },
                Includes = new [] { "includes" }
            }
        } }
    }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

pipelineTriggerDeclarationProperty := &PipelineTriggerDeclarationProperty{
	ProviderType: jsii.String("providerType"),

	// the properties below are optional
	GitConfiguration: &GitConfigurationProperty{
		SourceActionName: jsii.String("sourceActionName"),

		// the properties below are optional
		PullRequest: []interface{}{
			&GitPullRequestFilterProperty{
				Branches: &GitBranchFilterCriteriaProperty{
					Excludes: []*string{
						jsii.String("excludes"),
					},
					Includes: []*string{
						jsii.String("includes"),
					},
				},
				Events: []*string{
					jsii.String("events"),
				},
				FilePaths: &GitFilePathFilterCriteriaProperty{
					Excludes: []*string{
						jsii.String("excludes"),
					},
					Includes: []*string{
						jsii.String("includes"),
					},
				},
			},
		},
		Push: []interface{}{
			&GitPushFilterProperty{
				Branches: &GitBranchFilterCriteriaProperty{
					Excludes: []*string{
						jsii.String("excludes"),
					},
					Includes: []*string{
						jsii.String("includes"),
					},
				},
				FilePaths: &GitFilePathFilterCriteriaProperty{
					Excludes: []*string{
						jsii.String("excludes"),
					},
					Includes: []*string{
						jsii.String("includes"),
					},
				},
				Tags: &GitTagFilterCriteriaProperty{
					Excludes: []*string{
						jsii.String("excludes"),
					},
					Includes: []*string{
						jsii.String("includes"),
					},
				},
			},
		},
	},
}

Properties ​

gitConfigurationoptionalIResolvable | CfnPipeline.GitConfigurationPropertygit_configurationoptionaltyping.Union[IResolvable, GitConfigurationProperty]gitConfigurationoptionalIResolvableGitConfigurationoptionalIResolvableGitConfigurationoptionalinterface{} #
Provides the filter criteria and the source stage for the repository event that starts the pipeline, such as Git tags.
providerTypestringprovider_typestrproviderTypeStringProviderTypestringProviderType*string required #
The source provider for the event, such as connections configured for a repository with Git tags, for the specified trigger configuration.