Class CfnProjectPropsMixin.WebhookFilterProperty
WebhookFilter is a structure of the FilterGroups property on the AWS CodeBuild Project ProjectTriggers property type that specifies which webhooks trigger an AWS CodeBuild build.
Implements
Inherited Members
Namespace: Amazon.CDK.Mixins.Preview.AWS.CodeBuild.Mixins
Assembly: Amazon.CDK.Mixins.Preview.dll
Syntax (csharp)
public class CfnProjectPropsMixin.WebhookFilterProperty : CfnProjectPropsMixin.IWebhookFilterProperty
Syntax (vb)
Public Class CfnProjectPropsMixin.WebhookFilterProperty Implements CfnProjectPropsMixin.IWebhookFilterProperty
Remarks
The Webhook feature isn't available in AWS CloudFormation for GitHub Enterprise projects. Use the AWS CLI or AWS CodeBuild console to create the webhook.
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.Mixins.Preview.AWS.CodeBuild.Mixins;
var webhookFilterProperty = new WebhookFilterProperty {
ExcludeMatchedPattern = false,
Pattern = "pattern",
Type = "type"
};
Synopsis
Constructors
| WebhookFilterProperty() |
|
Properties
| ExcludeMatchedPattern | Used to indicate that the |
| Pattern | For a |
| Type | The type of webhook filter. |
Constructors
WebhookFilterProperty()
WebhookFilter is a structure of the FilterGroups property on the AWS CodeBuild Project ProjectTriggers property type that specifies which webhooks trigger an AWS CodeBuild build.
public WebhookFilterProperty()
Remarks
The Webhook feature isn't available in AWS CloudFormation for GitHub Enterprise projects. Use the AWS CLI or AWS CodeBuild console to create the webhook.
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.Mixins.Preview.AWS.CodeBuild.Mixins;
var webhookFilterProperty = new WebhookFilterProperty {
ExcludeMatchedPattern = false,
Pattern = "pattern",
Type = "type"
};
Properties
ExcludeMatchedPattern
Used to indicate that the pattern determines which webhook events do not trigger a build.
public object? ExcludeMatchedPattern { get; set; }
Property Value
Remarks
If true, then a webhook event that does not match the pattern triggers a build. If false, then a webhook event that matches the pattern triggers a build.
Type union: either bool or IResolvable
Pattern
For a WebHookFilter that uses EVENT type, a comma-separated string that specifies one or more events.
public string? Pattern { get; set; }
Property Value
Remarks
For example, the webhook filter PUSH, PULL_REQUEST_CREATED, PULL_REQUEST_UPDATED allows all push, pull request created, and pull request updated events to trigger a build.
For a WebHookFilter that uses any of the other filter types, a regular expression pattern. For example, a WebHookFilter that uses HEAD_REF for its type and the pattern ^refs/heads/ triggers a build when the head reference is a branch with a reference name refs/heads/branch-name .
Type
The type of webhook filter.
public string? Type { get; set; }
Property Value
Remarks
There are 11 webhook filter types: EVENT , ACTOR_ACCOUNT_ID , HEAD_REF , BASE_REF , FILE_PATH , COMMIT_MESSAGE , TAG_NAME , RELEASE_NAME , REPOSITORY_NAME , ORGANIZATION_NAME , and WORKFLOW_NAME .
Types <code>PULL_REQUEST_REOPENED</code> and <code>WORKFLOW_JOB_QUEUED</code> work with GitHub and GitHub Enterprise only. Types <code>RELEASED</code> and <code>PRERELEASED</code> work with GitHub only.
Works with GitHub and GitHub Enterprise push, GitHub and GitHub Enterprise pull request, Bitbucket push, and Bitbucket pull request events.
Works with pull request events only.
Works with push and pull request events only.
Works with push and pull request events only.
Works with <code>RELEASED</code> and <code>PRERELEASED</code> events only.
Works with <code>RELEASED</code> and <code>PRERELEASED</code> events only.
Works with GitHub global or organization webhooks only.
Works with GitHub global webhooks only.
Works with <code>WORKFLOW_JOB_QUEUED</code> events only. > For CodeBuild-hosted Buildkite runner builds, WORKFLOW_NAME filters will filter by pipeline name.