Skip to content

Commit e386e27

Browse files
1 parent 7ded117 commit e386e27

File tree

9 files changed

+708
-6
lines changed

9 files changed

+708
-6
lines changed

clients/google-api-services-notebooks/v2/2.0.0/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Add the following lines to your `pom.xml` file:
2222
<dependency>
2323
<groupId>com.google.apis</groupId>
2424
<artifactId>google-api-services-notebooks</artifactId>
25-
<version>v2-rev20250604-2.0.0</version>
25+
<version>v2-rev20250710-2.0.0</version>
2626
</dependency>
2727
</dependencies>
2828
</project>
@@ -35,7 +35,7 @@ repositories {
3535
mavenCentral()
3636
}
3737
dependencies {
38-
implementation 'com.google.apis:google-api-services-notebooks:v2-rev20250604-2.0.0'
38+
implementation 'com.google.apis:google-api-services-notebooks:v2-rev20250710-2.0.0'
3939
}
4040
```
4141

clients/google-api-services-notebooks/v2/2.0.0/com/google/api/services/notebooks/v2/AIPlatformNotebooks.java

Lines changed: 279 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -557,6 +557,148 @@ public Instances instances() {
557557
*/
558558
public class Instances {
559559

560+
/**
561+
* Initiated by Cloud Console for Oauth consent flow for Workbench Instances. Do not use this method
562+
* directly. Design doc: go/wbi-euc:auth-dd
563+
*
564+
* Create a request for the method "instances.checkAuthorization".
565+
*
566+
* This request holds the parameters needed by the notebooks server. After setting any optional
567+
* parameters, call the {@link CheckAuthorization#execute()} method to invoke the remote operation.
568+
*
569+
* @param name Required. The name of the Notebook Instance resource. Format:
570+
* `projects/{project}/locations/{location}/instances/{instance}`
571+
* @param content the {@link com.google.api.services.notebooks.v2.model.CheckAuthorizationRequest}
572+
* @return the request
573+
*/
574+
public CheckAuthorization checkAuthorization(java.lang.String name, com.google.api.services.notebooks.v2.model.CheckAuthorizationRequest content) throws java.io.IOException {
575+
CheckAuthorization result = new CheckAuthorization(name, content);
576+
initialize(result);
577+
return result;
578+
}
579+
580+
public class CheckAuthorization extends AIPlatformNotebooksRequest<com.google.api.services.notebooks.v2.model.CheckAuthorizationResponse> {
581+
582+
private static final String REST_PATH = "v2/{+name}:checkAuthorization";
583+
584+
private final java.util.regex.Pattern NAME_PATTERN =
585+
java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/instances/[^/]+$");
586+
587+
/**
588+
* Initiated by Cloud Console for Oauth consent flow for Workbench Instances. Do not use this
589+
* method directly. Design doc: go/wbi-euc:auth-dd
590+
*
591+
* Create a request for the method "instances.checkAuthorization".
592+
*
593+
* This request holds the parameters needed by the the notebooks server. After setting any
594+
* optional parameters, call the {@link CheckAuthorization#execute()} method to invoke the remote
595+
* operation. <p> {@link CheckAuthorization#initialize(com.google.api.client.googleapis.services.A
596+
* bstractGoogleClientRequest)} must be called to initialize this instance immediately after
597+
* invoking the constructor. </p>
598+
*
599+
* @param name Required. The name of the Notebook Instance resource. Format:
600+
* `projects/{project}/locations/{location}/instances/{instance}`
601+
* @param content the {@link com.google.api.services.notebooks.v2.model.CheckAuthorizationRequest}
602+
* @since 1.13
603+
*/
604+
protected CheckAuthorization(java.lang.String name, com.google.api.services.notebooks.v2.model.CheckAuthorizationRequest content) {
605+
super(AIPlatformNotebooks.this, "POST", REST_PATH, content, com.google.api.services.notebooks.v2.model.CheckAuthorizationResponse.class);
606+
this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
607+
if (!getSuppressPatternChecks()) {
608+
com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
609+
"Parameter name must conform to the pattern " +
610+
"^projects/[^/]+/locations/[^/]+/instances/[^/]+$");
611+
}
612+
}
613+
614+
@Override
615+
public CheckAuthorization set$Xgafv(java.lang.String $Xgafv) {
616+
return (CheckAuthorization) super.set$Xgafv($Xgafv);
617+
}
618+
619+
@Override
620+
public CheckAuthorization setAccessToken(java.lang.String accessToken) {
621+
return (CheckAuthorization) super.setAccessToken(accessToken);
622+
}
623+
624+
@Override
625+
public CheckAuthorization setAlt(java.lang.String alt) {
626+
return (CheckAuthorization) super.setAlt(alt);
627+
}
628+
629+
@Override
630+
public CheckAuthorization setCallback(java.lang.String callback) {
631+
return (CheckAuthorization) super.setCallback(callback);
632+
}
633+
634+
@Override
635+
public CheckAuthorization setFields(java.lang.String fields) {
636+
return (CheckAuthorization) super.setFields(fields);
637+
}
638+
639+
@Override
640+
public CheckAuthorization setKey(java.lang.String key) {
641+
return (CheckAuthorization) super.setKey(key);
642+
}
643+
644+
@Override
645+
public CheckAuthorization setOauthToken(java.lang.String oauthToken) {
646+
return (CheckAuthorization) super.setOauthToken(oauthToken);
647+
}
648+
649+
@Override
650+
public CheckAuthorization setPrettyPrint(java.lang.Boolean prettyPrint) {
651+
return (CheckAuthorization) super.setPrettyPrint(prettyPrint);
652+
}
653+
654+
@Override
655+
public CheckAuthorization setQuotaUser(java.lang.String quotaUser) {
656+
return (CheckAuthorization) super.setQuotaUser(quotaUser);
657+
}
658+
659+
@Override
660+
public CheckAuthorization setUploadType(java.lang.String uploadType) {
661+
return (CheckAuthorization) super.setUploadType(uploadType);
662+
}
663+
664+
@Override
665+
public CheckAuthorization setUploadProtocol(java.lang.String uploadProtocol) {
666+
return (CheckAuthorization) super.setUploadProtocol(uploadProtocol);
667+
}
668+
669+
/**
670+
* Required. The name of the Notebook Instance resource. Format:
671+
* `projects/{project}/locations/{location}/instances/{instance}`
672+
*/
673+
@com.google.api.client.util.Key
674+
private java.lang.String name;
675+
676+
/** Required. The name of the Notebook Instance resource. Format:
677+
`projects/{project}/locations/{location}/instances/{instance}`
678+
*/
679+
public java.lang.String getName() {
680+
return name;
681+
}
682+
683+
/**
684+
* Required. The name of the Notebook Instance resource. Format:
685+
* `projects/{project}/locations/{location}/instances/{instance}`
686+
*/
687+
public CheckAuthorization setName(java.lang.String name) {
688+
if (!getSuppressPatternChecks()) {
689+
com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
690+
"Parameter name must conform to the pattern " +
691+
"^projects/[^/]+/locations/[^/]+/instances/[^/]+$");
692+
}
693+
this.name = name;
694+
return this;
695+
}
696+
697+
@Override
698+
public CheckAuthorization set(String parameterName, Object value) {
699+
return (CheckAuthorization) super.set(parameterName, value);
700+
}
701+
}
560702
/**
561703
* Checks whether a notebook instance is upgradable.
562704
*
@@ -1147,6 +1289,143 @@ public Diagnose set(String parameterName, Object value) {
11471289
return (Diagnose) super.set(parameterName, value);
11481290
}
11491291
}
1292+
/**
1293+
* Called by VM to return an EUC for the instance owner. Do not use this method directly. Design
1294+
* doc: go/wbi-euc:dd
1295+
*
1296+
* Create a request for the method "instances.generateAccessToken".
1297+
*
1298+
* This request holds the parameters needed by the notebooks server. After setting any optional
1299+
* parameters, call the {@link GenerateAccessToken#execute()} method to invoke the remote operation.
1300+
*
1301+
* @param name Required. Format: `projects/{project}/locations/{location}/instances/{instance_id}`
1302+
* @param content the {@link com.google.api.services.notebooks.v2.model.GenerateAccessTokenRequest}
1303+
* @return the request
1304+
*/
1305+
public GenerateAccessToken generateAccessToken(java.lang.String name, com.google.api.services.notebooks.v2.model.GenerateAccessTokenRequest content) throws java.io.IOException {
1306+
GenerateAccessToken result = new GenerateAccessToken(name, content);
1307+
initialize(result);
1308+
return result;
1309+
}
1310+
1311+
public class GenerateAccessToken extends AIPlatformNotebooksRequest<com.google.api.services.notebooks.v2.model.GenerateAccessTokenResponse> {
1312+
1313+
private static final String REST_PATH = "v2/{+name}:generateAccessToken";
1314+
1315+
private final java.util.regex.Pattern NAME_PATTERN =
1316+
java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/instances/[^/]+$");
1317+
1318+
/**
1319+
* Called by VM to return an EUC for the instance owner. Do not use this method directly. Design
1320+
* doc: go/wbi-euc:dd
1321+
*
1322+
* Create a request for the method "instances.generateAccessToken".
1323+
*
1324+
* This request holds the parameters needed by the the notebooks server. After setting any
1325+
* optional parameters, call the {@link GenerateAccessToken#execute()} method to invoke the remote
1326+
* operation. <p> {@link GenerateAccessToken#initialize(com.google.api.client.googleapis.services.
1327+
* AbstractGoogleClientRequest)} must be called to initialize this instance immediately after
1328+
* invoking the constructor. </p>
1329+
*
1330+
* @param name Required. Format: `projects/{project}/locations/{location}/instances/{instance_id}`
1331+
* @param content the {@link com.google.api.services.notebooks.v2.model.GenerateAccessTokenRequest}
1332+
* @since 1.13
1333+
*/
1334+
protected GenerateAccessToken(java.lang.String name, com.google.api.services.notebooks.v2.model.GenerateAccessTokenRequest content) {
1335+
super(AIPlatformNotebooks.this, "POST", REST_PATH, content, com.google.api.services.notebooks.v2.model.GenerateAccessTokenResponse.class);
1336+
this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
1337+
if (!getSuppressPatternChecks()) {
1338+
com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
1339+
"Parameter name must conform to the pattern " +
1340+
"^projects/[^/]+/locations/[^/]+/instances/[^/]+$");
1341+
}
1342+
}
1343+
1344+
@Override
1345+
public GenerateAccessToken set$Xgafv(java.lang.String $Xgafv) {
1346+
return (GenerateAccessToken) super.set$Xgafv($Xgafv);
1347+
}
1348+
1349+
@Override
1350+
public GenerateAccessToken setAccessToken(java.lang.String accessToken) {
1351+
return (GenerateAccessToken) super.setAccessToken(accessToken);
1352+
}
1353+
1354+
@Override
1355+
public GenerateAccessToken setAlt(java.lang.String alt) {
1356+
return (GenerateAccessToken) super.setAlt(alt);
1357+
}
1358+
1359+
@Override
1360+
public GenerateAccessToken setCallback(java.lang.String callback) {
1361+
return (GenerateAccessToken) super.setCallback(callback);
1362+
}
1363+
1364+
@Override
1365+
public GenerateAccessToken setFields(java.lang.String fields) {
1366+
return (GenerateAccessToken) super.setFields(fields);
1367+
}
1368+
1369+
@Override
1370+
public GenerateAccessToken setKey(java.lang.String key) {
1371+
return (GenerateAccessToken) super.setKey(key);
1372+
}
1373+
1374+
@Override
1375+
public GenerateAccessToken setOauthToken(java.lang.String oauthToken) {
1376+
return (GenerateAccessToken) super.setOauthToken(oauthToken);
1377+
}
1378+
1379+
@Override
1380+
public GenerateAccessToken setPrettyPrint(java.lang.Boolean prettyPrint) {
1381+
return (GenerateAccessToken) super.setPrettyPrint(prettyPrint);
1382+
}
1383+
1384+
@Override
1385+
public GenerateAccessToken setQuotaUser(java.lang.String quotaUser) {
1386+
return (GenerateAccessToken) super.setQuotaUser(quotaUser);
1387+
}
1388+
1389+
@Override
1390+
public GenerateAccessToken setUploadType(java.lang.String uploadType) {
1391+
return (GenerateAccessToken) super.setUploadType(uploadType);
1392+
}
1393+
1394+
@Override
1395+
public GenerateAccessToken setUploadProtocol(java.lang.String uploadProtocol) {
1396+
return (GenerateAccessToken) super.setUploadProtocol(uploadProtocol);
1397+
}
1398+
1399+
/**
1400+
* Required. Format: `projects/{project}/locations/{location}/instances/{instance_id}`
1401+
*/
1402+
@com.google.api.client.util.Key
1403+
private java.lang.String name;
1404+
1405+
/** Required. Format: `projects/{project}/locations/{location}/instances/{instance_id}`
1406+
*/
1407+
public java.lang.String getName() {
1408+
return name;
1409+
}
1410+
1411+
/**
1412+
* Required. Format: `projects/{project}/locations/{location}/instances/{instance_id}`
1413+
*/
1414+
public GenerateAccessToken setName(java.lang.String name) {
1415+
if (!getSuppressPatternChecks()) {
1416+
com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
1417+
"Parameter name must conform to the pattern " +
1418+
"^projects/[^/]+/locations/[^/]+/instances/[^/]+$");
1419+
}
1420+
this.name = name;
1421+
return this;
1422+
}
1423+
1424+
@Override
1425+
public GenerateAccessToken set(String parameterName, Object value) {
1426+
return (GenerateAccessToken) super.set(parameterName, value);
1427+
}
1428+
}
11501429
/**
11511430
* Gets details of a single Instance.
11521431
*
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
/*
2+
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
3+
* in compliance with the License. You may obtain a copy of the License at
4+
*
5+
* http://www.apache.org/licenses/LICENSE-2.0
6+
*
7+
* Unless required by applicable law or agreed to in writing, software distributed under the License
8+
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
9+
* or implied. See the License for the specific language governing permissions and limitations under
10+
* the License.
11+
*/
12+
/*
13+
* This code was generated by https://github.com/googleapis/google-api-java-client-services/
14+
* Modify at your own risk.
15+
*/
16+
17+
package com.google.api.services.notebooks.v2.model;
18+
19+
/**
20+
* Request message for checking authorization for the instance owner.
21+
*
22+
* <p> This is the Java data model class that specifies how to parse/serialize into the JSON that is
23+
* transmitted over HTTP when working with the Notebooks API. For a detailed explanation see:
24+
* <a href="https://developers.google.com/api-client-library/java/google-http-java-client/json">https://developers.google.com/api-client-library/java/google-http-java-client/json</a>
25+
* </p>
26+
*
27+
* @author Google, Inc.
28+
*/
29+
@SuppressWarnings("javadoc")
30+
public final class CheckAuthorizationRequest extends com.google.api.client.json.GenericJson {
31+
32+
/**
33+
* Optional. The details of the OAuth authorization response. This may include additional params
34+
* such as dry_run, version_info, origin, propagate, etc.
35+
* The value may be {@code null}.
36+
*/
37+
@com.google.api.client.util.Key
38+
private java.util.Map<String, java.lang.String> authorizationDetails;
39+
40+
/**
41+
* Optional. The details of the OAuth authorization response. This may include additional params
42+
* such as dry_run, version_info, origin, propagate, etc.
43+
* @return value or {@code null} for none
44+
*/
45+
public java.util.Map<String, java.lang.String> getAuthorizationDetails() {
46+
return authorizationDetails;
47+
}
48+
49+
/**
50+
* Optional. The details of the OAuth authorization response. This may include additional params
51+
* such as dry_run, version_info, origin, propagate, etc.
52+
* @param authorizationDetails authorizationDetails or {@code null} for none
53+
*/
54+
public CheckAuthorizationRequest setAuthorizationDetails(java.util.Map<String, java.lang.String> authorizationDetails) {
55+
this.authorizationDetails = authorizationDetails;
56+
return this;
57+
}
58+
59+
@Override
60+
public CheckAuthorizationRequest set(String fieldName, Object value) {
61+
return (CheckAuthorizationRequest) super.set(fieldName, value);
62+
}
63+
64+
@Override
65+
public CheckAuthorizationRequest clone() {
66+
return (CheckAuthorizationRequest) super.clone();
67+
}
68+
69+
}

0 commit comments

Comments
 (0)