From 28442479e75e32aef80e07fdf1138c44e43d140b Mon Sep 17 00:00:00 2001 From: yoshi-code-bot <70984784+yoshi-code-bot@users.noreply.github.com> Date: Wed, 22 Jul 2026 17:58:54 -0700 Subject: [PATCH] chore: regenerate agentidentitycredentials client --- .../v1/2.0.0/README.md | 44 ++ .../v1/AgentIdentityCredentials.java | 635 ++++++++++++++++++ .../v1/AgentIdentityCredentialsRequest.java | 267 ++++++++ ...IdentityCredentialsRequestInitializer.java | 119 ++++ .../v1/AgentIdentityCredentialsScopes.java | 42 ++ ...tidentitycredentialsV1ConsentRejected.java | 43 ++ ...edentialsV1FinalizeCredentialsRequest.java | 146 ++++ ...dentialsV1FinalizeCredentialsResponse.java | 43 ++ ...loudAgentidentitycredentialsV1Pending.java | 44 ++ ...edentialsV1RetrieveCredentialsRequest.java | 151 +++++ ...dentialsV1RetrieveCredentialsResponse.java | 139 ++++ ...loudAgentidentitycredentialsV1Success.java | 169 +++++ ...entitycredentialsV1UriConsentRequired.java | 129 ++++ .../v1/2.0.0/pom.xml | 219 ++++++ .../v1/README.md | 44 ++ .../v1alpha/2.0.0/README.md | 44 ++ .../v1alpha/AgentIdentityCredentials.java | 635 ++++++++++++++++++ .../AgentIdentityCredentialsRequest.java | 267 ++++++++ ...IdentityCredentialsRequestInitializer.java | 119 ++++ .../AgentIdentityCredentialsScopes.java | 42 ++ ...titycredentialsV1alphaConsentRejected.java | 43 ++ ...ialsV1alphaFinalizeCredentialsRequest.java | 146 ++++ ...alsV1alphaFinalizeCredentialsResponse.java | 43 ++ ...gentidentitycredentialsV1alphaPending.java | 44 ++ ...ialsV1alphaRetrieveCredentialsRequest.java | 151 +++++ ...alsV1alphaRetrieveCredentialsResponse.java | 139 ++++ ...gentidentitycredentialsV1alphaSuccess.java | 169 +++++ ...ycredentialsV1alphaUriConsentRequired.java | 129 ++++ .../v1alpha/2.0.0/pom.xml | 219 ++++++ .../v1alpha/README.md | 44 ++ 30 files changed, 4468 insertions(+) create mode 100644 clients/google-api-services-agentidentitycredentials/v1/2.0.0/README.md create mode 100644 clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentials.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentialsRequest.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentialsRequestInitializer.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentialsScopes.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1ConsentRejected.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsResponse.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1Pending.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsResponse.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1Success.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1UriConsentRequired.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1/2.0.0/pom.xml create mode 100644 clients/google-api-services-agentidentitycredentials/v1/README.md create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/README.md create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentials.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentialsRequest.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentialsRequestInitializer.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentialsScopes.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaConsentRejected.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsResponse.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaPending.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsResponse.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaSuccess.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired.java create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/pom.xml create mode 100644 clients/google-api-services-agentidentitycredentials/v1alpha/README.md diff --git a/clients/google-api-services-agentidentitycredentials/v1/2.0.0/README.md b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/README.md new file mode 100644 index 00000000000..bb3e110236f --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/README.md @@ -0,0 +1,44 @@ +# Agent Identity Credentials API Client Library for Java + +agentidentitycredentials.googleapis.com API. + +This page contains information about getting started with the Agent Identity Credentials API +using the Google API Client Library for Java. In addition, you may be interested +in the following documentation: + +* Browse the [Javadoc reference for the Agent Identity Credentials API][javadoc] +* Read the [Developer's Guide for the Google API Client Library for Java][google-api-client]. +* Interact with this API in your browser using the [APIs Explorer for the Agent Identity Credentials API][api-explorer] + +## Installation + +### Maven + +Add the following lines to your `pom.xml` file: + +```xml + + + + com.google.apis + google-api-services-agentidentitycredentials + v1-rev20260717-2.0.0 + + + +``` + +### Gradle + +```gradle +repositories { + mavenCentral() +} +dependencies { + implementation 'com.google.apis:google-api-services-agentidentitycredentials:v1-rev20260717-2.0.0' +} +``` + +[javadoc]: https://googleapis.dev/java/google-api-services-agentidentitycredentials/latest/index.html +[google-api-client]: https://github.com/googleapis/google-api-java-client/ +[api-explorer]: https://developers.google.com/apis-explorer/#p/agentidentitycredentials/v1/ diff --git a/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentials.java b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentials.java new file mode 100644 index 00000000000..8cd9720ff4b --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentials.java @@ -0,0 +1,635 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1; + +/** + * Service definition for AgentIdentityCredentials (v1). + * + *

+ * agentidentitycredentials.googleapis.com API. + *

+ * + *

+ * For more information about this service, see the + * API Documentation + *

+ * + *

+ * This service uses {@link AgentIdentityCredentialsRequestInitializer} to initialize global parameters via its + * {@link Builder}. + *

+ * + * @since 1.3 + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public class AgentIdentityCredentials extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClient { + + // Note: Leave this static initializer at the top of the file. + static { + com.google.api.client.util.Preconditions.checkState( + (com.google.api.client.googleapis.GoogleUtils.MAJOR_VERSION == 1 && + (com.google.api.client.googleapis.GoogleUtils.MINOR_VERSION >= 32 || + (com.google.api.client.googleapis.GoogleUtils.MINOR_VERSION == 31 && + com.google.api.client.googleapis.GoogleUtils.BUGFIX_VERSION >= 1))) || + com.google.api.client.googleapis.GoogleUtils.MAJOR_VERSION >= 2, + "You are currently running with version %s of google-api-client. " + + "You need at least version 1.31.1 of google-api-client to run version " + + "2.0.0 of the Agent Identity Credentials API library.", com.google.api.client.googleapis.GoogleUtils.VERSION); + } + + /** + * The default encoded root URL of the service. This is determined when the library is generated + * and normally should not be changed. + * + * @since 1.7 + */ + public static final String DEFAULT_ROOT_URL = "https://agentidentitycredentials.googleapis.com/"; + + /** + * The default encoded mTLS root URL of the service. This is determined when the library is generated + * and normally should not be changed. + * + * @since 1.31 + */ + public static final String DEFAULT_MTLS_ROOT_URL = "https://agentidentitycredentials.mtls.googleapis.com/"; + + /** + * The default encoded service path of the service. This is determined when the library is + * generated and normally should not be changed. + * + * @since 1.7 + */ + public static final String DEFAULT_SERVICE_PATH = ""; + + /** + * The default encoded batch path of the service. This is determined when the library is + * generated and normally should not be changed. + * + * @since 1.23 + */ + public static final String DEFAULT_BATCH_PATH = "batch"; + + /** + * The default encoded base URL of the service. This is determined when the library is generated + * and normally should not be changed. + */ + public static final String DEFAULT_BASE_URL = DEFAULT_ROOT_URL + DEFAULT_SERVICE_PATH; + + /** + * Constructor. + * + *

+ * Use {@link Builder} if you need to specify any of the optional parameters. + *

+ * + * @param transport HTTP transport, which should normally be: + * + * @param jsonFactory JSON factory, which may be: + * + * @param httpRequestInitializer HTTP request initializer or {@code null} for none + * @since 1.7 + */ + public AgentIdentityCredentials(com.google.api.client.http.HttpTransport transport, com.google.api.client.json.JsonFactory jsonFactory, + com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) { + this(new Builder(transport, jsonFactory, httpRequestInitializer)); + } + + /** + * @param builder builder + */ + AgentIdentityCredentials(Builder builder) { + super(builder); + } + + @Override + protected void initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest httpClientRequest) throws java.io.IOException { + super.initialize(httpClientRequest); + } + + /** + * An accessor for creating requests from the Projects collection. + * + *

The typical use is:

+ *
+   *   {@code AgentIdentityCredentials agentidentitycredentials = new AgentIdentityCredentials(...);}
+   *   {@code AgentIdentityCredentials.Projects.List request = agentidentitycredentials.projects().list(parameters ...)}
+   * 
+ * + * @return the resource collection + */ + public Projects projects() { + return new Projects(); + } + + /** + * The "projects" collection of methods. + */ + public class Projects { + + /** + * An accessor for creating requests from the Locations collection. + * + *

The typical use is:

+ *
+     *   {@code AgentIdentityCredentials agentidentitycredentials = new AgentIdentityCredentials(...);}
+     *   {@code AgentIdentityCredentials.Locations.List request = agentidentitycredentials.locations().list(parameters ...)}
+     * 
+ * + * @return the resource collection + */ + public Locations locations() { + return new Locations(); + } + + /** + * The "locations" collection of methods. + */ + public class Locations { + + /** + * An accessor for creating requests from the AuthProviders collection. + * + *

The typical use is:

+ *
+       *   {@code AgentIdentityCredentials agentidentitycredentials = new AgentIdentityCredentials(...);}
+       *   {@code AgentIdentityCredentials.AuthProviders.List request = agentidentitycredentials.authProviders().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public AuthProviders authProviders() { + return new AuthProviders(); + } + + /** + * The "authProviders" collection of methods. + */ + public class AuthProviders { + + /** + * An accessor for creating requests from the Credentials collection. + * + *

The typical use is:

+ *
+         *   {@code AgentIdentityCredentials agentidentitycredentials = new AgentIdentityCredentials(...);}
+         *   {@code AgentIdentityCredentials.Credentials.List request = agentidentitycredentials.credentials().list(parameters ...)}
+         * 
+ * + * @return the resource collection + */ + public Credentials credentials() { + return new Credentials(); + } + + /** + * The "credentials" collection of methods. + */ + public class Credentials { + + /** + * Finalizes the credentials after a successful consent flow. + * + * Create a request for the method "credentials.finalize". + * + * This request holds the parameters needed by the agentidentitycredentials server. After setting + * any optional parameters, call the {@link Finalize#execute()} method to invoke the remote + * operation. + * + * @param authProvider Required. The resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + * @param content the {@link com.google.api.services.agentidentitycredentials.v1.model.GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest} + * @return the request + */ + public Finalize finalize(java.lang.String authProvider, com.google.api.services.agentidentitycredentials.v1.model.GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest content) throws java.io.IOException { + Finalize result = new Finalize(authProvider, content); + initialize(result); + return result; + } + + public class Finalize extends AgentIdentityCredentialsRequest { + + private static final String REST_PATH = "v1/{+authProvider}/credentials:finalize"; + + private final java.util.regex.Pattern AUTH_PROVIDER_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/authProviders/[^/]+$"); + + /** + * Finalizes the credentials after a successful consent flow. + * + * Create a request for the method "credentials.finalize". + * + * This request holds the parameters needed by the the agentidentitycredentials server. After + * setting any optional parameters, call the {@link Finalize#execute()} method to invoke the + * remote operation.

{@link + * Finalize#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param authProvider Required. The resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + * @param content the {@link com.google.api.services.agentidentitycredentials.v1.model.GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest} + * @since 1.13 + */ + protected Finalize(java.lang.String authProvider, com.google.api.services.agentidentitycredentials.v1.model.GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest content) { + super(AgentIdentityCredentials.this, "POST", REST_PATH, content, com.google.api.services.agentidentitycredentials.v1.model.GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsResponse.class); + this.authProvider = com.google.api.client.util.Preconditions.checkNotNull(authProvider, "Required parameter authProvider must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(AUTH_PROVIDER_PATTERN.matcher(authProvider).matches(), + "Parameter authProvider must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/authProviders/[^/]+$"); + } + } + + @Override + public Finalize set$Xgafv(java.lang.String $Xgafv) { + return (Finalize) super.set$Xgafv($Xgafv); + } + + @Override + public Finalize setAccessToken(java.lang.String accessToken) { + return (Finalize) super.setAccessToken(accessToken); + } + + @Override + public Finalize setAlt(java.lang.String alt) { + return (Finalize) super.setAlt(alt); + } + + @Override + public Finalize setCallback(java.lang.String callback) { + return (Finalize) super.setCallback(callback); + } + + @Override + public Finalize setFields(java.lang.String fields) { + return (Finalize) super.setFields(fields); + } + + @Override + public Finalize setKey(java.lang.String key) { + return (Finalize) super.setKey(key); + } + + @Override + public Finalize setOauthToken(java.lang.String oauthToken) { + return (Finalize) super.setOauthToken(oauthToken); + } + + @Override + public Finalize setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Finalize) super.setPrettyPrint(prettyPrint); + } + + @Override + public Finalize setQuotaUser(java.lang.String quotaUser) { + return (Finalize) super.setQuotaUser(quotaUser); + } + + @Override + public Finalize setUploadType(java.lang.String uploadType) { + return (Finalize) super.setUploadType(uploadType); + } + + @Override + public Finalize setUploadProtocol(java.lang.String uploadProtocol) { + return (Finalize) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. The resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + */ + @com.google.api.client.util.Key + private java.lang.String authProvider; + + /** Required. The resource name of the AuthProvider. Format: + `projects/{project}/locations/{location}/authProviders/{auth_provider}` + */ + public java.lang.String getAuthProvider() { + return authProvider; + } + + /** + * Required. The resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + */ + public Finalize setAuthProvider(java.lang.String authProvider) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(AUTH_PROVIDER_PATTERN.matcher(authProvider).matches(), + "Parameter authProvider must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/authProviders/[^/]+$"); + } + this.authProvider = authProvider; + return this; + } + + @Override + public Finalize set(String parameterName, Object value) { + return (Finalize) super.set(parameterName, value); + } + } + /** + * Retrieves authorization credentials for an authprovider, or indicates what action needs to be + * taken to obtain credentials. If the `token` field in the response is populated, credential + * retrieval was successful. If one of the fields in the `status` oneof is populated, further action + * is required to obtain credentials, such as redirecting the user for consent. View comments on + * `RetrieveCredentialsResponse` for more information. + * + * Create a request for the method "credentials.retrieve". + * + * This request holds the parameters needed by the agentidentitycredentials server. After setting + * any optional parameters, call the {@link Retrieve#execute()} method to invoke the remote + * operation. + * + * @param authProvider Required. The parent resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + * @param content the {@link com.google.api.services.agentidentitycredentials.v1.model.GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest} + * @return the request + */ + public Retrieve retrieve(java.lang.String authProvider, com.google.api.services.agentidentitycredentials.v1.model.GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest content) throws java.io.IOException { + Retrieve result = new Retrieve(authProvider, content); + initialize(result); + return result; + } + + public class Retrieve extends AgentIdentityCredentialsRequest { + + private static final String REST_PATH = "v1/{+authProvider}/credentials:retrieve"; + + private final java.util.regex.Pattern AUTH_PROVIDER_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/authProviders/[^/]+$"); + + /** + * Retrieves authorization credentials for an authprovider, or indicates what action needs to be + * taken to obtain credentials. If the `token` field in the response is populated, credential + * retrieval was successful. If one of the fields in the `status` oneof is populated, further + * action is required to obtain credentials, such as redirecting the user for consent. View + * comments on `RetrieveCredentialsResponse` for more information. + * + * Create a request for the method "credentials.retrieve". + * + * This request holds the parameters needed by the the agentidentitycredentials server. After + * setting any optional parameters, call the {@link Retrieve#execute()} method to invoke the + * remote operation.

{@link + * Retrieve#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param authProvider Required. The parent resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + * @param content the {@link com.google.api.services.agentidentitycredentials.v1.model.GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest} + * @since 1.13 + */ + protected Retrieve(java.lang.String authProvider, com.google.api.services.agentidentitycredentials.v1.model.GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest content) { + super(AgentIdentityCredentials.this, "POST", REST_PATH, content, com.google.api.services.agentidentitycredentials.v1.model.GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsResponse.class); + this.authProvider = com.google.api.client.util.Preconditions.checkNotNull(authProvider, "Required parameter authProvider must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(AUTH_PROVIDER_PATTERN.matcher(authProvider).matches(), + "Parameter authProvider must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/authProviders/[^/]+$"); + } + } + + @Override + public Retrieve set$Xgafv(java.lang.String $Xgafv) { + return (Retrieve) super.set$Xgafv($Xgafv); + } + + @Override + public Retrieve setAccessToken(java.lang.String accessToken) { + return (Retrieve) super.setAccessToken(accessToken); + } + + @Override + public Retrieve setAlt(java.lang.String alt) { + return (Retrieve) super.setAlt(alt); + } + + @Override + public Retrieve setCallback(java.lang.String callback) { + return (Retrieve) super.setCallback(callback); + } + + @Override + public Retrieve setFields(java.lang.String fields) { + return (Retrieve) super.setFields(fields); + } + + @Override + public Retrieve setKey(java.lang.String key) { + return (Retrieve) super.setKey(key); + } + + @Override + public Retrieve setOauthToken(java.lang.String oauthToken) { + return (Retrieve) super.setOauthToken(oauthToken); + } + + @Override + public Retrieve setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Retrieve) super.setPrettyPrint(prettyPrint); + } + + @Override + public Retrieve setQuotaUser(java.lang.String quotaUser) { + return (Retrieve) super.setQuotaUser(quotaUser); + } + + @Override + public Retrieve setUploadType(java.lang.String uploadType) { + return (Retrieve) super.setUploadType(uploadType); + } + + @Override + public Retrieve setUploadProtocol(java.lang.String uploadProtocol) { + return (Retrieve) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. The parent resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + */ + @com.google.api.client.util.Key + private java.lang.String authProvider; + + /** Required. The parent resource name of the AuthProvider. Format: + `projects/{project}/locations/{location}/authProviders/{auth_provider}` + */ + public java.lang.String getAuthProvider() { + return authProvider; + } + + /** + * Required. The parent resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + */ + public Retrieve setAuthProvider(java.lang.String authProvider) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(AUTH_PROVIDER_PATTERN.matcher(authProvider).matches(), + "Parameter authProvider must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/authProviders/[^/]+$"); + } + this.authProvider = authProvider; + return this; + } + + @Override + public Retrieve set(String parameterName, Object value) { + return (Retrieve) super.set(parameterName, value); + } + } + + } + } + } + } + + /** + * Builder for {@link AgentIdentityCredentials}. + * + *

+ * Implementation is not thread-safe. + *

+ * + * @since 1.3.0 + */ + public static final class Builder extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClient.Builder { + + private static String chooseEndpoint(com.google.api.client.http.HttpTransport transport) { + // If the GOOGLE_API_USE_MTLS_ENDPOINT environment variable value is "always", use mTLS endpoint. + // If the env variable is "auto", use mTLS endpoint if and only if the transport is mTLS. + // Use the regular endpoint for all other cases. + String useMtlsEndpoint = System.getenv("GOOGLE_API_USE_MTLS_ENDPOINT"); + useMtlsEndpoint = useMtlsEndpoint == null ? "auto" : useMtlsEndpoint; + if ("always".equals(useMtlsEndpoint) || ("auto".equals(useMtlsEndpoint) && transport != null && transport.isMtls())) { + return DEFAULT_MTLS_ROOT_URL; + } + return DEFAULT_ROOT_URL; + } + + /** + * Returns an instance of a new builder. + * + * @param transport HTTP transport, which should normally be: + * + * @param jsonFactory JSON factory, which may be: + * + * @param httpRequestInitializer HTTP request initializer or {@code null} for none + * @since 1.7 + */ + public Builder(com.google.api.client.http.HttpTransport transport, com.google.api.client.json.JsonFactory jsonFactory, + com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) { + super( + transport, + jsonFactory, + Builder.chooseEndpoint(transport), + DEFAULT_SERVICE_PATH, + httpRequestInitializer, + false); + setBatchPath(DEFAULT_BATCH_PATH); + } + + /** Builds a new instance of {@link AgentIdentityCredentials}. */ + @Override + public AgentIdentityCredentials build() { + return new AgentIdentityCredentials(this); + } + + @Override + public Builder setRootUrl(String rootUrl) { + return (Builder) super.setRootUrl(rootUrl); + } + + @Override + public Builder setServicePath(String servicePath) { + return (Builder) super.setServicePath(servicePath); + } + + @Override + public Builder setBatchPath(String batchPath) { + return (Builder) super.setBatchPath(batchPath); + } + + @Override + public Builder setHttpRequestInitializer(com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) { + return (Builder) super.setHttpRequestInitializer(httpRequestInitializer); + } + + @Override + public Builder setApplicationName(String applicationName) { + return (Builder) super.setApplicationName(applicationName); + } + + @Override + public Builder setSuppressPatternChecks(boolean suppressPatternChecks) { + return (Builder) super.setSuppressPatternChecks(suppressPatternChecks); + } + + @Override + public Builder setSuppressRequiredParameterChecks(boolean suppressRequiredParameterChecks) { + return (Builder) super.setSuppressRequiredParameterChecks(suppressRequiredParameterChecks); + } + + @Override + public Builder setSuppressAllChecks(boolean suppressAllChecks) { + return (Builder) super.setSuppressAllChecks(suppressAllChecks); + } + + /** + * Set the {@link AgentIdentityCredentialsRequestInitializer}. + * + * @since 1.12 + */ + public Builder setAgentIdentityCredentialsRequestInitializer( + AgentIdentityCredentialsRequestInitializer agentidentitycredentialsRequestInitializer) { + return (Builder) super.setGoogleClientRequestInitializer(agentidentitycredentialsRequestInitializer); + } + + @Override + public Builder setGoogleClientRequestInitializer( + com.google.api.client.googleapis.services.GoogleClientRequestInitializer googleClientRequestInitializer) { + return (Builder) super.setGoogleClientRequestInitializer(googleClientRequestInitializer); + } + + @Override + public Builder setUniverseDomain(String universeDomain) { + return (Builder) super.setUniverseDomain(universeDomain); + } + } +} diff --git a/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentialsRequest.java b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentialsRequest.java new file mode 100644 index 00000000000..250092a5238 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentialsRequest.java @@ -0,0 +1,267 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1; + +/** + * AgentIdentityCredentials request. + * + * @since 1.3 + */ +@SuppressWarnings("javadoc") +public abstract class AgentIdentityCredentialsRequest extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest { + + /** + * @param client Google client + * @param method HTTP Method + * @param uriTemplate URI template for the path relative to the base URL. If it starts with a "/" + * the base path from the base URL will be stripped out. The URI template can also be a + * full URL. URI template expansion is done using + * {@link com.google.api.client.http.UriTemplate#expand(String, String, Object, boolean)} + * @param content A POJO that can be serialized into JSON or {@code null} for none + * @param responseClass response class to parse into + */ + public AgentIdentityCredentialsRequest( + AgentIdentityCredentials client, String method, String uriTemplate, Object content, Class responseClass) { + super( + client, + method, + uriTemplate, + content, + responseClass); + } + + /** V1 error format. */ + @com.google.api.client.util.Key("$.xgafv") + private java.lang.String $Xgafv; + + /** + * V1 error format. + */ + public java.lang.String get$Xgafv() { + return $Xgafv; + } + + /** V1 error format. */ + public AgentIdentityCredentialsRequest set$Xgafv(java.lang.String $Xgafv) { + this.$Xgafv = $Xgafv; + return this; + } + + /** OAuth access token. */ + @com.google.api.client.util.Key("access_token") + private java.lang.String accessToken; + + /** + * OAuth access token. + */ + public java.lang.String getAccessToken() { + return accessToken; + } + + /** OAuth access token. */ + public AgentIdentityCredentialsRequest setAccessToken(java.lang.String accessToken) { + this.accessToken = accessToken; + return this; + } + + /** Data format for response. */ + @com.google.api.client.util.Key + private java.lang.String alt; + + /** + * Data format for response. [default: json] + */ + public java.lang.String getAlt() { + return alt; + } + + /** Data format for response. */ + public AgentIdentityCredentialsRequest setAlt(java.lang.String alt) { + this.alt = alt; + return this; + } + + /** JSONP */ + @com.google.api.client.util.Key + private java.lang.String callback; + + /** + * JSONP + */ + public java.lang.String getCallback() { + return callback; + } + + /** JSONP */ + public AgentIdentityCredentialsRequest setCallback(java.lang.String callback) { + this.callback = callback; + return this; + } + + /** Selector specifying which fields to include in a partial response. */ + @com.google.api.client.util.Key + private java.lang.String fields; + + /** + * Selector specifying which fields to include in a partial response. + */ + public java.lang.String getFields() { + return fields; + } + + /** Selector specifying which fields to include in a partial response. */ + public AgentIdentityCredentialsRequest setFields(java.lang.String fields) { + this.fields = fields; + return this; + } + + /** + * API key. Your API key identifies your project and provides you with API access, quota, and + * reports. Required unless you provide an OAuth 2.0 token. + */ + @com.google.api.client.util.Key + private java.lang.String key; + + /** + * API key. Your API key identifies your project and provides you with API access, quota, and + * reports. Required unless you provide an OAuth 2.0 token. + */ + public java.lang.String getKey() { + return key; + } + + /** + * API key. Your API key identifies your project and provides you with API access, quota, and + * reports. Required unless you provide an OAuth 2.0 token. + */ + public AgentIdentityCredentialsRequest setKey(java.lang.String key) { + this.key = key; + return this; + } + + /** OAuth 2.0 token for the current user. */ + @com.google.api.client.util.Key("oauth_token") + private java.lang.String oauthToken; + + /** + * OAuth 2.0 token for the current user. + */ + public java.lang.String getOauthToken() { + return oauthToken; + } + + /** OAuth 2.0 token for the current user. */ + public AgentIdentityCredentialsRequest setOauthToken(java.lang.String oauthToken) { + this.oauthToken = oauthToken; + return this; + } + + /** Returns response with indentations and line breaks. */ + @com.google.api.client.util.Key + private java.lang.Boolean prettyPrint; + + /** + * Returns response with indentations and line breaks. [default: true] + */ + public java.lang.Boolean getPrettyPrint() { + return prettyPrint; + } + + /** Returns response with indentations and line breaks. */ + public AgentIdentityCredentialsRequest setPrettyPrint(java.lang.Boolean prettyPrint) { + this.prettyPrint = prettyPrint; + return this; + } + + /** + * Available to use for quota purposes for server-side applications. Can be any arbitrary string + * assigned to a user, but should not exceed 40 characters. + */ + @com.google.api.client.util.Key + private java.lang.String quotaUser; + + /** + * Available to use for quota purposes for server-side applications. Can be any arbitrary string + * assigned to a user, but should not exceed 40 characters. + */ + public java.lang.String getQuotaUser() { + return quotaUser; + } + + /** + * Available to use for quota purposes for server-side applications. Can be any arbitrary string + * assigned to a user, but should not exceed 40 characters. + */ + public AgentIdentityCredentialsRequest setQuotaUser(java.lang.String quotaUser) { + this.quotaUser = quotaUser; + return this; + } + + /** Legacy upload protocol for media (e.g. "media", "multipart"). */ + @com.google.api.client.util.Key + private java.lang.String uploadType; + + /** + * Legacy upload protocol for media (e.g. "media", "multipart"). + */ + public java.lang.String getUploadType() { + return uploadType; + } + + /** Legacy upload protocol for media (e.g. "media", "multipart"). */ + public AgentIdentityCredentialsRequest setUploadType(java.lang.String uploadType) { + this.uploadType = uploadType; + return this; + } + + /** Upload protocol for media (e.g. "raw", "multipart"). */ + @com.google.api.client.util.Key("upload_protocol") + private java.lang.String uploadProtocol; + + /** + * Upload protocol for media (e.g. "raw", "multipart"). + */ + public java.lang.String getUploadProtocol() { + return uploadProtocol; + } + + /** Upload protocol for media (e.g. "raw", "multipart"). */ + public AgentIdentityCredentialsRequest setUploadProtocol(java.lang.String uploadProtocol) { + this.uploadProtocol = uploadProtocol; + return this; + } + + @Override + public final AgentIdentityCredentials getAbstractGoogleClient() { + return (AgentIdentityCredentials) super.getAbstractGoogleClient(); + } + + @Override + public AgentIdentityCredentialsRequest setDisableGZipContent(boolean disableGZipContent) { + return (AgentIdentityCredentialsRequest) super.setDisableGZipContent(disableGZipContent); + } + + @Override + public AgentIdentityCredentialsRequest setRequestHeaders(com.google.api.client.http.HttpHeaders headers) { + return (AgentIdentityCredentialsRequest) super.setRequestHeaders(headers); + } + + @Override + public AgentIdentityCredentialsRequest set(String parameterName, Object value) { + return (AgentIdentityCredentialsRequest) super.set(parameterName, value); + } +} diff --git a/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentialsRequestInitializer.java b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentialsRequestInitializer.java new file mode 100644 index 00000000000..38cb4949b1f --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentialsRequestInitializer.java @@ -0,0 +1,119 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1; + +/** + * AgentIdentityCredentials request initializer for setting properties like key and userIp. + * + *

+ * The simplest usage is to use it to set the key parameter: + *

+ * + *
+  public static final GoogleClientRequestInitializer KEY_INITIALIZER =
+      new AgentIdentityCredentialsRequestInitializer(KEY);
+ * 
+ * + *

+ * There is also a constructor to set both the key and userIp parameters: + *

+ * + *
+  public static final GoogleClientRequestInitializer INITIALIZER =
+      new AgentIdentityCredentialsRequestInitializer(KEY, USER_IP);
+ * 
+ * + *

+ * If you want to implement custom logic, extend it like this: + *

+ * + *
+  public static class MyRequestInitializer extends AgentIdentityCredentialsRequestInitializer {
+
+    {@literal @}Override
+    public void initializeAgentIdentityCredentialsRequest(AgentIdentityCredentialsRequest{@literal <}?{@literal >} request)
+        throws IOException {
+      // custom logic
+    }
+  }
+ * 
+ * + *

+ * Finally, to set the key and userIp parameters and insert custom logic, extend it like this: + *

+ * + *
+  public static class MyRequestInitializer2 extends AgentIdentityCredentialsRequestInitializer {
+
+    public MyKeyRequestInitializer() {
+      super(KEY, USER_IP);
+    }
+
+    {@literal @}Override
+    public void initializeAgentIdentityCredentialsRequest(AgentIdentityCredentialsRequest{@literal <}?{@literal >} request)
+        throws IOException {
+      // custom logic
+    }
+  }
+ * 
+ * + *

+ * Subclasses should be thread-safe. + *

+ * + * @since 1.12 + */ +public class AgentIdentityCredentialsRequestInitializer extends com.google.api.client.googleapis.services.json.CommonGoogleJsonClientRequestInitializer { + + public AgentIdentityCredentialsRequestInitializer() { + super(); + } + + /** + * @param key API key or {@code null} to leave it unchanged + */ + public AgentIdentityCredentialsRequestInitializer(String key) { + super(key); + } + + /** + * @param key API key or {@code null} to leave it unchanged + * @param userIp user IP or {@code null} to leave it unchanged + */ + public AgentIdentityCredentialsRequestInitializer(String key, String userIp) { + super(key, userIp); + } + + @Override + public final void initializeJsonRequest(com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest request) throws java.io.IOException { + super.initializeJsonRequest(request); + initializeAgentIdentityCredentialsRequest((AgentIdentityCredentialsRequest) request); + } + + /** + * Initializes AgentIdentityCredentials request. + * + *

+ * Default implementation does nothing. Called from + * {@link #initializeJsonRequest(com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest)}. + *

+ * + * @throws java.io.IOException I/O exception + */ + protected void initializeAgentIdentityCredentialsRequest(AgentIdentityCredentialsRequest request) throws java.io.IOException { + } +} diff --git a/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentialsScopes.java b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentialsScopes.java new file mode 100644 index 00000000000..23a588089c2 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/AgentIdentityCredentialsScopes.java @@ -0,0 +1,42 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1; + +/** + * Available OAuth 2.0 scopes for use with the Agent Identity Credentials API. + * + * @since 1.4 + */ +public class AgentIdentityCredentialsScopes { + + /** See, edit, configure, and delete your Google Cloud data and see the email address for your Google Account.. */ + public static final String CLOUD_PLATFORM = "https://www.googleapis.com/auth/cloud-platform"; + + /** + * Returns an unmodifiable set that contains all scopes declared by this class. + * + * @since 1.16 + */ + public static java.util.Set all() { + java.util.Set set = new java.util.HashSet(); + set.add(CLOUD_PLATFORM); + return java.util.Collections.unmodifiableSet(set); + } + + private AgentIdentityCredentialsScopes() { + } +} diff --git a/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1ConsentRejected.java b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1ConsentRejected.java new file mode 100644 index 00000000000..b69174d6718 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1ConsentRejected.java @@ -0,0 +1,43 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1.model; + +/** + * Indicates the user has rejected the permission delegation or cancelled the request. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1ConsentRejected extends com.google.api.client.json.GenericJson { + + @Override + public GoogleCloudAgentidentitycredentialsV1ConsentRejected set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1ConsentRejected) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1ConsentRejected clone() { + return (GoogleCloudAgentidentitycredentialsV1ConsentRejected) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest.java b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest.java new file mode 100644 index 00000000000..d8bd98b294c --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest.java @@ -0,0 +1,146 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1.model; + +/** + * Request message for FinalizeCredentials. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest extends com.google.api.client.json.GenericJson { + + /** + * Required. The same consent_nonce value that was provided during redirect in the + * UriConsentRequired metadata. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String consentNonce; + + /** + * Required. The identity of the end user. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String userId; + + /** + * Required. The encrypted state passed back from the consent flow. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String userIdValidationState; + + /** + * Required. The same consent_nonce value that was provided during redirect in the + * UriConsentRequired metadata. + * @return value or {@code null} for none + */ + public java.lang.String getConsentNonce() { + return consentNonce; + } + + /** + * Required. The same consent_nonce value that was provided during redirect in the + * UriConsentRequired metadata. + * @param consentNonce consentNonce or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest setConsentNonce(java.lang.String consentNonce) { + this.consentNonce = consentNonce; + return this; + } + + /** + * Required. The identity of the end user. + * @return value or {@code null} for none + */ + public java.lang.String getUserId() { + return userId; + } + + /** + * Required. The identity of the end user. + * @param userId userId or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest setUserId(java.lang.String userId) { + this.userId = userId; + return this; + } + + /** + * Required. The encrypted state passed back from the consent flow. + * @see #decodeUserIdValidationState() + * @return value or {@code null} for none + */ + public java.lang.String getUserIdValidationState() { + return userIdValidationState; + } + + /** + * Required. The encrypted state passed back from the consent flow. + * @see #getUserIdValidationState() + * @return Base64 decoded value or {@code null} for none + * + * @since 1.14 + */ + public byte[] decodeUserIdValidationState() { + return com.google.api.client.util.Base64.decodeBase64(userIdValidationState); + } + + /** + * Required. The encrypted state passed back from the consent flow. + * @see #encodeUserIdValidationState() + * @param userIdValidationState userIdValidationState or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest setUserIdValidationState(java.lang.String userIdValidationState) { + this.userIdValidationState = userIdValidationState; + return this; + } + + /** + * Required. The encrypted state passed back from the consent flow. + * @see #setUserIdValidationState() + * + *

+ * The value is encoded Base64 or {@code null} for none. + *

+ * + * @since 1.14 + */ + public GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest encodeUserIdValidationState(byte[] userIdValidationState) { + this.userIdValidationState = com.google.api.client.util.Base64.encodeBase64URLSafeString(userIdValidationState); + return this; + } + + @Override + public GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest clone() { + return (GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsRequest) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsResponse.java b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsResponse.java new file mode 100644 index 00000000000..40571a3e143 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsResponse.java @@ -0,0 +1,43 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1.model; + +/** + * Response message for FinalizeCredentials. Intentionally empty + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsResponse extends com.google.api.client.json.GenericJson { + + @Override + public GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsResponse set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsResponse) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsResponse clone() { + return (GoogleCloudAgentidentitycredentialsV1FinalizeCredentialsResponse) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1Pending.java b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1Pending.java new file mode 100644 index 00000000000..3ca9c406663 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1Pending.java @@ -0,0 +1,44 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1.model; + +/** + * Indicates that the credential retrieval is pending. The caller should retry the + * RetrieveCredentials request after some time. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1Pending extends com.google.api.client.json.GenericJson { + + @Override + public GoogleCloudAgentidentitycredentialsV1Pending set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1Pending) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1Pending clone() { + return (GoogleCloudAgentidentitycredentialsV1Pending) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest.java b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest.java new file mode 100644 index 00000000000..b242ae7103c --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest.java @@ -0,0 +1,151 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1.model; + +/** + * Request message for RetrieveCredentials. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest extends com.google.api.client.json.GenericJson { + + /** + * Optional. The URI to redirect the user to after consent is completed. This field is required + * for authproviders using the 3-legged OAuth flow. For other authprovider types, this field is + * unused but not rejected. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String continueUri; + + /** + * Optional. Input only. Set this field only if the previous token was expired or invalid. This + * value must be the full, previously returned token string. Will trigger a refresh of the access + * token with a stored refresh token, if possible, or a new consent flow. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String forceRefreshToken; + + /** + * Optional. The OAuth scopes required for this access. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List scopes; + + /** + * Required. The identity of the end user. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String userId; + + /** + * Optional. The URI to redirect the user to after consent is completed. This field is required + * for authproviders using the 3-legged OAuth flow. For other authprovider types, this field is + * unused but not rejected. + * @return value or {@code null} for none + */ + public java.lang.String getContinueUri() { + return continueUri; + } + + /** + * Optional. The URI to redirect the user to after consent is completed. This field is required + * for authproviders using the 3-legged OAuth flow. For other authprovider types, this field is + * unused but not rejected. + * @param continueUri continueUri or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest setContinueUri(java.lang.String continueUri) { + this.continueUri = continueUri; + return this; + } + + /** + * Optional. Input only. Set this field only if the previous token was expired or invalid. This + * value must be the full, previously returned token string. Will trigger a refresh of the access + * token with a stored refresh token, if possible, or a new consent flow. + * @return value or {@code null} for none + */ + public java.lang.String getForceRefreshToken() { + return forceRefreshToken; + } + + /** + * Optional. Input only. Set this field only if the previous token was expired or invalid. This + * value must be the full, previously returned token string. Will trigger a refresh of the access + * token with a stored refresh token, if possible, or a new consent flow. + * @param forceRefreshToken forceRefreshToken or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest setForceRefreshToken(java.lang.String forceRefreshToken) { + this.forceRefreshToken = forceRefreshToken; + return this; + } + + /** + * Optional. The OAuth scopes required for this access. + * @return value or {@code null} for none + */ + public java.util.List getScopes() { + return scopes; + } + + /** + * Optional. The OAuth scopes required for this access. + * @param scopes scopes or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest setScopes(java.util.List scopes) { + this.scopes = scopes; + return this; + } + + /** + * Required. The identity of the end user. + * @return value or {@code null} for none + */ + public java.lang.String getUserId() { + return userId; + } + + /** + * Required. The identity of the end user. + * @param userId userId or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest setUserId(java.lang.String userId) { + this.userId = userId; + return this; + } + + @Override + public GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest clone() { + return (GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsRequest) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsResponse.java b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsResponse.java new file mode 100644 index 00000000000..5a83916dfde --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsResponse.java @@ -0,0 +1,139 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1.model; + +/** + * Response message for RetrieveCredentials. Contains the access tokens and related artifacts. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsResponse extends com.google.api.client.json.GenericJson { + + /** + * Message indicating consent was rejected. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private GoogleCloudAgentidentitycredentialsV1ConsentRejected consentRejected; + + /** + * Message indicating credential retrieval is pending. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private GoogleCloudAgentidentitycredentialsV1Pending pending; + + /** + * Message indicating credentials were successfully retrieved. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private GoogleCloudAgentidentitycredentialsV1Success success; + + /** + * Message indicating uri based consent is required. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private GoogleCloudAgentidentitycredentialsV1UriConsentRequired uriConsentRequired; + + /** + * Message indicating consent was rejected. + * @return value or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1ConsentRejected getConsentRejected() { + return consentRejected; + } + + /** + * Message indicating consent was rejected. + * @param consentRejected consentRejected or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsResponse setConsentRejected(GoogleCloudAgentidentitycredentialsV1ConsentRejected consentRejected) { + this.consentRejected = consentRejected; + return this; + } + + /** + * Message indicating credential retrieval is pending. + * @return value or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1Pending getPending() { + return pending; + } + + /** + * Message indicating credential retrieval is pending. + * @param pending pending or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsResponse setPending(GoogleCloudAgentidentitycredentialsV1Pending pending) { + this.pending = pending; + return this; + } + + /** + * Message indicating credentials were successfully retrieved. + * @return value or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1Success getSuccess() { + return success; + } + + /** + * Message indicating credentials were successfully retrieved. + * @param success success or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsResponse setSuccess(GoogleCloudAgentidentitycredentialsV1Success success) { + this.success = success; + return this; + } + + /** + * Message indicating uri based consent is required. + * @return value or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1UriConsentRequired getUriConsentRequired() { + return uriConsentRequired; + } + + /** + * Message indicating uri based consent is required. + * @param uriConsentRequired uriConsentRequired or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsResponse setUriConsentRequired(GoogleCloudAgentidentitycredentialsV1UriConsentRequired uriConsentRequired) { + this.uriConsentRequired = uriConsentRequired; + return this; + } + + @Override + public GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsResponse set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsResponse) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsResponse clone() { + return (GoogleCloudAgentidentitycredentialsV1RetrieveCredentialsResponse) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1Success.java b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1Success.java new file mode 100644 index 00000000000..2263f2b07b3 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1Success.java @@ -0,0 +1,169 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1.model; + +/** + * Message indicating successful retrieval of credentials. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1Success extends com.google.api.client.json.GenericJson { + + /** + * The expiration time of the token. This does not guarantee that the token will be valid until + * this time, since the token could be revoked earlier. There could also be clock skew between the + * auth provider and the client so it may expire slightly earlier. If not set, the token might be + * permanent or it may be that the service does not (or cannot) know when it will expire. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private String expireTime; + + /** + * The HTTP header name where the token should be placed. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String header; + + /** + * The scopes actually associated with the retrieved token. End users may have rejected some + * requested scopes, or the third-party authorization servers can return a different set of scopes + * than what was asked for. Callers should verify that all required scopes for their intended use + * are included in this list. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List scopes; + + /** + * The retrieved access token or credential for the end user. On MCPTool call, for an invalid + * token OAuth spec says this should return 401 or 403, but MCPServers may implement this + * differently. If you get any flavor of `PERMISSION_DENIED`, retry your original request to + * RetrieveCredentials with force_refresh_token set to the expired/invalid token string, which + * will fetch a new token or initiate a new consent flow. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String token; + + /** + * The expiration time of the token. This does not guarantee that the token will be valid until + * this time, since the token could be revoked earlier. There could also be clock skew between the + * auth provider and the client so it may expire slightly earlier. If not set, the token might be + * permanent or it may be that the service does not (or cannot) know when it will expire. + * @return value or {@code null} for none + */ + public String getExpireTime() { + return expireTime; + } + + /** + * The expiration time of the token. This does not guarantee that the token will be valid until + * this time, since the token could be revoked earlier. There could also be clock skew between the + * auth provider and the client so it may expire slightly earlier. If not set, the token might be + * permanent or it may be that the service does not (or cannot) know when it will expire. + * @param expireTime expireTime or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1Success setExpireTime(String expireTime) { + this.expireTime = expireTime; + return this; + } + + /** + * The HTTP header name where the token should be placed. + * @return value or {@code null} for none + */ + public java.lang.String getHeader() { + return header; + } + + /** + * The HTTP header name where the token should be placed. + * @param header header or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1Success setHeader(java.lang.String header) { + this.header = header; + return this; + } + + /** + * The scopes actually associated with the retrieved token. End users may have rejected some + * requested scopes, or the third-party authorization servers can return a different set of scopes + * than what was asked for. Callers should verify that all required scopes for their intended use + * are included in this list. + * @return value or {@code null} for none + */ + public java.util.List getScopes() { + return scopes; + } + + /** + * The scopes actually associated with the retrieved token. End users may have rejected some + * requested scopes, or the third-party authorization servers can return a different set of scopes + * than what was asked for. Callers should verify that all required scopes for their intended use + * are included in this list. + * @param scopes scopes or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1Success setScopes(java.util.List scopes) { + this.scopes = scopes; + return this; + } + + /** + * The retrieved access token or credential for the end user. On MCPTool call, for an invalid + * token OAuth spec says this should return 401 or 403, but MCPServers may implement this + * differently. If you get any flavor of `PERMISSION_DENIED`, retry your original request to + * RetrieveCredentials with force_refresh_token set to the expired/invalid token string, which + * will fetch a new token or initiate a new consent flow. + * @return value or {@code null} for none + */ + public java.lang.String getToken() { + return token; + } + + /** + * The retrieved access token or credential for the end user. On MCPTool call, for an invalid + * token OAuth spec says this should return 401 or 403, but MCPServers may implement this + * differently. If you get any flavor of `PERMISSION_DENIED`, retry your original request to + * RetrieveCredentials with force_refresh_token set to the expired/invalid token string, which + * will fetch a new token or initiate a new consent flow. + * @param token token or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1Success setToken(java.lang.String token) { + this.token = token; + return this; + } + + @Override + public GoogleCloudAgentidentitycredentialsV1Success set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1Success) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1Success clone() { + return (GoogleCloudAgentidentitycredentialsV1Success) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1UriConsentRequired.java b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1UriConsentRequired.java new file mode 100644 index 00000000000..002a5cdb26c --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/com/google/api/services/agentidentitycredentials/v1/model/GoogleCloudAgentidentitycredentialsV1UriConsentRequired.java @@ -0,0 +1,129 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1.model; + +/** + * Indicates that the user must visit the provided URI to consent to delegate permission to the + * agent to act on their behalf. The caller can either poll the `RetrieveCredentials` method, or + * await the /ValidateUserId callback + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1UriConsentRequired extends com.google.api.client.json.GenericJson { + + /** + * Output only. The URL where the user should be redirected to grant consent. This will always be + * present. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String authorizationUri; + + /** + * Output only. A one-time, randomly generated value that validates the entire consent flow is + * handled by a single user, avoiding CSRF attacks. It must be submitted with the + * FinalizeCredentials request to complete the OAuth exchange. This will always be present. + * Implemented per https://www.rfc-editor.org/rfc/rfc6819#section-5.3.5 + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String consentNonce; + + /** + * Output only. The unique ID of the credentials retrieval operation. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String uid; + + /** + * Output only. The URL where the user should be redirected to grant consent. This will always be + * present. + * @return value or {@code null} for none + */ + public java.lang.String getAuthorizationUri() { + return authorizationUri; + } + + /** + * Output only. The URL where the user should be redirected to grant consent. This will always be + * present. + * @param authorizationUri authorizationUri or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1UriConsentRequired setAuthorizationUri(java.lang.String authorizationUri) { + this.authorizationUri = authorizationUri; + return this; + } + + /** + * Output only. A one-time, randomly generated value that validates the entire consent flow is + * handled by a single user, avoiding CSRF attacks. It must be submitted with the + * FinalizeCredentials request to complete the OAuth exchange. This will always be present. + * Implemented per https://www.rfc-editor.org/rfc/rfc6819#section-5.3.5 + * @return value or {@code null} for none + */ + public java.lang.String getConsentNonce() { + return consentNonce; + } + + /** + * Output only. A one-time, randomly generated value that validates the entire consent flow is + * handled by a single user, avoiding CSRF attacks. It must be submitted with the + * FinalizeCredentials request to complete the OAuth exchange. This will always be present. + * Implemented per https://www.rfc-editor.org/rfc/rfc6819#section-5.3.5 + * @param consentNonce consentNonce or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1UriConsentRequired setConsentNonce(java.lang.String consentNonce) { + this.consentNonce = consentNonce; + return this; + } + + /** + * Output only. The unique ID of the credentials retrieval operation. + * @return value or {@code null} for none + */ + public java.lang.String getUid() { + return uid; + } + + /** + * Output only. The unique ID of the credentials retrieval operation. + * @param uid uid or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1UriConsentRequired setUid(java.lang.String uid) { + this.uid = uid; + return this; + } + + @Override + public GoogleCloudAgentidentitycredentialsV1UriConsentRequired set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1UriConsentRequired) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1UriConsentRequired clone() { + return (GoogleCloudAgentidentitycredentialsV1UriConsentRequired) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1/2.0.0/pom.xml b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/pom.xml new file mode 100644 index 00000000000..37622d79821 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/2.0.0/pom.xml @@ -0,0 +1,219 @@ + + 4.0.0 + + org.sonatype.oss + oss-parent + 7 + + + com.google.apis + google-api-services-agentidentitycredentials + v1-rev20260717-2.0.0 + Agent Identity Credentials API v1-rev20260717-2.0.0 + jar + + 2011 + + + + GoogleAPIs + GoogleAPIs + googleapis@googlegroups.com + Google + https://www.google.com + + + + + Google + http://www.google.com/ + + + + + The Apache Software License, Version 2.0 + http://www.apache.org/licenses/LICENSE-2.0.txt + repo + + + + + + ossrh + https://google.oss.sonatype.org/content/repositories/snapshots + + + + + + + maven-compiler-plugin + 3.9.0 + + 1.7 + 1.7 + + + + org.apache.maven.plugins + maven-source-plugin + 2.4 + + + org.apache.maven.plugins + maven-jar-plugin + 3.1.2 + + + + com.google.api.services.agentidentitycredentials + + + + + + org.apache.maven.plugins + maven-javadoc-plugin + 3.1.0 + + + attach-javadocs + + jar + + + + + none + Agent Identity Credentials API ${project.version} + Agent Identity Credentials API ${project.version} + + http://docs.oracle.com/javase/7/docs/api + https://googleapis.dev/java/google-http-client/${httpClientLibrary}/ + https://googleapis.dev/java/google-oauth-client/${oauthClientLibrary}/ + https://googleapis.dev/java/google-api-client/2.7.2/ + + + + + org.codehaus.mojo + clirr-maven-plugin + 2.8 + + clirr-ignored-differences.xml + true + + + + + check + + + + + + . + + + ./resources + + + + + + + com.google.api-client + google-api-client + 2.7.2 + + + + + UTF-8 + + + + + + release-sonatype + + + + !artifact-registry-url + + + + + + org.sonatype.plugins + nexus-staging-maven-plugin + 1.6.13 + true + + sonatype-nexus-staging + https://google.oss.sonatype.org/ + false + + + + + + + + release-gcp-artifact-registry + + artifactregistry://please-define-artifact-registry-url-property + + + + gcp-artifact-registry-repository + ${artifact-registry-url} + + + gcp-artifact-registry-repository + ${artifact-registry-url} + + + + + release-sign-artifacts + + + performRelease + true + + + + + + org.apache.maven.plugins + maven-gpg-plugin + 3.2.7 + + + sign-artifacts + verify + + sign + + + + --pinentry-mode + loopback + + + + + + + + + + \ No newline at end of file diff --git a/clients/google-api-services-agentidentitycredentials/v1/README.md b/clients/google-api-services-agentidentitycredentials/v1/README.md new file mode 100644 index 00000000000..bb3e110236f --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1/README.md @@ -0,0 +1,44 @@ +# Agent Identity Credentials API Client Library for Java + +agentidentitycredentials.googleapis.com API. + +This page contains information about getting started with the Agent Identity Credentials API +using the Google API Client Library for Java. In addition, you may be interested +in the following documentation: + +* Browse the [Javadoc reference for the Agent Identity Credentials API][javadoc] +* Read the [Developer's Guide for the Google API Client Library for Java][google-api-client]. +* Interact with this API in your browser using the [APIs Explorer for the Agent Identity Credentials API][api-explorer] + +## Installation + +### Maven + +Add the following lines to your `pom.xml` file: + +```xml + + + + com.google.apis + google-api-services-agentidentitycredentials + v1-rev20260717-2.0.0 + + + +``` + +### Gradle + +```gradle +repositories { + mavenCentral() +} +dependencies { + implementation 'com.google.apis:google-api-services-agentidentitycredentials:v1-rev20260717-2.0.0' +} +``` + +[javadoc]: https://googleapis.dev/java/google-api-services-agentidentitycredentials/latest/index.html +[google-api-client]: https://github.com/googleapis/google-api-java-client/ +[api-explorer]: https://developers.google.com/apis-explorer/#p/agentidentitycredentials/v1/ diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/README.md b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/README.md new file mode 100644 index 00000000000..bb2f7d96c36 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/README.md @@ -0,0 +1,44 @@ +# Agent Identity Credentials API Client Library for Java + +agentidentitycredentials.googleapis.com API. + +This page contains information about getting started with the Agent Identity Credentials API +using the Google API Client Library for Java. In addition, you may be interested +in the following documentation: + +* Browse the [Javadoc reference for the Agent Identity Credentials API][javadoc] +* Read the [Developer's Guide for the Google API Client Library for Java][google-api-client]. +* Interact with this API in your browser using the [APIs Explorer for the Agent Identity Credentials API][api-explorer] + +## Installation + +### Maven + +Add the following lines to your `pom.xml` file: + +```xml + + + + com.google.apis + google-api-services-agentidentitycredentials + v1alpha-rev20260717-2.0.0 + + + +``` + +### Gradle + +```gradle +repositories { + mavenCentral() +} +dependencies { + implementation 'com.google.apis:google-api-services-agentidentitycredentials:v1alpha-rev20260717-2.0.0' +} +``` + +[javadoc]: https://googleapis.dev/java/google-api-services-agentidentitycredentials/latest/index.html +[google-api-client]: https://github.com/googleapis/google-api-java-client/ +[api-explorer]: https://developers.google.com/apis-explorer/#p/agentidentitycredentials/v1/ diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentials.java b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentials.java new file mode 100644 index 00000000000..5a4fb6e54b8 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentials.java @@ -0,0 +1,635 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1alpha; + +/** + * Service definition for AgentIdentityCredentials (v1alpha). + * + *

+ * agentidentitycredentials.googleapis.com API. + *

+ * + *

+ * For more information about this service, see the + * API Documentation + *

+ * + *

+ * This service uses {@link AgentIdentityCredentialsRequestInitializer} to initialize global parameters via its + * {@link Builder}. + *

+ * + * @since 1.3 + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public class AgentIdentityCredentials extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClient { + + // Note: Leave this static initializer at the top of the file. + static { + com.google.api.client.util.Preconditions.checkState( + (com.google.api.client.googleapis.GoogleUtils.MAJOR_VERSION == 1 && + (com.google.api.client.googleapis.GoogleUtils.MINOR_VERSION >= 32 || + (com.google.api.client.googleapis.GoogleUtils.MINOR_VERSION == 31 && + com.google.api.client.googleapis.GoogleUtils.BUGFIX_VERSION >= 1))) || + com.google.api.client.googleapis.GoogleUtils.MAJOR_VERSION >= 2, + "You are currently running with version %s of google-api-client. " + + "You need at least version 1.31.1 of google-api-client to run version " + + "2.0.0 of the Agent Identity Credentials API library.", com.google.api.client.googleapis.GoogleUtils.VERSION); + } + + /** + * The default encoded root URL of the service. This is determined when the library is generated + * and normally should not be changed. + * + * @since 1.7 + */ + public static final String DEFAULT_ROOT_URL = "https://agentidentitycredentials.googleapis.com/"; + + /** + * The default encoded mTLS root URL of the service. This is determined when the library is generated + * and normally should not be changed. + * + * @since 1.31 + */ + public static final String DEFAULT_MTLS_ROOT_URL = "https://agentidentitycredentials.mtls.googleapis.com/"; + + /** + * The default encoded service path of the service. This is determined when the library is + * generated and normally should not be changed. + * + * @since 1.7 + */ + public static final String DEFAULT_SERVICE_PATH = ""; + + /** + * The default encoded batch path of the service. This is determined when the library is + * generated and normally should not be changed. + * + * @since 1.23 + */ + public static final String DEFAULT_BATCH_PATH = "batch"; + + /** + * The default encoded base URL of the service. This is determined when the library is generated + * and normally should not be changed. + */ + public static final String DEFAULT_BASE_URL = DEFAULT_ROOT_URL + DEFAULT_SERVICE_PATH; + + /** + * Constructor. + * + *

+ * Use {@link Builder} if you need to specify any of the optional parameters. + *

+ * + * @param transport HTTP transport, which should normally be: + *
    + *
  • Google App Engine: + * {@code com.google.api.client.extensions.appengine.http.UrlFetchTransport}
  • + *
  • Android: {@code newCompatibleTransport} from + * {@code com.google.api.client.extensions.android.http.AndroidHttp}
  • + *
  • Java: {@code com.google.api.client.http.javanet.NetHttpTransport}
  • + * + *
+ * @param jsonFactory JSON factory, which may be: + *
    + *
  • Jackson: {@code com.google.api.client.json.jackson2.JacksonFactory}
  • + *
  • Google GSON: {@code com.google.api.client.json.gson.GsonFactory}
  • + *
  • Android Honeycomb or higher: + * {@code com.google.api.client.extensions.android.json.AndroidJsonFactory}
  • + *
+ * @param httpRequestInitializer HTTP request initializer or {@code null} for none + * @since 1.7 + */ + public AgentIdentityCredentials(com.google.api.client.http.HttpTransport transport, com.google.api.client.json.JsonFactory jsonFactory, + com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) { + this(new Builder(transport, jsonFactory, httpRequestInitializer)); + } + + /** + * @param builder builder + */ + AgentIdentityCredentials(Builder builder) { + super(builder); + } + + @Override + protected void initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest httpClientRequest) throws java.io.IOException { + super.initialize(httpClientRequest); + } + + /** + * An accessor for creating requests from the Projects collection. + * + *

The typical use is:

+ *
+   *   {@code AgentIdentityCredentials agentidentitycredentials = new AgentIdentityCredentials(...);}
+   *   {@code AgentIdentityCredentials.Projects.List request = agentidentitycredentials.projects().list(parameters ...)}
+   * 
+ * + * @return the resource collection + */ + public Projects projects() { + return new Projects(); + } + + /** + * The "projects" collection of methods. + */ + public class Projects { + + /** + * An accessor for creating requests from the Locations collection. + * + *

The typical use is:

+ *
+     *   {@code AgentIdentityCredentials agentidentitycredentials = new AgentIdentityCredentials(...);}
+     *   {@code AgentIdentityCredentials.Locations.List request = agentidentitycredentials.locations().list(parameters ...)}
+     * 
+ * + * @return the resource collection + */ + public Locations locations() { + return new Locations(); + } + + /** + * The "locations" collection of methods. + */ + public class Locations { + + /** + * An accessor for creating requests from the AuthProviders collection. + * + *

The typical use is:

+ *
+       *   {@code AgentIdentityCredentials agentidentitycredentials = new AgentIdentityCredentials(...);}
+       *   {@code AgentIdentityCredentials.AuthProviders.List request = agentidentitycredentials.authProviders().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public AuthProviders authProviders() { + return new AuthProviders(); + } + + /** + * The "authProviders" collection of methods. + */ + public class AuthProviders { + + /** + * An accessor for creating requests from the Credentials collection. + * + *

The typical use is:

+ *
+         *   {@code AgentIdentityCredentials agentidentitycredentials = new AgentIdentityCredentials(...);}
+         *   {@code AgentIdentityCredentials.Credentials.List request = agentidentitycredentials.credentials().list(parameters ...)}
+         * 
+ * + * @return the resource collection + */ + public Credentials credentials() { + return new Credentials(); + } + + /** + * The "credentials" collection of methods. + */ + public class Credentials { + + /** + * Finalizes the credentials after a successful consent flow. + * + * Create a request for the method "credentials.finalize". + * + * This request holds the parameters needed by the agentidentitycredentials server. After setting + * any optional parameters, call the {@link Finalize#execute()} method to invoke the remote + * operation. + * + * @param authProvider Required. The resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + * @param content the {@link com.google.api.services.agentidentitycredentials.v1alpha.model.GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest} + * @return the request + */ + public Finalize finalize(java.lang.String authProvider, com.google.api.services.agentidentitycredentials.v1alpha.model.GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest content) throws java.io.IOException { + Finalize result = new Finalize(authProvider, content); + initialize(result); + return result; + } + + public class Finalize extends AgentIdentityCredentialsRequest { + + private static final String REST_PATH = "v1alpha/{+authProvider}/credentials:finalize"; + + private final java.util.regex.Pattern AUTH_PROVIDER_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/authProviders/[^/]+$"); + + /** + * Finalizes the credentials after a successful consent flow. + * + * Create a request for the method "credentials.finalize". + * + * This request holds the parameters needed by the the agentidentitycredentials server. After + * setting any optional parameters, call the {@link Finalize#execute()} method to invoke the + * remote operation.

{@link + * Finalize#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param authProvider Required. The resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + * @param content the {@link com.google.api.services.agentidentitycredentials.v1alpha.model.GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest} + * @since 1.13 + */ + protected Finalize(java.lang.String authProvider, com.google.api.services.agentidentitycredentials.v1alpha.model.GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest content) { + super(AgentIdentityCredentials.this, "POST", REST_PATH, content, com.google.api.services.agentidentitycredentials.v1alpha.model.GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsResponse.class); + this.authProvider = com.google.api.client.util.Preconditions.checkNotNull(authProvider, "Required parameter authProvider must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(AUTH_PROVIDER_PATTERN.matcher(authProvider).matches(), + "Parameter authProvider must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/authProviders/[^/]+$"); + } + } + + @Override + public Finalize set$Xgafv(java.lang.String $Xgafv) { + return (Finalize) super.set$Xgafv($Xgafv); + } + + @Override + public Finalize setAccessToken(java.lang.String accessToken) { + return (Finalize) super.setAccessToken(accessToken); + } + + @Override + public Finalize setAlt(java.lang.String alt) { + return (Finalize) super.setAlt(alt); + } + + @Override + public Finalize setCallback(java.lang.String callback) { + return (Finalize) super.setCallback(callback); + } + + @Override + public Finalize setFields(java.lang.String fields) { + return (Finalize) super.setFields(fields); + } + + @Override + public Finalize setKey(java.lang.String key) { + return (Finalize) super.setKey(key); + } + + @Override + public Finalize setOauthToken(java.lang.String oauthToken) { + return (Finalize) super.setOauthToken(oauthToken); + } + + @Override + public Finalize setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Finalize) super.setPrettyPrint(prettyPrint); + } + + @Override + public Finalize setQuotaUser(java.lang.String quotaUser) { + return (Finalize) super.setQuotaUser(quotaUser); + } + + @Override + public Finalize setUploadType(java.lang.String uploadType) { + return (Finalize) super.setUploadType(uploadType); + } + + @Override + public Finalize setUploadProtocol(java.lang.String uploadProtocol) { + return (Finalize) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. The resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + */ + @com.google.api.client.util.Key + private java.lang.String authProvider; + + /** Required. The resource name of the AuthProvider. Format: + `projects/{project}/locations/{location}/authProviders/{auth_provider}` + */ + public java.lang.String getAuthProvider() { + return authProvider; + } + + /** + * Required. The resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + */ + public Finalize setAuthProvider(java.lang.String authProvider) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(AUTH_PROVIDER_PATTERN.matcher(authProvider).matches(), + "Parameter authProvider must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/authProviders/[^/]+$"); + } + this.authProvider = authProvider; + return this; + } + + @Override + public Finalize set(String parameterName, Object value) { + return (Finalize) super.set(parameterName, value); + } + } + /** + * Retrieves authorization credentials for an authprovider, or indicates what action needs to be + * taken to obtain credentials. If the `token` field in the response is populated, credential + * retrieval was successful. If one of the fields in the `status` oneof is populated, further action + * is required to obtain credentials, such as redirecting the user for consent. View comments on + * `RetrieveCredentialsResponse` for more information. + * + * Create a request for the method "credentials.retrieve". + * + * This request holds the parameters needed by the agentidentitycredentials server. After setting + * any optional parameters, call the {@link Retrieve#execute()} method to invoke the remote + * operation. + * + * @param authProvider Required. The parent resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + * @param content the {@link com.google.api.services.agentidentitycredentials.v1alpha.model.GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest} + * @return the request + */ + public Retrieve retrieve(java.lang.String authProvider, com.google.api.services.agentidentitycredentials.v1alpha.model.GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest content) throws java.io.IOException { + Retrieve result = new Retrieve(authProvider, content); + initialize(result); + return result; + } + + public class Retrieve extends AgentIdentityCredentialsRequest { + + private static final String REST_PATH = "v1alpha/{+authProvider}/credentials:retrieve"; + + private final java.util.regex.Pattern AUTH_PROVIDER_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/authProviders/[^/]+$"); + + /** + * Retrieves authorization credentials for an authprovider, or indicates what action needs to be + * taken to obtain credentials. If the `token` field in the response is populated, credential + * retrieval was successful. If one of the fields in the `status` oneof is populated, further + * action is required to obtain credentials, such as redirecting the user for consent. View + * comments on `RetrieveCredentialsResponse` for more information. + * + * Create a request for the method "credentials.retrieve". + * + * This request holds the parameters needed by the the agentidentitycredentials server. After + * setting any optional parameters, call the {@link Retrieve#execute()} method to invoke the + * remote operation.

{@link + * Retrieve#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param authProvider Required. The parent resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + * @param content the {@link com.google.api.services.agentidentitycredentials.v1alpha.model.GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest} + * @since 1.13 + */ + protected Retrieve(java.lang.String authProvider, com.google.api.services.agentidentitycredentials.v1alpha.model.GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest content) { + super(AgentIdentityCredentials.this, "POST", REST_PATH, content, com.google.api.services.agentidentitycredentials.v1alpha.model.GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsResponse.class); + this.authProvider = com.google.api.client.util.Preconditions.checkNotNull(authProvider, "Required parameter authProvider must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(AUTH_PROVIDER_PATTERN.matcher(authProvider).matches(), + "Parameter authProvider must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/authProviders/[^/]+$"); + } + } + + @Override + public Retrieve set$Xgafv(java.lang.String $Xgafv) { + return (Retrieve) super.set$Xgafv($Xgafv); + } + + @Override + public Retrieve setAccessToken(java.lang.String accessToken) { + return (Retrieve) super.setAccessToken(accessToken); + } + + @Override + public Retrieve setAlt(java.lang.String alt) { + return (Retrieve) super.setAlt(alt); + } + + @Override + public Retrieve setCallback(java.lang.String callback) { + return (Retrieve) super.setCallback(callback); + } + + @Override + public Retrieve setFields(java.lang.String fields) { + return (Retrieve) super.setFields(fields); + } + + @Override + public Retrieve setKey(java.lang.String key) { + return (Retrieve) super.setKey(key); + } + + @Override + public Retrieve setOauthToken(java.lang.String oauthToken) { + return (Retrieve) super.setOauthToken(oauthToken); + } + + @Override + public Retrieve setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Retrieve) super.setPrettyPrint(prettyPrint); + } + + @Override + public Retrieve setQuotaUser(java.lang.String quotaUser) { + return (Retrieve) super.setQuotaUser(quotaUser); + } + + @Override + public Retrieve setUploadType(java.lang.String uploadType) { + return (Retrieve) super.setUploadType(uploadType); + } + + @Override + public Retrieve setUploadProtocol(java.lang.String uploadProtocol) { + return (Retrieve) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. The parent resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + */ + @com.google.api.client.util.Key + private java.lang.String authProvider; + + /** Required. The parent resource name of the AuthProvider. Format: + `projects/{project}/locations/{location}/authProviders/{auth_provider}` + */ + public java.lang.String getAuthProvider() { + return authProvider; + } + + /** + * Required. The parent resource name of the AuthProvider. Format: + * `projects/{project}/locations/{location}/authProviders/{auth_provider}` + */ + public Retrieve setAuthProvider(java.lang.String authProvider) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(AUTH_PROVIDER_PATTERN.matcher(authProvider).matches(), + "Parameter authProvider must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/authProviders/[^/]+$"); + } + this.authProvider = authProvider; + return this; + } + + @Override + public Retrieve set(String parameterName, Object value) { + return (Retrieve) super.set(parameterName, value); + } + } + + } + } + } + } + + /** + * Builder for {@link AgentIdentityCredentials}. + * + *

+ * Implementation is not thread-safe. + *

+ * + * @since 1.3.0 + */ + public static final class Builder extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClient.Builder { + + private static String chooseEndpoint(com.google.api.client.http.HttpTransport transport) { + // If the GOOGLE_API_USE_MTLS_ENDPOINT environment variable value is "always", use mTLS endpoint. + // If the env variable is "auto", use mTLS endpoint if and only if the transport is mTLS. + // Use the regular endpoint for all other cases. + String useMtlsEndpoint = System.getenv("GOOGLE_API_USE_MTLS_ENDPOINT"); + useMtlsEndpoint = useMtlsEndpoint == null ? "auto" : useMtlsEndpoint; + if ("always".equals(useMtlsEndpoint) || ("auto".equals(useMtlsEndpoint) && transport != null && transport.isMtls())) { + return DEFAULT_MTLS_ROOT_URL; + } + return DEFAULT_ROOT_URL; + } + + /** + * Returns an instance of a new builder. + * + * @param transport HTTP transport, which should normally be: + *
    + *
  • Google App Engine: + * {@code com.google.api.client.extensions.appengine.http.UrlFetchTransport}
  • + *
  • Android: {@code newCompatibleTransport} from + * {@code com.google.api.client.extensions.android.http.AndroidHttp}
  • + *
  • Java: {@code com.google.api.client.http.javanet.NetHttpTransport}
  • + *
+ * @param jsonFactory JSON factory, which may be: + *
    + *
  • Jackson: {@code com.google.api.client.json.jackson2.JacksonFactory}
  • + *
  • Google GSON: {@code com.google.api.client.json.gson.GsonFactory}
  • + *
  • Android Honeycomb or higher: + * {@code com.google.api.client.extensions.android.json.AndroidJsonFactory}
  • + *
+ * @param httpRequestInitializer HTTP request initializer or {@code null} for none + * @since 1.7 + */ + public Builder(com.google.api.client.http.HttpTransport transport, com.google.api.client.json.JsonFactory jsonFactory, + com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) { + super( + transport, + jsonFactory, + Builder.chooseEndpoint(transport), + DEFAULT_SERVICE_PATH, + httpRequestInitializer, + false); + setBatchPath(DEFAULT_BATCH_PATH); + } + + /** Builds a new instance of {@link AgentIdentityCredentials}. */ + @Override + public AgentIdentityCredentials build() { + return new AgentIdentityCredentials(this); + } + + @Override + public Builder setRootUrl(String rootUrl) { + return (Builder) super.setRootUrl(rootUrl); + } + + @Override + public Builder setServicePath(String servicePath) { + return (Builder) super.setServicePath(servicePath); + } + + @Override + public Builder setBatchPath(String batchPath) { + return (Builder) super.setBatchPath(batchPath); + } + + @Override + public Builder setHttpRequestInitializer(com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) { + return (Builder) super.setHttpRequestInitializer(httpRequestInitializer); + } + + @Override + public Builder setApplicationName(String applicationName) { + return (Builder) super.setApplicationName(applicationName); + } + + @Override + public Builder setSuppressPatternChecks(boolean suppressPatternChecks) { + return (Builder) super.setSuppressPatternChecks(suppressPatternChecks); + } + + @Override + public Builder setSuppressRequiredParameterChecks(boolean suppressRequiredParameterChecks) { + return (Builder) super.setSuppressRequiredParameterChecks(suppressRequiredParameterChecks); + } + + @Override + public Builder setSuppressAllChecks(boolean suppressAllChecks) { + return (Builder) super.setSuppressAllChecks(suppressAllChecks); + } + + /** + * Set the {@link AgentIdentityCredentialsRequestInitializer}. + * + * @since 1.12 + */ + public Builder setAgentIdentityCredentialsRequestInitializer( + AgentIdentityCredentialsRequestInitializer agentidentitycredentialsRequestInitializer) { + return (Builder) super.setGoogleClientRequestInitializer(agentidentitycredentialsRequestInitializer); + } + + @Override + public Builder setGoogleClientRequestInitializer( + com.google.api.client.googleapis.services.GoogleClientRequestInitializer googleClientRequestInitializer) { + return (Builder) super.setGoogleClientRequestInitializer(googleClientRequestInitializer); + } + + @Override + public Builder setUniverseDomain(String universeDomain) { + return (Builder) super.setUniverseDomain(universeDomain); + } + } +} diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentialsRequest.java b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentialsRequest.java new file mode 100644 index 00000000000..a7f29eb07dc --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentialsRequest.java @@ -0,0 +1,267 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1alpha; + +/** + * AgentIdentityCredentials request. + * + * @since 1.3 + */ +@SuppressWarnings("javadoc") +public abstract class AgentIdentityCredentialsRequest extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest { + + /** + * @param client Google client + * @param method HTTP Method + * @param uriTemplate URI template for the path relative to the base URL. If it starts with a "/" + * the base path from the base URL will be stripped out. The URI template can also be a + * full URL. URI template expansion is done using + * {@link com.google.api.client.http.UriTemplate#expand(String, String, Object, boolean)} + * @param content A POJO that can be serialized into JSON or {@code null} for none + * @param responseClass response class to parse into + */ + public AgentIdentityCredentialsRequest( + AgentIdentityCredentials client, String method, String uriTemplate, Object content, Class responseClass) { + super( + client, + method, + uriTemplate, + content, + responseClass); + } + + /** V1 error format. */ + @com.google.api.client.util.Key("$.xgafv") + private java.lang.String $Xgafv; + + /** + * V1 error format. + */ + public java.lang.String get$Xgafv() { + return $Xgafv; + } + + /** V1 error format. */ + public AgentIdentityCredentialsRequest set$Xgafv(java.lang.String $Xgafv) { + this.$Xgafv = $Xgafv; + return this; + } + + /** OAuth access token. */ + @com.google.api.client.util.Key("access_token") + private java.lang.String accessToken; + + /** + * OAuth access token. + */ + public java.lang.String getAccessToken() { + return accessToken; + } + + /** OAuth access token. */ + public AgentIdentityCredentialsRequest setAccessToken(java.lang.String accessToken) { + this.accessToken = accessToken; + return this; + } + + /** Data format for response. */ + @com.google.api.client.util.Key + private java.lang.String alt; + + /** + * Data format for response. [default: json] + */ + public java.lang.String getAlt() { + return alt; + } + + /** Data format for response. */ + public AgentIdentityCredentialsRequest setAlt(java.lang.String alt) { + this.alt = alt; + return this; + } + + /** JSONP */ + @com.google.api.client.util.Key + private java.lang.String callback; + + /** + * JSONP + */ + public java.lang.String getCallback() { + return callback; + } + + /** JSONP */ + public AgentIdentityCredentialsRequest setCallback(java.lang.String callback) { + this.callback = callback; + return this; + } + + /** Selector specifying which fields to include in a partial response. */ + @com.google.api.client.util.Key + private java.lang.String fields; + + /** + * Selector specifying which fields to include in a partial response. + */ + public java.lang.String getFields() { + return fields; + } + + /** Selector specifying which fields to include in a partial response. */ + public AgentIdentityCredentialsRequest setFields(java.lang.String fields) { + this.fields = fields; + return this; + } + + /** + * API key. Your API key identifies your project and provides you with API access, quota, and + * reports. Required unless you provide an OAuth 2.0 token. + */ + @com.google.api.client.util.Key + private java.lang.String key; + + /** + * API key. Your API key identifies your project and provides you with API access, quota, and + * reports. Required unless you provide an OAuth 2.0 token. + */ + public java.lang.String getKey() { + return key; + } + + /** + * API key. Your API key identifies your project and provides you with API access, quota, and + * reports. Required unless you provide an OAuth 2.0 token. + */ + public AgentIdentityCredentialsRequest setKey(java.lang.String key) { + this.key = key; + return this; + } + + /** OAuth 2.0 token for the current user. */ + @com.google.api.client.util.Key("oauth_token") + private java.lang.String oauthToken; + + /** + * OAuth 2.0 token for the current user. + */ + public java.lang.String getOauthToken() { + return oauthToken; + } + + /** OAuth 2.0 token for the current user. */ + public AgentIdentityCredentialsRequest setOauthToken(java.lang.String oauthToken) { + this.oauthToken = oauthToken; + return this; + } + + /** Returns response with indentations and line breaks. */ + @com.google.api.client.util.Key + private java.lang.Boolean prettyPrint; + + /** + * Returns response with indentations and line breaks. [default: true] + */ + public java.lang.Boolean getPrettyPrint() { + return prettyPrint; + } + + /** Returns response with indentations and line breaks. */ + public AgentIdentityCredentialsRequest setPrettyPrint(java.lang.Boolean prettyPrint) { + this.prettyPrint = prettyPrint; + return this; + } + + /** + * Available to use for quota purposes for server-side applications. Can be any arbitrary string + * assigned to a user, but should not exceed 40 characters. + */ + @com.google.api.client.util.Key + private java.lang.String quotaUser; + + /** + * Available to use for quota purposes for server-side applications. Can be any arbitrary string + * assigned to a user, but should not exceed 40 characters. + */ + public java.lang.String getQuotaUser() { + return quotaUser; + } + + /** + * Available to use for quota purposes for server-side applications. Can be any arbitrary string + * assigned to a user, but should not exceed 40 characters. + */ + public AgentIdentityCredentialsRequest setQuotaUser(java.lang.String quotaUser) { + this.quotaUser = quotaUser; + return this; + } + + /** Legacy upload protocol for media (e.g. "media", "multipart"). */ + @com.google.api.client.util.Key + private java.lang.String uploadType; + + /** + * Legacy upload protocol for media (e.g. "media", "multipart"). + */ + public java.lang.String getUploadType() { + return uploadType; + } + + /** Legacy upload protocol for media (e.g. "media", "multipart"). */ + public AgentIdentityCredentialsRequest setUploadType(java.lang.String uploadType) { + this.uploadType = uploadType; + return this; + } + + /** Upload protocol for media (e.g. "raw", "multipart"). */ + @com.google.api.client.util.Key("upload_protocol") + private java.lang.String uploadProtocol; + + /** + * Upload protocol for media (e.g. "raw", "multipart"). + */ + public java.lang.String getUploadProtocol() { + return uploadProtocol; + } + + /** Upload protocol for media (e.g. "raw", "multipart"). */ + public AgentIdentityCredentialsRequest setUploadProtocol(java.lang.String uploadProtocol) { + this.uploadProtocol = uploadProtocol; + return this; + } + + @Override + public final AgentIdentityCredentials getAbstractGoogleClient() { + return (AgentIdentityCredentials) super.getAbstractGoogleClient(); + } + + @Override + public AgentIdentityCredentialsRequest setDisableGZipContent(boolean disableGZipContent) { + return (AgentIdentityCredentialsRequest) super.setDisableGZipContent(disableGZipContent); + } + + @Override + public AgentIdentityCredentialsRequest setRequestHeaders(com.google.api.client.http.HttpHeaders headers) { + return (AgentIdentityCredentialsRequest) super.setRequestHeaders(headers); + } + + @Override + public AgentIdentityCredentialsRequest set(String parameterName, Object value) { + return (AgentIdentityCredentialsRequest) super.set(parameterName, value); + } +} diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentialsRequestInitializer.java b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentialsRequestInitializer.java new file mode 100644 index 00000000000..61bec8600aa --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentialsRequestInitializer.java @@ -0,0 +1,119 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1alpha; + +/** + * AgentIdentityCredentials request initializer for setting properties like key and userIp. + * + *

+ * The simplest usage is to use it to set the key parameter: + *

+ * + *
+  public static final GoogleClientRequestInitializer KEY_INITIALIZER =
+      new AgentIdentityCredentialsRequestInitializer(KEY);
+ * 
+ * + *

+ * There is also a constructor to set both the key and userIp parameters: + *

+ * + *
+  public static final GoogleClientRequestInitializer INITIALIZER =
+      new AgentIdentityCredentialsRequestInitializer(KEY, USER_IP);
+ * 
+ * + *

+ * If you want to implement custom logic, extend it like this: + *

+ * + *
+  public static class MyRequestInitializer extends AgentIdentityCredentialsRequestInitializer {
+
+    {@literal @}Override
+    public void initializeAgentIdentityCredentialsRequest(AgentIdentityCredentialsRequest{@literal <}?{@literal >} request)
+        throws IOException {
+      // custom logic
+    }
+  }
+ * 
+ * + *

+ * Finally, to set the key and userIp parameters and insert custom logic, extend it like this: + *

+ * + *
+  public static class MyRequestInitializer2 extends AgentIdentityCredentialsRequestInitializer {
+
+    public MyKeyRequestInitializer() {
+      super(KEY, USER_IP);
+    }
+
+    {@literal @}Override
+    public void initializeAgentIdentityCredentialsRequest(AgentIdentityCredentialsRequest{@literal <}?{@literal >} request)
+        throws IOException {
+      // custom logic
+    }
+  }
+ * 
+ * + *

+ * Subclasses should be thread-safe. + *

+ * + * @since 1.12 + */ +public class AgentIdentityCredentialsRequestInitializer extends com.google.api.client.googleapis.services.json.CommonGoogleJsonClientRequestInitializer { + + public AgentIdentityCredentialsRequestInitializer() { + super(); + } + + /** + * @param key API key or {@code null} to leave it unchanged + */ + public AgentIdentityCredentialsRequestInitializer(String key) { + super(key); + } + + /** + * @param key API key or {@code null} to leave it unchanged + * @param userIp user IP or {@code null} to leave it unchanged + */ + public AgentIdentityCredentialsRequestInitializer(String key, String userIp) { + super(key, userIp); + } + + @Override + public final void initializeJsonRequest(com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest request) throws java.io.IOException { + super.initializeJsonRequest(request); + initializeAgentIdentityCredentialsRequest((AgentIdentityCredentialsRequest) request); + } + + /** + * Initializes AgentIdentityCredentials request. + * + *

+ * Default implementation does nothing. Called from + * {@link #initializeJsonRequest(com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest)}. + *

+ * + * @throws java.io.IOException I/O exception + */ + protected void initializeAgentIdentityCredentialsRequest(AgentIdentityCredentialsRequest request) throws java.io.IOException { + } +} diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentialsScopes.java b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentialsScopes.java new file mode 100644 index 00000000000..598f3df310b --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/AgentIdentityCredentialsScopes.java @@ -0,0 +1,42 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1alpha; + +/** + * Available OAuth 2.0 scopes for use with the Agent Identity Credentials API. + * + * @since 1.4 + */ +public class AgentIdentityCredentialsScopes { + + /** See, edit, configure, and delete your Google Cloud data and see the email address for your Google Account.. */ + public static final String CLOUD_PLATFORM = "https://www.googleapis.com/auth/cloud-platform"; + + /** + * Returns an unmodifiable set that contains all scopes declared by this class. + * + * @since 1.16 + */ + public static java.util.Set all() { + java.util.Set set = new java.util.HashSet(); + set.add(CLOUD_PLATFORM); + return java.util.Collections.unmodifiableSet(set); + } + + private AgentIdentityCredentialsScopes() { + } +} diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaConsentRejected.java b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaConsentRejected.java new file mode 100644 index 00000000000..ffd783dad05 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaConsentRejected.java @@ -0,0 +1,43 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1alpha.model; + +/** + * Indicates the user has rejected the permission delegation or cancelled the request. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1alphaConsentRejected extends com.google.api.client.json.GenericJson { + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaConsentRejected set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1alphaConsentRejected) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaConsentRejected clone() { + return (GoogleCloudAgentidentitycredentialsV1alphaConsentRejected) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest.java b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest.java new file mode 100644 index 00000000000..2dbb1a3bfaf --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest.java @@ -0,0 +1,146 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1alpha.model; + +/** + * Request message for FinalizeCredentials. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest extends com.google.api.client.json.GenericJson { + + /** + * Required. The same consent_nonce value that was provided during redirect in the + * UriConsentRequired metadata. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String consentNonce; + + /** + * Required. The identity of the end user. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String userId; + + /** + * Required. The encrypted state passed back from the consent flow. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String userIdValidationState; + + /** + * Required. The same consent_nonce value that was provided during redirect in the + * UriConsentRequired metadata. + * @return value or {@code null} for none + */ + public java.lang.String getConsentNonce() { + return consentNonce; + } + + /** + * Required. The same consent_nonce value that was provided during redirect in the + * UriConsentRequired metadata. + * @param consentNonce consentNonce or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest setConsentNonce(java.lang.String consentNonce) { + this.consentNonce = consentNonce; + return this; + } + + /** + * Required. The identity of the end user. + * @return value or {@code null} for none + */ + public java.lang.String getUserId() { + return userId; + } + + /** + * Required. The identity of the end user. + * @param userId userId or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest setUserId(java.lang.String userId) { + this.userId = userId; + return this; + } + + /** + * Required. The encrypted state passed back from the consent flow. + * @see #decodeUserIdValidationState() + * @return value or {@code null} for none + */ + public java.lang.String getUserIdValidationState() { + return userIdValidationState; + } + + /** + * Required. The encrypted state passed back from the consent flow. + * @see #getUserIdValidationState() + * @return Base64 decoded value or {@code null} for none + * + * @since 1.14 + */ + public byte[] decodeUserIdValidationState() { + return com.google.api.client.util.Base64.decodeBase64(userIdValidationState); + } + + /** + * Required. The encrypted state passed back from the consent flow. + * @see #encodeUserIdValidationState() + * @param userIdValidationState userIdValidationState or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest setUserIdValidationState(java.lang.String userIdValidationState) { + this.userIdValidationState = userIdValidationState; + return this; + } + + /** + * Required. The encrypted state passed back from the consent flow. + * @see #setUserIdValidationState() + * + *

+ * The value is encoded Base64 or {@code null} for none. + *

+ * + * @since 1.14 + */ + public GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest encodeUserIdValidationState(byte[] userIdValidationState) { + this.userIdValidationState = com.google.api.client.util.Base64.encodeBase64URLSafeString(userIdValidationState); + return this; + } + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest clone() { + return (GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsRequest) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsResponse.java b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsResponse.java new file mode 100644 index 00000000000..4e786e15416 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsResponse.java @@ -0,0 +1,43 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1alpha.model; + +/** + * Response message for FinalizeCredentials. Intentionally empty + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsResponse extends com.google.api.client.json.GenericJson { + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsResponse set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsResponse) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsResponse clone() { + return (GoogleCloudAgentidentitycredentialsV1alphaFinalizeCredentialsResponse) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaPending.java b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaPending.java new file mode 100644 index 00000000000..ee4455a95da --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaPending.java @@ -0,0 +1,44 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1alpha.model; + +/** + * Indicates that the credential retrieval is pending. The caller should retry the + * RetrieveCredentials request after some time. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1alphaPending extends com.google.api.client.json.GenericJson { + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaPending set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1alphaPending) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaPending clone() { + return (GoogleCloudAgentidentitycredentialsV1alphaPending) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest.java b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest.java new file mode 100644 index 00000000000..c6490511cdc --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest.java @@ -0,0 +1,151 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1alpha.model; + +/** + * Request message for RetrieveCredentials. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest extends com.google.api.client.json.GenericJson { + + /** + * Optional. The URI to redirect the user to after consent is completed. This field is required + * for authproviders using the 3-legged OAuth flow. For other authprovider types, this field is + * unused but not rejected. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String continueUri; + + /** + * Optional. Input only. Set this field only if the previous token was expired or invalid. This + * value must be the full, previously returned token string. Will trigger a refresh of the access + * token with a stored refresh token, if possible, or a new consent flow. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String forceRefreshToken; + + /** + * Optional. The OAuth scopes required for this access. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List scopes; + + /** + * Required. The identity of the end user. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String userId; + + /** + * Optional. The URI to redirect the user to after consent is completed. This field is required + * for authproviders using the 3-legged OAuth flow. For other authprovider types, this field is + * unused but not rejected. + * @return value or {@code null} for none + */ + public java.lang.String getContinueUri() { + return continueUri; + } + + /** + * Optional. The URI to redirect the user to after consent is completed. This field is required + * for authproviders using the 3-legged OAuth flow. For other authprovider types, this field is + * unused but not rejected. + * @param continueUri continueUri or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest setContinueUri(java.lang.String continueUri) { + this.continueUri = continueUri; + return this; + } + + /** + * Optional. Input only. Set this field only if the previous token was expired or invalid. This + * value must be the full, previously returned token string. Will trigger a refresh of the access + * token with a stored refresh token, if possible, or a new consent flow. + * @return value or {@code null} for none + */ + public java.lang.String getForceRefreshToken() { + return forceRefreshToken; + } + + /** + * Optional. Input only. Set this field only if the previous token was expired or invalid. This + * value must be the full, previously returned token string. Will trigger a refresh of the access + * token with a stored refresh token, if possible, or a new consent flow. + * @param forceRefreshToken forceRefreshToken or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest setForceRefreshToken(java.lang.String forceRefreshToken) { + this.forceRefreshToken = forceRefreshToken; + return this; + } + + /** + * Optional. The OAuth scopes required for this access. + * @return value or {@code null} for none + */ + public java.util.List getScopes() { + return scopes; + } + + /** + * Optional. The OAuth scopes required for this access. + * @param scopes scopes or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest setScopes(java.util.List scopes) { + this.scopes = scopes; + return this; + } + + /** + * Required. The identity of the end user. + * @return value or {@code null} for none + */ + public java.lang.String getUserId() { + return userId; + } + + /** + * Required. The identity of the end user. + * @param userId userId or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest setUserId(java.lang.String userId) { + this.userId = userId; + return this; + } + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest clone() { + return (GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsRequest) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsResponse.java b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsResponse.java new file mode 100644 index 00000000000..24ca60051c8 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsResponse.java @@ -0,0 +1,139 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1alpha.model; + +/** + * Response message for RetrieveCredentials. Contains the access tokens and related artifacts. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsResponse extends com.google.api.client.json.GenericJson { + + /** + * Message indicating consent was rejected. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private GoogleCloudAgentidentitycredentialsV1alphaConsentRejected consentRejected; + + /** + * Message indicating credential retrieval is pending. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private GoogleCloudAgentidentitycredentialsV1alphaPending pending; + + /** + * Message indicating credentials were successfully retrieved. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private GoogleCloudAgentidentitycredentialsV1alphaSuccess success; + + /** + * Message indicating uri based consent is required. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired uriConsentRequired; + + /** + * Message indicating consent was rejected. + * @return value or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaConsentRejected getConsentRejected() { + return consentRejected; + } + + /** + * Message indicating consent was rejected. + * @param consentRejected consentRejected or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsResponse setConsentRejected(GoogleCloudAgentidentitycredentialsV1alphaConsentRejected consentRejected) { + this.consentRejected = consentRejected; + return this; + } + + /** + * Message indicating credential retrieval is pending. + * @return value or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaPending getPending() { + return pending; + } + + /** + * Message indicating credential retrieval is pending. + * @param pending pending or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsResponse setPending(GoogleCloudAgentidentitycredentialsV1alphaPending pending) { + this.pending = pending; + return this; + } + + /** + * Message indicating credentials were successfully retrieved. + * @return value or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaSuccess getSuccess() { + return success; + } + + /** + * Message indicating credentials were successfully retrieved. + * @param success success or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsResponse setSuccess(GoogleCloudAgentidentitycredentialsV1alphaSuccess success) { + this.success = success; + return this; + } + + /** + * Message indicating uri based consent is required. + * @return value or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired getUriConsentRequired() { + return uriConsentRequired; + } + + /** + * Message indicating uri based consent is required. + * @param uriConsentRequired uriConsentRequired or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsResponse setUriConsentRequired(GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired uriConsentRequired) { + this.uriConsentRequired = uriConsentRequired; + return this; + } + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsResponse set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsResponse) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsResponse clone() { + return (GoogleCloudAgentidentitycredentialsV1alphaRetrieveCredentialsResponse) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaSuccess.java b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaSuccess.java new file mode 100644 index 00000000000..30bea067f90 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaSuccess.java @@ -0,0 +1,169 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1alpha.model; + +/** + * Message indicating successful retrieval of credentials. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1alphaSuccess extends com.google.api.client.json.GenericJson { + + /** + * The expiration time of the token. This does not guarantee that the token will be valid until + * this time, since the token could be revoked earlier. There could also be clock skew between the + * auth provider and the client so it may expire slightly earlier. If not set, the token might be + * permanent or it may be that the service does not (or cannot) know when it will expire. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private String expireTime; + + /** + * The HTTP header name where the token should be placed. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String header; + + /** + * The scopes actually associated with the retrieved token. End users may have rejected some + * requested scopes, or the third-party authorization servers can return a different set of scopes + * than what was asked for. Callers should verify that all required scopes for their intended use + * are included in this list. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List scopes; + + /** + * The retrieved access token or credential for the end user. On MCPTool call, for an invalid + * token OAuth spec says this should return 401 or 403, but MCPServers may implement this + * differently. If you get any flavor of `PERMISSION_DENIED`, retry your original request to + * RetrieveCredentials with force_refresh_token set to the expired/invalid token string, which + * will fetch a new token or initiate a new consent flow. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String token; + + /** + * The expiration time of the token. This does not guarantee that the token will be valid until + * this time, since the token could be revoked earlier. There could also be clock skew between the + * auth provider and the client so it may expire slightly earlier. If not set, the token might be + * permanent or it may be that the service does not (or cannot) know when it will expire. + * @return value or {@code null} for none + */ + public String getExpireTime() { + return expireTime; + } + + /** + * The expiration time of the token. This does not guarantee that the token will be valid until + * this time, since the token could be revoked earlier. There could also be clock skew between the + * auth provider and the client so it may expire slightly earlier. If not set, the token might be + * permanent or it may be that the service does not (or cannot) know when it will expire. + * @param expireTime expireTime or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaSuccess setExpireTime(String expireTime) { + this.expireTime = expireTime; + return this; + } + + /** + * The HTTP header name where the token should be placed. + * @return value or {@code null} for none + */ + public java.lang.String getHeader() { + return header; + } + + /** + * The HTTP header name where the token should be placed. + * @param header header or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaSuccess setHeader(java.lang.String header) { + this.header = header; + return this; + } + + /** + * The scopes actually associated with the retrieved token. End users may have rejected some + * requested scopes, or the third-party authorization servers can return a different set of scopes + * than what was asked for. Callers should verify that all required scopes for their intended use + * are included in this list. + * @return value or {@code null} for none + */ + public java.util.List getScopes() { + return scopes; + } + + /** + * The scopes actually associated with the retrieved token. End users may have rejected some + * requested scopes, or the third-party authorization servers can return a different set of scopes + * than what was asked for. Callers should verify that all required scopes for their intended use + * are included in this list. + * @param scopes scopes or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaSuccess setScopes(java.util.List scopes) { + this.scopes = scopes; + return this; + } + + /** + * The retrieved access token or credential for the end user. On MCPTool call, for an invalid + * token OAuth spec says this should return 401 or 403, but MCPServers may implement this + * differently. If you get any flavor of `PERMISSION_DENIED`, retry your original request to + * RetrieveCredentials with force_refresh_token set to the expired/invalid token string, which + * will fetch a new token or initiate a new consent flow. + * @return value or {@code null} for none + */ + public java.lang.String getToken() { + return token; + } + + /** + * The retrieved access token or credential for the end user. On MCPTool call, for an invalid + * token OAuth spec says this should return 401 or 403, but MCPServers may implement this + * differently. If you get any flavor of `PERMISSION_DENIED`, retry your original request to + * RetrieveCredentials with force_refresh_token set to the expired/invalid token string, which + * will fetch a new token or initiate a new consent flow. + * @param token token or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaSuccess setToken(java.lang.String token) { + this.token = token; + return this; + } + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaSuccess set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1alphaSuccess) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaSuccess clone() { + return (GoogleCloudAgentidentitycredentialsV1alphaSuccess) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired.java b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired.java new file mode 100644 index 00000000000..3f12f54c06f --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/com/google/api/services/agentidentitycredentials/v1alpha/model/GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired.java @@ -0,0 +1,129 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.agentidentitycredentials.v1alpha.model; + +/** + * Indicates that the user must visit the provided URI to consent to delegate permission to the + * agent to act on their behalf. The caller can either poll the `RetrieveCredentials` method, or + * await the /ValidateUserId callback + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Agent Identity Credentials API. For a detailed + * explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired extends com.google.api.client.json.GenericJson { + + /** + * Output only. The URL where the user should be redirected to grant consent. This will always be + * present. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String authorizationUri; + + /** + * Output only. A one-time, randomly generated value that validates the entire consent flow is + * handled by a single user, avoiding CSRF attacks. It must be submitted with the + * FinalizeCredentials request to complete the OAuth exchange. This will always be present. + * Implemented per https://www.rfc-editor.org/rfc/rfc6819#section-5.3.5 + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String consentNonce; + + /** + * Output only. The unique ID of the credentials retrieval operation. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String uid; + + /** + * Output only. The URL where the user should be redirected to grant consent. This will always be + * present. + * @return value or {@code null} for none + */ + public java.lang.String getAuthorizationUri() { + return authorizationUri; + } + + /** + * Output only. The URL where the user should be redirected to grant consent. This will always be + * present. + * @param authorizationUri authorizationUri or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired setAuthorizationUri(java.lang.String authorizationUri) { + this.authorizationUri = authorizationUri; + return this; + } + + /** + * Output only. A one-time, randomly generated value that validates the entire consent flow is + * handled by a single user, avoiding CSRF attacks. It must be submitted with the + * FinalizeCredentials request to complete the OAuth exchange. This will always be present. + * Implemented per https://www.rfc-editor.org/rfc/rfc6819#section-5.3.5 + * @return value or {@code null} for none + */ + public java.lang.String getConsentNonce() { + return consentNonce; + } + + /** + * Output only. A one-time, randomly generated value that validates the entire consent flow is + * handled by a single user, avoiding CSRF attacks. It must be submitted with the + * FinalizeCredentials request to complete the OAuth exchange. This will always be present. + * Implemented per https://www.rfc-editor.org/rfc/rfc6819#section-5.3.5 + * @param consentNonce consentNonce or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired setConsentNonce(java.lang.String consentNonce) { + this.consentNonce = consentNonce; + return this; + } + + /** + * Output only. The unique ID of the credentials retrieval operation. + * @return value or {@code null} for none + */ + public java.lang.String getUid() { + return uid; + } + + /** + * Output only. The unique ID of the credentials retrieval operation. + * @param uid uid or {@code null} for none + */ + public GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired setUid(java.lang.String uid) { + this.uid = uid; + return this; + } + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired set(String fieldName, Object value) { + return (GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired) super.set(fieldName, value); + } + + @Override + public GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired clone() { + return (GoogleCloudAgentidentitycredentialsV1alphaUriConsentRequired) super.clone(); + } + +} diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/pom.xml b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/pom.xml new file mode 100644 index 00000000000..3f7ccd51433 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/2.0.0/pom.xml @@ -0,0 +1,219 @@ + + 4.0.0 + + org.sonatype.oss + oss-parent + 7 + + + com.google.apis + google-api-services-agentidentitycredentials + v1alpha-rev20260717-2.0.0 + Agent Identity Credentials API v1alpha-rev20260717-2.0.0 + jar + + 2011 + + + + GoogleAPIs + GoogleAPIs + googleapis@googlegroups.com + Google + https://www.google.com + + + + + Google + http://www.google.com/ + + + + + The Apache Software License, Version 2.0 + http://www.apache.org/licenses/LICENSE-2.0.txt + repo + + + + + + ossrh + https://google.oss.sonatype.org/content/repositories/snapshots + + + + + + + maven-compiler-plugin + 3.9.0 + + 1.7 + 1.7 + + + + org.apache.maven.plugins + maven-source-plugin + 2.4 + + + org.apache.maven.plugins + maven-jar-plugin + 3.1.2 + + + + com.google.api.services.agentidentitycredentials + + + + + + org.apache.maven.plugins + maven-javadoc-plugin + 3.1.0 + + + attach-javadocs + + jar + + + + + none + Agent Identity Credentials API ${project.version} + Agent Identity Credentials API ${project.version} + + http://docs.oracle.com/javase/7/docs/api + https://googleapis.dev/java/google-http-client/${httpClientLibrary}/ + https://googleapis.dev/java/google-oauth-client/${oauthClientLibrary}/ + https://googleapis.dev/java/google-api-client/2.7.2/ + + + + + org.codehaus.mojo + clirr-maven-plugin + 2.8 + + clirr-ignored-differences.xml + true + + + + + check + + + + + + . + + + ./resources + + + + + + + com.google.api-client + google-api-client + 2.7.2 + + + + + UTF-8 + + + + + + release-sonatype + + + + !artifact-registry-url + + + + + + org.sonatype.plugins + nexus-staging-maven-plugin + 1.6.13 + true + + sonatype-nexus-staging + https://google.oss.sonatype.org/ + false + + + + + + + + release-gcp-artifact-registry + + artifactregistry://please-define-artifact-registry-url-property + + + + gcp-artifact-registry-repository + ${artifact-registry-url} + + + gcp-artifact-registry-repository + ${artifact-registry-url} + + + + + release-sign-artifacts + + + performRelease + true + + + + + + org.apache.maven.plugins + maven-gpg-plugin + 3.2.7 + + + sign-artifacts + verify + + sign + + + + --pinentry-mode + loopback + + + + + + + + + + \ No newline at end of file diff --git a/clients/google-api-services-agentidentitycredentials/v1alpha/README.md b/clients/google-api-services-agentidentitycredentials/v1alpha/README.md new file mode 100644 index 00000000000..bb2f7d96c36 --- /dev/null +++ b/clients/google-api-services-agentidentitycredentials/v1alpha/README.md @@ -0,0 +1,44 @@ +# Agent Identity Credentials API Client Library for Java + +agentidentitycredentials.googleapis.com API. + +This page contains information about getting started with the Agent Identity Credentials API +using the Google API Client Library for Java. In addition, you may be interested +in the following documentation: + +* Browse the [Javadoc reference for the Agent Identity Credentials API][javadoc] +* Read the [Developer's Guide for the Google API Client Library for Java][google-api-client]. +* Interact with this API in your browser using the [APIs Explorer for the Agent Identity Credentials API][api-explorer] + +## Installation + +### Maven + +Add the following lines to your `pom.xml` file: + +```xml + + + + com.google.apis + google-api-services-agentidentitycredentials + v1alpha-rev20260717-2.0.0 + + + +``` + +### Gradle + +```gradle +repositories { + mavenCentral() +} +dependencies { + implementation 'com.google.apis:google-api-services-agentidentitycredentials:v1alpha-rev20260717-2.0.0' +} +``` + +[javadoc]: https://googleapis.dev/java/google-api-services-agentidentitycredentials/latest/index.html +[google-api-client]: https://github.com/googleapis/google-api-java-client/ +[api-explorer]: https://developers.google.com/apis-explorer/#p/agentidentitycredentials/v1/