Skip to content

Commit 6658409

Browse files
feat(notebooks): update the api
#### notebooks:v1 The following keys were added: - resources.projects.resources.locations.resources.instances.methods.isUpgradeable.parameters.type (Total Keys: 2) - resources.projects.resources.locations.resources.instances.methods.updateMetadataItems (Total Keys: 12) - schemas.UpdateInstanceMetadataItemsRequest (Total Keys: 4) - schemas.UpdateInstanceMetadataItemsResponse (Total Keys: 4) - schemas.UpgradeInstanceInternalRequest.properties.type.type (Total Keys: 1) - schemas.UpgradeInstanceRequest.properties.type.type (Total Keys: 1)
1 parent 288618f commit 6658409

File tree

3 files changed

+162
-8
lines changed

3 files changed

+162
-8
lines changed

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

Lines changed: 45 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ <h2>Instance Methods</h2>
9393
<code><a href="#getInstanceHealth">getInstanceHealth(name, x__xgafv=None)</a></code></p>
9494
<p class="firstline">Check if a notebook instance is healthy.</p>
9595
<p class="toc_element">
96-
<code><a href="#isUpgradeable">isUpgradeable(notebookInstance, x__xgafv=None)</a></code></p>
96+
<code><a href="#isUpgradeable">isUpgradeable(notebookInstance, type=None, x__xgafv=None)</a></code></p>
9797
<p class="firstline">Check if a notebook instance is upgradable.</p>
9898
<p class="toc_element">
9999
<code><a href="#list">list(parent, pageSize=None, pageToken=None, x__xgafv=None)</a></code></p>
@@ -137,6 +137,9 @@ <h2>Instance Methods</h2>
137137
<p class="toc_element">
138138
<code><a href="#updateConfig">updateConfig(name, body=None, x__xgafv=None)</a></code></p>
139139
<p class="firstline">Update Notebook Instance configurations.</p>
140+
<p class="toc_element">
141+
<code><a href="#updateMetadataItems">updateMetadataItems(name, body=None, x__xgafv=None)</a></code></p>
142+
<p class="firstline">Add/update metadata items for an instance.</p>
140143
<p class="toc_element">
141144
<code><a href="#updateShieldedInstanceConfig">updateShieldedInstanceConfig(name, body=None, x__xgafv=None)</a></code></p>
142145
<p class="firstline">Updates the Shielded instance configuration of a single Instance.</p>
@@ -449,7 +452,7 @@ <h3>Method Details</h3>
449452

450453
Args:
451454
resource: string, REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. (required)
452-
options_requestedPolicyVersion: integer, Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
455+
options_requestedPolicyVersion: integer, Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
453456
x__xgafv: string, V1 error format.
454457
Allowed values
455458
1 - v1 error format
@@ -501,11 +504,18 @@ <h3>Method Details</h3>
501504
</div>
502505

503506
<div class="method">
504-
<code class="details" id="isUpgradeable">isUpgradeable(notebookInstance, x__xgafv=None)</code>
507+
<code class="details" id="isUpgradeable">isUpgradeable(notebookInstance, type=None, x__xgafv=None)</code>
505508
<pre>Check if a notebook instance is upgradable.
506509

507510
Args:
508511
notebookInstance: string, Required. Format: `projects/{project_id}/locations/{location}/instances/{instance_id}` (required)
512+
type: string, Optional. The optional UpgradeType. Setting this field will search for additional compute images to upgrade this instance.
513+
Allowed values
514+
UPGRADE_TYPE_UNSPECIFIED - Upgrade type is not specified.
515+
UPGRADE_FRAMEWORK - Upgrade ML framework.
516+
UPGRADE_OS - Upgrade Operating System.
517+
UPGRADE_CUDA - Upgrade CUDA.
518+
UPGRADE_ALL - Upgrade All (OS, Framework and CUDA).
509519
x__xgafv: string, V1 error format.
510520
Allowed values
511521
1 - v1 error format
@@ -1176,6 +1186,36 @@ <h3>Method Details</h3>
11761186
}</pre>
11771187
</div>
11781188

1189+
<div class="method">
1190+
<code class="details" id="updateMetadataItems">updateMetadataItems(name, body=None, x__xgafv=None)</code>
1191+
<pre>Add/update metadata items for an instance.
1192+
1193+
Args:
1194+
name: string, Required. Format: `projects/{project_id}/locations/{location}/instances/{instance_id}` (required)
1195+
body: object, The request body.
1196+
The object takes the form of:
1197+
1198+
{ # Request for adding/changing metadata items for an instance.
1199+
&quot;items&quot;: { # Metadata items to add/update for the instance.
1200+
&quot;a_key&quot;: &quot;A String&quot;,
1201+
},
1202+
}
1203+
1204+
x__xgafv: string, V1 error format.
1205+
Allowed values
1206+
1 - v1 error format
1207+
2 - v2 error format
1208+
1209+
Returns:
1210+
An object of the form:
1211+
1212+
{ # Response for adding/changing metadata items for an instance.
1213+
&quot;items&quot;: { # Map of items that were added/updated to/in the metadata.
1214+
&quot;a_key&quot;: &quot;A String&quot;,
1215+
},
1216+
}</pre>
1217+
</div>
1218+
11791219
<div class="method">
11801220
<code class="details" id="updateShieldedInstanceConfig">updateShieldedInstanceConfig(name, body=None, x__xgafv=None)</code>
11811221
<pre>Updates the Shielded instance configuration of a single Instance.
@@ -1232,6 +1272,7 @@ <h3>Method Details</h3>
12321272
The object takes the form of:
12331273

12341274
{ # Request for upgrading a notebook instance
1275+
&quot;type&quot;: &quot;A String&quot;, # Optional. The optional UpgradeType. Setting this field will search for additional compute images to upgrade this instance.
12351276
}
12361277

12371278
x__xgafv: string, V1 error format.
@@ -1273,6 +1314,7 @@ <h3>Method Details</h3>
12731314
The object takes the form of:
12741315

12751316
{ # Request for upgrading a notebook instance from within the VM
1317+
&quot;type&quot;: &quot;A String&quot;, # Optional. The optional UpgradeType. Setting this field will search for additional compute images to upgrade this instance.
12761318
&quot;vmId&quot;: &quot;A String&quot;, # Required. The VM hardware token for authenticating the VM. https://cloud.google.com/compute/docs/instances/verifying-instance-identity
12771319
}
12781320

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -411,7 +411,7 @@ <h3>Method Details</h3>
411411

412412
Args:
413413
resource: string, REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. (required)
414-
options_requestedPolicyVersion: integer, Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
414+
options_requestedPolicyVersion: integer, Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
415415
x__xgafv: string, V1 error format.
416416
Allowed values
417417
1 - v1 error format

googleapiclient/discovery_cache/documents/notebooks.v1.json

Lines changed: 116 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -528,7 +528,7 @@
528528
],
529529
"parameters": {
530530
"options.requestedPolicyVersion": {
531-
"description": "Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).",
531+
"description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).",
532532
"format": "int32",
533533
"location": "query",
534534
"type": "integer"
@@ -589,6 +589,25 @@
589589
"pattern": "^projects/[^/]+/locations/[^/]+/instances/[^/]+$",
590590
"required": true,
591591
"type": "string"
592+
},
593+
"type": {
594+
"description": "Optional. The optional UpgradeType. Setting this field will search for additional compute images to upgrade this instance.",
595+
"enum": [
596+
"UPGRADE_TYPE_UNSPECIFIED",
597+
"UPGRADE_FRAMEWORK",
598+
"UPGRADE_OS",
599+
"UPGRADE_CUDA",
600+
"UPGRADE_ALL"
601+
],
602+
"enumDescriptions": [
603+
"Upgrade type is not specified.",
604+
"Upgrade ML framework.",
605+
"Upgrade Operating System.",
606+
"Upgrade CUDA.",
607+
"Upgrade All (OS, Framework and CUDA)."
608+
],
609+
"location": "query",
610+
"type": "string"
592611
}
593612
},
594613
"path": "v1/{+notebookInstance}:isUpgradeable",
@@ -971,6 +990,34 @@
971990
"https://www.googleapis.com/auth/cloud-platform"
972991
]
973992
},
993+
"updateMetadataItems": {
994+
"description": "Add/update metadata items for an instance.",
995+
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/instances/{instancesId}:updateMetadataItems",
996+
"httpMethod": "PATCH",
997+
"id": "notebooks.projects.locations.instances.updateMetadataItems",
998+
"parameterOrder": [
999+
"name"
1000+
],
1001+
"parameters": {
1002+
"name": {
1003+
"description": "Required. Format: `projects/{project_id}/locations/{location}/instances/{instance_id}`",
1004+
"location": "path",
1005+
"pattern": "^projects/[^/]+/locations/[^/]+/instances/[^/]+$",
1006+
"required": true,
1007+
"type": "string"
1008+
}
1009+
},
1010+
"path": "v1/{+name}:updateMetadataItems",
1011+
"request": {
1012+
"$ref": "UpdateInstanceMetadataItemsRequest"
1013+
},
1014+
"response": {
1015+
"$ref": "UpdateInstanceMetadataItemsResponse"
1016+
},
1017+
"scopes": [
1018+
"https://www.googleapis.com/auth/cloud-platform"
1019+
]
1020+
},
9741021
"updateShieldedInstanceConfig": {
9751022
"description": "Updates the Shielded instance configuration of a single Instance.",
9761023
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/instances/{instancesId}:updateShieldedInstanceConfig",
@@ -1275,7 +1322,7 @@
12751322
],
12761323
"parameters": {
12771324
"options.requestedPolicyVersion": {
1278-
"description": "Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).",
1325+
"description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).",
12791326
"format": "int32",
12801327
"location": "query",
12811328
"type": "integer"
@@ -1696,7 +1743,7 @@
16961743
}
16971744
}
16981745
},
1699-
"revision": "20211019",
1746+
"revision": "20220104",
17001747
"rootUrl": "https://notebooks.googleapis.com/",
17011748
"schemas": {
17021749
"AcceleratorConfig": {
@@ -3526,6 +3573,34 @@
35263573
},
35273574
"type": "object"
35283575
},
3576+
"UpdateInstanceMetadataItemsRequest": {
3577+
"description": "Request for adding/changing metadata items for an instance.",
3578+
"id": "UpdateInstanceMetadataItemsRequest",
3579+
"properties": {
3580+
"items": {
3581+
"additionalProperties": {
3582+
"type": "string"
3583+
},
3584+
"description": "Metadata items to add/update for the instance.",
3585+
"type": "object"
3586+
}
3587+
},
3588+
"type": "object"
3589+
},
3590+
"UpdateInstanceMetadataItemsResponse": {
3591+
"description": "Response for adding/changing metadata items for an instance.",
3592+
"id": "UpdateInstanceMetadataItemsResponse",
3593+
"properties": {
3594+
"items": {
3595+
"additionalProperties": {
3596+
"type": "string"
3597+
},
3598+
"description": "Map of items that were added/updated to/in the metadata.",
3599+
"type": "object"
3600+
}
3601+
},
3602+
"type": "object"
3603+
},
35293604
"UpdateShieldedInstanceConfigRequest": {
35303605
"description": "Request for updating the Shielded Instance config for a notebook instance. You can only use this method on a stopped instance",
35313606
"id": "UpdateShieldedInstanceConfigRequest",
@@ -3611,6 +3686,24 @@
36113686
"description": "Request for upgrading a notebook instance from within the VM",
36123687
"id": "UpgradeInstanceInternalRequest",
36133688
"properties": {
3689+
"type": {
3690+
"description": "Optional. The optional UpgradeType. Setting this field will search for additional compute images to upgrade this instance.",
3691+
"enum": [
3692+
"UPGRADE_TYPE_UNSPECIFIED",
3693+
"UPGRADE_FRAMEWORK",
3694+
"UPGRADE_OS",
3695+
"UPGRADE_CUDA",
3696+
"UPGRADE_ALL"
3697+
],
3698+
"enumDescriptions": [
3699+
"Upgrade type is not specified.",
3700+
"Upgrade ML framework.",
3701+
"Upgrade Operating System.",
3702+
"Upgrade CUDA.",
3703+
"Upgrade All (OS, Framework and CUDA)."
3704+
],
3705+
"type": "string"
3706+
},
36143707
"vmId": {
36153708
"description": "Required. The VM hardware token for authenticating the VM. https://cloud.google.com/compute/docs/instances/verifying-instance-identity",
36163709
"type": "string"
@@ -3621,7 +3714,26 @@
36213714
"UpgradeInstanceRequest": {
36223715
"description": "Request for upgrading a notebook instance",
36233716
"id": "UpgradeInstanceRequest",
3624-
"properties": {},
3717+
"properties": {
3718+
"type": {
3719+
"description": "Optional. The optional UpgradeType. Setting this field will search for additional compute images to upgrade this instance.",
3720+
"enum": [
3721+
"UPGRADE_TYPE_UNSPECIFIED",
3722+
"UPGRADE_FRAMEWORK",
3723+
"UPGRADE_OS",
3724+
"UPGRADE_CUDA",
3725+
"UPGRADE_ALL"
3726+
],
3727+
"enumDescriptions": [
3728+
"Upgrade type is not specified.",
3729+
"Upgrade ML framework.",
3730+
"Upgrade Operating System.",
3731+
"Upgrade CUDA.",
3732+
"Upgrade All (OS, Framework and CUDA)."
3733+
],
3734+
"type": "string"
3735+
}
3736+
},
36253737
"type": "object"
36263738
},
36273739
"VertexAIParameters": {

0 commit comments

Comments
 (0)