Class CfnWebhook.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnWebhook>
- Enclosing class:
CfnWebhook
CfnWebhook
.-
Method Summary
Modifier and TypeMethodDescriptionauthentication
(String authentication) Supported options are GITHUB_HMAC, IP, and UNAUTHENTICATED.authenticationConfiguration
(IResolvable authenticationConfiguration) Properties that configure the authentication applied to incoming webhook trigger requests.authenticationConfiguration
(CfnWebhook.WebhookAuthConfigurationProperty authenticationConfiguration) Properties that configure the authentication applied to incoming webhook trigger requests.build()
static CfnWebhook.Builder
A list of rules applied to the body/payload sent in the POST request to a webhook URL.filters
(IResolvable filters) A list of rules applied to the body/payload sent in the POST request to a webhook URL.The name of the webhook.registerWithThirdParty
(Boolean registerWithThirdParty) Configures a connection between the webhook that was created and the external tool with events to be detected.registerWithThirdParty
(IResolvable registerWithThirdParty) Configures a connection between the webhook that was created and the external tool with events to be detected.targetAction
(String targetAction) The name of the action in a pipeline you want to connect to the webhook.targetPipeline
(String targetPipeline) The name of the pipeline you want to connect to the webhook.targetPipelineVersion
(Number targetPipelineVersion) The version number of the pipeline to be connected to the trigger request.
-
Method Details
-
create
@Stability(Stable) public static CfnWebhook.Builder create(software.constructs.Construct scope, String id) - Parameters:
scope
- Scope in which this resource is defined. This parameter is required.id
- Construct identifier for this resource (unique in its scope). This parameter is required.- Returns:
- a new instance of
CfnWebhook.Builder
.
-
authentication
Supported options are GITHUB_HMAC, IP, and UNAUTHENTICATED.When creating CodePipeline webhooks, do not use your own credentials or reuse the same secret token across multiple webhooks. For optimal security, generate a unique secret token for each webhook you create. The secret token is an arbitrary string that you provide, which GitHub uses to compute and sign the webhook payloads sent to CodePipeline, for protecting the integrity and authenticity of the webhook payloads. Using your own credentials or reusing the same token across multiple webhooks can lead to security vulnerabilities. > If a secret token was provided, it will be redacted in the response.
- For information about the authentication scheme implemented by GITHUB_HMAC, see Securing your webhooks on the GitHub Developer website.
- IP rejects webhooks trigger requests unless they originate from an IP address in the IP range whitelisted in the authentication configuration.
- UNAUTHENTICATED accepts all webhook trigger requests regardless of origin.
- Parameters:
authentication
- Supported options are GITHUB_HMAC, IP, and UNAUTHENTICATED. This parameter is required.- Returns:
this
- See Also:
-
authenticationConfiguration
@Stability(Stable) public CfnWebhook.Builder authenticationConfiguration(IResolvable authenticationConfiguration) Properties that configure the authentication applied to incoming webhook trigger requests.The required properties depend on the authentication type. For GITHUB_HMAC, only the
SecretToken
property must be set. For IP, only theAllowedIPRange
property must be set to a valid CIDR range. For UNAUTHENTICATED, no properties can be set.- Parameters:
authenticationConfiguration
- Properties that configure the authentication applied to incoming webhook trigger requests. This parameter is required.- Returns:
this
- See Also:
-
authenticationConfiguration
@Stability(Stable) public CfnWebhook.Builder authenticationConfiguration(CfnWebhook.WebhookAuthConfigurationProperty authenticationConfiguration) Properties that configure the authentication applied to incoming webhook trigger requests.The required properties depend on the authentication type. For GITHUB_HMAC, only the
SecretToken
property must be set. For IP, only theAllowedIPRange
property must be set to a valid CIDR range. For UNAUTHENTICATED, no properties can be set.- Parameters:
authenticationConfiguration
- Properties that configure the authentication applied to incoming webhook trigger requests. This parameter is required.- Returns:
this
- See Also:
-
filters
A list of rules applied to the body/payload sent in the POST request to a webhook URL.All defined rules must pass for the request to be accepted and the pipeline started.
- Parameters:
filters
- A list of rules applied to the body/payload sent in the POST request to a webhook URL. This parameter is required.- Returns:
this
- See Also:
-
filters
A list of rules applied to the body/payload sent in the POST request to a webhook URL.All defined rules must pass for the request to be accepted and the pipeline started.
- Parameters:
filters
- A list of rules applied to the body/payload sent in the POST request to a webhook URL. This parameter is required.- Returns:
this
- See Also:
-
targetAction
The name of the action in a pipeline you want to connect to the webhook.The action must be from the source (first) stage of the pipeline.
- Parameters:
targetAction
- The name of the action in a pipeline you want to connect to the webhook. This parameter is required.- Returns:
this
- See Also:
-
targetPipeline
The name of the pipeline you want to connect to the webhook.- Parameters:
targetPipeline
- The name of the pipeline you want to connect to the webhook. This parameter is required.- Returns:
this
- See Also:
-
targetPipelineVersion
The version number of the pipeline to be connected to the trigger request.Required: Yes
Type: Integer
Update requires: No interruption
- Parameters:
targetPipelineVersion
- The version number of the pipeline to be connected to the trigger request. This parameter is required.- Returns:
this
- See Also:
-
name
The name of the webhook.- Parameters:
name
- The name of the webhook. This parameter is required.- Returns:
this
- See Also:
-
registerWithThirdParty
Configures a connection between the webhook that was created and the external tool with events to be detected.- Parameters:
registerWithThirdParty
- Configures a connection between the webhook that was created and the external tool with events to be detected. This parameter is required.- Returns:
this
- See Also:
-
registerWithThirdParty
@Stability(Stable) public CfnWebhook.Builder registerWithThirdParty(IResolvable registerWithThirdParty) Configures a connection between the webhook that was created and the external tool with events to be detected.- Parameters:
registerWithThirdParty
- Configures a connection between the webhook that was created and the external tool with events to be detected. This parameter is required.- Returns:
this
- See Also:
-
build
- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<CfnWebhook>
- Returns:
- a newly built instance of
CfnWebhook
.
-