openapi: 3.1.0 info: title: Google Cloud Build Builds Triggers API description: The Cloud Build API provides programmatic access to create, manage, and monitor builds on Google Cloud infrastructure. It supports build triggers, worker pools, source repository connections, and build configuration management for CI/CD workflows. version: v1 contact: name: Google Cloud Support url: https://cloud.google.com/build/docs/support termsOfService: https://cloud.google.com/terms servers: - url: https://cloudbuild.googleapis.com/v1 description: Production Server security: - oauth2: [] tags: - name: Triggers description: Operations for managing build triggers paths: /projects/{projectId}/triggers: get: operationId: listTriggers summary: Google Cloud Build List build triggers description: Lists existing build triggers for a project. tags: - Triggers parameters: - $ref: '#/components/parameters/projectId' - $ref: '#/components/parameters/pageSize' - $ref: '#/components/parameters/pageToken' responses: '200': description: Successful response content: application/json: schema: $ref: '#/components/schemas/ListTriggersResponse' post: operationId: createTrigger summary: Google Cloud Build Create a build trigger description: Creates a new build trigger. tags: - Triggers parameters: - $ref: '#/components/parameters/projectId' requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/BuildTrigger' responses: '200': description: Successful response content: application/json: schema: $ref: '#/components/schemas/BuildTrigger' /projects/{projectId}/triggers/{triggerId}: get: operationId: getTrigger summary: Google Cloud Build Get a build trigger description: Returns information about a build trigger. tags: - Triggers parameters: - $ref: '#/components/parameters/projectId' - $ref: '#/components/parameters/triggerId' responses: '200': description: Successful response content: application/json: schema: $ref: '#/components/schemas/BuildTrigger' patch: operationId: updateTrigger summary: Google Cloud Build Update a build trigger description: Updates a build trigger by its project ID and trigger ID. tags: - Triggers parameters: - $ref: '#/components/parameters/projectId' - $ref: '#/components/parameters/triggerId' requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/BuildTrigger' responses: '200': description: Successful response content: application/json: schema: $ref: '#/components/schemas/BuildTrigger' delete: operationId: deleteTrigger summary: Google Cloud Build Delete a build trigger description: Deletes a build trigger by its project ID and trigger ID. tags: - Triggers parameters: - $ref: '#/components/parameters/projectId' - $ref: '#/components/parameters/triggerId' responses: '200': description: Successful response components: schemas: Build: type: object properties: id: type: string description: Unique identifier of the build projectId: type: string status: type: string enum: - STATUS_UNKNOWN - PENDING - QUEUED - WORKING - SUCCESS - FAILURE - INTERNAL_ERROR - TIMEOUT - CANCELLED - EXPIRED source: type: object properties: storageSource: type: object properties: bucket: type: string object: type: string generation: type: string repoSource: type: object properties: projectId: type: string repoName: type: string branchName: type: string tagName: type: string commitSha: type: string steps: type: array items: $ref: '#/components/schemas/BuildStep' description: The operations to be performed on the workspace results: type: object properties: images: type: array items: type: object properties: name: type: string digest: type: string buildStepImages: type: array items: type: string createTime: type: string format: date-time startTime: type: string format: date-time finishTime: type: string format: date-time timeout: type: string description: Amount of time that this build should be allowed to run images: type: array items: type: string description: List of images to be pushed upon successful completion logUrl: type: string description: URL to logs for this build in Cloud Console substitutions: type: object additionalProperties: type: string tags: type: array items: type: string BuildStep: type: object properties: name: type: string description: The name of the container image for this build step args: type: array items: type: string description: Command-line arguments for the step's container dir: type: string description: Working directory to use when running the step's container id: type: string description: Unique identifier for the build step waitFor: type: array items: type: string description: The IDs of steps that must complete before this step starts entrypoint: type: string description: Entrypoint to use when running the step's container env: type: array items: type: string description: Environment variables for the step timeout: type: string ListTriggersResponse: type: object properties: triggers: type: array items: $ref: '#/components/schemas/BuildTrigger' nextPageToken: type: string BuildTrigger: type: object properties: id: type: string name: type: string description: type: string disabled: type: boolean triggerTemplate: type: object properties: projectId: type: string repoName: type: string branchName: type: string tagName: type: string github: type: object properties: owner: type: string name: type: string pullRequest: type: object properties: branch: type: string push: type: object properties: branch: type: string tag: type: string build: $ref: '#/components/schemas/Build' filename: type: string description: Path to the build configuration file substitutions: type: object additionalProperties: type: string tags: type: array items: type: string createTime: type: string format: date-time parameters: pageToken: name: pageToken in: query schema: type: string projectId: name: projectId in: path required: true schema: type: string pageSize: name: pageSize in: query schema: type: integer triggerId: name: triggerId in: path required: true schema: type: string securitySchemes: oauth2: type: oauth2 flows: authorizationCode: authorizationUrl: https://accounts.google.com/o/oauth2/auth tokenUrl: https://oauth2.googleapis.com/token scopes: https://www.googleapis.com/auth/cloud-platform: Full access to Google Cloud externalDocs: description: Cloud Build API Documentation url: https://cloud.google.com/build/docs/api/reference/rest