target.apidocs.com.google.api.services.secretmanager.v1.SecretManager.Projects.Locations.Secrets.html Maven / Gradle / Ivy
The newest version!
SecretManager.Projects.Locations.Secrets (Secret Manager API v1-rev20240924-2.0.0)
com.google.api.services.secretmanager.v1
Class SecretManager.Projects.Locations.Secrets
- java.lang.Object
-
- com.google.api.services.secretmanager.v1.SecretManager.Projects.Locations.Secrets
-
- Enclosing class:
- SecretManager.Projects.Locations
public class SecretManager.Projects.Locations.Secrets
extends Object
The "secrets" collection of methods.
-
-
Nested Class Summary
Nested Classes
Modifier and Type
Class and Description
class
SecretManager.Projects.Locations.Secrets.AddVersion
class
SecretManager.Projects.Locations.Secrets.Create
class
SecretManager.Projects.Locations.Secrets.Delete
class
SecretManager.Projects.Locations.Secrets.Get
class
SecretManager.Projects.Locations.Secrets.GetIamPolicy
class
SecretManager.Projects.Locations.Secrets.List
class
SecretManager.Projects.Locations.Secrets.Patch
class
SecretManager.Projects.Locations.Secrets.SetIamPolicy
class
SecretManager.Projects.Locations.Secrets.TestIamPermissions
class
SecretManager.Projects.Locations.Secrets.Versions
The "versions" collection of methods.
-
Constructor Summary
Constructors
Constructor and Description
Secrets()
-
Method Summary
-
-
Method Detail
-
addVersion
public SecretManager.Projects.Locations.Secrets.AddVersion addVersion(String parent,
AddSecretVersionRequest content)
throws IOException
Creates a new SecretVersion containing secret data and attaches it to an existing Secret.
Create a request for the method "secrets.addVersion".
This request holds the parameters needed by the secretmanager server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
parent
- Required. The resource name of the Secret to associate with the SecretVersion in the format
`projects/secrets` or `projects/locations/secrets`.
content
- the AddSecretVersionRequest
- Returns:
- the request
- Throws:
IOException
-
create
public SecretManager.Projects.Locations.Secrets.Create create(String parent,
Secret content)
throws IOException
Creates a new Secret containing no SecretVersions.
Create a request for the method "secrets.create".
This request holds the parameters needed by the secretmanager server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
parent
- Required. The resource name of the project to associate with the Secret, in the format `projects` or
`projects/locations`.
content
- the Secret
- Returns:
- the request
- Throws:
IOException
-
delete
public SecretManager.Projects.Locations.Secrets.Delete delete(String name)
throws IOException
Deletes a Secret.
Create a request for the method "secrets.delete".
This request holds the parameters needed by the secretmanager server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
name
- Required. The resource name of the Secret to delete in the format `projects/secrets`.
- Returns:
- the request
- Throws:
IOException
-
get
public SecretManager.Projects.Locations.Secrets.Get get(String name)
throws IOException
Gets metadata for a given Secret.
Create a request for the method "secrets.get".
This request holds the parameters needed by the secretmanager server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
name
- Required. The resource name of the Secret, in the format `projects/secrets` or
`projects/locations/secrets`.
- Returns:
- the request
- Throws:
IOException
-
getIamPolicy
public SecretManager.Projects.Locations.Secrets.GetIamPolicy getIamPolicy(String resource)
throws IOException
Gets the access control policy for a secret. Returns empty policy if the secret exists and does
not have a policy set.
Create a request for the method "secrets.getIamPolicy".
This request holds the parameters needed by the secretmanager server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
resource
- REQUIRED: The resource for which the policy is being requested. See [Resource
names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for
this field.
- Returns:
- the request
- Throws:
IOException
-
list
public SecretManager.Projects.Locations.Secrets.List list(String parent)
throws IOException
Lists Secrets.
Create a request for the method "secrets.list".
This request holds the parameters needed by the secretmanager server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
parent
- Required. The resource name of the project associated with the Secrets, in the format `projects` or
`projects/locations`
- Returns:
- the request
- Throws:
IOException
-
patch
public SecretManager.Projects.Locations.Secrets.Patch patch(String name,
Secret content)
throws IOException
Updates metadata of an existing Secret.
Create a request for the method "secrets.patch".
This request holds the parameters needed by the secretmanager server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
name
- Output only. The resource name of the Secret in the format `projects/secrets`.
content
- the Secret
- Returns:
- the request
- Throws:
IOException
-
setIamPolicy
public SecretManager.Projects.Locations.Secrets.SetIamPolicy setIamPolicy(String resource,
SetIamPolicyRequest content)
throws IOException
Sets the access control policy on the specified secret. Replaces any existing policy. Permissions
on SecretVersions are enforced according to the policy set on the associated Secret.
Create a request for the method "secrets.setIamPolicy".
This request holds the parameters needed by the secretmanager server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
resource
- REQUIRED: The resource for which the policy is being specified. See [Resource
names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for
this field.
content
- the SetIamPolicyRequest
- Returns:
- the request
- Throws:
IOException
-
testIamPermissions
public SecretManager.Projects.Locations.Secrets.TestIamPermissions testIamPermissions(String resource,
TestIamPermissionsRequest content)
throws IOException
Returns permissions that a caller has for the specified secret. If the secret does not exist,
this call returns an empty set of permissions, not a NOT_FOUND error. Note: This operation is
designed to be used for building permission-aware UIs and command-line tools, not for
authorization checking. This operation may "fail open" without warning.
Create a request for the method "secrets.testIamPermissions".
This request holds the parameters needed by the secretmanager server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
resource
- REQUIRED: The resource for which the policy detail is being requested. See [Resource
names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for
this field.
content
- the TestIamPermissionsRequest
- Returns:
- the request
- Throws:
IOException
-
versions
public SecretManager.Projects.Locations.Secrets.Versions versions()
An accessor for creating requests from the Versions collection.
The typical use is:
SecretManager secretmanager = new SecretManager(...);
SecretManager.Versions.List request = secretmanager.versions().list(parameters ...)
- Returns:
- the resource collection
Copyright © 2011–2024 Google. All rights reserved.
© 2015 - 2024 Weber Informatics LLC | Privacy Policy