update_webhook
¶
update_webhook(
project_name: ProjectName,
*,
config_overrides: Optional[CodeBuildClientConfig] = None,
branch_filter: Optional[String] = None,
rotate_secret: Optional[Boolean] = None,
filter_groups: Optional[FilterGroups] = None,
build_type: Optional[WebhookBuildType] = None,
pull_request_build_policy: Optional[PullRequestBuildPolicy] = None,
) -> UpdateWebhookOutput
Updates the webhook associated with an CodeBuild build project.
If you use Bitbucket for your repository, rotateSecret is ignored.
Parameters:
-
project_name(ProjectName) –The name of the CodeBuild project.
-
branch_filter(Optional[String], default:None) –A regular expression used to determine which repository branches are built when a webhook is triggered. If the name of a branch matches the regular expression, then it is built. If
branchFilteris empty, then all branches are built.It is recommended that you use
filterGroupsinstead ofbranchFilter. -
rotate_secret(Optional[Boolean], default:None) –A boolean value that specifies whether the associated GitHub repository's secret token should be updated. If you use Bitbucket for your repository,
rotateSecretis ignored. -
filter_groups(Optional[FilterGroups], default:None) –An array of arrays of
WebhookFilterobjects used to determine if a webhook event can trigger a build. A filter group must contain at least oneEVENTWebhookFilter. -
build_type(Optional[WebhookBuildType], default:None) –Specifies the type of build this webhook will trigger.
RUNNER_BUILDKITE_BUILDis only available forNO_SOURCEsource type projects configured for Buildkite runner builds. For more information about CodeBuild-hosted Buildkite runner builds, see Tutorial: Configure a CodeBuild-hosted Buildkite runner in the CodeBuild user guide. -
pull_request_build_policy(Optional[PullRequestBuildPolicy], default:None) –A PullRequestBuildPolicy object that defines comment-based approval requirements for triggering builds on pull requests. This policy helps control when automated builds are executed based on contributor permissions and approval workflows.
Raises:
-
InvalidInputException–The input value that was provided is not valid.
-
OAuthProviderException–There was a problem with the underlying OAuth provider.
-
ResourceNotFoundException–The specified Amazon Web Services resource cannot be found.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_codebuild/_services/code_build.py
4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 4621 4622 4623 4624 4625 4626 4627 4628 4629 4630 4631 4632 4633 4634 4635 4636 4637 4638 4639 4640 4641 4642 4643 4644 4645 4646 4647 4648 4649 4650 4651 4652 4653 4654 4655 4656 4657 4658 4659 4660 4661 4662 4663 4664 4665 4666 4667 4668 4669 4670 4671 4672 4673 4674 4675 4676 4677 4678 4679 4680 4681 4682 | |