blob: 4a8d92b2ba901964b34722689151308db3ec73db [file] [log] [blame]
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04001<html><body>
2<style>
3
4body, 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
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, 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 Kim715bd7f2019-06-14 16:50:42 -070075<h1><a href="cloudfunctions_v1beta2.html">Cloud Functions API</a> . <a href="cloudfunctions_v1beta2.projects.html">projects</a> . <a href="cloudfunctions_v1beta2.projects.locations.html">locations</a> . <a href="cloudfunctions_v1beta2.projects.locations.functions.html">functions</a></h1>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040076<h2>Instance Methods</h2>
77<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070078 <code><a href="#call">call(name, body=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070079<p class="firstline">Synchronously invokes a deployed Cloud Function. To be used for testing</p>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040080<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070081 <code><a href="#create">create(location, body=None, x__xgafv=None)</a></code></p>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040082<p class="firstline">Creates a new function. If a function with the given name already exists in</p>
83<p class="toc_element">
84 <code><a href="#delete">delete(name, x__xgafv=None)</a></code></p>
85<p class="firstline">Deletes a function with the given name from the specified project. If the</p>
86<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070087 <code><a href="#generateDownloadUrl">generateDownloadUrl(name, body=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070088<p class="firstline">Returns a signed URL for downloading deployed function source code.</p>
89<p class="toc_element">
90 <code><a href="#generateUploadUrl">generateUploadUrl(parent, body=None, x__xgafv=None)</a></code></p>
91<p class="firstline">Returns a signed URL for uploading a function source code.</p>
92<p class="toc_element">
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040093 <code><a href="#get">get(name, x__xgafv=None)</a></code></p>
94<p class="firstline">Returns a function with the given name from the requested project.</p>
95<p class="toc_element">
Bu Sun Kim65020912020-05-20 12:08:20 -070096 <code><a href="#list">list(location, pageToken=None, pageSize=None, x__xgafv=None)</a></code></p>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040097<p class="firstline">Returns a list of functions that belong to the requested project.</p>
98<p class="toc_element">
99 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
100<p class="firstline">Retrieves the next page of results.</p>
101<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700102 <code><a href="#update">update(name, body=None, x__xgafv=None)</a></code></p>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400103<p class="firstline">Updates existing function.</p>
104<h3>Method Details</h3>
105<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700106 <code class="details" id="call">call(name, body=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700107 <pre>Synchronously invokes a deployed Cloud Function. To be used for testing
108purposes as very limited traffic is allowed. For more information on
109the actual limits refer to [API Calls](
110https://cloud.google.com/functions/quotas#rate_limits).
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400111
112Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700113 name: string, Required. The name of the function to be called. (required)
114 body: object, The request body.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400115 The object takes the form of:
116
117{ # Request for the `CallFunction` method.
Bu Sun Kim65020912020-05-20 12:08:20 -0700118 &quot;data&quot;: &quot;A String&quot;, # Required. Input to be passed to the function.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400119 }
120
121 x__xgafv: string, V1 error format.
122 Allowed values
123 1 - v1 error format
124 2 - v2 error format
125
126Returns:
127 An object of the form:
128
129 { # Response of `CallFunction` method.
Bu Sun Kim65020912020-05-20 12:08:20 -0700130 &quot;executionId&quot;: &quot;A String&quot;, # Execution id of function invocation.
131 &quot;result&quot;: &quot;A String&quot;, # Result populated for successful execution of synchronous function. Will
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400132 # not be populated if function does not return a result through context.
Bu Sun Kim65020912020-05-20 12:08:20 -0700133 &quot;error&quot;: &quot;A String&quot;, # Either system or user-function generated error. Set if execution
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400134 # was not successful.
135 }</pre>
136</div>
137
138<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700139 <code class="details" id="create">create(location, body=None, x__xgafv=None)</code>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400140 <pre>Creates a new function. If a function with the given name already exists in
141the specified project, the long running operation will return
142`ALREADY_EXISTS` error.
143
144Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700145 location: string, Required. The project and location in which the function should be created, specified
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400146in the format `projects/*/locations/*` (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700147 body: object, The request body.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400148 The object takes the form of:
149
150{ # Describes a Cloud Function that contains user computation executed in
151 # response to an event. It encapsulate function and triggers configurations.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700152 &quot;httpsTrigger&quot;: { # Describes HTTPSTrigger, could be used to connect web hooks to function. # An HTTPS endpoint type of source that can be triggered via URL.
153 &quot;url&quot;: &quot;A String&quot;, # Output only. The deployed url for the function.
154 },
155 &quot;maxInstances&quot;: 42, # The limit on the maximum number of function instances that may coexist at a
156 # given time.
157 &quot;environmentVariables&quot;: { # Environment variables that shall be available during function execution.
158 &quot;a_key&quot;: &quot;A String&quot;,
159 },
160 &quot;status&quot;: &quot;A String&quot;, # Output only. Status of the function deployment.
161 &quot;eventTrigger&quot;: { # Describes EventTrigger, used to request events be sent from another # A source that fires events in response to a condition in another service.
162 # service.
163 &quot;eventType&quot;: &quot;A String&quot;, # `event_type` names contain the service that is sending an event and the
164 # kind of event that was fired. Must be of the form
165 # `providers/*/eventTypes/*` e.g. Directly handle a Message published to
166 # Google Cloud Pub/Sub `providers/cloud.pubsub/eventTypes/topic.publish`.
167 #
168 # Handle an object changing in Google Cloud Storage:
169 # `providers/cloud.storage/eventTypes/object.change`
170 #
171 # Handle a write to the Firebase Realtime Database:
172 # `providers/google.firebase.database/eventTypes/ref.write`
173 &quot;resource&quot;: &quot;A String&quot;, # Which instance of the source&#x27;s service should send events. E.g. for Pub/Sub
174 # this would be a Pub/Sub topic at `projects/*/topics/*`. For Google Cloud
175 # Storage this would be a bucket at `projects/*/buckets/*`. For any source
176 # that only supports one instance per-project, this should be the name of the
177 # project (`projects/*`)
178 &quot;service&quot;: &quot;A String&quot;, # The hostname of the service that should be observed.
179 #
180 # If no string is provided, the default service implementing the API will
181 # be used. For example, `storage.googleapis.com` is the default for all
182 # event types in the `google.storage` namespace.
183 &quot;failurePolicy&quot;: { # Describes the policy in case of function&#x27;s execution failure. # Specifies policy for failed executions.
184 # If empty, then defaults to ignoring failures (i.e. not retrying them).
185 &quot;retry&quot;: { # Describes the retry policy in case of function&#x27;s execution failure. # If specified, then the function will be retried in case of a failure.
186 # A function execution will be retried on any failure.
187 # A failed execution will be retried up to 7 days with an exponential backoff
188 # (capped at 10 seconds).
189 # Retried execution is charged as any other execution.
190 },
191 },
192 },
193 &quot;sourceUploadUrl&quot;: &quot;A String&quot;, # The Google Cloud Storage signed URL used for source uploading, generated
194 # by google.cloud.functions.v1beta2.GenerateUploadUrl
195 &quot;timeout&quot;: &quot;A String&quot;, # The function execution timeout. Execution is considered failed and
196 # can be terminated if the function is not completed at the end of the
197 # timeout period. Defaults to 60 seconds.
198 &quot;availableMemoryMb&quot;: 42, # The amount of memory in MB available for a function.
199 # Defaults to 256MB.
200 &quot;runtime&quot;: &quot;A String&quot;, # The runtime in which to run the function. Required when deploying a new
201 # function, optional when updating an existing function. For a complete
202 # list of possible choices, see the
203 # [`gcloud` command
204 # reference](/sdk/gcloud/reference/functions/deploy#--runtime).
205 &quot;name&quot;: &quot;A String&quot;, # A user-defined name of the function. Function names must be unique
206 # globally and match pattern `projects/*/locations/*/functions/*`
207 &quot;versionId&quot;: &quot;A String&quot;, # Output only. The version identifier of the Cloud Function. Each deployment attempt
208 # results in a new version of a function being created.
209 &quot;serviceAccount&quot;: &quot;A String&quot;, # The email of the function&#x27;s service account. If empty, defaults to
210 # `{project_id}@appspot.gserviceaccount.com`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700211 &quot;sourceArchiveUrl&quot;: &quot;A String&quot;, # The Google Cloud Storage URL, starting with gs://, pointing to the zip
212 # archive which contains the function.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700213 &quot;vpcConnector&quot;: &quot;A String&quot;, # The VPC Network Connector that this cloud function can connect to. It can
214 # be either the fully-qualified URI, or the short name of the network
215 # connector resource. The format of this field is
216 # `projects/*/locations/*/connectors/*`
217 #
218 # This field is mutually exclusive with `network` field and will eventually
219 # replace it.
220 #
221 # See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for
222 # more information on connecting Cloud projects.
Bu Sun Kim65020912020-05-20 12:08:20 -0700223 &quot;network&quot;: &quot;A String&quot;, # The VPC Network that this cloud function can connect to. It can be
Dan O'Mearadd494642020-05-01 07:42:23 -0700224 # either the fully-qualified URI, or the short name of the network resource.
225 # If the short network name is used, the network must belong to the same
226 # project. Otherwise, it must belong to a project within the same
227 # organization. The format of this field is either
228 # `projects/{project}/global/networks/{network}` or `{network}`, where
229 # {project} is a project id where the network is defined, and {network} is
230 # the short name of the network.
231 #
232 # This field is mutually exclusive with `vpc_connector` and will be replaced
233 # by it.
234 #
235 # See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for
236 # more information on connecting Cloud projects.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700237 &quot;sourceRepository&quot;: { # Describes the location of the function source in a remote repository. # The hosted repository where the function is defined.
238 &quot;revision&quot;: &quot;A String&quot;, # The id of the revision that captures the state of the repository from
239 # which the function should be fetched.
240 &quot;repositoryUrl&quot;: &quot;A String&quot;, # URL to the hosted repository where the function is defined. Only paths in
241 # https://source.developers.google.com domain are supported. The path should
242 # contain the name of the repository.
243 &quot;tag&quot;: &quot;A String&quot;, # The name of the tag that captures the state of the repository from
244 # which the function should be fetched.
245 &quot;branch&quot;: &quot;A String&quot;, # The name of the branch from which the function should be fetched.
246 &quot;deployedRevision&quot;: &quot;A String&quot;, # Output only. The id of the revision that was resolved at the moment of
247 # function creation or update. For example when a user deployed from a
248 # branch, it will be the revision id of the latest change on this branch at
249 # that time. If user deployed from revision then this value will be always
250 # equal to the revision specified by the user.
251 &quot;sourcePath&quot;: &quot;A String&quot;, # The path within the repository where the function is defined. The path
252 # should point to the directory where Cloud Functions files are located. Use
253 # &quot;/&quot; if the function is defined directly in the root directory of a
254 # repository.
255 },
256 &quot;labels&quot;: { # Labels associated with this Cloud Function.
257 &quot;a_key&quot;: &quot;A String&quot;,
258 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700259 &quot;entryPoint&quot;: &quot;A String&quot;, # The name of the function (as defined in source code) that will be
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400260 # executed. Defaults to the resource name suffix, if not specified. For
261 # backward compatibility, if function with given name is not found, then the
Bu Sun Kim65020912020-05-20 12:08:20 -0700262 # system will try to use function named &quot;function&quot;.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400263 # For Node.js this is name of a function exported by the module specified
264 # in `source_location`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700265 &quot;sourceRepositoryUrl&quot;: &quot;A String&quot;, # The URL pointing to the hosted repository where the function is defined.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700266 # There are supported Cloud Source Repository URLs in the following
267 # formats:
268 #
269 # To refer to a specific commit:
270 # `https://source.developers.google.com/projects/*/repos/*/revisions/*/paths/*`
271 # To refer to a moveable alias (branch):
272 # `https://source.developers.google.com/projects/*/repos/*/moveable-aliases/*/paths/*`
273 # In particular, to refer to HEAD use `master` moveable alias.
274 # To refer to a specific fixed alias (tag):
275 # `https://source.developers.google.com/projects/*/repos/*/fixed-aliases/*/paths/*`
276 #
277 # You may omit `paths/*` if you want to use the main directory.
Bu Sun Kim65020912020-05-20 12:08:20 -0700278 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. The last update timestamp of a Cloud Function.
279 &quot;latestOperation&quot;: &quot;A String&quot;, # Output only. Name of the most recent operation modifying the function. If
280 # the function status is `DEPLOYING` or `DELETING`, then it points to the
281 # active operation.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400282}
283
284 x__xgafv: string, V1 error format.
285 Allowed values
286 1 - v1 error format
287 2 - v2 error format
288
289Returns:
290 An object of the form:
291
292 { # This resource represents a long-running operation that is the result of a
293 # network API call.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700294 &quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically
295 # contains progress information and common metadata such as create time.
296 # Some services might not provide such metadata. Any method that returns a
297 # long-running operation should document the metadata type, if any.
298 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
299 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700300 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700301 # If `true`, the operation is completed, and either `error` or `response` is
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400302 # available.
Bu Sun Kim65020912020-05-20 12:08:20 -0700303 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400304 # method returns no data on success, such as `Delete`, the response is
305 # `google.protobuf.Empty`. If the original method is standard
306 # `Get`/`Create`/`Update`, the response should be the resource. For other
307 # methods, the response should have the type `XxxResponse`, where `Xxx`
308 # is the original method name. For example, if the original method name
309 # is `TakeSnapshot()`, the inferred response type is
310 # `TakeSnapshotResponse`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700311 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400312 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700313 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400314 # originally returns it. If you use the default HTTP mapping, the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700315 # `name` should be a resource name ending with `operations/{unique_id}`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700316 &quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation.
317 # different programming environments, including REST APIs and RPC APIs. It is
318 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
319 # three pieces of data: error code, error message, and error details.
320 #
321 # You can find out more about this error model and how to work with it in the
322 # [API Design Guide](https://cloud.google.com/apis/design/errors).
Bu Sun Kim65020912020-05-20 12:08:20 -0700323 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
324 # user-facing error message should be localized and sent in the
325 # google.rpc.Status.details field, or localized by the client.
326 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
327 # message types for APIs to use.
328 {
329 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
330 },
331 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700332 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
Bu Sun Kim65020912020-05-20 12:08:20 -0700333 },
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400334 }</pre>
335</div>
336
337<div class="method">
338 <code class="details" id="delete">delete(name, x__xgafv=None)</code>
339 <pre>Deletes a function with the given name from the specified project. If the
340given function is used by some trigger, the trigger will be updated to
341remove this function.
342
343Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700344 name: string, Required. The name of the function which should be deleted. (required)
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400345 x__xgafv: string, V1 error format.
346 Allowed values
347 1 - v1 error format
348 2 - v2 error format
349
350Returns:
351 An object of the form:
352
353 { # This resource represents a long-running operation that is the result of a
354 # network API call.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700355 &quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically
356 # contains progress information and common metadata such as create time.
357 # Some services might not provide such metadata. Any method that returns a
358 # long-running operation should document the metadata type, if any.
359 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
360 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700361 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700362 # If `true`, the operation is completed, and either `error` or `response` is
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400363 # available.
Bu Sun Kim65020912020-05-20 12:08:20 -0700364 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400365 # method returns no data on success, such as `Delete`, the response is
366 # `google.protobuf.Empty`. If the original method is standard
367 # `Get`/`Create`/`Update`, the response should be the resource. For other
368 # methods, the response should have the type `XxxResponse`, where `Xxx`
369 # is the original method name. For example, if the original method name
370 # is `TakeSnapshot()`, the inferred response type is
371 # `TakeSnapshotResponse`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700372 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400373 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700374 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400375 # originally returns it. If you use the default HTTP mapping, the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700376 # `name` should be a resource name ending with `operations/{unique_id}`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700377 &quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation.
378 # different programming environments, including REST APIs and RPC APIs. It is
379 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
380 # three pieces of data: error code, error message, and error details.
381 #
382 # You can find out more about this error model and how to work with it in the
383 # [API Design Guide](https://cloud.google.com/apis/design/errors).
Bu Sun Kim65020912020-05-20 12:08:20 -0700384 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
385 # user-facing error message should be localized and sent in the
386 # google.rpc.Status.details field, or localized by the client.
387 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
388 # message types for APIs to use.
389 {
390 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
391 },
392 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700393 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
Bu Sun Kim65020912020-05-20 12:08:20 -0700394 },
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700395 }</pre>
396</div>
397
398<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700399 <code class="details" id="generateDownloadUrl">generateDownloadUrl(name, body=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700400 <pre>Returns a signed URL for downloading deployed function source code.
401The URL is only valid for a limited period and should be used within
402minutes after generation.
403For more information about the signed URL usage see:
404https://cloud.google.com/storage/docs/access-control/signed-urls
405
406Args:
407 name: string, The name of function for which source code Google Cloud Storage signed
408URL should be generated. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700409 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700410 The object takes the form of:
411
412{ # Request of `GenerateDownloadUrl` method.
Bu Sun Kim65020912020-05-20 12:08:20 -0700413 &quot;versionId&quot;: &quot;A String&quot;, # The optional version of function.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700414 }
415
416 x__xgafv: string, V1 error format.
417 Allowed values
418 1 - v1 error format
419 2 - v2 error format
420
421Returns:
422 An object of the form:
423
424 { # Response of `GenerateDownloadUrl` method.
Bu Sun Kim65020912020-05-20 12:08:20 -0700425 &quot;downloadUrl&quot;: &quot;A String&quot;, # The generated Google Cloud Storage signed URL that should be used for
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700426 # function source code download.
427 }</pre>
428</div>
429
430<div class="method">
431 <code class="details" id="generateUploadUrl">generateUploadUrl(parent, body=None, x__xgafv=None)</code>
432 <pre>Returns a signed URL for uploading a function source code.
433For more information about the signed URL usage see:
434https://cloud.google.com/storage/docs/access-control/signed-urls
435Once the function source code upload is complete, the used signed
436URL should be provided in CreateFunction or UpdateFunction request
437as a reference to the function source code.
438
439When uploading source code to the generated signed URL, please follow
440these restrictions:
441
442* Source file type should be a zip file.
443* Source file size should not exceed 100MB limit.
444* No credentials should be attached - the signed URLs provide access to the
445 target bucket using internal service identity; if credentials were
446 attached, the identity from the credentials would be used, but that
447 identity does not have permissions to upload files to the URL.
448
449When making a HTTP PUT request, these two headers need to be specified:
450
451* `content-type: application/zip`
452* `x-goog-content-length-range: 0,104857600`
453
454And this header SHOULD NOT be specified:
455
456* `Authorization: Bearer YOUR_TOKEN`
457
458Args:
459 parent: string, The project and location in which the Google Cloud Storage signed URL
460should be generated, specified in the format `projects/*/locations/*`. (required)
461 body: object, The request body.
462 The object takes the form of:
463
464{ # Request of `GenerateUploadUrl` method.
465 }
466
467 x__xgafv: string, V1 error format.
468 Allowed values
469 1 - v1 error format
470 2 - v2 error format
471
472Returns:
473 An object of the form:
474
475 { # Response of `GenerateUploadUrl` method.
Bu Sun Kim65020912020-05-20 12:08:20 -0700476 &quot;uploadUrl&quot;: &quot;A String&quot;, # The generated Google Cloud Storage signed URL that should be used for a
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700477 # function source code upload. The uploaded file should be a zip archive
478 # which contains a function.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400479 }</pre>
480</div>
481
482<div class="method">
483 <code class="details" id="get">get(name, x__xgafv=None)</code>
484 <pre>Returns a function with the given name from the requested project.
485
486Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700487 name: string, Required. The name of the function which details should be obtained. (required)
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400488 x__xgafv: string, V1 error format.
489 Allowed values
490 1 - v1 error format
491 2 - v2 error format
492
493Returns:
494 An object of the form:
495
496 { # Describes a Cloud Function that contains user computation executed in
497 # response to an event. It encapsulate function and triggers configurations.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700498 &quot;httpsTrigger&quot;: { # Describes HTTPSTrigger, could be used to connect web hooks to function. # An HTTPS endpoint type of source that can be triggered via URL.
499 &quot;url&quot;: &quot;A String&quot;, # Output only. The deployed url for the function.
500 },
501 &quot;maxInstances&quot;: 42, # The limit on the maximum number of function instances that may coexist at a
502 # given time.
503 &quot;environmentVariables&quot;: { # Environment variables that shall be available during function execution.
504 &quot;a_key&quot;: &quot;A String&quot;,
505 },
506 &quot;status&quot;: &quot;A String&quot;, # Output only. Status of the function deployment.
507 &quot;eventTrigger&quot;: { # Describes EventTrigger, used to request events be sent from another # A source that fires events in response to a condition in another service.
508 # service.
509 &quot;eventType&quot;: &quot;A String&quot;, # `event_type` names contain the service that is sending an event and the
510 # kind of event that was fired. Must be of the form
511 # `providers/*/eventTypes/*` e.g. Directly handle a Message published to
512 # Google Cloud Pub/Sub `providers/cloud.pubsub/eventTypes/topic.publish`.
513 #
514 # Handle an object changing in Google Cloud Storage:
515 # `providers/cloud.storage/eventTypes/object.change`
516 #
517 # Handle a write to the Firebase Realtime Database:
518 # `providers/google.firebase.database/eventTypes/ref.write`
519 &quot;resource&quot;: &quot;A String&quot;, # Which instance of the source&#x27;s service should send events. E.g. for Pub/Sub
520 # this would be a Pub/Sub topic at `projects/*/topics/*`. For Google Cloud
521 # Storage this would be a bucket at `projects/*/buckets/*`. For any source
522 # that only supports one instance per-project, this should be the name of the
523 # project (`projects/*`)
524 &quot;service&quot;: &quot;A String&quot;, # The hostname of the service that should be observed.
525 #
526 # If no string is provided, the default service implementing the API will
527 # be used. For example, `storage.googleapis.com` is the default for all
528 # event types in the `google.storage` namespace.
529 &quot;failurePolicy&quot;: { # Describes the policy in case of function&#x27;s execution failure. # Specifies policy for failed executions.
530 # If empty, then defaults to ignoring failures (i.e. not retrying them).
531 &quot;retry&quot;: { # Describes the retry policy in case of function&#x27;s execution failure. # If specified, then the function will be retried in case of a failure.
532 # A function execution will be retried on any failure.
533 # A failed execution will be retried up to 7 days with an exponential backoff
534 # (capped at 10 seconds).
535 # Retried execution is charged as any other execution.
536 },
537 },
538 },
539 &quot;sourceUploadUrl&quot;: &quot;A String&quot;, # The Google Cloud Storage signed URL used for source uploading, generated
540 # by google.cloud.functions.v1beta2.GenerateUploadUrl
541 &quot;timeout&quot;: &quot;A String&quot;, # The function execution timeout. Execution is considered failed and
542 # can be terminated if the function is not completed at the end of the
543 # timeout period. Defaults to 60 seconds.
544 &quot;availableMemoryMb&quot;: 42, # The amount of memory in MB available for a function.
545 # Defaults to 256MB.
546 &quot;runtime&quot;: &quot;A String&quot;, # The runtime in which to run the function. Required when deploying a new
547 # function, optional when updating an existing function. For a complete
548 # list of possible choices, see the
549 # [`gcloud` command
550 # reference](/sdk/gcloud/reference/functions/deploy#--runtime).
551 &quot;name&quot;: &quot;A String&quot;, # A user-defined name of the function. Function names must be unique
552 # globally and match pattern `projects/*/locations/*/functions/*`
553 &quot;versionId&quot;: &quot;A String&quot;, # Output only. The version identifier of the Cloud Function. Each deployment attempt
554 # results in a new version of a function being created.
555 &quot;serviceAccount&quot;: &quot;A String&quot;, # The email of the function&#x27;s service account. If empty, defaults to
556 # `{project_id}@appspot.gserviceaccount.com`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700557 &quot;sourceArchiveUrl&quot;: &quot;A String&quot;, # The Google Cloud Storage URL, starting with gs://, pointing to the zip
558 # archive which contains the function.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700559 &quot;vpcConnector&quot;: &quot;A String&quot;, # The VPC Network Connector that this cloud function can connect to. It can
560 # be either the fully-qualified URI, or the short name of the network
561 # connector resource. The format of this field is
562 # `projects/*/locations/*/connectors/*`
563 #
564 # This field is mutually exclusive with `network` field and will eventually
565 # replace it.
566 #
567 # See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for
568 # more information on connecting Cloud projects.
Bu Sun Kim65020912020-05-20 12:08:20 -0700569 &quot;network&quot;: &quot;A String&quot;, # The VPC Network that this cloud function can connect to. It can be
Dan O'Mearadd494642020-05-01 07:42:23 -0700570 # either the fully-qualified URI, or the short name of the network resource.
571 # If the short network name is used, the network must belong to the same
572 # project. Otherwise, it must belong to a project within the same
573 # organization. The format of this field is either
574 # `projects/{project}/global/networks/{network}` or `{network}`, where
575 # {project} is a project id where the network is defined, and {network} is
576 # the short name of the network.
577 #
578 # This field is mutually exclusive with `vpc_connector` and will be replaced
579 # by it.
580 #
581 # See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for
582 # more information on connecting Cloud projects.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700583 &quot;sourceRepository&quot;: { # Describes the location of the function source in a remote repository. # The hosted repository where the function is defined.
584 &quot;revision&quot;: &quot;A String&quot;, # The id of the revision that captures the state of the repository from
585 # which the function should be fetched.
586 &quot;repositoryUrl&quot;: &quot;A String&quot;, # URL to the hosted repository where the function is defined. Only paths in
587 # https://source.developers.google.com domain are supported. The path should
588 # contain the name of the repository.
589 &quot;tag&quot;: &quot;A String&quot;, # The name of the tag that captures the state of the repository from
590 # which the function should be fetched.
591 &quot;branch&quot;: &quot;A String&quot;, # The name of the branch from which the function should be fetched.
592 &quot;deployedRevision&quot;: &quot;A String&quot;, # Output only. The id of the revision that was resolved at the moment of
593 # function creation or update. For example when a user deployed from a
594 # branch, it will be the revision id of the latest change on this branch at
595 # that time. If user deployed from revision then this value will be always
596 # equal to the revision specified by the user.
597 &quot;sourcePath&quot;: &quot;A String&quot;, # The path within the repository where the function is defined. The path
598 # should point to the directory where Cloud Functions files are located. Use
599 # &quot;/&quot; if the function is defined directly in the root directory of a
600 # repository.
601 },
602 &quot;labels&quot;: { # Labels associated with this Cloud Function.
603 &quot;a_key&quot;: &quot;A String&quot;,
604 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700605 &quot;entryPoint&quot;: &quot;A String&quot;, # The name of the function (as defined in source code) that will be
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400606 # executed. Defaults to the resource name suffix, if not specified. For
607 # backward compatibility, if function with given name is not found, then the
Bu Sun Kim65020912020-05-20 12:08:20 -0700608 # system will try to use function named &quot;function&quot;.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400609 # For Node.js this is name of a function exported by the module specified
610 # in `source_location`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700611 &quot;sourceRepositoryUrl&quot;: &quot;A String&quot;, # The URL pointing to the hosted repository where the function is defined.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700612 # There are supported Cloud Source Repository URLs in the following
613 # formats:
614 #
615 # To refer to a specific commit:
616 # `https://source.developers.google.com/projects/*/repos/*/revisions/*/paths/*`
617 # To refer to a moveable alias (branch):
618 # `https://source.developers.google.com/projects/*/repos/*/moveable-aliases/*/paths/*`
619 # In particular, to refer to HEAD use `master` moveable alias.
620 # To refer to a specific fixed alias (tag):
621 # `https://source.developers.google.com/projects/*/repos/*/fixed-aliases/*/paths/*`
622 #
623 # You may omit `paths/*` if you want to use the main directory.
Bu Sun Kim65020912020-05-20 12:08:20 -0700624 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. The last update timestamp of a Cloud Function.
625 &quot;latestOperation&quot;: &quot;A String&quot;, # Output only. Name of the most recent operation modifying the function. If
626 # the function status is `DEPLOYING` or `DELETING`, then it points to the
627 # active operation.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400628 }</pre>
629</div>
630
631<div class="method">
Bu Sun Kim65020912020-05-20 12:08:20 -0700632 <code class="details" id="list">list(location, pageToken=None, pageSize=None, x__xgafv=None)</code>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400633 <pre>Returns a list of functions that belong to the requested project.
634
635Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700636 location: string, Required. The project and location from which the function should be listed,
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400637specified in the format `projects/*/locations/*`
Bu Sun Kim65020912020-05-20 12:08:20 -0700638If you want to list functions in all locations, use &quot;-&quot; in place of a
Dan O'Mearadd494642020-05-01 07:42:23 -0700639location. When listing functions in all locations, if one or more
640location(s) are unreachable, the response will contain functions from all
641reachable locations along with the names of any unreachable locations. (required)
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400642 pageToken: string, The value returned by the last
643`ListFunctionsResponse`; indicates that
644this is a continuation of a prior `ListFunctions` call, and that the
645system should return the next page of data.
Bu Sun Kim65020912020-05-20 12:08:20 -0700646 pageSize: integer, Maximum number of functions to return per call.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400647 x__xgafv: string, V1 error format.
648 Allowed values
649 1 - v1 error format
650 2 - v2 error format
651
652Returns:
653 An object of the form:
654
655 { # Response for the `ListFunctions` method.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700656 &quot;unreachable&quot;: [ # Locations that could not be reached. The response does not include any
657 # functions from these locations.
658 &quot;A String&quot;,
659 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700660 &quot;functions&quot;: [ # The functions that match the request.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400661 { # Describes a Cloud Function that contains user computation executed in
662 # response to an event. It encapsulate function and triggers configurations.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700663 &quot;httpsTrigger&quot;: { # Describes HTTPSTrigger, could be used to connect web hooks to function. # An HTTPS endpoint type of source that can be triggered via URL.
664 &quot;url&quot;: &quot;A String&quot;, # Output only. The deployed url for the function.
665 },
666 &quot;maxInstances&quot;: 42, # The limit on the maximum number of function instances that may coexist at a
667 # given time.
668 &quot;environmentVariables&quot;: { # Environment variables that shall be available during function execution.
669 &quot;a_key&quot;: &quot;A String&quot;,
670 },
671 &quot;status&quot;: &quot;A String&quot;, # Output only. Status of the function deployment.
672 &quot;eventTrigger&quot;: { # Describes EventTrigger, used to request events be sent from another # A source that fires events in response to a condition in another service.
673 # service.
674 &quot;eventType&quot;: &quot;A String&quot;, # `event_type` names contain the service that is sending an event and the
675 # kind of event that was fired. Must be of the form
676 # `providers/*/eventTypes/*` e.g. Directly handle a Message published to
677 # Google Cloud Pub/Sub `providers/cloud.pubsub/eventTypes/topic.publish`.
678 #
679 # Handle an object changing in Google Cloud Storage:
680 # `providers/cloud.storage/eventTypes/object.change`
681 #
682 # Handle a write to the Firebase Realtime Database:
683 # `providers/google.firebase.database/eventTypes/ref.write`
684 &quot;resource&quot;: &quot;A String&quot;, # Which instance of the source&#x27;s service should send events. E.g. for Pub/Sub
685 # this would be a Pub/Sub topic at `projects/*/topics/*`. For Google Cloud
686 # Storage this would be a bucket at `projects/*/buckets/*`. For any source
687 # that only supports one instance per-project, this should be the name of the
688 # project (`projects/*`)
689 &quot;service&quot;: &quot;A String&quot;, # The hostname of the service that should be observed.
690 #
691 # If no string is provided, the default service implementing the API will
692 # be used. For example, `storage.googleapis.com` is the default for all
693 # event types in the `google.storage` namespace.
694 &quot;failurePolicy&quot;: { # Describes the policy in case of function&#x27;s execution failure. # Specifies policy for failed executions.
695 # If empty, then defaults to ignoring failures (i.e. not retrying them).
696 &quot;retry&quot;: { # Describes the retry policy in case of function&#x27;s execution failure. # If specified, then the function will be retried in case of a failure.
697 # A function execution will be retried on any failure.
698 # A failed execution will be retried up to 7 days with an exponential backoff
699 # (capped at 10 seconds).
700 # Retried execution is charged as any other execution.
701 },
702 },
703 },
704 &quot;sourceUploadUrl&quot;: &quot;A String&quot;, # The Google Cloud Storage signed URL used for source uploading, generated
705 # by google.cloud.functions.v1beta2.GenerateUploadUrl
706 &quot;timeout&quot;: &quot;A String&quot;, # The function execution timeout. Execution is considered failed and
707 # can be terminated if the function is not completed at the end of the
708 # timeout period. Defaults to 60 seconds.
709 &quot;availableMemoryMb&quot;: 42, # The amount of memory in MB available for a function.
710 # Defaults to 256MB.
711 &quot;runtime&quot;: &quot;A String&quot;, # The runtime in which to run the function. Required when deploying a new
712 # function, optional when updating an existing function. For a complete
713 # list of possible choices, see the
714 # [`gcloud` command
715 # reference](/sdk/gcloud/reference/functions/deploy#--runtime).
716 &quot;name&quot;: &quot;A String&quot;, # A user-defined name of the function. Function names must be unique
717 # globally and match pattern `projects/*/locations/*/functions/*`
718 &quot;versionId&quot;: &quot;A String&quot;, # Output only. The version identifier of the Cloud Function. Each deployment attempt
719 # results in a new version of a function being created.
720 &quot;serviceAccount&quot;: &quot;A String&quot;, # The email of the function&#x27;s service account. If empty, defaults to
721 # `{project_id}@appspot.gserviceaccount.com`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700722 &quot;sourceArchiveUrl&quot;: &quot;A String&quot;, # The Google Cloud Storage URL, starting with gs://, pointing to the zip
723 # archive which contains the function.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700724 &quot;vpcConnector&quot;: &quot;A String&quot;, # The VPC Network Connector that this cloud function can connect to. It can
725 # be either the fully-qualified URI, or the short name of the network
726 # connector resource. The format of this field is
727 # `projects/*/locations/*/connectors/*`
728 #
729 # This field is mutually exclusive with `network` field and will eventually
730 # replace it.
731 #
732 # See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for
733 # more information on connecting Cloud projects.
Bu Sun Kim65020912020-05-20 12:08:20 -0700734 &quot;network&quot;: &quot;A String&quot;, # The VPC Network that this cloud function can connect to. It can be
Dan O'Mearadd494642020-05-01 07:42:23 -0700735 # either the fully-qualified URI, or the short name of the network resource.
736 # If the short network name is used, the network must belong to the same
737 # project. Otherwise, it must belong to a project within the same
738 # organization. The format of this field is either
739 # `projects/{project}/global/networks/{network}` or `{network}`, where
740 # {project} is a project id where the network is defined, and {network} is
741 # the short name of the network.
742 #
743 # This field is mutually exclusive with `vpc_connector` and will be replaced
744 # by it.
745 #
746 # See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for
747 # more information on connecting Cloud projects.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700748 &quot;sourceRepository&quot;: { # Describes the location of the function source in a remote repository. # The hosted repository where the function is defined.
749 &quot;revision&quot;: &quot;A String&quot;, # The id of the revision that captures the state of the repository from
750 # which the function should be fetched.
751 &quot;repositoryUrl&quot;: &quot;A String&quot;, # URL to the hosted repository where the function is defined. Only paths in
752 # https://source.developers.google.com domain are supported. The path should
753 # contain the name of the repository.
754 &quot;tag&quot;: &quot;A String&quot;, # The name of the tag that captures the state of the repository from
755 # which the function should be fetched.
756 &quot;branch&quot;: &quot;A String&quot;, # The name of the branch from which the function should be fetched.
757 &quot;deployedRevision&quot;: &quot;A String&quot;, # Output only. The id of the revision that was resolved at the moment of
758 # function creation or update. For example when a user deployed from a
759 # branch, it will be the revision id of the latest change on this branch at
760 # that time. If user deployed from revision then this value will be always
761 # equal to the revision specified by the user.
762 &quot;sourcePath&quot;: &quot;A String&quot;, # The path within the repository where the function is defined. The path
763 # should point to the directory where Cloud Functions files are located. Use
764 # &quot;/&quot; if the function is defined directly in the root directory of a
765 # repository.
766 },
767 &quot;labels&quot;: { # Labels associated with this Cloud Function.
768 &quot;a_key&quot;: &quot;A String&quot;,
769 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700770 &quot;entryPoint&quot;: &quot;A String&quot;, # The name of the function (as defined in source code) that will be
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400771 # executed. Defaults to the resource name suffix, if not specified. For
772 # backward compatibility, if function with given name is not found, then the
Bu Sun Kim65020912020-05-20 12:08:20 -0700773 # system will try to use function named &quot;function&quot;.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400774 # For Node.js this is name of a function exported by the module specified
775 # in `source_location`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700776 &quot;sourceRepositoryUrl&quot;: &quot;A String&quot;, # The URL pointing to the hosted repository where the function is defined.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700777 # There are supported Cloud Source Repository URLs in the following
778 # formats:
779 #
780 # To refer to a specific commit:
781 # `https://source.developers.google.com/projects/*/repos/*/revisions/*/paths/*`
782 # To refer to a moveable alias (branch):
783 # `https://source.developers.google.com/projects/*/repos/*/moveable-aliases/*/paths/*`
784 # In particular, to refer to HEAD use `master` moveable alias.
785 # To refer to a specific fixed alias (tag):
786 # `https://source.developers.google.com/projects/*/repos/*/fixed-aliases/*/paths/*`
787 #
788 # You may omit `paths/*` if you want to use the main directory.
Bu Sun Kim65020912020-05-20 12:08:20 -0700789 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. The last update timestamp of a Cloud Function.
790 &quot;latestOperation&quot;: &quot;A String&quot;, # Output only. Name of the most recent operation modifying the function. If
791 # the function status is `DEPLOYING` or `DELETING`, then it points to the
792 # active operation.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400793 },
794 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700795 &quot;nextPageToken&quot;: &quot;A String&quot;, # If not empty, indicates that there may be more functions that match
796 # the request; this value should be passed in a new
797 # google.cloud.functions.v1beta2.ListFunctionsRequest
798 # to get more functions.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400799 }</pre>
800</div>
801
802<div class="method">
803 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
804 <pre>Retrieves the next page of results.
805
806Args:
807 previous_request: The request for the previous page. (required)
808 previous_response: The response from the request for the previous page. (required)
809
810Returns:
Bu Sun Kim65020912020-05-20 12:08:20 -0700811 A request object that you can call &#x27;execute()&#x27; on to request the next
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400812 page. Returns None if there are no more items in the collection.
813 </pre>
814</div>
815
816<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700817 <code class="details" id="update">update(name, body=None, x__xgafv=None)</code>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400818 <pre>Updates existing function.
819
820Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700821 name: string, Required. The name of the function to be updated. (required)
822 body: object, The request body.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400823 The object takes the form of:
824
825{ # Describes a Cloud Function that contains user computation executed in
826 # response to an event. It encapsulate function and triggers configurations.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700827 &quot;httpsTrigger&quot;: { # Describes HTTPSTrigger, could be used to connect web hooks to function. # An HTTPS endpoint type of source that can be triggered via URL.
828 &quot;url&quot;: &quot;A String&quot;, # Output only. The deployed url for the function.
829 },
830 &quot;maxInstances&quot;: 42, # The limit on the maximum number of function instances that may coexist at a
831 # given time.
832 &quot;environmentVariables&quot;: { # Environment variables that shall be available during function execution.
833 &quot;a_key&quot;: &quot;A String&quot;,
834 },
835 &quot;status&quot;: &quot;A String&quot;, # Output only. Status of the function deployment.
836 &quot;eventTrigger&quot;: { # Describes EventTrigger, used to request events be sent from another # A source that fires events in response to a condition in another service.
837 # service.
838 &quot;eventType&quot;: &quot;A String&quot;, # `event_type` names contain the service that is sending an event and the
839 # kind of event that was fired. Must be of the form
840 # `providers/*/eventTypes/*` e.g. Directly handle a Message published to
841 # Google Cloud Pub/Sub `providers/cloud.pubsub/eventTypes/topic.publish`.
842 #
843 # Handle an object changing in Google Cloud Storage:
844 # `providers/cloud.storage/eventTypes/object.change`
845 #
846 # Handle a write to the Firebase Realtime Database:
847 # `providers/google.firebase.database/eventTypes/ref.write`
848 &quot;resource&quot;: &quot;A String&quot;, # Which instance of the source&#x27;s service should send events. E.g. for Pub/Sub
849 # this would be a Pub/Sub topic at `projects/*/topics/*`. For Google Cloud
850 # Storage this would be a bucket at `projects/*/buckets/*`. For any source
851 # that only supports one instance per-project, this should be the name of the
852 # project (`projects/*`)
853 &quot;service&quot;: &quot;A String&quot;, # The hostname of the service that should be observed.
854 #
855 # If no string is provided, the default service implementing the API will
856 # be used. For example, `storage.googleapis.com` is the default for all
857 # event types in the `google.storage` namespace.
858 &quot;failurePolicy&quot;: { # Describes the policy in case of function&#x27;s execution failure. # Specifies policy for failed executions.
859 # If empty, then defaults to ignoring failures (i.e. not retrying them).
860 &quot;retry&quot;: { # Describes the retry policy in case of function&#x27;s execution failure. # If specified, then the function will be retried in case of a failure.
861 # A function execution will be retried on any failure.
862 # A failed execution will be retried up to 7 days with an exponential backoff
863 # (capped at 10 seconds).
864 # Retried execution is charged as any other execution.
865 },
866 },
867 },
868 &quot;sourceUploadUrl&quot;: &quot;A String&quot;, # The Google Cloud Storage signed URL used for source uploading, generated
869 # by google.cloud.functions.v1beta2.GenerateUploadUrl
870 &quot;timeout&quot;: &quot;A String&quot;, # The function execution timeout. Execution is considered failed and
871 # can be terminated if the function is not completed at the end of the
872 # timeout period. Defaults to 60 seconds.
873 &quot;availableMemoryMb&quot;: 42, # The amount of memory in MB available for a function.
874 # Defaults to 256MB.
875 &quot;runtime&quot;: &quot;A String&quot;, # The runtime in which to run the function. Required when deploying a new
876 # function, optional when updating an existing function. For a complete
877 # list of possible choices, see the
878 # [`gcloud` command
879 # reference](/sdk/gcloud/reference/functions/deploy#--runtime).
880 &quot;name&quot;: &quot;A String&quot;, # A user-defined name of the function. Function names must be unique
881 # globally and match pattern `projects/*/locations/*/functions/*`
882 &quot;versionId&quot;: &quot;A String&quot;, # Output only. The version identifier of the Cloud Function. Each deployment attempt
883 # results in a new version of a function being created.
884 &quot;serviceAccount&quot;: &quot;A String&quot;, # The email of the function&#x27;s service account. If empty, defaults to
885 # `{project_id}@appspot.gserviceaccount.com`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700886 &quot;sourceArchiveUrl&quot;: &quot;A String&quot;, # The Google Cloud Storage URL, starting with gs://, pointing to the zip
887 # archive which contains the function.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700888 &quot;vpcConnector&quot;: &quot;A String&quot;, # The VPC Network Connector that this cloud function can connect to. It can
889 # be either the fully-qualified URI, or the short name of the network
890 # connector resource. The format of this field is
891 # `projects/*/locations/*/connectors/*`
892 #
893 # This field is mutually exclusive with `network` field and will eventually
894 # replace it.
895 #
896 # See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for
897 # more information on connecting Cloud projects.
Bu Sun Kim65020912020-05-20 12:08:20 -0700898 &quot;network&quot;: &quot;A String&quot;, # The VPC Network that this cloud function can connect to. It can be
Dan O'Mearadd494642020-05-01 07:42:23 -0700899 # either the fully-qualified URI, or the short name of the network resource.
900 # If the short network name is used, the network must belong to the same
901 # project. Otherwise, it must belong to a project within the same
902 # organization. The format of this field is either
903 # `projects/{project}/global/networks/{network}` or `{network}`, where
904 # {project} is a project id where the network is defined, and {network} is
905 # the short name of the network.
906 #
907 # This field is mutually exclusive with `vpc_connector` and will be replaced
908 # by it.
909 #
910 # See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for
911 # more information on connecting Cloud projects.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700912 &quot;sourceRepository&quot;: { # Describes the location of the function source in a remote repository. # The hosted repository where the function is defined.
913 &quot;revision&quot;: &quot;A String&quot;, # The id of the revision that captures the state of the repository from
914 # which the function should be fetched.
915 &quot;repositoryUrl&quot;: &quot;A String&quot;, # URL to the hosted repository where the function is defined. Only paths in
916 # https://source.developers.google.com domain are supported. The path should
917 # contain the name of the repository.
918 &quot;tag&quot;: &quot;A String&quot;, # The name of the tag that captures the state of the repository from
919 # which the function should be fetched.
920 &quot;branch&quot;: &quot;A String&quot;, # The name of the branch from which the function should be fetched.
921 &quot;deployedRevision&quot;: &quot;A String&quot;, # Output only. The id of the revision that was resolved at the moment of
922 # function creation or update. For example when a user deployed from a
923 # branch, it will be the revision id of the latest change on this branch at
924 # that time. If user deployed from revision then this value will be always
925 # equal to the revision specified by the user.
926 &quot;sourcePath&quot;: &quot;A String&quot;, # The path within the repository where the function is defined. The path
927 # should point to the directory where Cloud Functions files are located. Use
928 # &quot;/&quot; if the function is defined directly in the root directory of a
929 # repository.
930 },
931 &quot;labels&quot;: { # Labels associated with this Cloud Function.
932 &quot;a_key&quot;: &quot;A String&quot;,
933 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700934 &quot;entryPoint&quot;: &quot;A String&quot;, # The name of the function (as defined in source code) that will be
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400935 # executed. Defaults to the resource name suffix, if not specified. For
936 # backward compatibility, if function with given name is not found, then the
Bu Sun Kim65020912020-05-20 12:08:20 -0700937 # system will try to use function named &quot;function&quot;.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400938 # For Node.js this is name of a function exported by the module specified
939 # in `source_location`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700940 &quot;sourceRepositoryUrl&quot;: &quot;A String&quot;, # The URL pointing to the hosted repository where the function is defined.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700941 # There are supported Cloud Source Repository URLs in the following
942 # formats:
943 #
944 # To refer to a specific commit:
945 # `https://source.developers.google.com/projects/*/repos/*/revisions/*/paths/*`
946 # To refer to a moveable alias (branch):
947 # `https://source.developers.google.com/projects/*/repos/*/moveable-aliases/*/paths/*`
948 # In particular, to refer to HEAD use `master` moveable alias.
949 # To refer to a specific fixed alias (tag):
950 # `https://source.developers.google.com/projects/*/repos/*/fixed-aliases/*/paths/*`
951 #
952 # You may omit `paths/*` if you want to use the main directory.
Bu Sun Kim65020912020-05-20 12:08:20 -0700953 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. The last update timestamp of a Cloud Function.
954 &quot;latestOperation&quot;: &quot;A String&quot;, # Output only. Name of the most recent operation modifying the function. If
955 # the function status is `DEPLOYING` or `DELETING`, then it points to the
956 # active operation.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400957}
958
959 x__xgafv: string, V1 error format.
960 Allowed values
961 1 - v1 error format
962 2 - v2 error format
963
964Returns:
965 An object of the form:
966
967 { # This resource represents a long-running operation that is the result of a
968 # network API call.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700969 &quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically
970 # contains progress information and common metadata such as create time.
971 # Some services might not provide such metadata. Any method that returns a
972 # long-running operation should document the metadata type, if any.
973 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
974 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700975 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700976 # If `true`, the operation is completed, and either `error` or `response` is
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400977 # available.
Bu Sun Kim65020912020-05-20 12:08:20 -0700978 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400979 # method returns no data on success, such as `Delete`, the response is
980 # `google.protobuf.Empty`. If the original method is standard
981 # `Get`/`Create`/`Update`, the response should be the resource. For other
982 # methods, the response should have the type `XxxResponse`, where `Xxx`
983 # is the original method name. For example, if the original method name
984 # is `TakeSnapshot()`, the inferred response type is
985 # `TakeSnapshotResponse`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700986 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400987 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700988 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400989 # originally returns it. If you use the default HTTP mapping, the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700990 # `name` should be a resource name ending with `operations/{unique_id}`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700991 &quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation.
992 # different programming environments, including REST APIs and RPC APIs. It is
993 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
994 # three pieces of data: error code, error message, and error details.
995 #
996 # You can find out more about this error model and how to work with it in the
997 # [API Design Guide](https://cloud.google.com/apis/design/errors).
Bu Sun Kim65020912020-05-20 12:08:20 -0700998 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
999 # user-facing error message should be localized and sent in the
1000 # google.rpc.Status.details field, or localized by the client.
1001 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
1002 # message types for APIs to use.
1003 {
1004 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
1005 },
1006 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001007 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
Bu Sun Kim65020912020-05-20 12:08:20 -07001008 },
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04001009 }</pre>
1010</div>
1011
1012</body></html>