Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 9ff1945

Browse files
committedOct 11, 2022
feat(notebooks): update the api
#### notebooks:v1 The following keys were added: - resources.projects.resources.locations.resources.instances.methods.diagnose (Total Keys: 12) - resources.projects.resources.locations.resources.runtimes.methods.diagnose (Total Keys: 12) - resources.projects.resources.locations.resources.runtimes.methods.upgrade (Total Keys: 12) - schemas.DiagnoseInstanceRequest (Total Keys: 3) - schemas.DiagnoseRuntimeRequest (Total Keys: 3) - schemas.DiagnosticConfig (Total Keys: 7) - schemas.UpgradeRuntimeRequest (Total Keys: 3)
1 parent 6183625 commit 9ff1945

File tree

3 files changed

+292
-1
lines changed

3 files changed

+292
-1
lines changed
 

‎docs/dyn/notebooks_v1.projects.locations.instances.html

+51
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,9 @@ <h2>Instance Methods</h2>
8383
<p class="toc_element">
8484
<code><a href="#delete">delete(name, x__xgafv=None)</a></code></p>
8585
<p class="firstline">Deletes a single Instance.</p>
86+
<p class="toc_element">
87+
<code><a href="#diagnose">diagnose(name, body=None, x__xgafv=None)</a></code></p>
88+
<p class="firstline">Creates a Diagnostic File and runs Diagnostic Tool given an Instance.</p>
8689
<p class="toc_element">
8790
<code><a href="#get">get(name, x__xgafv=None)</a></code></p>
8891
<p class="firstline">Gets details of a single Instance.</p>
@@ -332,6 +335,54 @@ <h3>Method Details</h3>
332335
}</pre>
333336
</div>
334337

338+
<div class="method">
339+
<code class="details" id="diagnose">diagnose(name, body=None, x__xgafv=None)</code>
340+
<pre>Creates a Diagnostic File and runs Diagnostic Tool given an Instance.
341+
342+
Args:
343+
name: string, Required. Format: `projects/{project_id}/locations/{location}/instances/{instance_id}` (required)
344+
body: object, The request body.
345+
The object takes the form of:
346+
347+
{ # Request for creating a notebook instance diagnostic file.
348+
&quot;diagnosticConfig&quot;: { # Defines flags that are used to run the diagnostic tool # Required. Defines flags that are used to run the diagnostic tool
349+
&quot;copyHomeFilesFlagEnabled&quot;: True or False, # Optional. Enables flag to copy all `/home/jupyter` folder contents
350+
&quot;gcsBucket&quot;: &quot;A String&quot;, # Required. User Cloud Storage bucket location (REQUIRED) ## Must be formatted with path prefix (gs://$GCS_BUCKET) Permissions: User Managed Notebooks: - storage.buckets.writer: Must be given to the project&#x27;s service account attached to VM. Google Managed Notebooks: - storage.buckets.writer: Must be given to the project&#x27;s service account or ## user credentials attached to VM depending on authentication mode. Cloud Storage bucket Log file will be written to gs://$GCS_BUCKET/$RELATIVE_PATH/$VM_DATE_$TIME.tar.gz
351+
&quot;packetCaptureFlagEnabled&quot;: True or False, # Optional. Enables flag to capture packets from the instance for 30 seconds
352+
&quot;relativePath&quot;: &quot;A String&quot;, # Optional. Defines the relative storage path in the Cloud Storage bucket where the diagnostic logs will be written: Default path will be the root directory of the Cloud Storage bucket (gs://$GCS_BUCKET/$DATE_$TIME.tar.gz) Example of full path where Log file will be written: gs://$GCS_BUCKET/$RELATIVE_PATH/
353+
&quot;repairFlagEnabled&quot;: True or False, # Optional. Enables flag to repair service for instance
354+
},
355+
}
356+
357+
x__xgafv: string, V1 error format.
358+
Allowed values
359+
1 - v1 error format
360+
2 - v2 error format
361+
362+
Returns:
363+
An object of the form:
364+
365+
{ # This resource represents a long-running operation that is the result of a network API call.
366+
&quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.
367+
&quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
368+
&quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
369+
&quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
370+
{
371+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
372+
},
373+
],
374+
&quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
375+
},
376+
&quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
377+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
378+
},
379+
&quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`.
380+
&quot;response&quot;: { # The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
381+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
382+
},
383+
}</pre>
384+
</div>
385+
335386
<div class="method">
336387
<code class="details" id="get">get(name, x__xgafv=None)</code>
337388
<pre>Gets details of a single Instance.

‎docs/dyn/notebooks_v1.projects.locations.runtimes.html

+96
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,9 @@ <h2>Instance Methods</h2>
8383
<p class="toc_element">
8484
<code><a href="#delete">delete(name, requestId=None, x__xgafv=None)</a></code></p>
8585
<p class="firstline">Deletes a single Runtime.</p>
86+
<p class="toc_element">
87+
<code><a href="#diagnose">diagnose(name, body=None, x__xgafv=None)</a></code></p>
88+
<p class="firstline">Creates a Diagnostic File and runs Diagnostic Tool given a Runtime.</p>
8689
<p class="toc_element">
8790
<code><a href="#get">get(name, x__xgafv=None)</a></code></p>
8891
<p class="firstline">Gets details of a single Runtime. The location must be a regional endpoint rather than zonal.</p>
@@ -122,6 +125,9 @@ <h2>Instance Methods</h2>
122125
<p class="toc_element">
123126
<code><a href="#testIamPermissions">testIamPermissions(resource, body=None, x__xgafv=None)</a></code></p>
124127
<p class="firstline">Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may "fail open" without warning.</p>
128+
<p class="toc_element">
129+
<code><a href="#upgrade">upgrade(name, body=None, x__xgafv=None)</a></code></p>
130+
<p class="firstline">Upgrades a Managed Notebook Runtime to the latest version.</p>
125131
<h3>Method Details</h3>
126132
<div class="method">
127133
<code class="details" id="close">close()</code>
@@ -313,6 +319,54 @@ <h3>Method Details</h3>
313319
}</pre>
314320
</div>
315321

322+
<div class="method">
323+
<code class="details" id="diagnose">diagnose(name, body=None, x__xgafv=None)</code>
324+
<pre>Creates a Diagnostic File and runs Diagnostic Tool given a Runtime.
325+
326+
Args:
327+
name: string, Required. Format: `projects/{project_id}/locations/{location}/runtimes/{runtimes_id}` (required)
328+
body: object, The request body.
329+
The object takes the form of:
330+
331+
{ # Request for creating a notebook instance diagnostic file.
332+
&quot;diagnosticConfig&quot;: { # Defines flags that are used to run the diagnostic tool # Required. Defines flags that are used to run the diagnostic tool
333+
&quot;copyHomeFilesFlagEnabled&quot;: True or False, # Optional. Enables flag to copy all `/home/jupyter` folder contents
334+
&quot;gcsBucket&quot;: &quot;A String&quot;, # Required. User Cloud Storage bucket location (REQUIRED) ## Must be formatted with path prefix (gs://$GCS_BUCKET) Permissions: User Managed Notebooks: - storage.buckets.writer: Must be given to the project&#x27;s service account attached to VM. Google Managed Notebooks: - storage.buckets.writer: Must be given to the project&#x27;s service account or ## user credentials attached to VM depending on authentication mode. Cloud Storage bucket Log file will be written to gs://$GCS_BUCKET/$RELATIVE_PATH/$VM_DATE_$TIME.tar.gz
335+
&quot;packetCaptureFlagEnabled&quot;: True or False, # Optional. Enables flag to capture packets from the instance for 30 seconds
336+
&quot;relativePath&quot;: &quot;A String&quot;, # Optional. Defines the relative storage path in the Cloud Storage bucket where the diagnostic logs will be written: Default path will be the root directory of the Cloud Storage bucket (gs://$GCS_BUCKET/$DATE_$TIME.tar.gz) Example of full path where Log file will be written: gs://$GCS_BUCKET/$RELATIVE_PATH/
337+
&quot;repairFlagEnabled&quot;: True or False, # Optional. Enables flag to repair service for instance
338+
},
339+
}
340+
341+
x__xgafv: string, V1 error format.
342+
Allowed values
343+
1 - v1 error format
344+
2 - v2 error format
345+
346+
Returns:
347+
An object of the form:
348+
349+
{ # This resource represents a long-running operation that is the result of a network API call.
350+
&quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.
351+
&quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
352+
&quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
353+
&quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
354+
{
355+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
356+
},
357+
],
358+
&quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
359+
},
360+
&quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
361+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
362+
},
363+
&quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`.
364+
&quot;response&quot;: { # The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
365+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
366+
},
367+
}</pre>
368+
</div>
369+
316370
<div class="method">
317371
<code class="details" id="get">get(name, x__xgafv=None)</code>
318372
<pre>Gets details of a single Runtime. The location must be a regional endpoint rather than zonal.
@@ -1106,4 +1160,46 @@ <h3>Method Details</h3>
11061160
}</pre>
11071161
</div>
11081162

1163+
<div class="method">
1164+
<code class="details" id="upgrade">upgrade(name, body=None, x__xgafv=None)</code>
1165+
<pre>Upgrades a Managed Notebook Runtime to the latest version.
1166+
1167+
Args:
1168+
name: string, Required. Format: `projects/{project_id}/locations/{location}/runtimes/{runtime_id}` (required)
1169+
body: object, The request body.
1170+
The object takes the form of:
1171+
1172+
{ # Request for upgrading a Managed Notebook Runtime to the latest version. option (google.api.message_visibility).restriction = &quot;TRUSTED_TESTER,SPECIAL_TESTER&quot;;
1173+
&quot;requestId&quot;: &quot;A String&quot;, # Idempotent request UUID.
1174+
}
1175+
1176+
x__xgafv: string, V1 error format.
1177+
Allowed values
1178+
1 - v1 error format
1179+
2 - v2 error format
1180+
1181+
Returns:
1182+
An object of the form:
1183+
1184+
{ # This resource represents a long-running operation that is the result of a network API call.
1185+
&quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.
1186+
&quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
1187+
&quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
1188+
&quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
1189+
{
1190+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
1191+
},
1192+
],
1193+
&quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
1194+
},
1195+
&quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
1196+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
1197+
},
1198+
&quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`.
1199+
&quot;response&quot;: { # The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
1200+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
1201+
},
1202+
}</pre>
1203+
</div>
1204+
11091205
</body></html>

‎googleapiclient/discovery_cache/documents/notebooks.v1.json

+145-1
Original file line numberDiff line numberDiff line change
@@ -493,6 +493,34 @@
493493
"https://www.googleapis.com/auth/cloud-platform"
494494
]
495495
},
496+
"diagnose": {
497+
"description": "Creates a Diagnostic File and runs Diagnostic Tool given an Instance.",
498+
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/instances/{instancesId}:diagnose",
499+
"httpMethod": "POST",
500+
"id": "notebooks.projects.locations.instances.diagnose",
501+
"parameterOrder": [
502+
"name"
503+
],
504+
"parameters": {
505+
"name": {
506+
"description": "Required. Format: `projects/{project_id}/locations/{location}/instances/{instance_id}`",
507+
"location": "path",
508+
"pattern": "^projects/[^/]+/locations/[^/]+/instances/[^/]+$",
509+
"required": true,
510+
"type": "string"
511+
}
512+
},
513+
"path": "v1/{+name}:diagnose",
514+
"request": {
515+
"$ref": "DiagnoseInstanceRequest"
516+
},
517+
"response": {
518+
"$ref": "Operation"
519+
},
520+
"scopes": [
521+
"https://www.googleapis.com/auth/cloud-platform"
522+
]
523+
},
496524
"get": {
497525
"description": "Gets details of a single Instance.",
498526
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/instances/{instancesId}",
@@ -1297,6 +1325,34 @@
12971325
"https://www.googleapis.com/auth/cloud-platform"
12981326
]
12991327
},
1328+
"diagnose": {
1329+
"description": "Creates a Diagnostic File and runs Diagnostic Tool given a Runtime.",
1330+
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/runtimes/{runtimesId}:diagnose",
1331+
"httpMethod": "POST",
1332+
"id": "notebooks.projects.locations.runtimes.diagnose",
1333+
"parameterOrder": [
1334+
"name"
1335+
],
1336+
"parameters": {
1337+
"name": {
1338+
"description": "Required. Format: `projects/{project_id}/locations/{location}/runtimes/{runtimes_id}`",
1339+
"location": "path",
1340+
"pattern": "^projects/[^/]+/locations/[^/]+/runtimes/[^/]+$",
1341+
"required": true,
1342+
"type": "string"
1343+
}
1344+
},
1345+
"path": "v1/{+name}:diagnose",
1346+
"request": {
1347+
"$ref": "DiagnoseRuntimeRequest"
1348+
},
1349+
"response": {
1350+
"$ref": "Operation"
1351+
},
1352+
"scopes": [
1353+
"https://www.googleapis.com/auth/cloud-platform"
1354+
]
1355+
},
13001356
"get": {
13011357
"description": "Gets details of a single Runtime. The location must be a regional endpoint rather than zonal.",
13021358
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/runtimes/{runtimesId}",
@@ -1651,6 +1707,34 @@
16511707
"scopes": [
16521708
"https://www.googleapis.com/auth/cloud-platform"
16531709
]
1710+
},
1711+
"upgrade": {
1712+
"description": "Upgrades a Managed Notebook Runtime to the latest version.",
1713+
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/runtimes/{runtimesId}:upgrade",
1714+
"httpMethod": "POST",
1715+
"id": "notebooks.projects.locations.runtimes.upgrade",
1716+
"parameterOrder": [
1717+
"name"
1718+
],
1719+
"parameters": {
1720+
"name": {
1721+
"description": "Required. Format: `projects/{project_id}/locations/{location}/runtimes/{runtime_id}`",
1722+
"location": "path",
1723+
"pattern": "^projects/[^/]+/locations/[^/]+/runtimes/[^/]+$",
1724+
"required": true,
1725+
"type": "string"
1726+
}
1727+
},
1728+
"path": "v1/{+name}:upgrade",
1729+
"request": {
1730+
"$ref": "UpgradeRuntimeRequest"
1731+
},
1732+
"response": {
1733+
"$ref": "Operation"
1734+
},
1735+
"scopes": [
1736+
"https://www.googleapis.com/auth/cloud-platform"
1737+
]
16541738
}
16551739
}
16561740
},
@@ -1820,7 +1904,7 @@
18201904
}
18211905
}
18221906
},
1823-
"revision": "20220909",
1907+
"revision": "20220927",
18241908
"rootUrl": "https://notebooks.googleapis.com/",
18251909
"schemas": {
18261910
"AcceleratorConfig": {
@@ -1927,6 +2011,55 @@
19272011
},
19282012
"type": "object"
19292013
},
2014+
"DiagnoseInstanceRequest": {
2015+
"description": "Request for creating a notebook instance diagnostic file.",
2016+
"id": "DiagnoseInstanceRequest",
2017+
"properties": {
2018+
"diagnosticConfig": {
2019+
"$ref": "DiagnosticConfig",
2020+
"description": "Required. Defines flags that are used to run the diagnostic tool"
2021+
}
2022+
},
2023+
"type": "object"
2024+
},
2025+
"DiagnoseRuntimeRequest": {
2026+
"description": "Request for creating a notebook instance diagnostic file.",
2027+
"id": "DiagnoseRuntimeRequest",
2028+
"properties": {
2029+
"diagnosticConfig": {
2030+
"$ref": "DiagnosticConfig",
2031+
"description": "Required. Defines flags that are used to run the diagnostic tool"
2032+
}
2033+
},
2034+
"type": "object"
2035+
},
2036+
"DiagnosticConfig": {
2037+
"description": "Defines flags that are used to run the diagnostic tool",
2038+
"id": "DiagnosticConfig",
2039+
"properties": {
2040+
"copyHomeFilesFlagEnabled": {
2041+
"description": "Optional. Enables flag to copy all `/home/jupyter` folder contents",
2042+
"type": "boolean"
2043+
},
2044+
"gcsBucket": {
2045+
"description": "Required. User Cloud Storage bucket location (REQUIRED) ## Must be formatted with path prefix (gs://$GCS_BUCKET) Permissions: User Managed Notebooks: - storage.buckets.writer: Must be given to the project's service account attached to VM. Google Managed Notebooks: - storage.buckets.writer: Must be given to the project's service account or ## user credentials attached to VM depending on authentication mode. Cloud Storage bucket Log file will be written to gs://$GCS_BUCKET/$RELATIVE_PATH/$VM_DATE_$TIME.tar.gz",
2046+
"type": "string"
2047+
},
2048+
"packetCaptureFlagEnabled": {
2049+
"description": "Optional. Enables flag to capture packets from the instance for 30 seconds",
2050+
"type": "boolean"
2051+
},
2052+
"relativePath": {
2053+
"description": "Optional. Defines the relative storage path in the Cloud Storage bucket where the diagnostic logs will be written: Default path will be the root directory of the Cloud Storage bucket (gs://$GCS_BUCKET/$DATE_$TIME.tar.gz) Example of full path where Log file will be written: gs://$GCS_BUCKET/$RELATIVE_PATH/",
2054+
"type": "string"
2055+
},
2056+
"repairFlagEnabled": {
2057+
"description": "Optional. Enables flag to repair service for instance",
2058+
"type": "boolean"
2059+
}
2060+
},
2061+
"type": "object"
2062+
},
19302063
"Disk": {
19312064
"description": "An instance-attached disk resource.",
19322065
"id": "Disk",
@@ -3934,6 +4067,17 @@
39344067
},
39354068
"type": "object"
39364069
},
4070+
"UpgradeRuntimeRequest": {
4071+
"description": "Request for upgrading a Managed Notebook Runtime to the latest version. option (google.api.message_visibility).restriction = \"TRUSTED_TESTER,SPECIAL_TESTER\";",
4072+
"id": "UpgradeRuntimeRequest",
4073+
"properties": {
4074+
"requestId": {
4075+
"description": "Idempotent request UUID.",
4076+
"type": "string"
4077+
}
4078+
},
4079+
"type": "object"
4080+
},
39374081
"VertexAIParameters": {
39384082
"description": "Parameters used in Vertex AI JobType executions.",
39394083
"id": "VertexAIParameters",

0 commit comments

Comments
 (0)
Please sign in to comment.