Class: Google::Apis::SecretmanagerV1beta2::SecretManagerService
- Inherits:
-
Core::BaseService
- Object
- Core::BaseService
- Google::Apis::SecretmanagerV1beta2::SecretManagerService
- Defined in:
- lib/google/apis/secretmanager_v1beta2/service.rb
Overview
Secret Manager API
Stores sensitive data such as API keys, passwords, and certificates. Provides convenience while improving security.
Constant Summary collapse
- DEFAULT_ENDPOINT_TEMPLATE =
"https://secretmanager.$UNIVERSE_DOMAIN$/"
Instance Attribute Summary collapse
-
#key ⇒ String
API key.
-
#quota_user ⇒ String
Available to use for quota purposes for server-side applications.
Instance Method Summary collapse
-
#access_project_location_secret_version(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::AccessSecretVersionResponse
Accesses a SecretVersion.
-
#access_project_secret_version(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::AccessSecretVersionResponse
Accesses a SecretVersion.
-
#add_project_location_secret_version(parent, add_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Creates a new SecretVersion containing secret data and attaches it to an existing Secret.
-
#add_project_secret_version(parent, add_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Creates a new SecretVersion containing secret data and attaches it to an existing Secret.
-
#create_project_location_secret(parent, secret_object = nil, secret_id: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Secret
Creates a new Secret containing no SecretVersions.
-
#create_project_secret(parent, secret_object = nil, secret_id: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Secret
Creates a new Secret containing no SecretVersions.
-
#delete_project_location_secret(name, etag: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Empty
Deletes a Secret.
-
#delete_project_secret(name, etag: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Empty
Deletes a Secret.
-
#destroy_project_location_secret_version(name, destroy_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Destroys a SecretVersion.
-
#destroy_project_secret_version(name, destroy_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Destroys a SecretVersion.
-
#disable_project_location_secret_version(name, disable_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Disables a SecretVersion.
-
#disable_project_secret_version(name, disable_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Disables a SecretVersion.
-
#enable_project_location_secret_version(name, enable_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Enables a SecretVersion.
-
#enable_project_secret_version(name, enable_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Enables a SecretVersion.
-
#get_project_location(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Location
Gets information about a location.
-
#get_project_location_secret(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Secret
Gets metadata for a given Secret.
-
#get_project_location_secret_iam_policy(resource, options_requested_policy_version: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Policy
Gets the access control policy for a secret.
-
#get_project_location_secret_version(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Gets metadata for a SecretVersion.
-
#get_project_secret(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Secret
Gets metadata for a given Secret.
-
#get_project_secret_iam_policy(resource, options_requested_policy_version: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Policy
Gets the access control policy for a secret.
-
#get_project_secret_version(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Gets metadata for a SecretVersion.
-
#initialize ⇒ SecretManagerService
constructor
A new instance of SecretManagerService.
-
#list_project_location_secret_versions(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::ListSecretVersionsResponse
Lists SecretVersions.
-
#list_project_location_secrets(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::ListSecretsResponse
Lists Secrets.
-
#list_project_locations(name, extra_location_types: nil, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::ListLocationsResponse
Lists information about the supported locations for this service.
-
#list_project_secret_versions(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::ListSecretVersionsResponse
Lists SecretVersions.
-
#list_project_secrets(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::ListSecretsResponse
Lists Secrets.
-
#patch_project_location_secret(name, secret_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Secret
Updates metadata of an existing Secret.
-
#patch_project_secret(name, secret_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Secret
Updates metadata of an existing Secret.
-
#set_project_location_secret_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Policy
Sets the access control policy on the specified secret.
-
#set_project_secret_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Policy
Sets the access control policy on the specified secret.
-
#test_project_location_secret_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::TestIamPermissionsResponse
Returns permissions that a caller has for the specified secret.
-
#test_project_secret_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::TestIamPermissionsResponse
Returns permissions that a caller has for the specified secret.
Constructor Details
#initialize ⇒ SecretManagerService
Returns a new instance of SecretManagerService.
48 49 50 51 52 53 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 48 def initialize super(DEFAULT_ENDPOINT_TEMPLATE, '', client_name: 'google-apis-secretmanager_v1beta2', client_version: Google::Apis::SecretmanagerV1beta2::GEM_VERSION) @batch_path = 'batch' end |
Instance Attribute Details
#key ⇒ String
Returns 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.
41 42 43 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 41 def key @key end |
#quota_user ⇒ String
Returns 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.
46 47 48 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 46 def quota_user @quota_user end |
Instance Method Details
#access_project_location_secret_version(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::AccessSecretVersionResponse
Accesses a SecretVersion. This call returns the secret data. projects/*/
secrets/*/versions/latest is an alias to the most recently created
SecretVersion.
510 511 512 513 514 515 516 517 518 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 510 def access_project_location_secret_version(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1beta2/{+name}:access', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::AccessSecretVersionResponse::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::AccessSecretVersionResponse command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#access_project_secret_version(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::AccessSecretVersionResponse
Accesses a SecretVersion. This call returns the secret data. projects/*/
secrets/*/versions/latest is an alias to the most recently created
SecretVersion.
1076 1077 1078 1079 1080 1081 1082 1083 1084 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 1076 def access_project_secret_version(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1beta2/{+name}:access', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::AccessSecretVersionResponse::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::AccessSecretVersionResponse command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#add_project_location_secret_version(parent, add_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Creates a new SecretVersion containing secret data and attaches it to an existing Secret.
164 165 166 167 168 169 170 171 172 173 174 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 164 def add_project_location_secret_version(parent, add_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1beta2/{+parent}:addVersion', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::AddSecretVersionRequest::Representation command.request_object = add_secret_version_request_object command.response_representation = Google::Apis::SecretmanagerV1beta2::SecretVersion::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::SecretVersion command.params['parent'] = parent unless parent.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#add_project_secret_version(parent, add_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Creates a new SecretVersion containing secret data and attaches it to an existing Secret.
730 731 732 733 734 735 736 737 738 739 740 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 730 def add_project_secret_version(parent, add_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1beta2/{+parent}:addVersion', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::AddSecretVersionRequest::Representation command.request_object = add_secret_version_request_object command.response_representation = Google::Apis::SecretmanagerV1beta2::SecretVersion::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::SecretVersion command.params['parent'] = parent unless parent.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#create_project_location_secret(parent, secret_object = nil, secret_id: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Secret
Creates a new Secret containing no SecretVersions.
202 203 204 205 206 207 208 209 210 211 212 213 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 202 def create_project_location_secret(parent, secret_object = nil, secret_id: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1beta2/{+parent}/secrets', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::Secret::Representation command.request_object = secret_object command.response_representation = Google::Apis::SecretmanagerV1beta2::Secret::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::Secret command.params['parent'] = parent unless parent.nil? command.query['secretId'] = secret_id unless secret_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#create_project_secret(parent, secret_object = nil, secret_id: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Secret
Creates a new Secret containing no SecretVersions.
768 769 770 771 772 773 774 775 776 777 778 779 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 768 def create_project_secret(parent, secret_object = nil, secret_id: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1beta2/{+parent}/secrets', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::Secret::Representation command.request_object = secret_object command.response_representation = Google::Apis::SecretmanagerV1beta2::Secret::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::Secret command.params['parent'] = parent unless parent.nil? command.query['secretId'] = secret_id unless secret_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#delete_project_location_secret(name, etag: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Empty
Deletes a Secret.
240 241 242 243 244 245 246 247 248 249 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 240 def delete_project_location_secret(name, etag: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:delete, 'v1beta2/{+name}', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::Empty::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::Empty command.params['name'] = name unless name.nil? command.query['etag'] = etag unless etag.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#delete_project_secret(name, etag: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Empty
Deletes a Secret.
806 807 808 809 810 811 812 813 814 815 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 806 def delete_project_secret(name, etag: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:delete, 'v1beta2/{+name}', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::Empty::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::Empty command.params['name'] = name unless name.nil? command.query['etag'] = etag unless etag.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#destroy_project_location_secret_version(name, destroy_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Destroys a SecretVersion. Sets the state of the SecretVersion to DESTROYED and irrevocably destroys the secret data.
544 545 546 547 548 549 550 551 552 553 554 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 544 def destroy_project_location_secret_version(name, destroy_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1beta2/{+name}:destroy', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::DestroySecretVersionRequest::Representation command.request_object = destroy_secret_version_request_object command.response_representation = Google::Apis::SecretmanagerV1beta2::SecretVersion::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::SecretVersion command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#destroy_project_secret_version(name, destroy_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Destroys a SecretVersion. Sets the state of the SecretVersion to DESTROYED and irrevocably destroys the secret data.
1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 1110 def destroy_project_secret_version(name, destroy_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1beta2/{+name}:destroy', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::DestroySecretVersionRequest::Representation command.request_object = destroy_secret_version_request_object command.response_representation = Google::Apis::SecretmanagerV1beta2::SecretVersion::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::SecretVersion command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#disable_project_location_secret_version(name, disable_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Disables a SecretVersion. Sets the state of the SecretVersion to DISABLED.
579 580 581 582 583 584 585 586 587 588 589 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 579 def disable_project_location_secret_version(name, disable_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1beta2/{+name}:disable', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::DisableSecretVersionRequest::Representation command.request_object = disable_secret_version_request_object command.response_representation = Google::Apis::SecretmanagerV1beta2::SecretVersion::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::SecretVersion command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#disable_project_secret_version(name, disable_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Disables a SecretVersion. Sets the state of the SecretVersion to DISABLED.
1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 1145 def disable_project_secret_version(name, disable_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1beta2/{+name}:disable', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::DisableSecretVersionRequest::Representation command.request_object = disable_secret_version_request_object command.response_representation = Google::Apis::SecretmanagerV1beta2::SecretVersion::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::SecretVersion command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#enable_project_location_secret_version(name, enable_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Enables a SecretVersion. Sets the state of the SecretVersion to ENABLED.
614 615 616 617 618 619 620 621 622 623 624 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 614 def enable_project_location_secret_version(name, enable_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1beta2/{+name}:enable', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::EnableSecretVersionRequest::Representation command.request_object = enable_secret_version_request_object command.response_representation = Google::Apis::SecretmanagerV1beta2::SecretVersion::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::SecretVersion command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#enable_project_secret_version(name, enable_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Enables a SecretVersion. Sets the state of the SecretVersion to ENABLED.
1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 1180 def enable_project_secret_version(name, enable_secret_version_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1beta2/{+name}:enable', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::EnableSecretVersionRequest::Representation command.request_object = enable_secret_version_request_object command.response_representation = Google::Apis::SecretmanagerV1beta2::SecretVersion::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::SecretVersion command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_project_location(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Location
Gets information about a location.
75 76 77 78 79 80 81 82 83 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 75 def get_project_location(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1beta2/{+name}', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::Location::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::Location command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_project_location_secret(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Secret
Gets metadata for a given Secret.
272 273 274 275 276 277 278 279 280 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 272 def get_project_location_secret(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1beta2/{+name}', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::Secret::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::Secret command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_project_location_secret_iam_policy(resource, options_requested_policy_version: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Policy
Gets the access control policy for a secret. Returns empty policy if the secret exists and does not have a policy set.
316 317 318 319 320 321 322 323 324 325 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 316 def get_project_location_secret_iam_policy(resource, options_requested_policy_version: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1beta2/{+resource}:getIamPolicy', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::Policy::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::Policy command.params['resource'] = resource unless resource.nil? command.query['options.requestedPolicyVersion'] = unless .nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_project_location_secret_version(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Gets metadata for a SecretVersion. projects/*/secrets/*/versions/latest is
an alias to the most recently created SecretVersion.
650 651 652 653 654 655 656 657 658 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 650 def get_project_location_secret_version(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1beta2/{+name}', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::SecretVersion::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::SecretVersion command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_project_secret(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Secret
Gets metadata for a given Secret.
838 839 840 841 842 843 844 845 846 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 838 def get_project_secret(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1beta2/{+name}', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::Secret::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::Secret command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_project_secret_iam_policy(resource, options_requested_policy_version: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Policy
Gets the access control policy for a secret. Returns empty policy if the secret exists and does not have a policy set.
882 883 884 885 886 887 888 889 890 891 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 882 def get_project_secret_iam_policy(resource, options_requested_policy_version: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1beta2/{+resource}:getIamPolicy', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::Policy::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::Policy command.params['resource'] = resource unless resource.nil? command.query['options.requestedPolicyVersion'] = unless .nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_project_secret_version(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::SecretVersion
Gets metadata for a SecretVersion. projects/*/secrets/*/versions/latest is
an alias to the most recently created SecretVersion.
1216 1217 1218 1219 1220 1221 1222 1223 1224 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 1216 def get_project_secret_version(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1beta2/{+name}', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::SecretVersion::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::SecretVersion command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#list_project_location_secret_versions(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::ListSecretVersionsResponse
Lists SecretVersions. This call does not return secret data.
694 695 696 697 698 699 700 701 702 703 704 705 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 694 def list_project_location_secret_versions(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1beta2/{+parent}/versions', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::ListSecretVersionsResponse::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::ListSecretVersionsResponse command.params['parent'] = parent unless parent.nil? command.query['filter'] = filter unless filter.nil? command.query['pageSize'] = page_size unless page_size.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#list_project_location_secrets(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::ListSecretsResponse
Lists Secrets.
359 360 361 362 363 364 365 366 367 368 369 370 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 359 def list_project_location_secrets(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1beta2/{+parent}/secrets', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::ListSecretsResponse::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::ListSecretsResponse command.params['parent'] = parent unless parent.nil? command.query['filter'] = filter unless filter.nil? command.query['pageSize'] = page_size unless page_size.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#list_project_locations(name, extra_location_types: nil, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::ListLocationsResponse
Lists information about the supported locations for this service. This method
lists locations based on the resource scope provided in the [
ListLocationsRequest.name] field: * Global locations: If name is empty,
the method lists the public locations available to all projects. * Project-
specific locations: If name follows the format projects/project`, the
method lists locations visible to that specific project. This includes public,
private, or other project-specific locations enabled for the project. For gRPC
and client library implementations, the resource name is passed as thename`
field. For direct service calls, the resource name is incorporated into the
request path based on the specific service implementation and version.
127 128 129 130 131 132 133 134 135 136 137 138 139 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 127 def list_project_locations(name, extra_location_types: nil, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1beta2/{+name}/locations', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::ListLocationsResponse::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::ListLocationsResponse command.params['name'] = name unless name.nil? command.query['extraLocationTypes'] = extra_location_types unless extra_location_types.nil? command.query['filter'] = filter unless filter.nil? command.query['pageSize'] = page_size unless page_size.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#list_project_secret_versions(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::ListSecretVersionsResponse
Lists SecretVersions. This call does not return secret data.
1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 1260 def list_project_secret_versions(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1beta2/{+parent}/versions', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::ListSecretVersionsResponse::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::ListSecretVersionsResponse command.params['parent'] = parent unless parent.nil? command.query['filter'] = filter unless filter.nil? command.query['pageSize'] = page_size unless page_size.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#list_project_secrets(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::ListSecretsResponse
Lists Secrets.
925 926 927 928 929 930 931 932 933 934 935 936 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 925 def list_project_secrets(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1beta2/{+parent}/secrets', ) command.response_representation = Google::Apis::SecretmanagerV1beta2::ListSecretsResponse::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::ListSecretsResponse command.params['parent'] = parent unless parent.nil? command.query['filter'] = filter unless filter.nil? command.query['pageSize'] = page_size unless page_size.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#patch_project_location_secret(name, secret_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Secret
Updates metadata of an existing Secret.
396 397 398 399 400 401 402 403 404 405 406 407 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 396 def patch_project_location_secret(name, secret_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:patch, 'v1beta2/{+name}', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::Secret::Representation command.request_object = secret_object command.response_representation = Google::Apis::SecretmanagerV1beta2::Secret::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::Secret command.params['name'] = name unless name.nil? command.query['updateMask'] = update_mask unless update_mask.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#patch_project_secret(name, secret_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Secret
Updates metadata of an existing Secret.
962 963 964 965 966 967 968 969 970 971 972 973 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 962 def patch_project_secret(name, secret_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:patch, 'v1beta2/{+name}', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::Secret::Representation command.request_object = secret_object command.response_representation = Google::Apis::SecretmanagerV1beta2::Secret::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::Secret command.params['name'] = name unless name.nil? command.query['updateMask'] = update_mask unless update_mask.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#set_project_location_secret_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Policy
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.
434 435 436 437 438 439 440 441 442 443 444 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 434 def set_project_location_secret_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1beta2/{+resource}:setIamPolicy', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::SetIamPolicyRequest::Representation command.request_object = set_iam_policy_request_object command.response_representation = Google::Apis::SecretmanagerV1beta2::Policy::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::Policy command.params['resource'] = resource unless resource.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#set_project_secret_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::Policy
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.
1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 1000 def set_project_secret_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1beta2/{+resource}:setIamPolicy', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::SetIamPolicyRequest::Representation command.request_object = set_iam_policy_request_object command.response_representation = Google::Apis::SecretmanagerV1beta2::Policy::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::Policy command.params['resource'] = resource unless resource.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#test_project_location_secret_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::TestIamPermissionsResponse
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.
473 474 475 476 477 478 479 480 481 482 483 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 473 def (resource, = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1beta2/{+resource}:testIamPermissions', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::TestIamPermissionsRequest::Representation command.request_object = command.response_representation = Google::Apis::SecretmanagerV1beta2::TestIamPermissionsResponse::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::TestIamPermissionsResponse command.params['resource'] = resource unless resource.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#test_project_secret_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::SecretmanagerV1beta2::TestIamPermissionsResponse
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.
1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 |
# File 'lib/google/apis/secretmanager_v1beta2/service.rb', line 1039 def (resource, = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1beta2/{+resource}:testIamPermissions', ) command.request_representation = Google::Apis::SecretmanagerV1beta2::TestIamPermissionsRequest::Representation command.request_object = command.response_representation = Google::Apis::SecretmanagerV1beta2::TestIamPermissionsResponse::Representation command.response_class = Google::Apis::SecretmanagerV1beta2::TestIamPermissionsResponse command.params['resource'] = resource unless resource.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |