Skip to content

Commit e78df26

Browse files
author
awstools
committed
feat(client-codebuild): Add new webhook filter types for GitHub webhooks
1 parent 59e2f13 commit e78df26

File tree

7 files changed

+51
-16
lines changed

7 files changed

+51
-16
lines changed

clients/client-codebuild/src/commands/BatchGetProjectsCommand.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ export interface BatchGetProjectsCommandOutput extends BatchGetProjectsOutput, _
171171
* // filterGroups: [ // FilterGroups
172172
* // [ // FilterGroup
173173
* // { // WebhookFilter
174-
* // type: "EVENT" || "BASE_REF" || "HEAD_REF" || "ACTOR_ACCOUNT_ID" || "FILE_PATH" || "COMMIT_MESSAGE", // required
174+
* // type: "EVENT" || "BASE_REF" || "HEAD_REF" || "ACTOR_ACCOUNT_ID" || "FILE_PATH" || "COMMIT_MESSAGE" || "WORKFLOW_NAME" || "TAG_NAME" || "RELEASE_NAME", // required
175175
* // pattern: "STRING_VALUE", // required
176176
* // excludeMatchedPattern: true || false,
177177
* // },

clients/client-codebuild/src/commands/CreateProjectCommand.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -328,7 +328,7 @@ export interface CreateProjectCommandOutput extends CreateProjectOutput, __Metad
328328
* // filterGroups: [ // FilterGroups
329329
* // [ // FilterGroup
330330
* // { // WebhookFilter
331-
* // type: "EVENT" || "BASE_REF" || "HEAD_REF" || "ACTOR_ACCOUNT_ID" || "FILE_PATH" || "COMMIT_MESSAGE", // required
331+
* // type: "EVENT" || "BASE_REF" || "HEAD_REF" || "ACTOR_ACCOUNT_ID" || "FILE_PATH" || "COMMIT_MESSAGE" || "WORKFLOW_NAME" || "TAG_NAME" || "RELEASE_NAME", // required
332332
* // pattern: "STRING_VALUE", // required
333333
* // excludeMatchedPattern: true || false,
334334
* // },

clients/client-codebuild/src/commands/CreateWebhookCommand.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ export interface CreateWebhookCommandOutput extends CreateWebhookOutput, __Metad
5050
* filterGroups: [ // FilterGroups
5151
* [ // FilterGroup
5252
* { // WebhookFilter
53-
* type: "EVENT" || "BASE_REF" || "HEAD_REF" || "ACTOR_ACCOUNT_ID" || "FILE_PATH" || "COMMIT_MESSAGE", // required
53+
* type: "EVENT" || "BASE_REF" || "HEAD_REF" || "ACTOR_ACCOUNT_ID" || "FILE_PATH" || "COMMIT_MESSAGE" || "WORKFLOW_NAME" || "TAG_NAME" || "RELEASE_NAME", // required
5454
* pattern: "STRING_VALUE", // required
5555
* excludeMatchedPattern: true || false,
5656
* },
@@ -69,7 +69,7 @@ export interface CreateWebhookCommandOutput extends CreateWebhookOutput, __Metad
6969
* // filterGroups: [ // FilterGroups
7070
* // [ // FilterGroup
7171
* // { // WebhookFilter
72-
* // type: "EVENT" || "BASE_REF" || "HEAD_REF" || "ACTOR_ACCOUNT_ID" || "FILE_PATH" || "COMMIT_MESSAGE", // required
72+
* // type: "EVENT" || "BASE_REF" || "HEAD_REF" || "ACTOR_ACCOUNT_ID" || "FILE_PATH" || "COMMIT_MESSAGE" || "WORKFLOW_NAME" || "TAG_NAME" || "RELEASE_NAME", // required
7373
* // pattern: "STRING_VALUE", // required
7474
* // excludeMatchedPattern: true || false,
7575
* // },

clients/client-codebuild/src/commands/UpdateProjectCommand.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -328,7 +328,7 @@ export interface UpdateProjectCommandOutput extends UpdateProjectOutput, __Metad
328328
* // filterGroups: [ // FilterGroups
329329
* // [ // FilterGroup
330330
* // { // WebhookFilter
331-
* // type: "EVENT" || "BASE_REF" || "HEAD_REF" || "ACTOR_ACCOUNT_ID" || "FILE_PATH" || "COMMIT_MESSAGE", // required
331+
* // type: "EVENT" || "BASE_REF" || "HEAD_REF" || "ACTOR_ACCOUNT_ID" || "FILE_PATH" || "COMMIT_MESSAGE" || "WORKFLOW_NAME" || "TAG_NAME" || "RELEASE_NAME", // required
332332
* // pattern: "STRING_VALUE", // required
333333
* // excludeMatchedPattern: true || false,
334334
* // },

clients/client-codebuild/src/commands/UpdateWebhookCommand.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ export interface UpdateWebhookCommandOutput extends UpdateWebhookOutput, __Metad
4545
* filterGroups: [ // FilterGroups
4646
* [ // FilterGroup
4747
* { // WebhookFilter
48-
* type: "EVENT" || "BASE_REF" || "HEAD_REF" || "ACTOR_ACCOUNT_ID" || "FILE_PATH" || "COMMIT_MESSAGE", // required
48+
* type: "EVENT" || "BASE_REF" || "HEAD_REF" || "ACTOR_ACCOUNT_ID" || "FILE_PATH" || "COMMIT_MESSAGE" || "WORKFLOW_NAME" || "TAG_NAME" || "RELEASE_NAME", // required
4949
* pattern: "STRING_VALUE", // required
5050
* excludeMatchedPattern: true || false,
5151
* },
@@ -64,7 +64,7 @@ export interface UpdateWebhookCommandOutput extends UpdateWebhookOutput, __Metad
6464
* // filterGroups: [ // FilterGroups
6565
* // [ // FilterGroup
6666
* // { // WebhookFilter
67-
* // type: "EVENT" || "BASE_REF" || "HEAD_REF" || "ACTOR_ACCOUNT_ID" || "FILE_PATH" || "COMMIT_MESSAGE", // required
67+
* // type: "EVENT" || "BASE_REF" || "HEAD_REF" || "ACTOR_ACCOUNT_ID" || "FILE_PATH" || "COMMIT_MESSAGE" || "WORKFLOW_NAME" || "TAG_NAME" || "RELEASE_NAME", // required
6868
* // pattern: "STRING_VALUE", // required
6969
* // excludeMatchedPattern: true || false,
7070
* // },

clients/client-codebuild/src/models/models_0.ts

+24-7
Original file line numberDiff line numberDiff line change
@@ -1665,7 +1665,7 @@ export interface ProjectSource {
16651665
* that contains the source and the buildspec file. You must connect your Amazon Web Services account
16661666
* to your GitLab account. Use the CodeBuild console to start creating a build
16671667
* project. When you use the console to connect (or reconnect) with GitLab, on the
1668-
* Connections <b>Authorize application</b> page, choose <b>Authorize</b>. Then on the CodeStar Connections <b>Create GitLab connection</b> page,
1668+
* Connections <b>Authorize application</b> page, choose <b>Authorize</b>. Then on the CodeConnections <b>Create GitLab connection</b> page,
16691669
* choose <b>Connect to GitLab</b>. (After you have connected to your GitLab account,
16701670
* you do not need to finish creating the build project. You can leave the CodeBuild
16711671
* console.) To instruct CodeBuild to override the default connection and use this connection instead,
@@ -3460,6 +3460,9 @@ export const WebhookFilterType = {
34603460
EVENT: "EVENT",
34613461
FILE_PATH: "FILE_PATH",
34623462
HEAD_REF: "HEAD_REF",
3463+
RELEASE_NAME: "RELEASE_NAME",
3464+
TAG_NAME: "TAG_NAME",
3465+
WORKFLOW_NAME: "WORKFLOW_NAME",
34633466
} as const;
34643467

34653468
/**
@@ -3473,9 +3476,10 @@ export type WebhookFilterType = (typeof WebhookFilterType)[keyof typeof WebhookF
34733476
*/
34743477
export interface WebhookFilter {
34753478
/**
3476-
* <p> The type of webhook filter. There are eight webhook filter types: <code>EVENT</code>,
3479+
* <p> The type of webhook filter. There are nine webhook filter types: <code>EVENT</code>,
34773480
* <code>ACTOR_ACCOUNT_ID</code>, <code>HEAD_REF</code>, <code>BASE_REF</code>,
3478-
* <code>FILE_PATH</code>, <code>COMMIT_MESSAGE</code>, <code>TAG_NAME</code>, and <code>RELEASE_NAME</code>. </p>
3481+
* <code>FILE_PATH</code>, <code>COMMIT_MESSAGE</code>, <code>TAG_NAME</code>, <code>RELEASE_NAME</code>,
3482+
* and <code>WORKFLOW_NAME</code>. </p>
34793483
* <ul>
34803484
* <li>
34813485
* <p>
@@ -3484,17 +3488,18 @@ export interface WebhookFilter {
34843488
* <ul>
34853489
* <li>
34863490
* <p> A webhook event triggers a build when the provided <code>pattern</code>
3487-
* matches one of eight event types: <code>PUSH</code>,
3491+
* matches one of nine event types: <code>PUSH</code>,
34883492
* <code>PULL_REQUEST_CREATED</code>, <code>PULL_REQUEST_UPDATED</code>,
34893493
* <code>PULL_REQUEST_CLOSED</code>, <code>PULL_REQUEST_REOPENED</code>,
3490-
* <code>PULL_REQUEST_MERGED</code>, <code>RELEASED</code>, and <code>PRERELEASED</code>. The <code>EVENT</code> patterns are
3494+
* <code>PULL_REQUEST_MERGED</code>, <code>RELEASED</code>, <code>PRERELEASED</code>,
3495+
* and <code>WORKFLOW_JOB_QUEUED</code>. The <code>EVENT</code> patterns are
34913496
* specified as a comma-separated string. For example, <code>PUSH,
34923497
* PULL_REQUEST_CREATED, PULL_REQUEST_UPDATED</code> filters all push, pull
34933498
* request created, and pull request updated events. </p>
34943499
* <note>
34953500
* <p> The <code>PULL_REQUEST_REOPENED</code> works with GitHub and GitHub
3496-
* Enterprise only. The <code>RELEASED</code> and <code>PRERELEASED</code> work
3497-
* with GitHub only.</p>
3501+
* Enterprise only. The <code>RELEASED</code>, <code>PRERELEASED</code>,
3502+
* and <code>WORKFLOW_JOB_QUEUED</code> work with GitHub only.</p>
34983503
* </note>
34993504
* </li>
35003505
* </ul>
@@ -3588,6 +3593,18 @@ export interface WebhookFilter {
35883593
* </li>
35893594
* </ul>
35903595
* </li>
3596+
* <li>
3597+
* <p>WORKFLOW_NAME</p>
3598+
* <ul>
3599+
* <li>
3600+
* <p>A webhook triggers a build when the workflow name matches the
3601+
* regular expression <code>pattern</code>.</p>
3602+
* <note>
3603+
* <p> Works with <code>WORKFLOW_JOB_QUEUED</code> events only. </p>
3604+
* </note>
3605+
* </li>
3606+
* </ul>
3607+
* </li>
35913608
* </ul>
35923609
* @public
35933610
*/

0 commit comments

Comments
 (0)