Skip to content

Commit 6808657

Browse files
1 parent 646b00a commit 6808657

File tree

6 files changed

+404
-6
lines changed

6 files changed

+404
-6
lines changed

clients/google-api-services-oslogin/v1/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-oslogin</artifactId>
25-
<version>v1-rev20250518-2.0.0</version>
25+
<version>v1-rev20250921-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-oslogin:v1-rev20250518-2.0.0'
38+
implementation 'com.google.apis:google-api-services-oslogin:v1-rev20250921-2.0.0'
3939
}
4040
```
4141

clients/google-api-services-oslogin/v1/2.0.0/com/google/api/services/oslogin/v1/CloudOSLogin.java

Lines changed: 182 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,188 @@ protected void initialize(com.google.api.client.googleapis.services.AbstractGoog
133133
super.initialize(httpClientRequest);
134134
}
135135

136+
/**
137+
* An accessor for creating requests from the Projects collection.
138+
*
139+
* <p>The typical use is:</p>
140+
* <pre>
141+
* {@code CloudOSLogin oslogin = new CloudOSLogin(...);}
142+
* {@code CloudOSLogin.Projects.List request = oslogin.projects().list(parameters ...)}
143+
* </pre>
144+
*
145+
* @return the resource collection
146+
*/
147+
public Projects projects() {
148+
return new Projects();
149+
}
150+
151+
/**
152+
* The "projects" collection of methods.
153+
*/
154+
public class Projects {
155+
156+
/**
157+
* An accessor for creating requests from the Locations collection.
158+
*
159+
* <p>The typical use is:</p>
160+
* <pre>
161+
* {@code CloudOSLogin oslogin = new CloudOSLogin(...);}
162+
* {@code CloudOSLogin.Locations.List request = oslogin.locations().list(parameters ...)}
163+
* </pre>
164+
*
165+
* @return the resource collection
166+
*/
167+
public Locations locations() {
168+
return new Locations();
169+
}
170+
171+
/**
172+
* The "locations" collection of methods.
173+
*/
174+
public class Locations {
175+
176+
/**
177+
* Signs an SSH public key for a user to authenticate to a virtual machine on Google Compute Engine.
178+
*
179+
* Create a request for the method "locations.signSshPublicKey".
180+
*
181+
* This request holds the parameters needed by the oslogin server. After setting any optional
182+
* parameters, call the {@link SignSshPublicKey#execute()} method to invoke the remote operation.
183+
*
184+
* @param parent Required. The parent for the signing request. Format: projects/{project}/locations/{location}
185+
* @param content the {@link com.google.api.services.oslogin.v1.model.SignSshPublicKeyRequest}
186+
* @return the request
187+
*/
188+
public SignSshPublicKey signSshPublicKey(java.lang.String parent, com.google.api.services.oslogin.v1.model.SignSshPublicKeyRequest content) throws java.io.IOException {
189+
SignSshPublicKey result = new SignSshPublicKey(parent, content);
190+
initialize(result);
191+
return result;
192+
}
193+
194+
public class SignSshPublicKey extends CloudOSLoginRequest<com.google.api.services.oslogin.v1.model.SignSshPublicKeyResponse> {
195+
196+
private static final String REST_PATH = "v1/{+parent}:signSshPublicKey";
197+
198+
private final java.util.regex.Pattern PARENT_PATTERN =
199+
java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$");
200+
201+
/**
202+
* Signs an SSH public key for a user to authenticate to a virtual machine on Google Compute
203+
* Engine.
204+
*
205+
* Create a request for the method "locations.signSshPublicKey".
206+
*
207+
* This request holds the parameters needed by the the oslogin server. After setting any optional
208+
* parameters, call the {@link SignSshPublicKey#execute()} method to invoke the remote operation.
209+
* <p> {@link SignSshPublicKey#initialize(com.google.api.client.googleapis.services.AbstractGoogle
210+
* ClientRequest)} must be called to initialize this instance immediately after invoking the
211+
* constructor. </p>
212+
*
213+
* @param parent Required. The parent for the signing request. Format: projects/{project}/locations/{location}
214+
* @param content the {@link com.google.api.services.oslogin.v1.model.SignSshPublicKeyRequest}
215+
* @since 1.13
216+
*/
217+
protected SignSshPublicKey(java.lang.String parent, com.google.api.services.oslogin.v1.model.SignSshPublicKeyRequest content) {
218+
super(CloudOSLogin.this, "POST", REST_PATH, content, com.google.api.services.oslogin.v1.model.SignSshPublicKeyResponse.class);
219+
this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified.");
220+
if (!getSuppressPatternChecks()) {
221+
com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
222+
"Parameter parent must conform to the pattern " +
223+
"^projects/[^/]+/locations/[^/]+$");
224+
}
225+
}
226+
227+
@Override
228+
public SignSshPublicKey set$Xgafv(java.lang.String $Xgafv) {
229+
return (SignSshPublicKey) super.set$Xgafv($Xgafv);
230+
}
231+
232+
@Override
233+
public SignSshPublicKey setAccessToken(java.lang.String accessToken) {
234+
return (SignSshPublicKey) super.setAccessToken(accessToken);
235+
}
236+
237+
@Override
238+
public SignSshPublicKey setAlt(java.lang.String alt) {
239+
return (SignSshPublicKey) super.setAlt(alt);
240+
}
241+
242+
@Override
243+
public SignSshPublicKey setCallback(java.lang.String callback) {
244+
return (SignSshPublicKey) super.setCallback(callback);
245+
}
246+
247+
@Override
248+
public SignSshPublicKey setFields(java.lang.String fields) {
249+
return (SignSshPublicKey) super.setFields(fields);
250+
}
251+
252+
@Override
253+
public SignSshPublicKey setKey(java.lang.String key) {
254+
return (SignSshPublicKey) super.setKey(key);
255+
}
256+
257+
@Override
258+
public SignSshPublicKey setOauthToken(java.lang.String oauthToken) {
259+
return (SignSshPublicKey) super.setOauthToken(oauthToken);
260+
}
261+
262+
@Override
263+
public SignSshPublicKey setPrettyPrint(java.lang.Boolean prettyPrint) {
264+
return (SignSshPublicKey) super.setPrettyPrint(prettyPrint);
265+
}
266+
267+
@Override
268+
public SignSshPublicKey setQuotaUser(java.lang.String quotaUser) {
269+
return (SignSshPublicKey) super.setQuotaUser(quotaUser);
270+
}
271+
272+
@Override
273+
public SignSshPublicKey setUploadType(java.lang.String uploadType) {
274+
return (SignSshPublicKey) super.setUploadType(uploadType);
275+
}
276+
277+
@Override
278+
public SignSshPublicKey setUploadProtocol(java.lang.String uploadProtocol) {
279+
return (SignSshPublicKey) super.setUploadProtocol(uploadProtocol);
280+
}
281+
282+
/**
283+
* Required. The parent for the signing request. Format:
284+
* projects/{project}/locations/{location}
285+
*/
286+
@com.google.api.client.util.Key
287+
private java.lang.String parent;
288+
289+
/** Required. The parent for the signing request. Format: projects/{project}/locations/{location}
290+
*/
291+
public java.lang.String getParent() {
292+
return parent;
293+
}
294+
295+
/**
296+
* Required. The parent for the signing request. Format:
297+
* projects/{project}/locations/{location}
298+
*/
299+
public SignSshPublicKey setParent(java.lang.String parent) {
300+
if (!getSuppressPatternChecks()) {
301+
com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
302+
"Parameter parent must conform to the pattern " +
303+
"^projects/[^/]+/locations/[^/]+$");
304+
}
305+
this.parent = parent;
306+
return this;
307+
}
308+
309+
@Override
310+
public SignSshPublicKey set(String parameterName, Object value) {
311+
return (SignSshPublicKey) super.set(parameterName, value);
312+
}
313+
}
314+
315+
}
316+
}
317+
136318
/**
137319
* An accessor for creating requests from the Users collection.
138320
*
Lines changed: 150 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,150 @@
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.oslogin.v1.model;
18+
19+
/**
20+
* A request message for signing an SSH public key.
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 Cloud OS Login 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 SignSshPublicKeyRequest extends com.google.api.client.json.GenericJson {
31+
32+
/**
33+
* The App Engine instance to sign the SSH public key for. Expected format:
34+
* apps/{app}/services/{service}/versions/{version}/instances/{instance}
35+
* The value may be {@code null}.
36+
*/
37+
@com.google.api.client.util.Key
38+
private java.lang.String appEngineInstance;
39+
40+
/**
41+
* The Compute instance to sign the SSH public key for. Expected format:
42+
* projects/{project}/zones/{zone}/instances/{numeric_instance_id}
43+
* The value may be {@code null}.
44+
*/
45+
@com.google.api.client.util.Key
46+
private java.lang.String computeInstance;
47+
48+
/**
49+
* Optional. The service account for the instance. If the instance in question does not have a
50+
* service account, this field should be left empty. If the wrong service account is provided,
51+
* this operation will return a signed certificate that will not be accepted by the VM.
52+
* The value may be {@code null}.
53+
*/
54+
@com.google.api.client.util.Key
55+
private java.lang.String serviceAccount;
56+
57+
/**
58+
* Required. The SSH public key to sign.
59+
* The value may be {@code null}.
60+
*/
61+
@com.google.api.client.util.Key
62+
private java.lang.String sshPublicKey;
63+
64+
/**
65+
* The App Engine instance to sign the SSH public key for. Expected format:
66+
* apps/{app}/services/{service}/versions/{version}/instances/{instance}
67+
* @return value or {@code null} for none
68+
*/
69+
public java.lang.String getAppEngineInstance() {
70+
return appEngineInstance;
71+
}
72+
73+
/**
74+
* The App Engine instance to sign the SSH public key for. Expected format:
75+
* apps/{app}/services/{service}/versions/{version}/instances/{instance}
76+
* @param appEngineInstance appEngineInstance or {@code null} for none
77+
*/
78+
public SignSshPublicKeyRequest setAppEngineInstance(java.lang.String appEngineInstance) {
79+
this.appEngineInstance = appEngineInstance;
80+
return this;
81+
}
82+
83+
/**
84+
* The Compute instance to sign the SSH public key for. Expected format:
85+
* projects/{project}/zones/{zone}/instances/{numeric_instance_id}
86+
* @return value or {@code null} for none
87+
*/
88+
public java.lang.String getComputeInstance() {
89+
return computeInstance;
90+
}
91+
92+
/**
93+
* The Compute instance to sign the SSH public key for. Expected format:
94+
* projects/{project}/zones/{zone}/instances/{numeric_instance_id}
95+
* @param computeInstance computeInstance or {@code null} for none
96+
*/
97+
public SignSshPublicKeyRequest setComputeInstance(java.lang.String computeInstance) {
98+
this.computeInstance = computeInstance;
99+
return this;
100+
}
101+
102+
/**
103+
* Optional. The service account for the instance. If the instance in question does not have a
104+
* service account, this field should be left empty. If the wrong service account is provided,
105+
* this operation will return a signed certificate that will not be accepted by the VM.
106+
* @return value or {@code null} for none
107+
*/
108+
public java.lang.String getServiceAccount() {
109+
return serviceAccount;
110+
}
111+
112+
/**
113+
* Optional. The service account for the instance. If the instance in question does not have a
114+
* service account, this field should be left empty. If the wrong service account is provided,
115+
* this operation will return a signed certificate that will not be accepted by the VM.
116+
* @param serviceAccount serviceAccount or {@code null} for none
117+
*/
118+
public SignSshPublicKeyRequest setServiceAccount(java.lang.String serviceAccount) {
119+
this.serviceAccount = serviceAccount;
120+
return this;
121+
}
122+
123+
/**
124+
* Required. The SSH public key to sign.
125+
* @return value or {@code null} for none
126+
*/
127+
public java.lang.String getSshPublicKey() {
128+
return sshPublicKey;
129+
}
130+
131+
/**
132+
* Required. The SSH public key to sign.
133+
* @param sshPublicKey sshPublicKey or {@code null} for none
134+
*/
135+
public SignSshPublicKeyRequest setSshPublicKey(java.lang.String sshPublicKey) {
136+
this.sshPublicKey = sshPublicKey;
137+
return this;
138+
}
139+
140+
@Override
141+
public SignSshPublicKeyRequest set(String fieldName, Object value) {
142+
return (SignSshPublicKeyRequest) super.set(fieldName, value);
143+
}
144+
145+
@Override
146+
public SignSshPublicKeyRequest clone() {
147+
return (SignSshPublicKeyRequest) super.clone();
148+
}
149+
150+
}

0 commit comments

Comments
 (0)