blob: 4d2df9923054c27dd27a574e7d619f8d3d0e8b23 [file] [log] [blame]
Bu Sun Kim65020912020-05-20 12:08:20 -07001<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
75<h1><a href="firebaseml_v1beta2.html">Firebase ML API</a> . <a href="firebaseml_v1beta2.projects.html">projects</a> . <a href="firebaseml_v1beta2.projects.models.html">models</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78 <code><a href="#create">create(parent, body=None, x__xgafv=None)</a></code></p>
79<p class="firstline">Creates a model in Firebase ML.</p>
80<p class="toc_element">
81 <code><a href="#delete">delete(name, x__xgafv=None)</a></code></p>
82<p class="firstline">Deletes a model</p>
83<p class="toc_element">
84 <code><a href="#get">get(name, x__xgafv=None)</a></code></p>
85<p class="firstline">Gets a model resource.</p>
86<p class="toc_element">
Bu Sun Kimd059ad82020-07-22 17:02:09 -070087 <code><a href="#list">list(parent, pageToken=None, pageSize=None, filter=None, x__xgafv=None)</a></code></p>
Bu Sun Kim65020912020-05-20 12:08:20 -070088<p class="firstline">Lists the models</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>
92<p class="toc_element">
93 <code><a href="#patch">patch(name, body=None, updateMask=None, x__xgafv=None)</a></code></p>
94<p class="firstline">Updates a model. The longrunning operation will eventually return a Model.</p>
95<h3>Method Details</h3>
96<div class="method">
97 <code class="details" id="create">create(parent, body=None, x__xgafv=None)</code>
98 <pre>Creates a model in Firebase ML.
99The longrunning operation will eventually return a Model
100
101Args:
102 parent: string, Required. The parent project resource where the model is to be created.
103The parent must have the form `projects/{project_id}` (required)
104 body: object, The request body.
105 The object takes the form of:
106
107{ # An ML model hosted in Firebase ML
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700108 &quot;activeOperations&quot;: [ # Output only. Lists operation ids associated with this model whose status is NOT done.
109 { # This resource represents a long-running operation that is the result of a
110 # network API call.
111 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
112 # If `true`, the operation is completed, and either `error` or `response` is
113 # available.
114 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
115 # originally returns it. If you use the default HTTP mapping, the
116 # `name` should be a resource name ending with `operations/{unique_id}`.
117 &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.
Bu Sun Kim65020912020-05-20 12:08:20 -0700118 # different programming environments, including REST APIs and RPC APIs. It is
119 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
120 # three pieces of data: error code, error message, and error details.
121 #
122 # You can find out more about this error model and how to work with it in the
123 # [API Design Guide](https://cloud.google.com/apis/design/errors).
Bu Sun Kim65020912020-05-20 12:08:20 -0700124 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
125 # user-facing error message should be localized and sent in the
126 # google.rpc.Status.details field, or localized by the client.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700127 &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 -0700128 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
129 # message types for APIs to use.
130 {
131 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
132 },
133 ],
134 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700135 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
136 # method returns no data on success, such as `Delete`, the response is
137 # `google.protobuf.Empty`. If the original method is standard
138 # `Get`/`Create`/`Update`, the response should be the resource. For other
139 # methods, the response should have the type `XxxResponse`, where `Xxx`
140 # is the original method name. For example, if the original method name
141 # is `TakeSnapshot()`, the inferred response type is
142 # `TakeSnapshotResponse`.
143 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
144 },
145 &quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically
146 # contains progress information and common metadata such as create time.
147 # Some services might not provide such metadata. Any method that returns a
148 # long-running operation should document the metadata type, if any.
149 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
150 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700151 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700152 ],
153 &quot;tags&quot;: [ # User defined tags which can be used to group/filter models during listing
154 &quot;A String&quot;,
155 ],
156 &quot;tfliteModel&quot;: { # Information that is specific to TfLite models. # A TFLite Model
157 &quot;sizeBytes&quot;: &quot;A String&quot;, # Output only. The size of the TFLite model
158 &quot;gcsTfliteUri&quot;: &quot;A String&quot;, # The TfLite file containing the model. (Stored in Google Cloud).
159 # The gcs_tflite_uri should have form: gs://some-bucket/some-model.tflite
160 # Note: If you update the file in the original location, it is
161 # necessary to call UpdateModel for ML to pick up and validate the
162 # updated file.
163 },
164 &quot;displayName&quot;: &quot;A String&quot;, # Required. The name of the model to create. The name can be up to 32 characters long
165 # and can consist only of ASCII Latin letters A-Z and a-z, underscores(_)
166 # and ASCII digits 0-9. It must start with a letter.
167 &quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when this model was created in Firebase ML.
168 &quot;name&quot;: &quot;A String&quot;, # The resource name of the Model.
169 # Model names have the form `projects/{project_id}/models/{model_id}`
170 # The name is ignored when creating a model.
171 &quot;state&quot;: { # State common to all model types. # State common to all model types.
172 # Includes publishing and validation information.
173 # Includes publishing and validation information.
174 &quot;validationError&quot;: { # The `Status` type defines a logical error model that is suitable for # Output only. Indicates the latest validation error on the model if any.
175 # A model may have validation errors if there were problems during
176 # the model creation/update.
177 # e.g. in the case of a TfLiteModel, if a tflite model file was
178 # missing or in the wrong format.
179 # This field will be empty for valid models.
180 # different programming environments, including REST APIs and RPC APIs. It is
181 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
182 # three pieces of data: error code, error message, and error details.
183 #
184 # You can find out more about this error model and how to work with it in the
185 # [API Design Guide](https://cloud.google.com/apis/design/errors).
186 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
187 # user-facing error message should be localized and sent in the
188 # google.rpc.Status.details field, or localized by the client.
189 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
190 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
191 # message types for APIs to use.
192 {
193 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
194 },
195 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700196 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700197 &quot;published&quot;: True or False, # Indicates if this model has been published.
198 },
199 &quot;etag&quot;: &quot;A String&quot;, # Output only. See RFC7232
200 # https://tools.ietf.org/html/rfc7232#section-2.3
201 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. Timestamp when this model was updated in Firebase ML.
202 &quot;modelHash&quot;: &quot;A String&quot;, # Output only. The model_hash will change if a new file is available for download.
203}
Bu Sun Kim65020912020-05-20 12:08:20 -0700204
205 x__xgafv: string, V1 error format.
206 Allowed values
207 1 - v1 error format
208 2 - v2 error format
209
210Returns:
211 An object of the form:
212
213 { # This resource represents a long-running operation that is the result of a
214 # network API call.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700215 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
216 # If `true`, the operation is completed, and either `error` or `response` is
217 # available.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700218 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
219 # originally returns it. If you use the default HTTP mapping, the
220 # `name` should be a resource name ending with `operations/{unique_id}`.
221 &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.
222 # different programming environments, including REST APIs and RPC APIs. It is
223 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
224 # three pieces of data: error code, error message, and error details.
225 #
226 # You can find out more about this error model and how to work with it in the
227 # [API Design Guide](https://cloud.google.com/apis/design/errors).
228 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
229 # user-facing error message should be localized and sent in the
230 # google.rpc.Status.details field, or localized by the client.
231 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
232 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
233 # message types for APIs to use.
234 {
235 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
236 },
237 ],
238 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700239 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
240 # method returns no data on success, such as `Delete`, the response is
241 # `google.protobuf.Empty`. If the original method is standard
242 # `Get`/`Create`/`Update`, the response should be the resource. For other
243 # methods, the response should have the type `XxxResponse`, where `Xxx`
244 # is the original method name. For example, if the original method name
245 # is `TakeSnapshot()`, the inferred response type is
246 # `TakeSnapshotResponse`.
247 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
248 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700249 &quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically
250 # contains progress information and common metadata such as create time.
251 # Some services might not provide such metadata. Any method that returns a
252 # long-running operation should document the metadata type, if any.
253 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
254 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700255 }</pre>
256</div>
257
258<div class="method">
259 <code class="details" id="delete">delete(name, x__xgafv=None)</code>
260 <pre>Deletes a model
261
262Args:
263 name: string, Required. The name of the model to delete.
264The name must have the form `projects/{project_id}/models/{model_id}` (required)
265 x__xgafv: string, V1 error format.
266 Allowed values
267 1 - v1 error format
268 2 - v2 error format
269
270Returns:
271 An object of the form:
272
273 { # A generic empty message that you can re-use to avoid defining duplicated
274 # empty messages in your APIs. A typical example is to use it as the request
275 # or the response type of an API method. For instance:
276 #
277 # service Foo {
278 # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
279 # }
280 #
281 # The JSON representation for `Empty` is empty JSON object `{}`.
282 }</pre>
283</div>
284
285<div class="method">
286 <code class="details" id="get">get(name, x__xgafv=None)</code>
287 <pre>Gets a model resource.
288
289Args:
290 name: string, Required. The name of the model to get.
291The name must have the form `projects/{project_id}/models/{model_id}` (required)
292 x__xgafv: string, V1 error format.
293 Allowed values
294 1 - v1 error format
295 2 - v2 error format
296
297Returns:
298 An object of the form:
299
300 { # An ML model hosted in Firebase ML
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700301 &quot;activeOperations&quot;: [ # Output only. Lists operation ids associated with this model whose status is NOT done.
302 { # This resource represents a long-running operation that is the result of a
303 # network API call.
304 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
305 # If `true`, the operation is completed, and either `error` or `response` is
306 # available.
307 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
308 # originally returns it. If you use the default HTTP mapping, the
309 # `name` should be a resource name ending with `operations/{unique_id}`.
310 &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.
Bu Sun Kim65020912020-05-20 12:08:20 -0700311 # different programming environments, including REST APIs and RPC APIs. It is
312 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
313 # three pieces of data: error code, error message, and error details.
314 #
315 # You can find out more about this error model and how to work with it in the
316 # [API Design Guide](https://cloud.google.com/apis/design/errors).
Bu Sun Kim65020912020-05-20 12:08:20 -0700317 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
318 # user-facing error message should be localized and sent in the
319 # google.rpc.Status.details field, or localized by the client.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700320 &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 -0700321 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
322 # message types for APIs to use.
323 {
324 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
325 },
326 ],
327 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700328 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
329 # method returns no data on success, such as `Delete`, the response is
330 # `google.protobuf.Empty`. If the original method is standard
331 # `Get`/`Create`/`Update`, the response should be the resource. For other
332 # methods, the response should have the type `XxxResponse`, where `Xxx`
333 # is the original method name. For example, if the original method name
334 # is `TakeSnapshot()`, the inferred response type is
335 # `TakeSnapshotResponse`.
336 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
337 },
338 &quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically
339 # contains progress information and common metadata such as create time.
340 # Some services might not provide such metadata. Any method that returns a
341 # long-running operation should document the metadata type, if any.
342 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
343 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700344 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700345 ],
346 &quot;tags&quot;: [ # User defined tags which can be used to group/filter models during listing
347 &quot;A String&quot;,
348 ],
349 &quot;tfliteModel&quot;: { # Information that is specific to TfLite models. # A TFLite Model
350 &quot;sizeBytes&quot;: &quot;A String&quot;, # Output only. The size of the TFLite model
351 &quot;gcsTfliteUri&quot;: &quot;A String&quot;, # The TfLite file containing the model. (Stored in Google Cloud).
352 # The gcs_tflite_uri should have form: gs://some-bucket/some-model.tflite
353 # Note: If you update the file in the original location, it is
354 # necessary to call UpdateModel for ML to pick up and validate the
355 # updated file.
356 },
357 &quot;displayName&quot;: &quot;A String&quot;, # Required. The name of the model to create. The name can be up to 32 characters long
358 # and can consist only of ASCII Latin letters A-Z and a-z, underscores(_)
359 # and ASCII digits 0-9. It must start with a letter.
360 &quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when this model was created in Firebase ML.
361 &quot;name&quot;: &quot;A String&quot;, # The resource name of the Model.
362 # Model names have the form `projects/{project_id}/models/{model_id}`
363 # The name is ignored when creating a model.
364 &quot;state&quot;: { # State common to all model types. # State common to all model types.
365 # Includes publishing and validation information.
366 # Includes publishing and validation information.
367 &quot;validationError&quot;: { # The `Status` type defines a logical error model that is suitable for # Output only. Indicates the latest validation error on the model if any.
368 # A model may have validation errors if there were problems during
369 # the model creation/update.
370 # e.g. in the case of a TfLiteModel, if a tflite model file was
371 # missing or in the wrong format.
372 # This field will be empty for valid models.
373 # different programming environments, including REST APIs and RPC APIs. It is
374 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
375 # three pieces of data: error code, error message, and error details.
376 #
377 # You can find out more about this error model and how to work with it in the
378 # [API Design Guide](https://cloud.google.com/apis/design/errors).
379 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
380 # user-facing error message should be localized and sent in the
381 # google.rpc.Status.details field, or localized by the client.
382 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
383 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
384 # message types for APIs to use.
385 {
386 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
387 },
388 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700389 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700390 &quot;published&quot;: True or False, # Indicates if this model has been published.
391 },
392 &quot;etag&quot;: &quot;A String&quot;, # Output only. See RFC7232
393 # https://tools.ietf.org/html/rfc7232#section-2.3
394 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. Timestamp when this model was updated in Firebase ML.
395 &quot;modelHash&quot;: &quot;A String&quot;, # Output only. The model_hash will change if a new file is available for download.
396 }</pre>
Bu Sun Kim65020912020-05-20 12:08:20 -0700397</div>
398
399<div class="method">
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700400 <code class="details" id="list">list(parent, pageToken=None, pageSize=None, filter=None, x__xgafv=None)</code>
Bu Sun Kim65020912020-05-20 12:08:20 -0700401 <pre>Lists the models
402
403Args:
404 parent: string, Required. The name of the parent to list models for.
405The parent must have the form `projects/{project_id}&#x27; (required)
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700406 pageToken: string, The next_page_token value returned from a previous List request, if any.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700407 pageSize: integer, The maximum number of items to return
Bu Sun Kim65020912020-05-20 12:08:20 -0700408 filter: string, A filter for the list
409e.g. &#x27;tags: abc&#x27; to list models which are tagged with &quot;abc&quot;
Bu Sun Kim65020912020-05-20 12:08:20 -0700410 x__xgafv: string, V1 error format.
411 Allowed values
412 1 - v1 error format
413 2 - v2 error format
414
415Returns:
416 An object of the form:
417
418 { # The response for list models
419 &quot;models&quot;: [ # The list of models
420 { # An ML model hosted in Firebase ML
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700421 &quot;activeOperations&quot;: [ # Output only. Lists operation ids associated with this model whose status is NOT done.
422 { # This resource represents a long-running operation that is the result of a
423 # network API call.
424 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
425 # If `true`, the operation is completed, and either `error` or `response` is
426 # available.
427 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
428 # originally returns it. If you use the default HTTP mapping, the
429 # `name` should be a resource name ending with `operations/{unique_id}`.
430 &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.
Bu Sun Kim65020912020-05-20 12:08:20 -0700431 # different programming environments, including REST APIs and RPC APIs. It is
432 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
433 # three pieces of data: error code, error message, and error details.
434 #
435 # You can find out more about this error model and how to work with it in the
436 # [API Design Guide](https://cloud.google.com/apis/design/errors).
Bu Sun Kim65020912020-05-20 12:08:20 -0700437 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
438 # user-facing error message should be localized and sent in the
439 # google.rpc.Status.details field, or localized by the client.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700440 &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 -0700441 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
442 # message types for APIs to use.
443 {
444 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
445 },
446 ],
447 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700448 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
449 # method returns no data on success, such as `Delete`, the response is
450 # `google.protobuf.Empty`. If the original method is standard
451 # `Get`/`Create`/`Update`, the response should be the resource. For other
452 # methods, the response should have the type `XxxResponse`, where `Xxx`
453 # is the original method name. For example, if the original method name
454 # is `TakeSnapshot()`, the inferred response type is
455 # `TakeSnapshotResponse`.
456 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
457 },
458 &quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically
459 # contains progress information and common metadata such as create time.
460 # Some services might not provide such metadata. Any method that returns a
461 # long-running operation should document the metadata type, if any.
462 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
463 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700464 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700465 ],
466 &quot;tags&quot;: [ # User defined tags which can be used to group/filter models during listing
467 &quot;A String&quot;,
468 ],
469 &quot;tfliteModel&quot;: { # Information that is specific to TfLite models. # A TFLite Model
470 &quot;sizeBytes&quot;: &quot;A String&quot;, # Output only. The size of the TFLite model
471 &quot;gcsTfliteUri&quot;: &quot;A String&quot;, # The TfLite file containing the model. (Stored in Google Cloud).
472 # The gcs_tflite_uri should have form: gs://some-bucket/some-model.tflite
473 # Note: If you update the file in the original location, it is
474 # necessary to call UpdateModel for ML to pick up and validate the
475 # updated file.
Bu Sun Kim65020912020-05-20 12:08:20 -0700476 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700477 &quot;displayName&quot;: &quot;A String&quot;, # Required. The name of the model to create. The name can be up to 32 characters long
478 # and can consist only of ASCII Latin letters A-Z and a-z, underscores(_)
479 # and ASCII digits 0-9. It must start with a letter.
480 &quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when this model was created in Firebase ML.
481 &quot;name&quot;: &quot;A String&quot;, # The resource name of the Model.
482 # Model names have the form `projects/{project_id}/models/{model_id}`
483 # The name is ignored when creating a model.
484 &quot;state&quot;: { # State common to all model types. # State common to all model types.
485 # Includes publishing and validation information.
486 # Includes publishing and validation information.
487 &quot;validationError&quot;: { # The `Status` type defines a logical error model that is suitable for # Output only. Indicates the latest validation error on the model if any.
488 # A model may have validation errors if there were problems during
489 # the model creation/update.
490 # e.g. in the case of a TfLiteModel, if a tflite model file was
491 # missing or in the wrong format.
492 # This field will be empty for valid models.
493 # different programming environments, including REST APIs and RPC APIs. It is
494 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
495 # three pieces of data: error code, error message, and error details.
496 #
497 # You can find out more about this error model and how to work with it in the
498 # [API Design Guide](https://cloud.google.com/apis/design/errors).
499 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
500 # user-facing error message should be localized and sent in the
501 # google.rpc.Status.details field, or localized by the client.
502 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
503 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
504 # message types for APIs to use.
505 {
506 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
507 },
508 ],
509 },
510 &quot;published&quot;: True or False, # Indicates if this model has been published.
511 },
512 &quot;etag&quot;: &quot;A String&quot;, # Output only. See RFC7232
513 # https://tools.ietf.org/html/rfc7232#section-2.3
514 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. Timestamp when this model was updated in Firebase ML.
515 &quot;modelHash&quot;: &quot;A String&quot;, # Output only. The model_hash will change if a new file is available for download.
516 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700517 ],
518 &quot;nextPageToken&quot;: &quot;A String&quot;, # Token to retrieve the next page of results, or empty if there are no
519 # more results in the list.
520 }</pre>
521</div>
522
523<div class="method">
524 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
525 <pre>Retrieves the next page of results.
526
527Args:
528 previous_request: The request for the previous page. (required)
529 previous_response: The response from the request for the previous page. (required)
530
531Returns:
532 A request object that you can call &#x27;execute()&#x27; on to request the next
533 page. Returns None if there are no more items in the collection.
534 </pre>
535</div>
536
537<div class="method">
538 <code class="details" id="patch">patch(name, body=None, updateMask=None, x__xgafv=None)</code>
539 <pre>Updates a model. The longrunning operation will eventually return a Model.
540
541Args:
542 name: string, The resource name of the Model.
543Model names have the form `projects/{project_id}/models/{model_id}`
544The name is ignored when creating a model. (required)
545 body: object, The request body.
546 The object takes the form of:
547
548{ # An ML model hosted in Firebase ML
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700549 &quot;activeOperations&quot;: [ # Output only. Lists operation ids associated with this model whose status is NOT done.
550 { # This resource represents a long-running operation that is the result of a
551 # network API call.
552 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
553 # If `true`, the operation is completed, and either `error` or `response` is
554 # available.
555 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
556 # originally returns it. If you use the default HTTP mapping, the
557 # `name` should be a resource name ending with `operations/{unique_id}`.
558 &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.
Bu Sun Kim65020912020-05-20 12:08:20 -0700559 # different programming environments, including REST APIs and RPC APIs. It is
560 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
561 # three pieces of data: error code, error message, and error details.
562 #
563 # You can find out more about this error model and how to work with it in the
564 # [API Design Guide](https://cloud.google.com/apis/design/errors).
Bu Sun Kim65020912020-05-20 12:08:20 -0700565 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
566 # user-facing error message should be localized and sent in the
567 # google.rpc.Status.details field, or localized by the client.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700568 &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 -0700569 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
570 # message types for APIs to use.
571 {
572 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
573 },
574 ],
575 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700576 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
577 # method returns no data on success, such as `Delete`, the response is
578 # `google.protobuf.Empty`. If the original method is standard
579 # `Get`/`Create`/`Update`, the response should be the resource. For other
580 # methods, the response should have the type `XxxResponse`, where `Xxx`
581 # is the original method name. For example, if the original method name
582 # is `TakeSnapshot()`, the inferred response type is
583 # `TakeSnapshotResponse`.
584 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
585 },
586 &quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically
587 # contains progress information and common metadata such as create time.
588 # Some services might not provide such metadata. Any method that returns a
589 # long-running operation should document the metadata type, if any.
590 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
591 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700592 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700593 ],
594 &quot;tags&quot;: [ # User defined tags which can be used to group/filter models during listing
595 &quot;A String&quot;,
596 ],
597 &quot;tfliteModel&quot;: { # Information that is specific to TfLite models. # A TFLite Model
598 &quot;sizeBytes&quot;: &quot;A String&quot;, # Output only. The size of the TFLite model
599 &quot;gcsTfliteUri&quot;: &quot;A String&quot;, # The TfLite file containing the model. (Stored in Google Cloud).
600 # The gcs_tflite_uri should have form: gs://some-bucket/some-model.tflite
601 # Note: If you update the file in the original location, it is
602 # necessary to call UpdateModel for ML to pick up and validate the
603 # updated file.
604 },
605 &quot;displayName&quot;: &quot;A String&quot;, # Required. The name of the model to create. The name can be up to 32 characters long
606 # and can consist only of ASCII Latin letters A-Z and a-z, underscores(_)
607 # and ASCII digits 0-9. It must start with a letter.
608 &quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when this model was created in Firebase ML.
609 &quot;name&quot;: &quot;A String&quot;, # The resource name of the Model.
610 # Model names have the form `projects/{project_id}/models/{model_id}`
611 # The name is ignored when creating a model.
612 &quot;state&quot;: { # State common to all model types. # State common to all model types.
613 # Includes publishing and validation information.
614 # Includes publishing and validation information.
615 &quot;validationError&quot;: { # The `Status` type defines a logical error model that is suitable for # Output only. Indicates the latest validation error on the model if any.
616 # A model may have validation errors if there were problems during
617 # the model creation/update.
618 # e.g. in the case of a TfLiteModel, if a tflite model file was
619 # missing or in the wrong format.
620 # This field will be empty for valid models.
621 # different programming environments, including REST APIs and RPC APIs. It is
622 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
623 # three pieces of data: error code, error message, and error details.
624 #
625 # You can find out more about this error model and how to work with it in the
626 # [API Design Guide](https://cloud.google.com/apis/design/errors).
627 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
628 # user-facing error message should be localized and sent in the
629 # google.rpc.Status.details field, or localized by the client.
630 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
631 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
632 # message types for APIs to use.
633 {
634 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
635 },
636 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700637 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700638 &quot;published&quot;: True or False, # Indicates if this model has been published.
639 },
640 &quot;etag&quot;: &quot;A String&quot;, # Output only. See RFC7232
641 # https://tools.ietf.org/html/rfc7232#section-2.3
642 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. Timestamp when this model was updated in Firebase ML.
643 &quot;modelHash&quot;: &quot;A String&quot;, # Output only. The model_hash will change if a new file is available for download.
644}
Bu Sun Kim65020912020-05-20 12:08:20 -0700645
646 updateMask: string, The update mask
647 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 { # This resource represents a long-running operation that is the result of a
656 # network API call.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700657 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
658 # If `true`, the operation is completed, and either `error` or `response` is
659 # available.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700660 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
661 # originally returns it. If you use the default HTTP mapping, the
662 # `name` should be a resource name ending with `operations/{unique_id}`.
663 &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.
664 # different programming environments, including REST APIs and RPC APIs. It is
665 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
666 # three pieces of data: error code, error message, and error details.
667 #
668 # You can find out more about this error model and how to work with it in the
669 # [API Design Guide](https://cloud.google.com/apis/design/errors).
670 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
671 # user-facing error message should be localized and sent in the
672 # google.rpc.Status.details field, or localized by the client.
673 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
674 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
675 # message types for APIs to use.
676 {
677 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
678 },
679 ],
680 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700681 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
682 # method returns no data on success, such as `Delete`, the response is
683 # `google.protobuf.Empty`. If the original method is standard
684 # `Get`/`Create`/`Update`, the response should be the resource. For other
685 # methods, the response should have the type `XxxResponse`, where `Xxx`
686 # is the original method name. For example, if the original method name
687 # is `TakeSnapshot()`, the inferred response type is
688 # `TakeSnapshotResponse`.
689 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
690 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700691 &quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically
692 # contains progress information and common metadata such as create time.
693 # Some services might not provide such metadata. Any method that returns a
694 # long-running operation should document the metadata type, if any.
695 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
696 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700697 }</pre>
698</div>
699
700</body></html>