| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1 | <html><body> | 
|  | 2 | <style> | 
|  | 3 |  | 
|  | 4 | body, h1, h2, h3, div, span, p, pre, a { | 
|  | 5 | margin: 0; | 
|  | 6 | padding: 0; | 
|  | 7 | border: 0; | 
|  | 8 | font-weight: inherit; | 
|  | 9 | font-style: inherit; | 
|  | 10 | font-size: 100%; | 
|  | 11 | font-family: inherit; | 
|  | 12 | vertical-align: baseline; | 
|  | 13 | } | 
|  | 14 |  | 
|  | 15 | body { | 
|  | 16 | font-size: 13px; | 
|  | 17 | padding: 1em; | 
|  | 18 | } | 
|  | 19 |  | 
|  | 20 | h1 { | 
|  | 21 | font-size: 26px; | 
|  | 22 | margin-bottom: 1em; | 
|  | 23 | } | 
|  | 24 |  | 
|  | 25 | h2 { | 
|  | 26 | font-size: 24px; | 
|  | 27 | margin-bottom: 1em; | 
|  | 28 | } | 
|  | 29 |  | 
|  | 30 | h3 { | 
|  | 31 | font-size: 20px; | 
|  | 32 | margin-bottom: 1em; | 
|  | 33 | margin-top: 1em; | 
|  | 34 | } | 
|  | 35 |  | 
|  | 36 | pre, code { | 
|  | 37 | line-height: 1.5; | 
|  | 38 | font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace; | 
|  | 39 | } | 
|  | 40 |  | 
|  | 41 | pre { | 
|  | 42 | margin-top: 0.5em; | 
|  | 43 | } | 
|  | 44 |  | 
|  | 45 | h1, h2, h3, p { | 
|  | 46 | font-family: Arial, sans serif; | 
|  | 47 | } | 
|  | 48 |  | 
|  | 49 | h1, h2, h3 { | 
|  | 50 | border-bottom: solid #CCC 1px; | 
|  | 51 | } | 
|  | 52 |  | 
|  | 53 | .toc_element { | 
|  | 54 | margin-top: 0.5em; | 
|  | 55 | } | 
|  | 56 |  | 
|  | 57 | .firstline { | 
|  | 58 | margin-left: 2 em; | 
|  | 59 | } | 
|  | 60 |  | 
|  | 61 | .method  { | 
|  | 62 | margin-top: 1em; | 
|  | 63 | border: solid 1px #CCC; | 
|  | 64 | padding: 1em; | 
|  | 65 | background: #EEE; | 
|  | 66 | } | 
|  | 67 |  | 
|  | 68 | .details { | 
|  | 69 | font-weight: bold; | 
|  | 70 | font-size: 14px; | 
|  | 71 | } | 
|  | 72 |  | 
|  | 73 | </style> | 
|  | 74 |  | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 75 | <h1><a href="cloudbuild_v1.html">Cloud Build API</a> . <a href="cloudbuild_v1.projects.html">projects</a> . <a href="cloudbuild_v1.projects.builds.html">builds</a></h1> | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 76 | <h2>Instance Methods</h2> | 
|  | 77 | <p class="toc_element"> | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 78 | <code><a href="#cancel">cancel(projectId, id, body=None, x__xgafv=None)</a></code></p> | 
|  | 79 | <p class="firstline">Cancels a build in progress.</p> | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 80 | <p class="toc_element"> | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 81 | <code><a href="#create">create(projectId, body=None, x__xgafv=None)</a></code></p> | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 82 | <p class="firstline">Starts a build with the specified configuration.</p> | 
|  | 83 | <p class="toc_element"> | 
|  | 84 | <code><a href="#get">get(projectId, id, x__xgafv=None)</a></code></p> | 
|  | 85 | <p class="firstline">Returns information about a previously requested build.</p> | 
|  | 86 | <p class="toc_element"> | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 87 | <code><a href="#list">list(projectId, filter=None, pageToken=None, pageSize=None, x__xgafv=None)</a></code></p> | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 88 | <p class="firstline">Lists previously requested builds.</p> | 
|  | 89 | <p class="toc_element"> | 
|  | 90 | <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p> | 
|  | 91 | <p class="firstline">Retrieves the next page of results.</p> | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 92 | <p class="toc_element"> | 
|  | 93 | <code><a href="#retry">retry(projectId, id, body=None, x__xgafv=None)</a></code></p> | 
|  | 94 | <p class="firstline">Creates a new build based on the specified build.</p> | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 95 | <h3>Method Details</h3> | 
|  | 96 | <div class="method"> | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 97 | <code class="details" id="cancel">cancel(projectId, id, body=None, x__xgafv=None)</code> | 
|  | 98 | <pre>Cancels a build in progress. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 99 |  | 
|  | 100 | Args: | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 101 | projectId: string, Required. ID of the project. (required) | 
|  | 102 | id: string, Required. ID of the build. (required) | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 103 | body: object, The request body. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 104 | The object takes the form of: | 
|  | 105 |  | 
|  | 106 | { # Request to cancel an ongoing build. | 
|  | 107 | } | 
|  | 108 |  | 
|  | 109 | x__xgafv: string, V1 error format. | 
|  | 110 | Allowed values | 
|  | 111 | 1 - v1 error format | 
|  | 112 | 2 - v2 error format | 
|  | 113 |  | 
|  | 114 | Returns: | 
|  | 115 | An object of the form: | 
|  | 116 |  | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 117 | { # A build resource in the Cloud Build API. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 118 | # | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 119 | # At a high level, a `Build` describes where to find source code, how to build | 
|  | 120 | # it (for example, the builder image to run on the source), and where to store | 
|  | 121 | # the built artifacts. | 
| Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 122 | # | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 123 | # Fields can include the following variables, which will be expanded when the | 
| Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 124 | # build is created: | 
|  | 125 | # | 
|  | 126 | # - $PROJECT_ID: the project ID of the build. | 
|  | 127 | # - $BUILD_ID: the autogenerated ID of the build. | 
|  | 128 | # - $REPO_NAME: the source repository name specified by RepoSource. | 
|  | 129 | # - $BRANCH_NAME: the branch name specified by RepoSource. | 
|  | 130 | # - $TAG_NAME: the tag name specified by RepoSource. | 
|  | 131 | # - $REVISION_ID or $COMMIT_SHA: the commit SHA specified by RepoSource or | 
|  | 132 | #   resolved from the specified branch or tag. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 133 | # - $SHORT_SHA: first 7 characters of $REVISION_ID or $COMMIT_SHA. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 134 | "images": [ # A list of images to be pushed upon the successful completion of all build | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 135 | # steps. | 
|  | 136 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 137 | # The images are pushed using the builder service account's credentials. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 138 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 139 | # The digests of the pushed images will be stored in the `Build` resource's | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 140 | # results field. | 
|  | 141 | # | 
|  | 142 | # If any of the images fail to be pushed, the build status is marked | 
|  | 143 | # `FAILURE`. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 144 | "A String", | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 145 | ], | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 146 | "projectId": "A String", # Output only. ID of the project. | 
|  | 147 | "logUrl": "A String", # Output only. URL to logs for this build in Google Cloud Console. | 
|  | 148 | "queueTtl": "A String", # TTL in queue for this build. If provided and the build is enqueued longer | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 149 | # than this value, the build will expire and the build status will be | 
|  | 150 | # `EXPIRED`. | 
|  | 151 | # | 
|  | 152 | # The TTL starts ticking from create_time. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 153 | "finishTime": "A String", # Output only. Time at which execution of the build was finished. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 154 | # | 
|  | 155 | # The difference between finish_time and start_time is the duration of the | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 156 | # build's execution. | 
|  | 157 | "source": { # Location of the source in a supported storage service. # The location of the source files to build. | 
|  | 158 | "storageSource": { # Location of the source in an archive file in Google Cloud Storage. # If provided, get the source from this location in Google Cloud Storage. | 
|  | 159 | "generation": "A String", # Google Cloud Storage generation for the object. If the generation is | 
|  | 160 | # omitted, the latest generation will be used. | 
|  | 161 | "bucket": "A String", # Google Cloud Storage bucket containing the source (see | 
|  | 162 | # [Bucket Name | 
|  | 163 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 164 | "object": "A String", # Google Cloud Storage object containing the source. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 165 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 166 | # This object must be a gzipped archive file (`.tar.gz`) containing source to | 
|  | 167 | # build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 168 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 169 | "repoSource": { # Location of the source in a Google Cloud Source Repository. # If provided, get the source from this location in a Cloud Source | 
|  | 170 | # Repository. | 
|  | 171 | "commitSha": "A String", # Explicit commit SHA to build. | 
|  | 172 | "substitutions": { # Substitutions to use in a triggered build. | 
|  | 173 | # Should only be used with RunBuildTrigger | 
|  | 174 | "a_key": "A String", | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 175 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 176 | "invertRegex": True or False, # Only trigger a build if the revision regex does NOT match the revision | 
|  | 177 | # regex. | 
|  | 178 | "dir": "A String", # Directory, relative to the source root, in which to run the build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 179 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 180 | # This must be a relative path. If a step's `dir` is specified and is an | 
|  | 181 | # absolute path, this value is ignored for that step's execution. | 
|  | 182 | "branchName": "A String", # Regex matching branches to build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 183 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 184 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 185 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 186 | "tagName": "A String", # Regex matching tags to build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 187 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 188 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 189 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 190 | "projectId": "A String", # ID of the project that owns the Cloud Source Repository. If omitted, the | 
|  | 191 | # project ID requesting the build is assumed. | 
|  | 192 | "repoName": "A String", # Required. Name of the Cloud Source Repository. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 193 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 194 | }, | 
|  | 195 | "options": { # Optional arguments to enable specific features of builds. # Special options for this build. | 
|  | 196 | "workerPool": "A String", # Option to specify a `WorkerPool` for the build. | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 197 | # Format: projects/{project}/workerPools/{workerPool} | 
|  | 198 | # | 
|  | 199 | # This field is experimental. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 200 | "env": [ # A list of global environment variable definitions that will exist for all | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 201 | # build steps in this build. If a variable is defined in both globally and in | 
|  | 202 | # a build step, the variable will use the build step value. | 
|  | 203 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 204 | # The elements are of the form "KEY=VALUE" for the environment variable "KEY" | 
|  | 205 | # being given the value "VALUE". | 
|  | 206 | "A String", | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 207 | ], | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 208 | "logging": "A String", # Option to specify the logging mode, which determines where the logs are | 
|  | 209 | # stored. | 
|  | 210 | "requestedVerifyOption": "A String", # Requested verifiability options. | 
|  | 211 | "substitutionOption": "A String", # Option to specify behavior when there is an error in the substitution | 
|  | 212 | # checks. | 
|  | 213 | "diskSizeGb": "A String", # Requested disk size for the VM that runs the build. Note that this is *NOT* | 
|  | 214 | # "disk free"; some of the space will be used by the operating system and | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 215 | # build utilities. Also note that this is the minimum disk size that will be | 
|  | 216 | # allocated for the build -- the build may run with a larger disk than | 
|  | 217 | # requested. At present, the maximum disk size is 1000GB; builds that request | 
|  | 218 | # more than the maximum are rejected with an error. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 219 | "sourceProvenanceHash": [ # Requested hash for SourceProvenance. | 
|  | 220 | "A String", | 
|  | 221 | ], | 
|  | 222 | "secretEnv": [ # A list of global environment variables, which are encrypted using a Cloud | 
|  | 223 | # Key Management Service crypto key. These values must be specified in the | 
|  | 224 | # build's `Secret`. These variables will be available to all build steps | 
|  | 225 | # in this build. | 
|  | 226 | "A String", | 
|  | 227 | ], | 
|  | 228 | "volumes": [ # Global list of volumes to mount for ALL build steps | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 229 | # | 
|  | 230 | # Each volume is created as an empty volume prior to starting the build | 
|  | 231 | # process. Upon completion of the build, volumes and their contents are | 
|  | 232 | # discarded. Global volume names and paths cannot conflict with the volumes | 
|  | 233 | # defined a build step. | 
|  | 234 | # | 
|  | 235 | # Using a global volume in a build with only one step is not valid as | 
|  | 236 | # it is indicative of a build request with an incorrect configuration. | 
|  | 237 | { # Volume describes a Docker container volume which is mounted into build steps | 
|  | 238 | # in order to persist files across build step execution. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 239 | "path": "A String", # Path at which to mount the volume. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 240 | # | 
|  | 241 | # Paths must be absolute and cannot conflict with other volume paths on the | 
|  | 242 | # same build step or with certain reserved volume paths. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 243 | "name": "A String", # Name of the volume to mount. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 244 | # | 
|  | 245 | # Volume names must be unique per build step and must be valid names for | 
|  | 246 | # Docker volumes. Each named volume must be used by at least two build steps. | 
|  | 247 | }, | 
|  | 248 | ], | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 249 | "machineType": "A String", # Compute Engine machine type on which to run the build. | 
|  | 250 | "logStreamingOption": "A String", # Option to define build log streaming behavior to Google Cloud | 
|  | 251 | # Storage. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 252 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 253 | "timeout": "A String", # Amount of time that this build should be allowed to run, to second | 
|  | 254 | # granularity. If this amount of time elapses, work on the build will cease | 
|  | 255 | # and the build status will be `TIMEOUT`. | 
|  | 256 | # | 
|  | 257 | # Default time is ten minutes. | 
|  | 258 | "status": "A String", # Output only. Status of the build. | 
|  | 259 | "statusDetail": "A String", # Output only. Customer-readable message about the current status. | 
|  | 260 | "artifacts": { # Artifacts produced by a build that should be uploaded upon # Artifacts produced by the build that should be uploaded upon | 
|  | 261 | # successful completion of all build steps. | 
|  | 262 | # successful completion of all build steps. | 
|  | 263 | "objects": { # Files in the workspace to upload to Cloud Storage upon successful # A list of objects to be uploaded to Cloud Storage upon successful | 
|  | 264 | # completion of all build steps. | 
|  | 265 | # | 
|  | 266 | # Files in the workspace matching specified paths globs will be uploaded to | 
|  | 267 | # the specified Cloud Storage location using the builder service account's | 
|  | 268 | # credentials. | 
|  | 269 | # | 
|  | 270 | # The location and generation of the uploaded objects will be stored in the | 
|  | 271 | # Build resource's results field. | 
|  | 272 | # | 
|  | 273 | # If any objects fail to be pushed, the build is marked FAILURE. | 
|  | 274 | # completion of all build steps. | 
|  | 275 | "timing": { # Start and end times for a build execution phase. # Output only. Stores timing information for pushing all artifact objects. | 
|  | 276 | "endTime": "A String", # End of time span. | 
|  | 277 | "startTime": "A String", # Start of time span. | 
|  | 278 | }, | 
|  | 279 | "paths": [ # Path globs used to match files in the build's workspace. | 
|  | 280 | "A String", | 
|  | 281 | ], | 
|  | 282 | "location": "A String", # Cloud Storage bucket and optional object path, in the form | 
|  | 283 | # "gs://bucket/path/to/somewhere/". (see [Bucket Name | 
|  | 284 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 285 | # | 
|  | 286 | # Files in the workspace matching any path pattern will be uploaded to | 
|  | 287 | # Cloud Storage with this location as a prefix. | 
|  | 288 | }, | 
|  | 289 | "images": [ # A list of images to be pushed upon the successful completion of all build | 
|  | 290 | # steps. | 
|  | 291 | # | 
|  | 292 | # The images will be pushed using the builder service account's credentials. | 
|  | 293 | # | 
|  | 294 | # The digests of the pushed images will be stored in the Build resource's | 
|  | 295 | # results field. | 
|  | 296 | # | 
|  | 297 | # If any of the images fail to be pushed, the build is marked FAILURE. | 
|  | 298 | "A String", | 
|  | 299 | ], | 
|  | 300 | }, | 
|  | 301 | "secrets": [ # Secrets to decrypt using Cloud Key Management Service. | 
|  | 302 | { # Pairs a set of secret environment variables containing encrypted | 
|  | 303 | # values with the Cloud KMS key to use to decrypt the value. | 
|  | 304 | "secretEnv": { # Map of environment variable name to its encrypted value. | 
|  | 305 | # | 
|  | 306 | # Secret environment variables must be unique across all of a build's | 
|  | 307 | # secrets, and must be used by at least one build step. Values can be at most | 
|  | 308 | # 64 KB in size. There can be at most 100 secret values across all of a | 
|  | 309 | # build's secrets. | 
|  | 310 | "a_key": "A String", | 
|  | 311 | }, | 
|  | 312 | "kmsKeyName": "A String", # Cloud KMS key name to use to decrypt these envs. | 
|  | 313 | }, | 
|  | 314 | ], | 
|  | 315 | "results": { # Artifacts created by the build pipeline. # Output only. Results of the build. | 
|  | 316 | "buildStepImages": [ # List of build step digests, in the order corresponding to build step | 
|  | 317 | # indices. | 
|  | 318 | "A String", | 
|  | 319 | ], | 
|  | 320 | "artifactTiming": { # Start and end times for a build execution phase. # Time to push all non-container artifacts. | 
|  | 321 | "endTime": "A String", # End of time span. | 
|  | 322 | "startTime": "A String", # Start of time span. | 
|  | 323 | }, | 
|  | 324 | "buildStepOutputs": [ # List of build step outputs, produced by builder images, in the order | 
|  | 325 | # corresponding to build step indices. | 
|  | 326 | # | 
|  | 327 | # [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders) | 
|  | 328 | # can produce this output by writing to `$BUILDER_OUTPUT/output`. | 
|  | 329 | # Only the first 4KB of data is stored. | 
|  | 330 | "A String", | 
|  | 331 | ], | 
|  | 332 | "images": [ # Container images that were built as a part of the build. | 
|  | 333 | { # An image built by the pipeline. | 
|  | 334 | "name": "A String", # Name used to push the container image to Google Container Registry, as | 
|  | 335 | # presented to `docker push`. | 
|  | 336 | "digest": "A String", # Docker Registry 2.0 digest. | 
|  | 337 | "pushTiming": { # Start and end times for a build execution phase. # Output only. Stores timing information for pushing the specified image. | 
|  | 338 | "endTime": "A String", # End of time span. | 
|  | 339 | "startTime": "A String", # Start of time span. | 
|  | 340 | }, | 
|  | 341 | }, | 
|  | 342 | ], | 
|  | 343 | "numArtifacts": "A String", # Number of artifacts uploaded. Only populated when artifacts are uploaded. | 
|  | 344 | "artifactManifest": "A String", # Path to the artifact manifest. Only populated when artifacts are uploaded. | 
|  | 345 | }, | 
|  | 346 | "logsBucket": "A String", # Google Cloud Storage bucket where logs should be written (see | 
|  | 347 | # [Bucket Name | 
|  | 348 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 349 | # Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`. | 
|  | 350 | "steps": [ # Required. The operations to be performed on the workspace. | 
|  | 351 | { # A step in the build pipeline. | 
|  | 352 | "entrypoint": "A String", # Entrypoint to be used instead of the build step image's default entrypoint. | 
|  | 353 | # If unset, the image's default entrypoint is used. | 
|  | 354 | "volumes": [ # List of volumes to mount into the build step. | 
|  | 355 | # | 
|  | 356 | # Each volume is created as an empty volume prior to execution of the | 
|  | 357 | # build step. Upon completion of the build, volumes and their contents are | 
|  | 358 | # discarded. | 
|  | 359 | # | 
|  | 360 | # Using a named volume in only one step is not valid as it is indicative | 
|  | 361 | # of a build request with an incorrect configuration. | 
|  | 362 | { # Volume describes a Docker container volume which is mounted into build steps | 
|  | 363 | # in order to persist files across build step execution. | 
|  | 364 | "path": "A String", # Path at which to mount the volume. | 
|  | 365 | # | 
|  | 366 | # Paths must be absolute and cannot conflict with other volume paths on the | 
|  | 367 | # same build step or with certain reserved volume paths. | 
|  | 368 | "name": "A String", # Name of the volume to mount. | 
|  | 369 | # | 
|  | 370 | # Volume names must be unique per build step and must be valid names for | 
|  | 371 | # Docker volumes. Each named volume must be used by at least two build steps. | 
|  | 372 | }, | 
|  | 373 | ], | 
|  | 374 | "args": [ # A list of arguments that will be presented to the step when it is started. | 
|  | 375 | # | 
|  | 376 | # If the image used to run the step's container has an entrypoint, the `args` | 
|  | 377 | # are used as arguments to that entrypoint. If the image does not define | 
|  | 378 | # an entrypoint, the first element in args is used as the entrypoint, | 
|  | 379 | # and the remainder will be used as arguments. | 
|  | 380 | "A String", | 
|  | 381 | ], | 
|  | 382 | "status": "A String", # Output only. Status of the build step. At this time, build step status is | 
|  | 383 | # only updated on build completion; step status is not updated in real-time | 
|  | 384 | # as the build progresses. | 
|  | 385 | "timeout": "A String", # Time limit for executing this build step. If not defined, the step has no | 
|  | 386 | # time limit and will be allowed to continue to run until either it completes | 
|  | 387 | # or the build itself times out. | 
|  | 388 | "pullTiming": { # Start and end times for a build execution phase. # Output only. Stores timing information for pulling this build step's | 
|  | 389 | # builder image only. | 
|  | 390 | "endTime": "A String", # End of time span. | 
|  | 391 | "startTime": "A String", # Start of time span. | 
|  | 392 | }, | 
|  | 393 | "name": "A String", # Required. The name of the container image that will run this particular | 
|  | 394 | # build step. | 
|  | 395 | # | 
|  | 396 | # If the image is available in the host's Docker daemon's cache, it | 
|  | 397 | # will be run directly. If not, the host will attempt to pull the image | 
|  | 398 | # first, using the builder service account's credentials if necessary. | 
|  | 399 | # | 
|  | 400 | # The Docker daemon's cache will already have the latest versions of all of | 
|  | 401 | # the officially supported build steps | 
|  | 402 | # ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)). | 
|  | 403 | # The Docker daemon will also have cached many of the layers for some popular | 
|  | 404 | # images, like "ubuntu", "debian", but they will be refreshed at the time you | 
|  | 405 | # attempt to use them. | 
|  | 406 | # | 
|  | 407 | # If you built an image in a previous build step, it will be stored in the | 
|  | 408 | # host's Docker daemon's cache and is available to use as the name for a | 
|  | 409 | # later build step. | 
|  | 410 | "id": "A String", # Unique identifier for this build step, used in `wait_for` to | 
|  | 411 | # reference this build step as a dependency. | 
|  | 412 | "secretEnv": [ # A list of environment variables which are encrypted using a Cloud Key | 
|  | 413 | # Management Service crypto key. These values must be specified in the | 
|  | 414 | # build's `Secret`. | 
|  | 415 | "A String", | 
|  | 416 | ], | 
|  | 417 | "dir": "A String", # Working directory to use when running this step's container. | 
|  | 418 | # | 
|  | 419 | # If this value is a relative path, it is relative to the build's working | 
|  | 420 | # directory. If this value is absolute, it may be outside the build's working | 
|  | 421 | # directory, in which case the contents of the path may not be persisted | 
|  | 422 | # across build step executions, unless a `volume` for that path is specified. | 
|  | 423 | # | 
|  | 424 | # If the build specifies a `RepoSource` with `dir` and a step with a `dir`, | 
|  | 425 | # which specifies an absolute path, the `RepoSource` `dir` is ignored for | 
|  | 426 | # the step's execution. | 
|  | 427 | "env": [ # A list of environment variable definitions to be used when running a step. | 
|  | 428 | # | 
|  | 429 | # The elements are of the form "KEY=VALUE" for the environment variable "KEY" | 
|  | 430 | # being given the value "VALUE". | 
|  | 431 | "A String", | 
|  | 432 | ], | 
|  | 433 | "waitFor": [ # The ID(s) of the step(s) that this build step depends on. | 
|  | 434 | # This build step will not start until all the build steps in `wait_for` | 
|  | 435 | # have completed successfully. If `wait_for` is empty, this build step will | 
|  | 436 | # start when all previous build steps in the `Build.Steps` list have | 
|  | 437 | # completed successfully. | 
|  | 438 | "A String", | 
|  | 439 | ], | 
|  | 440 | "timing": { # Start and end times for a build execution phase. # Output only. Stores timing information for executing this build step. | 
|  | 441 | "endTime": "A String", # End of time span. | 
|  | 442 | "startTime": "A String", # Start of time span. | 
|  | 443 | }, | 
|  | 444 | }, | 
|  | 445 | ], | 
|  | 446 | "buildTriggerId": "A String", # Output only. The ID of the `BuildTrigger` that triggered this build, if it | 
|  | 447 | # was triggered automatically. | 
|  | 448 | "id": "A String", # Output only. Unique identifier of the build. | 
|  | 449 | "tags": [ # Tags for annotation of a `Build`. These are not docker tags. | 
|  | 450 | "A String", | 
|  | 451 | ], | 
|  | 452 | "substitutions": { # Substitutions data for `Build` resource. | 
|  | 453 | "a_key": "A String", | 
|  | 454 | }, | 
|  | 455 | "startTime": "A String", # Output only. Time at which execution of the build was started. | 
|  | 456 | "timing": { # Output only. Stores timing information for phases of the build. Valid keys | 
|  | 457 | # are: | 
|  | 458 | # | 
|  | 459 | # * BUILD: time to execute all build steps | 
|  | 460 | # * PUSH: time to push all specified images. | 
|  | 461 | # * FETCHSOURCE: time to fetch source. | 
|  | 462 | # | 
|  | 463 | # If the build does not specify source or images, | 
|  | 464 | # these keys will not be included. | 
|  | 465 | "a_key": { # Start and end times for a build execution phase. | 
|  | 466 | "endTime": "A String", # End of time span. | 
|  | 467 | "startTime": "A String", # Start of time span. | 
|  | 468 | }, | 
|  | 469 | }, | 
|  | 470 | "sourceProvenance": { # Provenance of the source. Ways to find the original source, or verify that # Output only. A permanent fixed identifier for source. | 
|  | 471 | # some source was used for this build. | 
|  | 472 | "resolvedRepoSource": { # Location of the source in a Google Cloud Source Repository. # A copy of the build's `source.repo_source`, if exists, with any | 
|  | 473 | # revisions resolved. | 
|  | 474 | "commitSha": "A String", # Explicit commit SHA to build. | 
|  | 475 | "substitutions": { # Substitutions to use in a triggered build. | 
|  | 476 | # Should only be used with RunBuildTrigger | 
|  | 477 | "a_key": "A String", | 
|  | 478 | }, | 
|  | 479 | "invertRegex": True or False, # Only trigger a build if the revision regex does NOT match the revision | 
|  | 480 | # regex. | 
|  | 481 | "dir": "A String", # Directory, relative to the source root, in which to run the build. | 
|  | 482 | # | 
|  | 483 | # This must be a relative path. If a step's `dir` is specified and is an | 
|  | 484 | # absolute path, this value is ignored for that step's execution. | 
|  | 485 | "branchName": "A String", # Regex matching branches to build. | 
|  | 486 | # | 
|  | 487 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 488 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 489 | "tagName": "A String", # Regex matching tags to build. | 
|  | 490 | # | 
|  | 491 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 492 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 493 | "projectId": "A String", # ID of the project that owns the Cloud Source Repository. If omitted, the | 
|  | 494 | # project ID requesting the build is assumed. | 
|  | 495 | "repoName": "A String", # Required. Name of the Cloud Source Repository. | 
|  | 496 | }, | 
|  | 497 | "resolvedStorageSource": { # Location of the source in an archive file in Google Cloud Storage. # A copy of the build's `source.storage_source`, if exists, with any | 
|  | 498 | # generations resolved. | 
|  | 499 | "generation": "A String", # Google Cloud Storage generation for the object. If the generation is | 
|  | 500 | # omitted, the latest generation will be used. | 
|  | 501 | "bucket": "A String", # Google Cloud Storage bucket containing the source (see | 
|  | 502 | # [Bucket Name | 
|  | 503 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 504 | "object": "A String", # Google Cloud Storage object containing the source. | 
|  | 505 | # | 
|  | 506 | # This object must be a gzipped archive file (`.tar.gz`) containing source to | 
|  | 507 | # build. | 
|  | 508 | }, | 
|  | 509 | "fileHashes": { # Output only. Hash(es) of the build source, which can be used to verify that | 
|  | 510 | # the original source integrity was maintained in the build. Note that | 
|  | 511 | # `FileHashes` will only be populated if `BuildOptions` has requested a | 
|  | 512 | # `SourceProvenanceHash`. | 
|  | 513 | # | 
|  | 514 | # The keys to this map are file paths used as build source and the values | 
|  | 515 | # contain the hash values for those files. | 
|  | 516 | # | 
|  | 517 | # If the build source came in a single package such as a gzipped tarfile | 
|  | 518 | # (`.tar.gz`), the `FileHash` will be for the single path to that file. | 
|  | 519 | "a_key": { # Container message for hashes of byte content of files, used in | 
|  | 520 | # SourceProvenance messages to verify integrity of source input to the build. | 
|  | 521 | "fileHash": [ # Collection of file hashes. | 
|  | 522 | { # Container message for hash values. | 
|  | 523 | "value": "A String", # The hash value. | 
|  | 524 | "type": "A String", # The type of hash that was performed. | 
|  | 525 | }, | 
|  | 526 | ], | 
|  | 527 | }, | 
|  | 528 | }, | 
|  | 529 | }, | 
|  | 530 | "createTime": "A String", # Output only. Time at which the request to create the build was received. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 531 | }</pre> | 
|  | 532 | </div> | 
|  | 533 |  | 
|  | 534 | <div class="method"> | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 535 | <code class="details" id="create">create(projectId, body=None, x__xgafv=None)</code> | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 536 | <pre>Starts a build with the specified configuration. | 
|  | 537 |  | 
|  | 538 | This method returns a long-running `Operation`, which includes the build | 
|  | 539 | ID. Pass the build ID to `GetBuild` to determine the build status (such as | 
|  | 540 | `SUCCESS` or `FAILURE`). | 
|  | 541 |  | 
|  | 542 | Args: | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 543 | projectId: string, Required. ID of the project. (required) | 
|  | 544 | body: object, The request body. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 545 | The object takes the form of: | 
|  | 546 |  | 
|  | 547 | { # A build resource in the Cloud Build API. | 
|  | 548 | # | 
|  | 549 | # At a high level, a `Build` describes where to find source code, how to build | 
|  | 550 | # it (for example, the builder image to run on the source), and where to store | 
|  | 551 | # the built artifacts. | 
|  | 552 | # | 
|  | 553 | # Fields can include the following variables, which will be expanded when the | 
|  | 554 | # build is created: | 
|  | 555 | # | 
|  | 556 | # - $PROJECT_ID: the project ID of the build. | 
|  | 557 | # - $BUILD_ID: the autogenerated ID of the build. | 
|  | 558 | # - $REPO_NAME: the source repository name specified by RepoSource. | 
|  | 559 | # - $BRANCH_NAME: the branch name specified by RepoSource. | 
|  | 560 | # - $TAG_NAME: the tag name specified by RepoSource. | 
|  | 561 | # - $REVISION_ID or $COMMIT_SHA: the commit SHA specified by RepoSource or | 
|  | 562 | #   resolved from the specified branch or tag. | 
|  | 563 | # - $SHORT_SHA: first 7 characters of $REVISION_ID or $COMMIT_SHA. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 564 | "images": [ # A list of images to be pushed upon the successful completion of all build | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 565 | # steps. | 
|  | 566 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 567 | # The images are pushed using the builder service account's credentials. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 568 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 569 | # The digests of the pushed images will be stored in the `Build` resource's | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 570 | # results field. | 
|  | 571 | # | 
|  | 572 | # If any of the images fail to be pushed, the build status is marked | 
|  | 573 | # `FAILURE`. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 574 | "A String", | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 575 | ], | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 576 | "projectId": "A String", # Output only. ID of the project. | 
|  | 577 | "logUrl": "A String", # Output only. URL to logs for this build in Google Cloud Console. | 
|  | 578 | "queueTtl": "A String", # TTL in queue for this build. If provided and the build is enqueued longer | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 579 | # than this value, the build will expire and the build status will be | 
|  | 580 | # `EXPIRED`. | 
|  | 581 | # | 
|  | 582 | # The TTL starts ticking from create_time. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 583 | "finishTime": "A String", # Output only. Time at which execution of the build was finished. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 584 | # | 
|  | 585 | # The difference between finish_time and start_time is the duration of the | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 586 | # build's execution. | 
|  | 587 | "source": { # Location of the source in a supported storage service. # The location of the source files to build. | 
|  | 588 | "storageSource": { # Location of the source in an archive file in Google Cloud Storage. # If provided, get the source from this location in Google Cloud Storage. | 
|  | 589 | "generation": "A String", # Google Cloud Storage generation for the object. If the generation is | 
|  | 590 | # omitted, the latest generation will be used. | 
|  | 591 | "bucket": "A String", # Google Cloud Storage bucket containing the source (see | 
|  | 592 | # [Bucket Name | 
|  | 593 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 594 | "object": "A String", # Google Cloud Storage object containing the source. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 595 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 596 | # This object must be a gzipped archive file (`.tar.gz`) containing source to | 
|  | 597 | # build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 598 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 599 | "repoSource": { # Location of the source in a Google Cloud Source Repository. # If provided, get the source from this location in a Cloud Source | 
|  | 600 | # Repository. | 
|  | 601 | "commitSha": "A String", # Explicit commit SHA to build. | 
|  | 602 | "substitutions": { # Substitutions to use in a triggered build. | 
|  | 603 | # Should only be used with RunBuildTrigger | 
|  | 604 | "a_key": "A String", | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 605 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 606 | "invertRegex": True or False, # Only trigger a build if the revision regex does NOT match the revision | 
|  | 607 | # regex. | 
|  | 608 | "dir": "A String", # Directory, relative to the source root, in which to run the build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 609 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 610 | # This must be a relative path. If a step's `dir` is specified and is an | 
|  | 611 | # absolute path, this value is ignored for that step's execution. | 
|  | 612 | "branchName": "A String", # Regex matching branches to build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 613 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 614 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 615 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 616 | "tagName": "A String", # Regex matching tags to build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 617 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 618 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 619 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 620 | "projectId": "A String", # ID of the project that owns the Cloud Source Repository. If omitted, the | 
|  | 621 | # project ID requesting the build is assumed. | 
|  | 622 | "repoName": "A String", # Required. Name of the Cloud Source Repository. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 623 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 624 | }, | 
|  | 625 | "options": { # Optional arguments to enable specific features of builds. # Special options for this build. | 
|  | 626 | "workerPool": "A String", # Option to specify a `WorkerPool` for the build. | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 627 | # Format: projects/{project}/workerPools/{workerPool} | 
|  | 628 | # | 
|  | 629 | # This field is experimental. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 630 | "env": [ # A list of global environment variable definitions that will exist for all | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 631 | # build steps in this build. If a variable is defined in both globally and in | 
|  | 632 | # a build step, the variable will use the build step value. | 
|  | 633 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 634 | # The elements are of the form "KEY=VALUE" for the environment variable "KEY" | 
|  | 635 | # being given the value "VALUE". | 
|  | 636 | "A String", | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 637 | ], | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 638 | "logging": "A String", # Option to specify the logging mode, which determines where the logs are | 
|  | 639 | # stored. | 
|  | 640 | "requestedVerifyOption": "A String", # Requested verifiability options. | 
|  | 641 | "substitutionOption": "A String", # Option to specify behavior when there is an error in the substitution | 
|  | 642 | # checks. | 
|  | 643 | "diskSizeGb": "A String", # Requested disk size for the VM that runs the build. Note that this is *NOT* | 
|  | 644 | # "disk free"; some of the space will be used by the operating system and | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 645 | # build utilities. Also note that this is the minimum disk size that will be | 
|  | 646 | # allocated for the build -- the build may run with a larger disk than | 
|  | 647 | # requested. At present, the maximum disk size is 1000GB; builds that request | 
|  | 648 | # more than the maximum are rejected with an error. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 649 | "sourceProvenanceHash": [ # Requested hash for SourceProvenance. | 
|  | 650 | "A String", | 
|  | 651 | ], | 
|  | 652 | "secretEnv": [ # A list of global environment variables, which are encrypted using a Cloud | 
|  | 653 | # Key Management Service crypto key. These values must be specified in the | 
|  | 654 | # build's `Secret`. These variables will be available to all build steps | 
|  | 655 | # in this build. | 
|  | 656 | "A String", | 
|  | 657 | ], | 
|  | 658 | "volumes": [ # Global list of volumes to mount for ALL build steps | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 659 | # | 
|  | 660 | # Each volume is created as an empty volume prior to starting the build | 
|  | 661 | # process. Upon completion of the build, volumes and their contents are | 
|  | 662 | # discarded. Global volume names and paths cannot conflict with the volumes | 
|  | 663 | # defined a build step. | 
|  | 664 | # | 
|  | 665 | # Using a global volume in a build with only one step is not valid as | 
|  | 666 | # it is indicative of a build request with an incorrect configuration. | 
|  | 667 | { # Volume describes a Docker container volume which is mounted into build steps | 
|  | 668 | # in order to persist files across build step execution. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 669 | "path": "A String", # Path at which to mount the volume. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 670 | # | 
|  | 671 | # Paths must be absolute and cannot conflict with other volume paths on the | 
|  | 672 | # same build step or with certain reserved volume paths. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 673 | "name": "A String", # Name of the volume to mount. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 674 | # | 
|  | 675 | # Volume names must be unique per build step and must be valid names for | 
|  | 676 | # Docker volumes. Each named volume must be used by at least two build steps. | 
|  | 677 | }, | 
|  | 678 | ], | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 679 | "machineType": "A String", # Compute Engine machine type on which to run the build. | 
|  | 680 | "logStreamingOption": "A String", # Option to define build log streaming behavior to Google Cloud | 
|  | 681 | # Storage. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 682 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 683 | "timeout": "A String", # Amount of time that this build should be allowed to run, to second | 
|  | 684 | # granularity. If this amount of time elapses, work on the build will cease | 
|  | 685 | # and the build status will be `TIMEOUT`. | 
|  | 686 | # | 
|  | 687 | # Default time is ten minutes. | 
|  | 688 | "status": "A String", # Output only. Status of the build. | 
|  | 689 | "statusDetail": "A String", # Output only. Customer-readable message about the current status. | 
|  | 690 | "artifacts": { # Artifacts produced by a build that should be uploaded upon # Artifacts produced by the build that should be uploaded upon | 
|  | 691 | # successful completion of all build steps. | 
|  | 692 | # successful completion of all build steps. | 
|  | 693 | "objects": { # Files in the workspace to upload to Cloud Storage upon successful # A list of objects to be uploaded to Cloud Storage upon successful | 
|  | 694 | # completion of all build steps. | 
|  | 695 | # | 
|  | 696 | # Files in the workspace matching specified paths globs will be uploaded to | 
|  | 697 | # the specified Cloud Storage location using the builder service account's | 
|  | 698 | # credentials. | 
|  | 699 | # | 
|  | 700 | # The location and generation of the uploaded objects will be stored in the | 
|  | 701 | # Build resource's results field. | 
|  | 702 | # | 
|  | 703 | # If any objects fail to be pushed, the build is marked FAILURE. | 
|  | 704 | # completion of all build steps. | 
|  | 705 | "timing": { # Start and end times for a build execution phase. # Output only. Stores timing information for pushing all artifact objects. | 
|  | 706 | "endTime": "A String", # End of time span. | 
|  | 707 | "startTime": "A String", # Start of time span. | 
|  | 708 | }, | 
|  | 709 | "paths": [ # Path globs used to match files in the build's workspace. | 
|  | 710 | "A String", | 
|  | 711 | ], | 
|  | 712 | "location": "A String", # Cloud Storage bucket and optional object path, in the form | 
|  | 713 | # "gs://bucket/path/to/somewhere/". (see [Bucket Name | 
|  | 714 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 715 | # | 
|  | 716 | # Files in the workspace matching any path pattern will be uploaded to | 
|  | 717 | # Cloud Storage with this location as a prefix. | 
|  | 718 | }, | 
|  | 719 | "images": [ # A list of images to be pushed upon the successful completion of all build | 
|  | 720 | # steps. | 
|  | 721 | # | 
|  | 722 | # The images will be pushed using the builder service account's credentials. | 
|  | 723 | # | 
|  | 724 | # The digests of the pushed images will be stored in the Build resource's | 
|  | 725 | # results field. | 
|  | 726 | # | 
|  | 727 | # If any of the images fail to be pushed, the build is marked FAILURE. | 
|  | 728 | "A String", | 
|  | 729 | ], | 
|  | 730 | }, | 
|  | 731 | "secrets": [ # Secrets to decrypt using Cloud Key Management Service. | 
|  | 732 | { # Pairs a set of secret environment variables containing encrypted | 
|  | 733 | # values with the Cloud KMS key to use to decrypt the value. | 
|  | 734 | "secretEnv": { # Map of environment variable name to its encrypted value. | 
|  | 735 | # | 
|  | 736 | # Secret environment variables must be unique across all of a build's | 
|  | 737 | # secrets, and must be used by at least one build step. Values can be at most | 
|  | 738 | # 64 KB in size. There can be at most 100 secret values across all of a | 
|  | 739 | # build's secrets. | 
|  | 740 | "a_key": "A String", | 
|  | 741 | }, | 
|  | 742 | "kmsKeyName": "A String", # Cloud KMS key name to use to decrypt these envs. | 
|  | 743 | }, | 
|  | 744 | ], | 
|  | 745 | "results": { # Artifacts created by the build pipeline. # Output only. Results of the build. | 
|  | 746 | "buildStepImages": [ # List of build step digests, in the order corresponding to build step | 
|  | 747 | # indices. | 
|  | 748 | "A String", | 
|  | 749 | ], | 
|  | 750 | "artifactTiming": { # Start and end times for a build execution phase. # Time to push all non-container artifacts. | 
|  | 751 | "endTime": "A String", # End of time span. | 
|  | 752 | "startTime": "A String", # Start of time span. | 
|  | 753 | }, | 
|  | 754 | "buildStepOutputs": [ # List of build step outputs, produced by builder images, in the order | 
|  | 755 | # corresponding to build step indices. | 
|  | 756 | # | 
|  | 757 | # [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders) | 
|  | 758 | # can produce this output by writing to `$BUILDER_OUTPUT/output`. | 
|  | 759 | # Only the first 4KB of data is stored. | 
|  | 760 | "A String", | 
|  | 761 | ], | 
|  | 762 | "images": [ # Container images that were built as a part of the build. | 
|  | 763 | { # An image built by the pipeline. | 
|  | 764 | "name": "A String", # Name used to push the container image to Google Container Registry, as | 
|  | 765 | # presented to `docker push`. | 
|  | 766 | "digest": "A String", # Docker Registry 2.0 digest. | 
|  | 767 | "pushTiming": { # Start and end times for a build execution phase. # Output only. Stores timing information for pushing the specified image. | 
|  | 768 | "endTime": "A String", # End of time span. | 
|  | 769 | "startTime": "A String", # Start of time span. | 
|  | 770 | }, | 
|  | 771 | }, | 
|  | 772 | ], | 
|  | 773 | "numArtifacts": "A String", # Number of artifacts uploaded. Only populated when artifacts are uploaded. | 
|  | 774 | "artifactManifest": "A String", # Path to the artifact manifest. Only populated when artifacts are uploaded. | 
|  | 775 | }, | 
|  | 776 | "logsBucket": "A String", # Google Cloud Storage bucket where logs should be written (see | 
|  | 777 | # [Bucket Name | 
|  | 778 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 779 | # Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`. | 
|  | 780 | "steps": [ # Required. The operations to be performed on the workspace. | 
|  | 781 | { # A step in the build pipeline. | 
|  | 782 | "entrypoint": "A String", # Entrypoint to be used instead of the build step image's default entrypoint. | 
|  | 783 | # If unset, the image's default entrypoint is used. | 
|  | 784 | "volumes": [ # List of volumes to mount into the build step. | 
|  | 785 | # | 
|  | 786 | # Each volume is created as an empty volume prior to execution of the | 
|  | 787 | # build step. Upon completion of the build, volumes and their contents are | 
|  | 788 | # discarded. | 
|  | 789 | # | 
|  | 790 | # Using a named volume in only one step is not valid as it is indicative | 
|  | 791 | # of a build request with an incorrect configuration. | 
|  | 792 | { # Volume describes a Docker container volume which is mounted into build steps | 
|  | 793 | # in order to persist files across build step execution. | 
|  | 794 | "path": "A String", # Path at which to mount the volume. | 
|  | 795 | # | 
|  | 796 | # Paths must be absolute and cannot conflict with other volume paths on the | 
|  | 797 | # same build step or with certain reserved volume paths. | 
|  | 798 | "name": "A String", # Name of the volume to mount. | 
|  | 799 | # | 
|  | 800 | # Volume names must be unique per build step and must be valid names for | 
|  | 801 | # Docker volumes. Each named volume must be used by at least two build steps. | 
|  | 802 | }, | 
|  | 803 | ], | 
|  | 804 | "args": [ # A list of arguments that will be presented to the step when it is started. | 
|  | 805 | # | 
|  | 806 | # If the image used to run the step's container has an entrypoint, the `args` | 
|  | 807 | # are used as arguments to that entrypoint. If the image does not define | 
|  | 808 | # an entrypoint, the first element in args is used as the entrypoint, | 
|  | 809 | # and the remainder will be used as arguments. | 
|  | 810 | "A String", | 
|  | 811 | ], | 
|  | 812 | "status": "A String", # Output only. Status of the build step. At this time, build step status is | 
|  | 813 | # only updated on build completion; step status is not updated in real-time | 
|  | 814 | # as the build progresses. | 
|  | 815 | "timeout": "A String", # Time limit for executing this build step. If not defined, the step has no | 
|  | 816 | # time limit and will be allowed to continue to run until either it completes | 
|  | 817 | # or the build itself times out. | 
|  | 818 | "pullTiming": { # Start and end times for a build execution phase. # Output only. Stores timing information for pulling this build step's | 
|  | 819 | # builder image only. | 
|  | 820 | "endTime": "A String", # End of time span. | 
|  | 821 | "startTime": "A String", # Start of time span. | 
|  | 822 | }, | 
|  | 823 | "name": "A String", # Required. The name of the container image that will run this particular | 
|  | 824 | # build step. | 
|  | 825 | # | 
|  | 826 | # If the image is available in the host's Docker daemon's cache, it | 
|  | 827 | # will be run directly. If not, the host will attempt to pull the image | 
|  | 828 | # first, using the builder service account's credentials if necessary. | 
|  | 829 | # | 
|  | 830 | # The Docker daemon's cache will already have the latest versions of all of | 
|  | 831 | # the officially supported build steps | 
|  | 832 | # ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)). | 
|  | 833 | # The Docker daemon will also have cached many of the layers for some popular | 
|  | 834 | # images, like "ubuntu", "debian", but they will be refreshed at the time you | 
|  | 835 | # attempt to use them. | 
|  | 836 | # | 
|  | 837 | # If you built an image in a previous build step, it will be stored in the | 
|  | 838 | # host's Docker daemon's cache and is available to use as the name for a | 
|  | 839 | # later build step. | 
|  | 840 | "id": "A String", # Unique identifier for this build step, used in `wait_for` to | 
|  | 841 | # reference this build step as a dependency. | 
|  | 842 | "secretEnv": [ # A list of environment variables which are encrypted using a Cloud Key | 
|  | 843 | # Management Service crypto key. These values must be specified in the | 
|  | 844 | # build's `Secret`. | 
|  | 845 | "A String", | 
|  | 846 | ], | 
|  | 847 | "dir": "A String", # Working directory to use when running this step's container. | 
|  | 848 | # | 
|  | 849 | # If this value is a relative path, it is relative to the build's working | 
|  | 850 | # directory. If this value is absolute, it may be outside the build's working | 
|  | 851 | # directory, in which case the contents of the path may not be persisted | 
|  | 852 | # across build step executions, unless a `volume` for that path is specified. | 
|  | 853 | # | 
|  | 854 | # If the build specifies a `RepoSource` with `dir` and a step with a `dir`, | 
|  | 855 | # which specifies an absolute path, the `RepoSource` `dir` is ignored for | 
|  | 856 | # the step's execution. | 
|  | 857 | "env": [ # A list of environment variable definitions to be used when running a step. | 
|  | 858 | # | 
|  | 859 | # The elements are of the form "KEY=VALUE" for the environment variable "KEY" | 
|  | 860 | # being given the value "VALUE". | 
|  | 861 | "A String", | 
|  | 862 | ], | 
|  | 863 | "waitFor": [ # The ID(s) of the step(s) that this build step depends on. | 
|  | 864 | # This build step will not start until all the build steps in `wait_for` | 
|  | 865 | # have completed successfully. If `wait_for` is empty, this build step will | 
|  | 866 | # start when all previous build steps in the `Build.Steps` list have | 
|  | 867 | # completed successfully. | 
|  | 868 | "A String", | 
|  | 869 | ], | 
|  | 870 | "timing": { # Start and end times for a build execution phase. # Output only. Stores timing information for executing this build step. | 
|  | 871 | "endTime": "A String", # End of time span. | 
|  | 872 | "startTime": "A String", # Start of time span. | 
|  | 873 | }, | 
|  | 874 | }, | 
|  | 875 | ], | 
|  | 876 | "buildTriggerId": "A String", # Output only. The ID of the `BuildTrigger` that triggered this build, if it | 
|  | 877 | # was triggered automatically. | 
|  | 878 | "id": "A String", # Output only. Unique identifier of the build. | 
|  | 879 | "tags": [ # Tags for annotation of a `Build`. These are not docker tags. | 
|  | 880 | "A String", | 
|  | 881 | ], | 
|  | 882 | "substitutions": { # Substitutions data for `Build` resource. | 
|  | 883 | "a_key": "A String", | 
|  | 884 | }, | 
|  | 885 | "startTime": "A String", # Output only. Time at which execution of the build was started. | 
|  | 886 | "timing": { # Output only. Stores timing information for phases of the build. Valid keys | 
|  | 887 | # are: | 
|  | 888 | # | 
|  | 889 | # * BUILD: time to execute all build steps | 
|  | 890 | # * PUSH: time to push all specified images. | 
|  | 891 | # * FETCHSOURCE: time to fetch source. | 
|  | 892 | # | 
|  | 893 | # If the build does not specify source or images, | 
|  | 894 | # these keys will not be included. | 
|  | 895 | "a_key": { # Start and end times for a build execution phase. | 
|  | 896 | "endTime": "A String", # End of time span. | 
|  | 897 | "startTime": "A String", # Start of time span. | 
|  | 898 | }, | 
|  | 899 | }, | 
|  | 900 | "sourceProvenance": { # Provenance of the source. Ways to find the original source, or verify that # Output only. A permanent fixed identifier for source. | 
|  | 901 | # some source was used for this build. | 
|  | 902 | "resolvedRepoSource": { # Location of the source in a Google Cloud Source Repository. # A copy of the build's `source.repo_source`, if exists, with any | 
|  | 903 | # revisions resolved. | 
|  | 904 | "commitSha": "A String", # Explicit commit SHA to build. | 
|  | 905 | "substitutions": { # Substitutions to use in a triggered build. | 
|  | 906 | # Should only be used with RunBuildTrigger | 
|  | 907 | "a_key": "A String", | 
|  | 908 | }, | 
|  | 909 | "invertRegex": True or False, # Only trigger a build if the revision regex does NOT match the revision | 
|  | 910 | # regex. | 
|  | 911 | "dir": "A String", # Directory, relative to the source root, in which to run the build. | 
|  | 912 | # | 
|  | 913 | # This must be a relative path. If a step's `dir` is specified and is an | 
|  | 914 | # absolute path, this value is ignored for that step's execution. | 
|  | 915 | "branchName": "A String", # Regex matching branches to build. | 
|  | 916 | # | 
|  | 917 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 918 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 919 | "tagName": "A String", # Regex matching tags to build. | 
|  | 920 | # | 
|  | 921 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 922 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 923 | "projectId": "A String", # ID of the project that owns the Cloud Source Repository. If omitted, the | 
|  | 924 | # project ID requesting the build is assumed. | 
|  | 925 | "repoName": "A String", # Required. Name of the Cloud Source Repository. | 
|  | 926 | }, | 
|  | 927 | "resolvedStorageSource": { # Location of the source in an archive file in Google Cloud Storage. # A copy of the build's `source.storage_source`, if exists, with any | 
|  | 928 | # generations resolved. | 
|  | 929 | "generation": "A String", # Google Cloud Storage generation for the object. If the generation is | 
|  | 930 | # omitted, the latest generation will be used. | 
|  | 931 | "bucket": "A String", # Google Cloud Storage bucket containing the source (see | 
|  | 932 | # [Bucket Name | 
|  | 933 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 934 | "object": "A String", # Google Cloud Storage object containing the source. | 
|  | 935 | # | 
|  | 936 | # This object must be a gzipped archive file (`.tar.gz`) containing source to | 
|  | 937 | # build. | 
|  | 938 | }, | 
|  | 939 | "fileHashes": { # Output only. Hash(es) of the build source, which can be used to verify that | 
|  | 940 | # the original source integrity was maintained in the build. Note that | 
|  | 941 | # `FileHashes` will only be populated if `BuildOptions` has requested a | 
|  | 942 | # `SourceProvenanceHash`. | 
|  | 943 | # | 
|  | 944 | # The keys to this map are file paths used as build source and the values | 
|  | 945 | # contain the hash values for those files. | 
|  | 946 | # | 
|  | 947 | # If the build source came in a single package such as a gzipped tarfile | 
|  | 948 | # (`.tar.gz`), the `FileHash` will be for the single path to that file. | 
|  | 949 | "a_key": { # Container message for hashes of byte content of files, used in | 
|  | 950 | # SourceProvenance messages to verify integrity of source input to the build. | 
|  | 951 | "fileHash": [ # Collection of file hashes. | 
|  | 952 | { # Container message for hash values. | 
|  | 953 | "value": "A String", # The hash value. | 
|  | 954 | "type": "A String", # The type of hash that was performed. | 
|  | 955 | }, | 
|  | 956 | ], | 
|  | 957 | }, | 
|  | 958 | }, | 
|  | 959 | }, | 
|  | 960 | "createTime": "A String", # Output only. Time at which the request to create the build was received. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 961 | } | 
|  | 962 |  | 
|  | 963 | x__xgafv: string, V1 error format. | 
|  | 964 | Allowed values | 
|  | 965 | 1 - v1 error format | 
|  | 966 | 2 - v2 error format | 
|  | 967 |  | 
|  | 968 | Returns: | 
|  | 969 | An object of the form: | 
|  | 970 |  | 
|  | 971 | { # This resource represents a long-running operation that is the result of a | 
|  | 972 | # network API call. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 973 | "done": True or False, # If the value is `false`, it means the operation is still in progress. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 974 | # If `true`, the operation is completed, and either `error` or `response` is | 
| Sai Cheemalapati | c30d2b5 | 2017-03-13 12:12:03 -0400 | [diff] [blame] | 975 | # available. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 976 | "response": { # The normal response of the operation in case of success.  If the original | 
| Sai Cheemalapati | c30d2b5 | 2017-03-13 12:12:03 -0400 | [diff] [blame] | 977 | # method returns no data on success, such as `Delete`, the response is | 
|  | 978 | # `google.protobuf.Empty`.  If the original method is standard | 
|  | 979 | # `Get`/`Create`/`Update`, the response should be the resource.  For other | 
|  | 980 | # methods, the response should have the type `XxxResponse`, where `Xxx` | 
|  | 981 | # is the original method name.  For example, if the original method name | 
|  | 982 | # is `TakeSnapshot()`, the inferred response type is | 
|  | 983 | # `TakeSnapshotResponse`. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 984 | "a_key": "", # Properties of the object. Contains field @type with type URL. | 
| Sai Cheemalapati | c30d2b5 | 2017-03-13 12:12:03 -0400 | [diff] [blame] | 985 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 986 | "name": "A String", # The server-assigned name, which is only unique within the same service that | 
| Sai Cheemalapati | c30d2b5 | 2017-03-13 12:12:03 -0400 | [diff] [blame] | 987 | # originally returns it. If you use the default HTTP mapping, the | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 988 | # `name` should be a resource name ending with `operations/{unique_id}`. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 989 | "error": { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation. | 
|  | 990 | # different programming environments, including REST APIs and RPC APIs. It is | 
|  | 991 | # used by [gRPC](https://github.com/grpc). Each `Status` message contains | 
|  | 992 | # three pieces of data: error code, error message, and error details. | 
|  | 993 | # | 
|  | 994 | # You can find out more about this error model and how to work with it in the | 
|  | 995 | # [API Design Guide](https://cloud.google.com/apis/design/errors). | 
|  | 996 | "code": 42, # The status code, which should be an enum value of google.rpc.Code. | 
|  | 997 | "message": "A String", # A developer-facing error message, which should be in English. Any | 
|  | 998 | # user-facing error message should be localized and sent in the | 
|  | 999 | # google.rpc.Status.details field, or localized by the client. | 
|  | 1000 | "details": [ # A list of messages that carry the error details.  There is a common set of | 
|  | 1001 | # message types for APIs to use. | 
|  | 1002 | { | 
|  | 1003 | "a_key": "", # Properties of the object. Contains field @type with type URL. | 
|  | 1004 | }, | 
|  | 1005 | ], | 
|  | 1006 | }, | 
|  | 1007 | "metadata": { # Service-specific metadata associated with the operation.  It typically | 
|  | 1008 | # contains progress information and common metadata such as create time. | 
|  | 1009 | # Some services might not provide such metadata.  Any method that returns a | 
|  | 1010 | # long-running operation should document the metadata type, if any. | 
|  | 1011 | "a_key": "", # Properties of the object. Contains field @type with type URL. | 
|  | 1012 | }, | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1013 | }</pre> | 
|  | 1014 | </div> | 
|  | 1015 |  | 
|  | 1016 | <div class="method"> | 
|  | 1017 | <code class="details" id="get">get(projectId, id, x__xgafv=None)</code> | 
|  | 1018 | <pre>Returns information about a previously requested build. | 
|  | 1019 |  | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1020 | The `Build` that is returned includes its status (such as `SUCCESS`, | 
|  | 1021 | `FAILURE`, or `WORKING`), and timing information. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1022 |  | 
|  | 1023 | Args: | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1024 | projectId: string, Required. ID of the project. (required) | 
|  | 1025 | id: string, Required. ID of the build. (required) | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1026 | x__xgafv: string, V1 error format. | 
|  | 1027 | Allowed values | 
|  | 1028 | 1 - v1 error format | 
|  | 1029 | 2 - v2 error format | 
|  | 1030 |  | 
|  | 1031 | Returns: | 
|  | 1032 | An object of the form: | 
|  | 1033 |  | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1034 | { # A build resource in the Cloud Build API. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1035 | # | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1036 | # At a high level, a `Build` describes where to find source code, how to build | 
|  | 1037 | # it (for example, the builder image to run on the source), and where to store | 
|  | 1038 | # the built artifacts. | 
| Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 1039 | # | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1040 | # Fields can include the following variables, which will be expanded when the | 
| Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 1041 | # build is created: | 
|  | 1042 | # | 
|  | 1043 | # - $PROJECT_ID: the project ID of the build. | 
|  | 1044 | # - $BUILD_ID: the autogenerated ID of the build. | 
|  | 1045 | # - $REPO_NAME: the source repository name specified by RepoSource. | 
|  | 1046 | # - $BRANCH_NAME: the branch name specified by RepoSource. | 
|  | 1047 | # - $TAG_NAME: the tag name specified by RepoSource. | 
|  | 1048 | # - $REVISION_ID or $COMMIT_SHA: the commit SHA specified by RepoSource or | 
|  | 1049 | #   resolved from the specified branch or tag. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1050 | # - $SHORT_SHA: first 7 characters of $REVISION_ID or $COMMIT_SHA. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1051 | "images": [ # A list of images to be pushed upon the successful completion of all build | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1052 | # steps. | 
|  | 1053 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1054 | # The images are pushed using the builder service account's credentials. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1055 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1056 | # The digests of the pushed images will be stored in the `Build` resource's | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1057 | # results field. | 
|  | 1058 | # | 
|  | 1059 | # If any of the images fail to be pushed, the build status is marked | 
|  | 1060 | # `FAILURE`. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1061 | "A String", | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1062 | ], | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1063 | "projectId": "A String", # Output only. ID of the project. | 
|  | 1064 | "logUrl": "A String", # Output only. URL to logs for this build in Google Cloud Console. | 
|  | 1065 | "queueTtl": "A String", # TTL in queue for this build. If provided and the build is enqueued longer | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1066 | # than this value, the build will expire and the build status will be | 
|  | 1067 | # `EXPIRED`. | 
|  | 1068 | # | 
|  | 1069 | # The TTL starts ticking from create_time. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1070 | "finishTime": "A String", # Output only. Time at which execution of the build was finished. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1071 | # | 
|  | 1072 | # The difference between finish_time and start_time is the duration of the | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1073 | # build's execution. | 
|  | 1074 | "source": { # Location of the source in a supported storage service. # The location of the source files to build. | 
|  | 1075 | "storageSource": { # Location of the source in an archive file in Google Cloud Storage. # If provided, get the source from this location in Google Cloud Storage. | 
|  | 1076 | "generation": "A String", # Google Cloud Storage generation for the object. If the generation is | 
|  | 1077 | # omitted, the latest generation will be used. | 
|  | 1078 | "bucket": "A String", # Google Cloud Storage bucket containing the source (see | 
|  | 1079 | # [Bucket Name | 
|  | 1080 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 1081 | "object": "A String", # Google Cloud Storage object containing the source. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1082 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1083 | # This object must be a gzipped archive file (`.tar.gz`) containing source to | 
|  | 1084 | # build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1085 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1086 | "repoSource": { # Location of the source in a Google Cloud Source Repository. # If provided, get the source from this location in a Cloud Source | 
|  | 1087 | # Repository. | 
|  | 1088 | "commitSha": "A String", # Explicit commit SHA to build. | 
|  | 1089 | "substitutions": { # Substitutions to use in a triggered build. | 
|  | 1090 | # Should only be used with RunBuildTrigger | 
|  | 1091 | "a_key": "A String", | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1092 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1093 | "invertRegex": True or False, # Only trigger a build if the revision regex does NOT match the revision | 
|  | 1094 | # regex. | 
|  | 1095 | "dir": "A String", # Directory, relative to the source root, in which to run the build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1096 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1097 | # This must be a relative path. If a step's `dir` is specified and is an | 
|  | 1098 | # absolute path, this value is ignored for that step's execution. | 
|  | 1099 | "branchName": "A String", # Regex matching branches to build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1100 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1101 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 1102 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 1103 | "tagName": "A String", # Regex matching tags to build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1104 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1105 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 1106 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 1107 | "projectId": "A String", # ID of the project that owns the Cloud Source Repository. If omitted, the | 
|  | 1108 | # project ID requesting the build is assumed. | 
|  | 1109 | "repoName": "A String", # Required. Name of the Cloud Source Repository. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1110 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1111 | }, | 
|  | 1112 | "options": { # Optional arguments to enable specific features of builds. # Special options for this build. | 
|  | 1113 | "workerPool": "A String", # Option to specify a `WorkerPool` for the build. | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1114 | # Format: projects/{project}/workerPools/{workerPool} | 
|  | 1115 | # | 
|  | 1116 | # This field is experimental. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1117 | "env": [ # A list of global environment variable definitions that will exist for all | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1118 | # build steps in this build. If a variable is defined in both globally and in | 
|  | 1119 | # a build step, the variable will use the build step value. | 
|  | 1120 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1121 | # The elements are of the form "KEY=VALUE" for the environment variable "KEY" | 
|  | 1122 | # being given the value "VALUE". | 
|  | 1123 | "A String", | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1124 | ], | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1125 | "logging": "A String", # Option to specify the logging mode, which determines where the logs are | 
|  | 1126 | # stored. | 
|  | 1127 | "requestedVerifyOption": "A String", # Requested verifiability options. | 
|  | 1128 | "substitutionOption": "A String", # Option to specify behavior when there is an error in the substitution | 
|  | 1129 | # checks. | 
|  | 1130 | "diskSizeGb": "A String", # Requested disk size for the VM that runs the build. Note that this is *NOT* | 
|  | 1131 | # "disk free"; some of the space will be used by the operating system and | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1132 | # build utilities. Also note that this is the minimum disk size that will be | 
|  | 1133 | # allocated for the build -- the build may run with a larger disk than | 
|  | 1134 | # requested. At present, the maximum disk size is 1000GB; builds that request | 
|  | 1135 | # more than the maximum are rejected with an error. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1136 | "sourceProvenanceHash": [ # Requested hash for SourceProvenance. | 
|  | 1137 | "A String", | 
|  | 1138 | ], | 
|  | 1139 | "secretEnv": [ # A list of global environment variables, which are encrypted using a Cloud | 
|  | 1140 | # Key Management Service crypto key. These values must be specified in the | 
|  | 1141 | # build's `Secret`. These variables will be available to all build steps | 
|  | 1142 | # in this build. | 
|  | 1143 | "A String", | 
|  | 1144 | ], | 
|  | 1145 | "volumes": [ # Global list of volumes to mount for ALL build steps | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1146 | # | 
|  | 1147 | # Each volume is created as an empty volume prior to starting the build | 
|  | 1148 | # process. Upon completion of the build, volumes and their contents are | 
|  | 1149 | # discarded. Global volume names and paths cannot conflict with the volumes | 
|  | 1150 | # defined a build step. | 
|  | 1151 | # | 
|  | 1152 | # Using a global volume in a build with only one step is not valid as | 
|  | 1153 | # it is indicative of a build request with an incorrect configuration. | 
|  | 1154 | { # Volume describes a Docker container volume which is mounted into build steps | 
|  | 1155 | # in order to persist files across build step execution. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1156 | "path": "A String", # Path at which to mount the volume. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1157 | # | 
|  | 1158 | # Paths must be absolute and cannot conflict with other volume paths on the | 
|  | 1159 | # same build step or with certain reserved volume paths. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1160 | "name": "A String", # Name of the volume to mount. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1161 | # | 
|  | 1162 | # Volume names must be unique per build step and must be valid names for | 
|  | 1163 | # Docker volumes. Each named volume must be used by at least two build steps. | 
|  | 1164 | }, | 
|  | 1165 | ], | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1166 | "machineType": "A String", # Compute Engine machine type on which to run the build. | 
|  | 1167 | "logStreamingOption": "A String", # Option to define build log streaming behavior to Google Cloud | 
|  | 1168 | # Storage. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1169 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1170 | "timeout": "A String", # Amount of time that this build should be allowed to run, to second | 
|  | 1171 | # granularity. If this amount of time elapses, work on the build will cease | 
|  | 1172 | # and the build status will be `TIMEOUT`. | 
|  | 1173 | # | 
|  | 1174 | # Default time is ten minutes. | 
|  | 1175 | "status": "A String", # Output only. Status of the build. | 
|  | 1176 | "statusDetail": "A String", # Output only. Customer-readable message about the current status. | 
|  | 1177 | "artifacts": { # Artifacts produced by a build that should be uploaded upon # Artifacts produced by the build that should be uploaded upon | 
|  | 1178 | # successful completion of all build steps. | 
|  | 1179 | # successful completion of all build steps. | 
|  | 1180 | "objects": { # Files in the workspace to upload to Cloud Storage upon successful # A list of objects to be uploaded to Cloud Storage upon successful | 
|  | 1181 | # completion of all build steps. | 
|  | 1182 | # | 
|  | 1183 | # Files in the workspace matching specified paths globs will be uploaded to | 
|  | 1184 | # the specified Cloud Storage location using the builder service account's | 
|  | 1185 | # credentials. | 
|  | 1186 | # | 
|  | 1187 | # The location and generation of the uploaded objects will be stored in the | 
|  | 1188 | # Build resource's results field. | 
|  | 1189 | # | 
|  | 1190 | # If any objects fail to be pushed, the build is marked FAILURE. | 
|  | 1191 | # completion of all build steps. | 
|  | 1192 | "timing": { # Start and end times for a build execution phase. # Output only. Stores timing information for pushing all artifact objects. | 
|  | 1193 | "endTime": "A String", # End of time span. | 
|  | 1194 | "startTime": "A String", # Start of time span. | 
|  | 1195 | }, | 
|  | 1196 | "paths": [ # Path globs used to match files in the build's workspace. | 
|  | 1197 | "A String", | 
|  | 1198 | ], | 
|  | 1199 | "location": "A String", # Cloud Storage bucket and optional object path, in the form | 
|  | 1200 | # "gs://bucket/path/to/somewhere/". (see [Bucket Name | 
|  | 1201 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 1202 | # | 
|  | 1203 | # Files in the workspace matching any path pattern will be uploaded to | 
|  | 1204 | # Cloud Storage with this location as a prefix. | 
|  | 1205 | }, | 
|  | 1206 | "images": [ # A list of images to be pushed upon the successful completion of all build | 
|  | 1207 | # steps. | 
|  | 1208 | # | 
|  | 1209 | # The images will be pushed using the builder service account's credentials. | 
|  | 1210 | # | 
|  | 1211 | # The digests of the pushed images will be stored in the Build resource's | 
|  | 1212 | # results field. | 
|  | 1213 | # | 
|  | 1214 | # If any of the images fail to be pushed, the build is marked FAILURE. | 
|  | 1215 | "A String", | 
|  | 1216 | ], | 
|  | 1217 | }, | 
|  | 1218 | "secrets": [ # Secrets to decrypt using Cloud Key Management Service. | 
|  | 1219 | { # Pairs a set of secret environment variables containing encrypted | 
|  | 1220 | # values with the Cloud KMS key to use to decrypt the value. | 
|  | 1221 | "secretEnv": { # Map of environment variable name to its encrypted value. | 
|  | 1222 | # | 
|  | 1223 | # Secret environment variables must be unique across all of a build's | 
|  | 1224 | # secrets, and must be used by at least one build step. Values can be at most | 
|  | 1225 | # 64 KB in size. There can be at most 100 secret values across all of a | 
|  | 1226 | # build's secrets. | 
|  | 1227 | "a_key": "A String", | 
|  | 1228 | }, | 
|  | 1229 | "kmsKeyName": "A String", # Cloud KMS key name to use to decrypt these envs. | 
|  | 1230 | }, | 
|  | 1231 | ], | 
|  | 1232 | "results": { # Artifacts created by the build pipeline. # Output only. Results of the build. | 
|  | 1233 | "buildStepImages": [ # List of build step digests, in the order corresponding to build step | 
|  | 1234 | # indices. | 
|  | 1235 | "A String", | 
|  | 1236 | ], | 
|  | 1237 | "artifactTiming": { # Start and end times for a build execution phase. # Time to push all non-container artifacts. | 
|  | 1238 | "endTime": "A String", # End of time span. | 
|  | 1239 | "startTime": "A String", # Start of time span. | 
|  | 1240 | }, | 
|  | 1241 | "buildStepOutputs": [ # List of build step outputs, produced by builder images, in the order | 
|  | 1242 | # corresponding to build step indices. | 
|  | 1243 | # | 
|  | 1244 | # [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders) | 
|  | 1245 | # can produce this output by writing to `$BUILDER_OUTPUT/output`. | 
|  | 1246 | # Only the first 4KB of data is stored. | 
|  | 1247 | "A String", | 
|  | 1248 | ], | 
|  | 1249 | "images": [ # Container images that were built as a part of the build. | 
|  | 1250 | { # An image built by the pipeline. | 
|  | 1251 | "name": "A String", # Name used to push the container image to Google Container Registry, as | 
|  | 1252 | # presented to `docker push`. | 
|  | 1253 | "digest": "A String", # Docker Registry 2.0 digest. | 
|  | 1254 | "pushTiming": { # Start and end times for a build execution phase. # Output only. Stores timing information for pushing the specified image. | 
|  | 1255 | "endTime": "A String", # End of time span. | 
|  | 1256 | "startTime": "A String", # Start of time span. | 
|  | 1257 | }, | 
|  | 1258 | }, | 
|  | 1259 | ], | 
|  | 1260 | "numArtifacts": "A String", # Number of artifacts uploaded. Only populated when artifacts are uploaded. | 
|  | 1261 | "artifactManifest": "A String", # Path to the artifact manifest. Only populated when artifacts are uploaded. | 
|  | 1262 | }, | 
|  | 1263 | "logsBucket": "A String", # Google Cloud Storage bucket where logs should be written (see | 
|  | 1264 | # [Bucket Name | 
|  | 1265 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 1266 | # Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`. | 
|  | 1267 | "steps": [ # Required. The operations to be performed on the workspace. | 
|  | 1268 | { # A step in the build pipeline. | 
|  | 1269 | "entrypoint": "A String", # Entrypoint to be used instead of the build step image's default entrypoint. | 
|  | 1270 | # If unset, the image's default entrypoint is used. | 
|  | 1271 | "volumes": [ # List of volumes to mount into the build step. | 
|  | 1272 | # | 
|  | 1273 | # Each volume is created as an empty volume prior to execution of the | 
|  | 1274 | # build step. Upon completion of the build, volumes and their contents are | 
|  | 1275 | # discarded. | 
|  | 1276 | # | 
|  | 1277 | # Using a named volume in only one step is not valid as it is indicative | 
|  | 1278 | # of a build request with an incorrect configuration. | 
|  | 1279 | { # Volume describes a Docker container volume which is mounted into build steps | 
|  | 1280 | # in order to persist files across build step execution. | 
|  | 1281 | "path": "A String", # Path at which to mount the volume. | 
|  | 1282 | # | 
|  | 1283 | # Paths must be absolute and cannot conflict with other volume paths on the | 
|  | 1284 | # same build step or with certain reserved volume paths. | 
|  | 1285 | "name": "A String", # Name of the volume to mount. | 
|  | 1286 | # | 
|  | 1287 | # Volume names must be unique per build step and must be valid names for | 
|  | 1288 | # Docker volumes. Each named volume must be used by at least two build steps. | 
|  | 1289 | }, | 
|  | 1290 | ], | 
|  | 1291 | "args": [ # A list of arguments that will be presented to the step when it is started. | 
|  | 1292 | # | 
|  | 1293 | # If the image used to run the step's container has an entrypoint, the `args` | 
|  | 1294 | # are used as arguments to that entrypoint. If the image does not define | 
|  | 1295 | # an entrypoint, the first element in args is used as the entrypoint, | 
|  | 1296 | # and the remainder will be used as arguments. | 
|  | 1297 | "A String", | 
|  | 1298 | ], | 
|  | 1299 | "status": "A String", # Output only. Status of the build step. At this time, build step status is | 
|  | 1300 | # only updated on build completion; step status is not updated in real-time | 
|  | 1301 | # as the build progresses. | 
|  | 1302 | "timeout": "A String", # Time limit for executing this build step. If not defined, the step has no | 
|  | 1303 | # time limit and will be allowed to continue to run until either it completes | 
|  | 1304 | # or the build itself times out. | 
|  | 1305 | "pullTiming": { # Start and end times for a build execution phase. # Output only. Stores timing information for pulling this build step's | 
|  | 1306 | # builder image only. | 
|  | 1307 | "endTime": "A String", # End of time span. | 
|  | 1308 | "startTime": "A String", # Start of time span. | 
|  | 1309 | }, | 
|  | 1310 | "name": "A String", # Required. The name of the container image that will run this particular | 
|  | 1311 | # build step. | 
|  | 1312 | # | 
|  | 1313 | # If the image is available in the host's Docker daemon's cache, it | 
|  | 1314 | # will be run directly. If not, the host will attempt to pull the image | 
|  | 1315 | # first, using the builder service account's credentials if necessary. | 
|  | 1316 | # | 
|  | 1317 | # The Docker daemon's cache will already have the latest versions of all of | 
|  | 1318 | # the officially supported build steps | 
|  | 1319 | # ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)). | 
|  | 1320 | # The Docker daemon will also have cached many of the layers for some popular | 
|  | 1321 | # images, like "ubuntu", "debian", but they will be refreshed at the time you | 
|  | 1322 | # attempt to use them. | 
|  | 1323 | # | 
|  | 1324 | # If you built an image in a previous build step, it will be stored in the | 
|  | 1325 | # host's Docker daemon's cache and is available to use as the name for a | 
|  | 1326 | # later build step. | 
|  | 1327 | "id": "A String", # Unique identifier for this build step, used in `wait_for` to | 
|  | 1328 | # reference this build step as a dependency. | 
|  | 1329 | "secretEnv": [ # A list of environment variables which are encrypted using a Cloud Key | 
|  | 1330 | # Management Service crypto key. These values must be specified in the | 
|  | 1331 | # build's `Secret`. | 
|  | 1332 | "A String", | 
|  | 1333 | ], | 
|  | 1334 | "dir": "A String", # Working directory to use when running this step's container. | 
|  | 1335 | # | 
|  | 1336 | # If this value is a relative path, it is relative to the build's working | 
|  | 1337 | # directory. If this value is absolute, it may be outside the build's working | 
|  | 1338 | # directory, in which case the contents of the path may not be persisted | 
|  | 1339 | # across build step executions, unless a `volume` for that path is specified. | 
|  | 1340 | # | 
|  | 1341 | # If the build specifies a `RepoSource` with `dir` and a step with a `dir`, | 
|  | 1342 | # which specifies an absolute path, the `RepoSource` `dir` is ignored for | 
|  | 1343 | # the step's execution. | 
|  | 1344 | "env": [ # A list of environment variable definitions to be used when running a step. | 
|  | 1345 | # | 
|  | 1346 | # The elements are of the form "KEY=VALUE" for the environment variable "KEY" | 
|  | 1347 | # being given the value "VALUE". | 
|  | 1348 | "A String", | 
|  | 1349 | ], | 
|  | 1350 | "waitFor": [ # The ID(s) of the step(s) that this build step depends on. | 
|  | 1351 | # This build step will not start until all the build steps in `wait_for` | 
|  | 1352 | # have completed successfully. If `wait_for` is empty, this build step will | 
|  | 1353 | # start when all previous build steps in the `Build.Steps` list have | 
|  | 1354 | # completed successfully. | 
|  | 1355 | "A String", | 
|  | 1356 | ], | 
|  | 1357 | "timing": { # Start and end times for a build execution phase. # Output only. Stores timing information for executing this build step. | 
|  | 1358 | "endTime": "A String", # End of time span. | 
|  | 1359 | "startTime": "A String", # Start of time span. | 
|  | 1360 | }, | 
|  | 1361 | }, | 
|  | 1362 | ], | 
|  | 1363 | "buildTriggerId": "A String", # Output only. The ID of the `BuildTrigger` that triggered this build, if it | 
|  | 1364 | # was triggered automatically. | 
|  | 1365 | "id": "A String", # Output only. Unique identifier of the build. | 
|  | 1366 | "tags": [ # Tags for annotation of a `Build`. These are not docker tags. | 
|  | 1367 | "A String", | 
|  | 1368 | ], | 
|  | 1369 | "substitutions": { # Substitutions data for `Build` resource. | 
|  | 1370 | "a_key": "A String", | 
|  | 1371 | }, | 
|  | 1372 | "startTime": "A String", # Output only. Time at which execution of the build was started. | 
|  | 1373 | "timing": { # Output only. Stores timing information for phases of the build. Valid keys | 
|  | 1374 | # are: | 
|  | 1375 | # | 
|  | 1376 | # * BUILD: time to execute all build steps | 
|  | 1377 | # * PUSH: time to push all specified images. | 
|  | 1378 | # * FETCHSOURCE: time to fetch source. | 
|  | 1379 | # | 
|  | 1380 | # If the build does not specify source or images, | 
|  | 1381 | # these keys will not be included. | 
|  | 1382 | "a_key": { # Start and end times for a build execution phase. | 
|  | 1383 | "endTime": "A String", # End of time span. | 
|  | 1384 | "startTime": "A String", # Start of time span. | 
|  | 1385 | }, | 
|  | 1386 | }, | 
|  | 1387 | "sourceProvenance": { # Provenance of the source. Ways to find the original source, or verify that # Output only. A permanent fixed identifier for source. | 
|  | 1388 | # some source was used for this build. | 
|  | 1389 | "resolvedRepoSource": { # Location of the source in a Google Cloud Source Repository. # A copy of the build's `source.repo_source`, if exists, with any | 
|  | 1390 | # revisions resolved. | 
|  | 1391 | "commitSha": "A String", # Explicit commit SHA to build. | 
|  | 1392 | "substitutions": { # Substitutions to use in a triggered build. | 
|  | 1393 | # Should only be used with RunBuildTrigger | 
|  | 1394 | "a_key": "A String", | 
|  | 1395 | }, | 
|  | 1396 | "invertRegex": True or False, # Only trigger a build if the revision regex does NOT match the revision | 
|  | 1397 | # regex. | 
|  | 1398 | "dir": "A String", # Directory, relative to the source root, in which to run the build. | 
|  | 1399 | # | 
|  | 1400 | # This must be a relative path. If a step's `dir` is specified and is an | 
|  | 1401 | # absolute path, this value is ignored for that step's execution. | 
|  | 1402 | "branchName": "A String", # Regex matching branches to build. | 
|  | 1403 | # | 
|  | 1404 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 1405 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 1406 | "tagName": "A String", # Regex matching tags to build. | 
|  | 1407 | # | 
|  | 1408 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 1409 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 1410 | "projectId": "A String", # ID of the project that owns the Cloud Source Repository. If omitted, the | 
|  | 1411 | # project ID requesting the build is assumed. | 
|  | 1412 | "repoName": "A String", # Required. Name of the Cloud Source Repository. | 
|  | 1413 | }, | 
|  | 1414 | "resolvedStorageSource": { # Location of the source in an archive file in Google Cloud Storage. # A copy of the build's `source.storage_source`, if exists, with any | 
|  | 1415 | # generations resolved. | 
|  | 1416 | "generation": "A String", # Google Cloud Storage generation for the object. If the generation is | 
|  | 1417 | # omitted, the latest generation will be used. | 
|  | 1418 | "bucket": "A String", # Google Cloud Storage bucket containing the source (see | 
|  | 1419 | # [Bucket Name | 
|  | 1420 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 1421 | "object": "A String", # Google Cloud Storage object containing the source. | 
|  | 1422 | # | 
|  | 1423 | # This object must be a gzipped archive file (`.tar.gz`) containing source to | 
|  | 1424 | # build. | 
|  | 1425 | }, | 
|  | 1426 | "fileHashes": { # Output only. Hash(es) of the build source, which can be used to verify that | 
|  | 1427 | # the original source integrity was maintained in the build. Note that | 
|  | 1428 | # `FileHashes` will only be populated if `BuildOptions` has requested a | 
|  | 1429 | # `SourceProvenanceHash`. | 
|  | 1430 | # | 
|  | 1431 | # The keys to this map are file paths used as build source and the values | 
|  | 1432 | # contain the hash values for those files. | 
|  | 1433 | # | 
|  | 1434 | # If the build source came in a single package such as a gzipped tarfile | 
|  | 1435 | # (`.tar.gz`), the `FileHash` will be for the single path to that file. | 
|  | 1436 | "a_key": { # Container message for hashes of byte content of files, used in | 
|  | 1437 | # SourceProvenance messages to verify integrity of source input to the build. | 
|  | 1438 | "fileHash": [ # Collection of file hashes. | 
|  | 1439 | { # Container message for hash values. | 
|  | 1440 | "value": "A String", # The hash value. | 
|  | 1441 | "type": "A String", # The type of hash that was performed. | 
|  | 1442 | }, | 
|  | 1443 | ], | 
|  | 1444 | }, | 
|  | 1445 | }, | 
|  | 1446 | }, | 
|  | 1447 | "createTime": "A String", # Output only. Time at which the request to create the build was received. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1448 | }</pre> | 
|  | 1449 | </div> | 
|  | 1450 |  | 
|  | 1451 | <div class="method"> | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1452 | <code class="details" id="list">list(projectId, filter=None, pageToken=None, pageSize=None, x__xgafv=None)</code> | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1453 | <pre>Lists previously requested builds. | 
|  | 1454 |  | 
|  | 1455 | Previously requested builds may still be in-progress, or may have finished | 
|  | 1456 | successfully or unsuccessfully. | 
|  | 1457 |  | 
|  | 1458 | Args: | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1459 | projectId: string, Required. ID of the project. (required) | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1460 | filter: string, The raw filter text to constrain the results. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1461 | pageToken: string, Token to provide to skip to a particular spot in the list. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1462 | pageSize: integer, Number of results to return in the list. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1463 | x__xgafv: string, V1 error format. | 
|  | 1464 | Allowed values | 
|  | 1465 | 1 - v1 error format | 
|  | 1466 | 2 - v2 error format | 
|  | 1467 |  | 
|  | 1468 | Returns: | 
|  | 1469 | An object of the form: | 
|  | 1470 |  | 
|  | 1471 | { # Response including listed builds. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1472 | "nextPageToken": "A String", # Token to receive the next page of results. | 
|  | 1473 | "builds": [ # Builds will be sorted by `create_time`, descending. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1474 | { # A build resource in the Cloud Build API. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1475 | # | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1476 | # At a high level, a `Build` describes where to find source code, how to build | 
|  | 1477 | # it (for example, the builder image to run on the source), and where to store | 
|  | 1478 | # the built artifacts. | 
| Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 1479 | # | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1480 | # Fields can include the following variables, which will be expanded when the | 
| Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 1481 | # build is created: | 
|  | 1482 | # | 
|  | 1483 | # - $PROJECT_ID: the project ID of the build. | 
|  | 1484 | # - $BUILD_ID: the autogenerated ID of the build. | 
|  | 1485 | # - $REPO_NAME: the source repository name specified by RepoSource. | 
|  | 1486 | # - $BRANCH_NAME: the branch name specified by RepoSource. | 
|  | 1487 | # - $TAG_NAME: the tag name specified by RepoSource. | 
|  | 1488 | # - $REVISION_ID or $COMMIT_SHA: the commit SHA specified by RepoSource or | 
|  | 1489 | #   resolved from the specified branch or tag. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1490 | # - $SHORT_SHA: first 7 characters of $REVISION_ID or $COMMIT_SHA. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1491 | "images": [ # A list of images to be pushed upon the successful completion of all build | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1492 | # steps. | 
|  | 1493 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1494 | # The images are pushed using the builder service account's credentials. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1495 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1496 | # The digests of the pushed images will be stored in the `Build` resource's | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1497 | # results field. | 
|  | 1498 | # | 
|  | 1499 | # If any of the images fail to be pushed, the build status is marked | 
|  | 1500 | # `FAILURE`. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1501 | "A String", | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1502 | ], | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1503 | "projectId": "A String", # Output only. ID of the project. | 
|  | 1504 | "logUrl": "A String", # Output only. URL to logs for this build in Google Cloud Console. | 
|  | 1505 | "queueTtl": "A String", # TTL in queue for this build. If provided and the build is enqueued longer | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1506 | # than this value, the build will expire and the build status will be | 
|  | 1507 | # `EXPIRED`. | 
|  | 1508 | # | 
|  | 1509 | # The TTL starts ticking from create_time. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1510 | "finishTime": "A String", # Output only. Time at which execution of the build was finished. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1511 | # | 
|  | 1512 | # The difference between finish_time and start_time is the duration of the | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1513 | # build's execution. | 
|  | 1514 | "source": { # Location of the source in a supported storage service. # The location of the source files to build. | 
|  | 1515 | "storageSource": { # Location of the source in an archive file in Google Cloud Storage. # If provided, get the source from this location in Google Cloud Storage. | 
|  | 1516 | "generation": "A String", # Google Cloud Storage generation for the object. If the generation is | 
|  | 1517 | # omitted, the latest generation will be used. | 
|  | 1518 | "bucket": "A String", # Google Cloud Storage bucket containing the source (see | 
|  | 1519 | # [Bucket Name | 
|  | 1520 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 1521 | "object": "A String", # Google Cloud Storage object containing the source. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1522 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1523 | # This object must be a gzipped archive file (`.tar.gz`) containing source to | 
|  | 1524 | # build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1525 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1526 | "repoSource": { # Location of the source in a Google Cloud Source Repository. # If provided, get the source from this location in a Cloud Source | 
|  | 1527 | # Repository. | 
|  | 1528 | "commitSha": "A String", # Explicit commit SHA to build. | 
|  | 1529 | "substitutions": { # Substitutions to use in a triggered build. | 
|  | 1530 | # Should only be used with RunBuildTrigger | 
|  | 1531 | "a_key": "A String", | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1532 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1533 | "invertRegex": True or False, # Only trigger a build if the revision regex does NOT match the revision | 
|  | 1534 | # regex. | 
|  | 1535 | "dir": "A String", # Directory, relative to the source root, in which to run the build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1536 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1537 | # This must be a relative path. If a step's `dir` is specified and is an | 
|  | 1538 | # absolute path, this value is ignored for that step's execution. | 
|  | 1539 | "branchName": "A String", # Regex matching branches to build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1540 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1541 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 1542 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 1543 | "tagName": "A String", # Regex matching tags to build. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1544 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1545 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 1546 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 1547 | "projectId": "A String", # ID of the project that owns the Cloud Source Repository. If omitted, the | 
|  | 1548 | # project ID requesting the build is assumed. | 
|  | 1549 | "repoName": "A String", # Required. Name of the Cloud Source Repository. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1550 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1551 | }, | 
|  | 1552 | "options": { # Optional arguments to enable specific features of builds. # Special options for this build. | 
|  | 1553 | "workerPool": "A String", # Option to specify a `WorkerPool` for the build. | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1554 | # Format: projects/{project}/workerPools/{workerPool} | 
|  | 1555 | # | 
|  | 1556 | # This field is experimental. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1557 | "env": [ # A list of global environment variable definitions that will exist for all | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1558 | # build steps in this build. If a variable is defined in both globally and in | 
|  | 1559 | # a build step, the variable will use the build step value. | 
|  | 1560 | # | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1561 | # The elements are of the form "KEY=VALUE" for the environment variable "KEY" | 
|  | 1562 | # being given the value "VALUE". | 
|  | 1563 | "A String", | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1564 | ], | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1565 | "logging": "A String", # Option to specify the logging mode, which determines where the logs are | 
|  | 1566 | # stored. | 
|  | 1567 | "requestedVerifyOption": "A String", # Requested verifiability options. | 
|  | 1568 | "substitutionOption": "A String", # Option to specify behavior when there is an error in the substitution | 
|  | 1569 | # checks. | 
|  | 1570 | "diskSizeGb": "A String", # Requested disk size for the VM that runs the build. Note that this is *NOT* | 
|  | 1571 | # "disk free"; some of the space will be used by the operating system and | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1572 | # build utilities. Also note that this is the minimum disk size that will be | 
|  | 1573 | # allocated for the build -- the build may run with a larger disk than | 
|  | 1574 | # requested. At present, the maximum disk size is 1000GB; builds that request | 
|  | 1575 | # more than the maximum are rejected with an error. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1576 | "sourceProvenanceHash": [ # Requested hash for SourceProvenance. | 
|  | 1577 | "A String", | 
|  | 1578 | ], | 
|  | 1579 | "secretEnv": [ # A list of global environment variables, which are encrypted using a Cloud | 
|  | 1580 | # Key Management Service crypto key. These values must be specified in the | 
|  | 1581 | # build's `Secret`. These variables will be available to all build steps | 
|  | 1582 | # in this build. | 
|  | 1583 | "A String", | 
|  | 1584 | ], | 
|  | 1585 | "volumes": [ # Global list of volumes to mount for ALL build steps | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1586 | # | 
|  | 1587 | # Each volume is created as an empty volume prior to starting the build | 
|  | 1588 | # process. Upon completion of the build, volumes and their contents are | 
|  | 1589 | # discarded. Global volume names and paths cannot conflict with the volumes | 
|  | 1590 | # defined a build step. | 
|  | 1591 | # | 
|  | 1592 | # Using a global volume in a build with only one step is not valid as | 
|  | 1593 | # it is indicative of a build request with an incorrect configuration. | 
|  | 1594 | { # Volume describes a Docker container volume which is mounted into build steps | 
|  | 1595 | # in order to persist files across build step execution. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1596 | "path": "A String", # Path at which to mount the volume. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1597 | # | 
|  | 1598 | # Paths must be absolute and cannot conflict with other volume paths on the | 
|  | 1599 | # same build step or with certain reserved volume paths. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1600 | "name": "A String", # Name of the volume to mount. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1601 | # | 
|  | 1602 | # Volume names must be unique per build step and must be valid names for | 
|  | 1603 | # Docker volumes. Each named volume must be used by at least two build steps. | 
|  | 1604 | }, | 
|  | 1605 | ], | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1606 | "machineType": "A String", # Compute Engine machine type on which to run the build. | 
|  | 1607 | "logStreamingOption": "A String", # Option to define build log streaming behavior to Google Cloud | 
|  | 1608 | # Storage. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1609 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1610 | "timeout": "A String", # Amount of time that this build should be allowed to run, to second | 
|  | 1611 | # granularity. If this amount of time elapses, work on the build will cease | 
|  | 1612 | # and the build status will be `TIMEOUT`. | 
|  | 1613 | # | 
|  | 1614 | # Default time is ten minutes. | 
|  | 1615 | "status": "A String", # Output only. Status of the build. | 
|  | 1616 | "statusDetail": "A String", # Output only. Customer-readable message about the current status. | 
|  | 1617 | "artifacts": { # Artifacts produced by a build that should be uploaded upon # Artifacts produced by the build that should be uploaded upon | 
|  | 1618 | # successful completion of all build steps. | 
|  | 1619 | # successful completion of all build steps. | 
|  | 1620 | "objects": { # Files in the workspace to upload to Cloud Storage upon successful # A list of objects to be uploaded to Cloud Storage upon successful | 
|  | 1621 | # completion of all build steps. | 
|  | 1622 | # | 
|  | 1623 | # Files in the workspace matching specified paths globs will be uploaded to | 
|  | 1624 | # the specified Cloud Storage location using the builder service account's | 
|  | 1625 | # credentials. | 
|  | 1626 | # | 
|  | 1627 | # The location and generation of the uploaded objects will be stored in the | 
|  | 1628 | # Build resource's results field. | 
|  | 1629 | # | 
|  | 1630 | # If any objects fail to be pushed, the build is marked FAILURE. | 
|  | 1631 | # completion of all build steps. | 
|  | 1632 | "timing": { # Start and end times for a build execution phase. # Output only. Stores timing information for pushing all artifact objects. | 
|  | 1633 | "endTime": "A String", # End of time span. | 
|  | 1634 | "startTime": "A String", # Start of time span. | 
|  | 1635 | }, | 
|  | 1636 | "paths": [ # Path globs used to match files in the build's workspace. | 
|  | 1637 | "A String", | 
|  | 1638 | ], | 
|  | 1639 | "location": "A String", # Cloud Storage bucket and optional object path, in the form | 
|  | 1640 | # "gs://bucket/path/to/somewhere/". (see [Bucket Name | 
|  | 1641 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 1642 | # | 
|  | 1643 | # Files in the workspace matching any path pattern will be uploaded to | 
|  | 1644 | # Cloud Storage with this location as a prefix. | 
|  | 1645 | }, | 
|  | 1646 | "images": [ # A list of images to be pushed upon the successful completion of all build | 
|  | 1647 | # steps. | 
|  | 1648 | # | 
|  | 1649 | # The images will be pushed using the builder service account's credentials. | 
|  | 1650 | # | 
|  | 1651 | # The digests of the pushed images will be stored in the Build resource's | 
|  | 1652 | # results field. | 
|  | 1653 | # | 
|  | 1654 | # If any of the images fail to be pushed, the build is marked FAILURE. | 
|  | 1655 | "A String", | 
|  | 1656 | ], | 
|  | 1657 | }, | 
|  | 1658 | "secrets": [ # Secrets to decrypt using Cloud Key Management Service. | 
|  | 1659 | { # Pairs a set of secret environment variables containing encrypted | 
|  | 1660 | # values with the Cloud KMS key to use to decrypt the value. | 
|  | 1661 | "secretEnv": { # Map of environment variable name to its encrypted value. | 
|  | 1662 | # | 
|  | 1663 | # Secret environment variables must be unique across all of a build's | 
|  | 1664 | # secrets, and must be used by at least one build step. Values can be at most | 
|  | 1665 | # 64 KB in size. There can be at most 100 secret values across all of a | 
|  | 1666 | # build's secrets. | 
|  | 1667 | "a_key": "A String", | 
|  | 1668 | }, | 
|  | 1669 | "kmsKeyName": "A String", # Cloud KMS key name to use to decrypt these envs. | 
|  | 1670 | }, | 
|  | 1671 | ], | 
|  | 1672 | "results": { # Artifacts created by the build pipeline. # Output only. Results of the build. | 
|  | 1673 | "buildStepImages": [ # List of build step digests, in the order corresponding to build step | 
|  | 1674 | # indices. | 
|  | 1675 | "A String", | 
|  | 1676 | ], | 
|  | 1677 | "artifactTiming": { # Start and end times for a build execution phase. # Time to push all non-container artifacts. | 
|  | 1678 | "endTime": "A String", # End of time span. | 
|  | 1679 | "startTime": "A String", # Start of time span. | 
|  | 1680 | }, | 
|  | 1681 | "buildStepOutputs": [ # List of build step outputs, produced by builder images, in the order | 
|  | 1682 | # corresponding to build step indices. | 
|  | 1683 | # | 
|  | 1684 | # [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders) | 
|  | 1685 | # can produce this output by writing to `$BUILDER_OUTPUT/output`. | 
|  | 1686 | # Only the first 4KB of data is stored. | 
|  | 1687 | "A String", | 
|  | 1688 | ], | 
|  | 1689 | "images": [ # Container images that were built as a part of the build. | 
|  | 1690 | { # An image built by the pipeline. | 
|  | 1691 | "name": "A String", # Name used to push the container image to Google Container Registry, as | 
|  | 1692 | # presented to `docker push`. | 
|  | 1693 | "digest": "A String", # Docker Registry 2.0 digest. | 
|  | 1694 | "pushTiming": { # Start and end times for a build execution phase. # Output only. Stores timing information for pushing the specified image. | 
|  | 1695 | "endTime": "A String", # End of time span. | 
|  | 1696 | "startTime": "A String", # Start of time span. | 
|  | 1697 | }, | 
|  | 1698 | }, | 
|  | 1699 | ], | 
|  | 1700 | "numArtifacts": "A String", # Number of artifacts uploaded. Only populated when artifacts are uploaded. | 
|  | 1701 | "artifactManifest": "A String", # Path to the artifact manifest. Only populated when artifacts are uploaded. | 
|  | 1702 | }, | 
|  | 1703 | "logsBucket": "A String", # Google Cloud Storage bucket where logs should be written (see | 
|  | 1704 | # [Bucket Name | 
|  | 1705 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 1706 | # Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`. | 
|  | 1707 | "steps": [ # Required. The operations to be performed on the workspace. | 
|  | 1708 | { # A step in the build pipeline. | 
|  | 1709 | "entrypoint": "A String", # Entrypoint to be used instead of the build step image's default entrypoint. | 
|  | 1710 | # If unset, the image's default entrypoint is used. | 
|  | 1711 | "volumes": [ # List of volumes to mount into the build step. | 
|  | 1712 | # | 
|  | 1713 | # Each volume is created as an empty volume prior to execution of the | 
|  | 1714 | # build step. Upon completion of the build, volumes and their contents are | 
|  | 1715 | # discarded. | 
|  | 1716 | # | 
|  | 1717 | # Using a named volume in only one step is not valid as it is indicative | 
|  | 1718 | # of a build request with an incorrect configuration. | 
|  | 1719 | { # Volume describes a Docker container volume which is mounted into build steps | 
|  | 1720 | # in order to persist files across build step execution. | 
|  | 1721 | "path": "A String", # Path at which to mount the volume. | 
|  | 1722 | # | 
|  | 1723 | # Paths must be absolute and cannot conflict with other volume paths on the | 
|  | 1724 | # same build step or with certain reserved volume paths. | 
|  | 1725 | "name": "A String", # Name of the volume to mount. | 
|  | 1726 | # | 
|  | 1727 | # Volume names must be unique per build step and must be valid names for | 
|  | 1728 | # Docker volumes. Each named volume must be used by at least two build steps. | 
|  | 1729 | }, | 
|  | 1730 | ], | 
|  | 1731 | "args": [ # A list of arguments that will be presented to the step when it is started. | 
|  | 1732 | # | 
|  | 1733 | # If the image used to run the step's container has an entrypoint, the `args` | 
|  | 1734 | # are used as arguments to that entrypoint. If the image does not define | 
|  | 1735 | # an entrypoint, the first element in args is used as the entrypoint, | 
|  | 1736 | # and the remainder will be used as arguments. | 
|  | 1737 | "A String", | 
|  | 1738 | ], | 
|  | 1739 | "status": "A String", # Output only. Status of the build step. At this time, build step status is | 
|  | 1740 | # only updated on build completion; step status is not updated in real-time | 
|  | 1741 | # as the build progresses. | 
|  | 1742 | "timeout": "A String", # Time limit for executing this build step. If not defined, the step has no | 
|  | 1743 | # time limit and will be allowed to continue to run until either it completes | 
|  | 1744 | # or the build itself times out. | 
|  | 1745 | "pullTiming": { # Start and end times for a build execution phase. # Output only. Stores timing information for pulling this build step's | 
|  | 1746 | # builder image only. | 
|  | 1747 | "endTime": "A String", # End of time span. | 
|  | 1748 | "startTime": "A String", # Start of time span. | 
|  | 1749 | }, | 
|  | 1750 | "name": "A String", # Required. The name of the container image that will run this particular | 
|  | 1751 | # build step. | 
|  | 1752 | # | 
|  | 1753 | # If the image is available in the host's Docker daemon's cache, it | 
|  | 1754 | # will be run directly. If not, the host will attempt to pull the image | 
|  | 1755 | # first, using the builder service account's credentials if necessary. | 
|  | 1756 | # | 
|  | 1757 | # The Docker daemon's cache will already have the latest versions of all of | 
|  | 1758 | # the officially supported build steps | 
|  | 1759 | # ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)). | 
|  | 1760 | # The Docker daemon will also have cached many of the layers for some popular | 
|  | 1761 | # images, like "ubuntu", "debian", but they will be refreshed at the time you | 
|  | 1762 | # attempt to use them. | 
|  | 1763 | # | 
|  | 1764 | # If you built an image in a previous build step, it will be stored in the | 
|  | 1765 | # host's Docker daemon's cache and is available to use as the name for a | 
|  | 1766 | # later build step. | 
|  | 1767 | "id": "A String", # Unique identifier for this build step, used in `wait_for` to | 
|  | 1768 | # reference this build step as a dependency. | 
|  | 1769 | "secretEnv": [ # A list of environment variables which are encrypted using a Cloud Key | 
|  | 1770 | # Management Service crypto key. These values must be specified in the | 
|  | 1771 | # build's `Secret`. | 
|  | 1772 | "A String", | 
|  | 1773 | ], | 
|  | 1774 | "dir": "A String", # Working directory to use when running this step's container. | 
|  | 1775 | # | 
|  | 1776 | # If this value is a relative path, it is relative to the build's working | 
|  | 1777 | # directory. If this value is absolute, it may be outside the build's working | 
|  | 1778 | # directory, in which case the contents of the path may not be persisted | 
|  | 1779 | # across build step executions, unless a `volume` for that path is specified. | 
|  | 1780 | # | 
|  | 1781 | # If the build specifies a `RepoSource` with `dir` and a step with a `dir`, | 
|  | 1782 | # which specifies an absolute path, the `RepoSource` `dir` is ignored for | 
|  | 1783 | # the step's execution. | 
|  | 1784 | "env": [ # A list of environment variable definitions to be used when running a step. | 
|  | 1785 | # | 
|  | 1786 | # The elements are of the form "KEY=VALUE" for the environment variable "KEY" | 
|  | 1787 | # being given the value "VALUE". | 
|  | 1788 | "A String", | 
|  | 1789 | ], | 
|  | 1790 | "waitFor": [ # The ID(s) of the step(s) that this build step depends on. | 
|  | 1791 | # This build step will not start until all the build steps in `wait_for` | 
|  | 1792 | # have completed successfully. If `wait_for` is empty, this build step will | 
|  | 1793 | # start when all previous build steps in the `Build.Steps` list have | 
|  | 1794 | # completed successfully. | 
|  | 1795 | "A String", | 
|  | 1796 | ], | 
|  | 1797 | "timing": { # Start and end times for a build execution phase. # Output only. Stores timing information for executing this build step. | 
|  | 1798 | "endTime": "A String", # End of time span. | 
|  | 1799 | "startTime": "A String", # Start of time span. | 
|  | 1800 | }, | 
|  | 1801 | }, | 
|  | 1802 | ], | 
|  | 1803 | "buildTriggerId": "A String", # Output only. The ID of the `BuildTrigger` that triggered this build, if it | 
|  | 1804 | # was triggered automatically. | 
|  | 1805 | "id": "A String", # Output only. Unique identifier of the build. | 
|  | 1806 | "tags": [ # Tags for annotation of a `Build`. These are not docker tags. | 
|  | 1807 | "A String", | 
|  | 1808 | ], | 
|  | 1809 | "substitutions": { # Substitutions data for `Build` resource. | 
|  | 1810 | "a_key": "A String", | 
|  | 1811 | }, | 
|  | 1812 | "startTime": "A String", # Output only. Time at which execution of the build was started. | 
|  | 1813 | "timing": { # Output only. Stores timing information for phases of the build. Valid keys | 
|  | 1814 | # are: | 
|  | 1815 | # | 
|  | 1816 | # * BUILD: time to execute all build steps | 
|  | 1817 | # * PUSH: time to push all specified images. | 
|  | 1818 | # * FETCHSOURCE: time to fetch source. | 
|  | 1819 | # | 
|  | 1820 | # If the build does not specify source or images, | 
|  | 1821 | # these keys will not be included. | 
|  | 1822 | "a_key": { # Start and end times for a build execution phase. | 
|  | 1823 | "endTime": "A String", # End of time span. | 
|  | 1824 | "startTime": "A String", # Start of time span. | 
|  | 1825 | }, | 
|  | 1826 | }, | 
|  | 1827 | "sourceProvenance": { # Provenance of the source. Ways to find the original source, or verify that # Output only. A permanent fixed identifier for source. | 
|  | 1828 | # some source was used for this build. | 
|  | 1829 | "resolvedRepoSource": { # Location of the source in a Google Cloud Source Repository. # A copy of the build's `source.repo_source`, if exists, with any | 
|  | 1830 | # revisions resolved. | 
|  | 1831 | "commitSha": "A String", # Explicit commit SHA to build. | 
|  | 1832 | "substitutions": { # Substitutions to use in a triggered build. | 
|  | 1833 | # Should only be used with RunBuildTrigger | 
|  | 1834 | "a_key": "A String", | 
|  | 1835 | }, | 
|  | 1836 | "invertRegex": True or False, # Only trigger a build if the revision regex does NOT match the revision | 
|  | 1837 | # regex. | 
|  | 1838 | "dir": "A String", # Directory, relative to the source root, in which to run the build. | 
|  | 1839 | # | 
|  | 1840 | # This must be a relative path. If a step's `dir` is specified and is an | 
|  | 1841 | # absolute path, this value is ignored for that step's execution. | 
|  | 1842 | "branchName": "A String", # Regex matching branches to build. | 
|  | 1843 | # | 
|  | 1844 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 1845 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 1846 | "tagName": "A String", # Regex matching tags to build. | 
|  | 1847 | # | 
|  | 1848 | # The syntax of the regular expressions accepted is the syntax accepted by | 
|  | 1849 | # RE2 and described at https://github.com/google/re2/wiki/Syntax | 
|  | 1850 | "projectId": "A String", # ID of the project that owns the Cloud Source Repository. If omitted, the | 
|  | 1851 | # project ID requesting the build is assumed. | 
|  | 1852 | "repoName": "A String", # Required. Name of the Cloud Source Repository. | 
|  | 1853 | }, | 
|  | 1854 | "resolvedStorageSource": { # Location of the source in an archive file in Google Cloud Storage. # A copy of the build's `source.storage_source`, if exists, with any | 
|  | 1855 | # generations resolved. | 
|  | 1856 | "generation": "A String", # Google Cloud Storage generation for the object. If the generation is | 
|  | 1857 | # omitted, the latest generation will be used. | 
|  | 1858 | "bucket": "A String", # Google Cloud Storage bucket containing the source (see | 
|  | 1859 | # [Bucket Name | 
|  | 1860 | # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). | 
|  | 1861 | "object": "A String", # Google Cloud Storage object containing the source. | 
|  | 1862 | # | 
|  | 1863 | # This object must be a gzipped archive file (`.tar.gz`) containing source to | 
|  | 1864 | # build. | 
|  | 1865 | }, | 
|  | 1866 | "fileHashes": { # Output only. Hash(es) of the build source, which can be used to verify that | 
|  | 1867 | # the original source integrity was maintained in the build. Note that | 
|  | 1868 | # `FileHashes` will only be populated if `BuildOptions` has requested a | 
|  | 1869 | # `SourceProvenanceHash`. | 
|  | 1870 | # | 
|  | 1871 | # The keys to this map are file paths used as build source and the values | 
|  | 1872 | # contain the hash values for those files. | 
|  | 1873 | # | 
|  | 1874 | # If the build source came in a single package such as a gzipped tarfile | 
|  | 1875 | # (`.tar.gz`), the `FileHash` will be for the single path to that file. | 
|  | 1876 | "a_key": { # Container message for hashes of byte content of files, used in | 
|  | 1877 | # SourceProvenance messages to verify integrity of source input to the build. | 
|  | 1878 | "fileHash": [ # Collection of file hashes. | 
|  | 1879 | { # Container message for hash values. | 
|  | 1880 | "value": "A String", # The hash value. | 
|  | 1881 | "type": "A String", # The type of hash that was performed. | 
|  | 1882 | }, | 
|  | 1883 | ], | 
|  | 1884 | }, | 
|  | 1885 | }, | 
|  | 1886 | }, | 
|  | 1887 | "createTime": "A String", # Output only. Time at which the request to create the build was received. | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1888 | }, | 
|  | 1889 | ], | 
|  | 1890 | }</pre> | 
|  | 1891 | </div> | 
|  | 1892 |  | 
|  | 1893 | <div class="method"> | 
|  | 1894 | <code class="details" id="list_next">list_next(previous_request, previous_response)</code> | 
|  | 1895 | <pre>Retrieves the next page of results. | 
|  | 1896 |  | 
|  | 1897 | Args: | 
|  | 1898 | previous_request: The request for the previous page. (required) | 
|  | 1899 | previous_response: The response from the request for the previous page. (required) | 
|  | 1900 |  | 
|  | 1901 | Returns: | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1902 | A request object that you can call 'execute()' on to request the next | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1903 | page. Returns None if there are no more items in the collection. | 
|  | 1904 | </pre> | 
|  | 1905 | </div> | 
|  | 1906 |  | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1907 | <div class="method"> | 
|  | 1908 | <code class="details" id="retry">retry(projectId, id, body=None, x__xgafv=None)</code> | 
|  | 1909 | <pre>Creates a new build based on the specified build. | 
|  | 1910 |  | 
|  | 1911 | This method creates a new build using the original build request, which may | 
|  | 1912 | or may not result in an identical build. | 
|  | 1913 |  | 
|  | 1914 | For triggered builds: | 
|  | 1915 |  | 
|  | 1916 | * Triggered builds resolve to a precise revision; therefore a retry of a | 
|  | 1917 | triggered build will result in a build that uses the same revision. | 
|  | 1918 |  | 
|  | 1919 | For non-triggered builds that specify `RepoSource`: | 
|  | 1920 |  | 
|  | 1921 | * If the original build built from the tip of a branch, the retried build | 
|  | 1922 | will build from the tip of that branch, which may not be the same revision | 
|  | 1923 | as the original build. | 
|  | 1924 | * If the original build specified a commit sha or revision ID, the retried | 
|  | 1925 | build will use the identical source. | 
|  | 1926 |  | 
|  | 1927 | For builds that specify `StorageSource`: | 
|  | 1928 |  | 
|  | 1929 | * If the original build pulled source from Google Cloud Storage without | 
|  | 1930 | specifying the generation of the object, the new build will use the current | 
|  | 1931 | object, which may be different from the original build source. | 
|  | 1932 | * If the original build pulled source from Cloud Storage and specified the | 
|  | 1933 | generation of the object, the new build will attempt to use the same | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1934 | object, which may or may not be available depending on the bucket's | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1935 | lifecycle management settings. | 
|  | 1936 |  | 
|  | 1937 | Args: | 
| Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1938 | projectId: string, Required. ID of the project. (required) | 
|  | 1939 | id: string, Required. Build ID of the original build. (required) | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1940 | body: object, The request body. | 
|  | 1941 | The object takes the form of: | 
|  | 1942 |  | 
|  | 1943 | { # Specifies a build to retry. | 
|  | 1944 | } | 
|  | 1945 |  | 
|  | 1946 | x__xgafv: string, V1 error format. | 
|  | 1947 | Allowed values | 
|  | 1948 | 1 - v1 error format | 
|  | 1949 | 2 - v2 error format | 
|  | 1950 |  | 
|  | 1951 | Returns: | 
|  | 1952 | An object of the form: | 
|  | 1953 |  | 
|  | 1954 | { # This resource represents a long-running operation that is the result of a | 
|  | 1955 | # network API call. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1956 | "done": True or False, # If the value is `false`, it means the operation is still in progress. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1957 | # If `true`, the operation is completed, and either `error` or `response` is | 
|  | 1958 | # available. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1959 | "response": { # The normal response of the operation in case of success.  If the original | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1960 | # method returns no data on success, such as `Delete`, the response is | 
|  | 1961 | # `google.protobuf.Empty`.  If the original method is standard | 
|  | 1962 | # `Get`/`Create`/`Update`, the response should be the resource.  For other | 
|  | 1963 | # methods, the response should have the type `XxxResponse`, where `Xxx` | 
|  | 1964 | # is the original method name.  For example, if the original method name | 
|  | 1965 | # is `TakeSnapshot()`, the inferred response type is | 
|  | 1966 | # `TakeSnapshotResponse`. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1967 | "a_key": "", # Properties of the object. Contains field @type with type URL. | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1968 | }, | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1969 | "name": "A String", # The server-assigned name, which is only unique within the same service that | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1970 | # originally returns it. If you use the default HTTP mapping, the | 
|  | 1971 | # `name` should be a resource name ending with `operations/{unique_id}`. | 
| Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1972 | "error": { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation. | 
|  | 1973 | # different programming environments, including REST APIs and RPC APIs. It is | 
|  | 1974 | # used by [gRPC](https://github.com/grpc). Each `Status` message contains | 
|  | 1975 | # three pieces of data: error code, error message, and error details. | 
|  | 1976 | # | 
|  | 1977 | # You can find out more about this error model and how to work with it in the | 
|  | 1978 | # [API Design Guide](https://cloud.google.com/apis/design/errors). | 
|  | 1979 | "code": 42, # The status code, which should be an enum value of google.rpc.Code. | 
|  | 1980 | "message": "A String", # A developer-facing error message, which should be in English. Any | 
|  | 1981 | # user-facing error message should be localized and sent in the | 
|  | 1982 | # google.rpc.Status.details field, or localized by the client. | 
|  | 1983 | "details": [ # A list of messages that carry the error details.  There is a common set of | 
|  | 1984 | # message types for APIs to use. | 
|  | 1985 | { | 
|  | 1986 | "a_key": "", # Properties of the object. Contains field @type with type URL. | 
|  | 1987 | }, | 
|  | 1988 | ], | 
|  | 1989 | }, | 
|  | 1990 | "metadata": { # Service-specific metadata associated with the operation.  It typically | 
|  | 1991 | # contains progress information and common metadata such as create time. | 
|  | 1992 | # Some services might not provide such metadata.  Any method that returns a | 
|  | 1993 | # long-running operation should document the metadata type, if any. | 
|  | 1994 | "a_key": "", # Properties of the object. Contains field @type with type URL. | 
|  | 1995 | }, | 
| Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1996 | }</pre> | 
|  | 1997 | </div> | 
|  | 1998 |  | 
| Jon Wayne Parrott | 0a471d3 | 2016-05-19 10:54:38 -0700 | [diff] [blame] | 1999 | </body></html> |