google-apis-gkehub_v1beta 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.yardopts +13 -0
- data/CHANGELOG.md +7 -0
- data/LICENSE.md +202 -0
- data/OVERVIEW.md +96 -0
- data/lib/google-apis-gkehub_v1beta.rb +15 -0
- data/lib/google/apis/gkehub_v1beta.rb +36 -0
- data/lib/google/apis/gkehub_v1beta/classes.rb +692 -0
- data/lib/google/apis/gkehub_v1beta/gem_version.rb +28 -0
- data/lib/google/apis/gkehub_v1beta/representations.rb +269 -0
- data/lib/google/apis/gkehub_v1beta/service.rb +514 -0
- metadata +76 -0
@@ -0,0 +1,28 @@
|
|
1
|
+
# Copyright 2020 Google LLC
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
15
|
+
module Google
|
16
|
+
module Apis
|
17
|
+
module GkehubV1beta
|
18
|
+
# Version of the google-apis-gkehub_v1beta gem
|
19
|
+
GEM_VERSION = "0.1.0"
|
20
|
+
|
21
|
+
# Version of the code generator used to generate this client
|
22
|
+
GENERATOR_VERSION = "0.2.0"
|
23
|
+
|
24
|
+
# Revision of the discovery document this client was generated from
|
25
|
+
REVISION = "20210315"
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
@@ -0,0 +1,269 @@
|
|
1
|
+
# Copyright 2020 Google LLC
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
15
|
+
require 'date'
|
16
|
+
require 'google/apis/core/base_service'
|
17
|
+
require 'google/apis/core/json_representation'
|
18
|
+
require 'google/apis/core/hashable'
|
19
|
+
require 'google/apis/errors'
|
20
|
+
|
21
|
+
module Google
|
22
|
+
module Apis
|
23
|
+
module GkehubV1beta
|
24
|
+
|
25
|
+
class AuditConfig
|
26
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
27
|
+
|
28
|
+
include Google::Apis::Core::JsonObjectSupport
|
29
|
+
end
|
30
|
+
|
31
|
+
class AuditLogConfig
|
32
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
33
|
+
|
34
|
+
include Google::Apis::Core::JsonObjectSupport
|
35
|
+
end
|
36
|
+
|
37
|
+
class Binding
|
38
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
39
|
+
|
40
|
+
include Google::Apis::Core::JsonObjectSupport
|
41
|
+
end
|
42
|
+
|
43
|
+
class CancelOperationRequest
|
44
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
45
|
+
|
46
|
+
include Google::Apis::Core::JsonObjectSupport
|
47
|
+
end
|
48
|
+
|
49
|
+
class Empty
|
50
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
51
|
+
|
52
|
+
include Google::Apis::Core::JsonObjectSupport
|
53
|
+
end
|
54
|
+
|
55
|
+
class Expr
|
56
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
57
|
+
|
58
|
+
include Google::Apis::Core::JsonObjectSupport
|
59
|
+
end
|
60
|
+
|
61
|
+
class GoogleRpcStatus
|
62
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
63
|
+
|
64
|
+
include Google::Apis::Core::JsonObjectSupport
|
65
|
+
end
|
66
|
+
|
67
|
+
class ListLocationsResponse
|
68
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
69
|
+
|
70
|
+
include Google::Apis::Core::JsonObjectSupport
|
71
|
+
end
|
72
|
+
|
73
|
+
class ListOperationsResponse
|
74
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
75
|
+
|
76
|
+
include Google::Apis::Core::JsonObjectSupport
|
77
|
+
end
|
78
|
+
|
79
|
+
class Location
|
80
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
81
|
+
|
82
|
+
include Google::Apis::Core::JsonObjectSupport
|
83
|
+
end
|
84
|
+
|
85
|
+
class Operation
|
86
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
87
|
+
|
88
|
+
include Google::Apis::Core::JsonObjectSupport
|
89
|
+
end
|
90
|
+
|
91
|
+
class OperationMetadata
|
92
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
93
|
+
|
94
|
+
include Google::Apis::Core::JsonObjectSupport
|
95
|
+
end
|
96
|
+
|
97
|
+
class Policy
|
98
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
99
|
+
|
100
|
+
include Google::Apis::Core::JsonObjectSupport
|
101
|
+
end
|
102
|
+
|
103
|
+
class SetIamPolicyRequest
|
104
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
105
|
+
|
106
|
+
include Google::Apis::Core::JsonObjectSupport
|
107
|
+
end
|
108
|
+
|
109
|
+
class TestIamPermissionsRequest
|
110
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
111
|
+
|
112
|
+
include Google::Apis::Core::JsonObjectSupport
|
113
|
+
end
|
114
|
+
|
115
|
+
class TestIamPermissionsResponse
|
116
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
117
|
+
|
118
|
+
include Google::Apis::Core::JsonObjectSupport
|
119
|
+
end
|
120
|
+
|
121
|
+
class AuditConfig
|
122
|
+
# @private
|
123
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
124
|
+
collection :audit_log_configs, as: 'auditLogConfigs', class: Google::Apis::GkehubV1beta::AuditLogConfig, decorator: Google::Apis::GkehubV1beta::AuditLogConfig::Representation
|
125
|
+
|
126
|
+
property :service, as: 'service'
|
127
|
+
end
|
128
|
+
end
|
129
|
+
|
130
|
+
class AuditLogConfig
|
131
|
+
# @private
|
132
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
133
|
+
collection :exempted_members, as: 'exemptedMembers'
|
134
|
+
property :log_type, as: 'logType'
|
135
|
+
end
|
136
|
+
end
|
137
|
+
|
138
|
+
class Binding
|
139
|
+
# @private
|
140
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
141
|
+
property :condition, as: 'condition', class: Google::Apis::GkehubV1beta::Expr, decorator: Google::Apis::GkehubV1beta::Expr::Representation
|
142
|
+
|
143
|
+
collection :members, as: 'members'
|
144
|
+
property :role, as: 'role'
|
145
|
+
end
|
146
|
+
end
|
147
|
+
|
148
|
+
class CancelOperationRequest
|
149
|
+
# @private
|
150
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
151
|
+
end
|
152
|
+
end
|
153
|
+
|
154
|
+
class Empty
|
155
|
+
# @private
|
156
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
157
|
+
end
|
158
|
+
end
|
159
|
+
|
160
|
+
class Expr
|
161
|
+
# @private
|
162
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
163
|
+
property :description, as: 'description'
|
164
|
+
property :expression, as: 'expression'
|
165
|
+
property :location, as: 'location'
|
166
|
+
property :title, as: 'title'
|
167
|
+
end
|
168
|
+
end
|
169
|
+
|
170
|
+
class GoogleRpcStatus
|
171
|
+
# @private
|
172
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
173
|
+
property :code, as: 'code'
|
174
|
+
collection :details, as: 'details'
|
175
|
+
property :message, as: 'message'
|
176
|
+
end
|
177
|
+
end
|
178
|
+
|
179
|
+
class ListLocationsResponse
|
180
|
+
# @private
|
181
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
182
|
+
collection :locations, as: 'locations', class: Google::Apis::GkehubV1beta::Location, decorator: Google::Apis::GkehubV1beta::Location::Representation
|
183
|
+
|
184
|
+
property :next_page_token, as: 'nextPageToken'
|
185
|
+
end
|
186
|
+
end
|
187
|
+
|
188
|
+
class ListOperationsResponse
|
189
|
+
# @private
|
190
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
191
|
+
property :next_page_token, as: 'nextPageToken'
|
192
|
+
collection :operations, as: 'operations', class: Google::Apis::GkehubV1beta::Operation, decorator: Google::Apis::GkehubV1beta::Operation::Representation
|
193
|
+
|
194
|
+
end
|
195
|
+
end
|
196
|
+
|
197
|
+
class Location
|
198
|
+
# @private
|
199
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
200
|
+
property :display_name, as: 'displayName'
|
201
|
+
hash :labels, as: 'labels'
|
202
|
+
property :location_id, as: 'locationId'
|
203
|
+
hash :metadata, as: 'metadata'
|
204
|
+
property :name, as: 'name'
|
205
|
+
end
|
206
|
+
end
|
207
|
+
|
208
|
+
class Operation
|
209
|
+
# @private
|
210
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
211
|
+
property :done, as: 'done'
|
212
|
+
property :error, as: 'error', class: Google::Apis::GkehubV1beta::GoogleRpcStatus, decorator: Google::Apis::GkehubV1beta::GoogleRpcStatus::Representation
|
213
|
+
|
214
|
+
hash :metadata, as: 'metadata'
|
215
|
+
property :name, as: 'name'
|
216
|
+
hash :response, as: 'response'
|
217
|
+
end
|
218
|
+
end
|
219
|
+
|
220
|
+
class OperationMetadata
|
221
|
+
# @private
|
222
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
223
|
+
property :api_version, as: 'apiVersion'
|
224
|
+
property :cancel_requested, as: 'cancelRequested'
|
225
|
+
property :create_time, as: 'createTime'
|
226
|
+
property :end_time, as: 'endTime'
|
227
|
+
property :status_detail, as: 'statusDetail'
|
228
|
+
property :target, as: 'target'
|
229
|
+
property :verb, as: 'verb'
|
230
|
+
end
|
231
|
+
end
|
232
|
+
|
233
|
+
class Policy
|
234
|
+
# @private
|
235
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
236
|
+
collection :audit_configs, as: 'auditConfigs', class: Google::Apis::GkehubV1beta::AuditConfig, decorator: Google::Apis::GkehubV1beta::AuditConfig::Representation
|
237
|
+
|
238
|
+
collection :bindings, as: 'bindings', class: Google::Apis::GkehubV1beta::Binding, decorator: Google::Apis::GkehubV1beta::Binding::Representation
|
239
|
+
|
240
|
+
property :etag, :base64 => true, as: 'etag'
|
241
|
+
property :version, as: 'version'
|
242
|
+
end
|
243
|
+
end
|
244
|
+
|
245
|
+
class SetIamPolicyRequest
|
246
|
+
# @private
|
247
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
248
|
+
property :policy, as: 'policy', class: Google::Apis::GkehubV1beta::Policy, decorator: Google::Apis::GkehubV1beta::Policy::Representation
|
249
|
+
|
250
|
+
property :update_mask, as: 'updateMask'
|
251
|
+
end
|
252
|
+
end
|
253
|
+
|
254
|
+
class TestIamPermissionsRequest
|
255
|
+
# @private
|
256
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
257
|
+
collection :permissions, as: 'permissions'
|
258
|
+
end
|
259
|
+
end
|
260
|
+
|
261
|
+
class TestIamPermissionsResponse
|
262
|
+
# @private
|
263
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
264
|
+
collection :permissions, as: 'permissions'
|
265
|
+
end
|
266
|
+
end
|
267
|
+
end
|
268
|
+
end
|
269
|
+
end
|
@@ -0,0 +1,514 @@
|
|
1
|
+
# Copyright 2020 Google LLC
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
15
|
+
require 'google/apis/core/base_service'
|
16
|
+
require 'google/apis/core/json_representation'
|
17
|
+
require 'google/apis/core/hashable'
|
18
|
+
require 'google/apis/errors'
|
19
|
+
|
20
|
+
module Google
|
21
|
+
module Apis
|
22
|
+
module GkehubV1beta
|
23
|
+
# GKE Hub
|
24
|
+
#
|
25
|
+
#
|
26
|
+
#
|
27
|
+
# @example
|
28
|
+
# require 'google/apis/gkehub_v1beta'
|
29
|
+
#
|
30
|
+
# Gkehub = Google::Apis::GkehubV1beta # Alias the module
|
31
|
+
# service = Gkehub::GKEHubService.new
|
32
|
+
#
|
33
|
+
# @see https://cloud.google.com/anthos/multicluster-management/connect/registering-a-cluster
|
34
|
+
class GKEHubService < Google::Apis::Core::BaseService
|
35
|
+
# @return [String]
|
36
|
+
# API key. Your API key identifies your project and provides you with API access,
|
37
|
+
# quota, and reports. Required unless you provide an OAuth 2.0 token.
|
38
|
+
attr_accessor :key
|
39
|
+
|
40
|
+
# @return [String]
|
41
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
42
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
43
|
+
attr_accessor :quota_user
|
44
|
+
|
45
|
+
def initialize
|
46
|
+
super('https://gkehub.googleapis.com/', '',
|
47
|
+
client_name: 'google-apis-gkehub_v1beta',
|
48
|
+
client_version: Google::Apis::GkehubV1beta::GEM_VERSION)
|
49
|
+
@batch_path = 'batch'
|
50
|
+
end
|
51
|
+
|
52
|
+
# Gets information about a location.
|
53
|
+
# @param [String] name
|
54
|
+
# Resource name for the location.
|
55
|
+
# @param [String] fields
|
56
|
+
# Selector specifying which fields to include in a partial response.
|
57
|
+
# @param [String] quota_user
|
58
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
59
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
60
|
+
# @param [Google::Apis::RequestOptions] options
|
61
|
+
# Request-specific options
|
62
|
+
#
|
63
|
+
# @yield [result, err] Result & error if block supplied
|
64
|
+
# @yieldparam result [Google::Apis::GkehubV1beta::Location] parsed result object
|
65
|
+
# @yieldparam err [StandardError] error object if request failed
|
66
|
+
#
|
67
|
+
# @return [Google::Apis::GkehubV1beta::Location]
|
68
|
+
#
|
69
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
70
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
71
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
72
|
+
def get_project_location(name, fields: nil, quota_user: nil, options: nil, &block)
|
73
|
+
command = make_simple_command(:get, 'v1beta/{+name}', options)
|
74
|
+
command.response_representation = Google::Apis::GkehubV1beta::Location::Representation
|
75
|
+
command.response_class = Google::Apis::GkehubV1beta::Location
|
76
|
+
command.params['name'] = name unless name.nil?
|
77
|
+
command.query['fields'] = fields unless fields.nil?
|
78
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
79
|
+
execute_or_queue_command(command, &block)
|
80
|
+
end
|
81
|
+
|
82
|
+
# Lists information about the supported locations for this service.
|
83
|
+
# @param [String] name
|
84
|
+
# The resource that owns the locations collection, if applicable.
|
85
|
+
# @param [String] filter
|
86
|
+
# A filter to narrow down results to a preferred subset. The filtering language
|
87
|
+
# accepts strings like "displayName=tokyo", and is documented in more detail in [
|
88
|
+
# AIP-160](https://google.aip.dev/160).
|
89
|
+
# @param [Fixnum] page_size
|
90
|
+
# The maximum number of results to return. If not set, the service will select a
|
91
|
+
# default.
|
92
|
+
# @param [String] page_token
|
93
|
+
# A page token received from the `next_page_token` field in the response. Send
|
94
|
+
# that page token to receive the subsequent page.
|
95
|
+
# @param [String] fields
|
96
|
+
# Selector specifying which fields to include in a partial response.
|
97
|
+
# @param [String] quota_user
|
98
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
99
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
100
|
+
# @param [Google::Apis::RequestOptions] options
|
101
|
+
# Request-specific options
|
102
|
+
#
|
103
|
+
# @yield [result, err] Result & error if block supplied
|
104
|
+
# @yieldparam result [Google::Apis::GkehubV1beta::ListLocationsResponse] parsed result object
|
105
|
+
# @yieldparam err [StandardError] error object if request failed
|
106
|
+
#
|
107
|
+
# @return [Google::Apis::GkehubV1beta::ListLocationsResponse]
|
108
|
+
#
|
109
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
110
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
111
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
112
|
+
def list_project_locations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
|
113
|
+
command = make_simple_command(:get, 'v1beta/{+name}/locations', options)
|
114
|
+
command.response_representation = Google::Apis::GkehubV1beta::ListLocationsResponse::Representation
|
115
|
+
command.response_class = Google::Apis::GkehubV1beta::ListLocationsResponse
|
116
|
+
command.params['name'] = name unless name.nil?
|
117
|
+
command.query['filter'] = filter unless filter.nil?
|
118
|
+
command.query['pageSize'] = page_size unless page_size.nil?
|
119
|
+
command.query['pageToken'] = page_token unless page_token.nil?
|
120
|
+
command.query['fields'] = fields unless fields.nil?
|
121
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
122
|
+
execute_or_queue_command(command, &block)
|
123
|
+
end
|
124
|
+
|
125
|
+
# Gets the access control policy for a resource. Returns an empty policy if the
|
126
|
+
# resource exists and does not have a policy set.
|
127
|
+
# @param [String] resource
|
128
|
+
# REQUIRED: The resource for which the policy is being requested. See the
|
129
|
+
# operation documentation for the appropriate value for this field.
|
130
|
+
# @param [Fixnum] options_requested_policy_version
|
131
|
+
# Optional. The policy format version to be returned. Valid values are 0, 1, and
|
132
|
+
# 3. Requests specifying an invalid value will be rejected. Requests for
|
133
|
+
# policies with any conditional bindings must specify version 3. Policies
|
134
|
+
# without any conditional bindings may specify any valid value or leave the
|
135
|
+
# field unset. To learn which resources support conditions in their IAM policies,
|
136
|
+
# see the [IAM documentation](https://cloud.google.com/iam/help/conditions/
|
137
|
+
# resource-policies).
|
138
|
+
# @param [String] fields
|
139
|
+
# Selector specifying which fields to include in a partial response.
|
140
|
+
# @param [String] quota_user
|
141
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
142
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
143
|
+
# @param [Google::Apis::RequestOptions] options
|
144
|
+
# Request-specific options
|
145
|
+
#
|
146
|
+
# @yield [result, err] Result & error if block supplied
|
147
|
+
# @yieldparam result [Google::Apis::GkehubV1beta::Policy] parsed result object
|
148
|
+
# @yieldparam err [StandardError] error object if request failed
|
149
|
+
#
|
150
|
+
# @return [Google::Apis::GkehubV1beta::Policy]
|
151
|
+
#
|
152
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
153
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
154
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
155
|
+
def get_project_location_feature_iam_policy(resource, options_requested_policy_version: nil, fields: nil, quota_user: nil, options: nil, &block)
|
156
|
+
command = make_simple_command(:get, 'v1beta/{+resource}:getIamPolicy', options)
|
157
|
+
command.response_representation = Google::Apis::GkehubV1beta::Policy::Representation
|
158
|
+
command.response_class = Google::Apis::GkehubV1beta::Policy
|
159
|
+
command.params['resource'] = resource unless resource.nil?
|
160
|
+
command.query['options.requestedPolicyVersion'] = options_requested_policy_version unless options_requested_policy_version.nil?
|
161
|
+
command.query['fields'] = fields unless fields.nil?
|
162
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
163
|
+
execute_or_queue_command(command, &block)
|
164
|
+
end
|
165
|
+
|
166
|
+
# Sets the access control policy on the specified resource. Replaces any
|
167
|
+
# existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `
|
168
|
+
# PERMISSION_DENIED` errors.
|
169
|
+
# @param [String] resource
|
170
|
+
# REQUIRED: The resource for which the policy is being specified. See the
|
171
|
+
# operation documentation for the appropriate value for this field.
|
172
|
+
# @param [Google::Apis::GkehubV1beta::SetIamPolicyRequest] set_iam_policy_request_object
|
173
|
+
# @param [String] fields
|
174
|
+
# Selector specifying which fields to include in a partial response.
|
175
|
+
# @param [String] quota_user
|
176
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
177
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
178
|
+
# @param [Google::Apis::RequestOptions] options
|
179
|
+
# Request-specific options
|
180
|
+
#
|
181
|
+
# @yield [result, err] Result & error if block supplied
|
182
|
+
# @yieldparam result [Google::Apis::GkehubV1beta::Policy] parsed result object
|
183
|
+
# @yieldparam err [StandardError] error object if request failed
|
184
|
+
#
|
185
|
+
# @return [Google::Apis::GkehubV1beta::Policy]
|
186
|
+
#
|
187
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
188
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
189
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
190
|
+
def set_feature_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
191
|
+
command = make_simple_command(:post, 'v1beta/{+resource}:setIamPolicy', options)
|
192
|
+
command.request_representation = Google::Apis::GkehubV1beta::SetIamPolicyRequest::Representation
|
193
|
+
command.request_object = set_iam_policy_request_object
|
194
|
+
command.response_representation = Google::Apis::GkehubV1beta::Policy::Representation
|
195
|
+
command.response_class = Google::Apis::GkehubV1beta::Policy
|
196
|
+
command.params['resource'] = resource unless resource.nil?
|
197
|
+
command.query['fields'] = fields unless fields.nil?
|
198
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
199
|
+
execute_or_queue_command(command, &block)
|
200
|
+
end
|
201
|
+
|
202
|
+
# Returns permissions that a caller has on the specified resource. If the
|
203
|
+
# resource does not exist, this will return an empty set of permissions, not a `
|
204
|
+
# NOT_FOUND` error. Note: This operation is designed to be used for building
|
205
|
+
# permission-aware UIs and command-line tools, not for authorization checking.
|
206
|
+
# This operation may "fail open" without warning.
|
207
|
+
# @param [String] resource
|
208
|
+
# REQUIRED: The resource for which the policy detail is being requested. See the
|
209
|
+
# operation documentation for the appropriate value for this field.
|
210
|
+
# @param [Google::Apis::GkehubV1beta::TestIamPermissionsRequest] test_iam_permissions_request_object
|
211
|
+
# @param [String] fields
|
212
|
+
# Selector specifying which fields to include in a partial response.
|
213
|
+
# @param [String] quota_user
|
214
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
215
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
216
|
+
# @param [Google::Apis::RequestOptions] options
|
217
|
+
# Request-specific options
|
218
|
+
#
|
219
|
+
# @yield [result, err] Result & error if block supplied
|
220
|
+
# @yieldparam result [Google::Apis::GkehubV1beta::TestIamPermissionsResponse] parsed result object
|
221
|
+
# @yieldparam err [StandardError] error object if request failed
|
222
|
+
#
|
223
|
+
# @return [Google::Apis::GkehubV1beta::TestIamPermissionsResponse]
|
224
|
+
#
|
225
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
226
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
227
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
228
|
+
def test_feature_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
229
|
+
command = make_simple_command(:post, 'v1beta/{+resource}:testIamPermissions', options)
|
230
|
+
command.request_representation = Google::Apis::GkehubV1beta::TestIamPermissionsRequest::Representation
|
231
|
+
command.request_object = test_iam_permissions_request_object
|
232
|
+
command.response_representation = Google::Apis::GkehubV1beta::TestIamPermissionsResponse::Representation
|
233
|
+
command.response_class = Google::Apis::GkehubV1beta::TestIamPermissionsResponse
|
234
|
+
command.params['resource'] = resource unless resource.nil?
|
235
|
+
command.query['fields'] = fields unless fields.nil?
|
236
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
237
|
+
execute_or_queue_command(command, &block)
|
238
|
+
end
|
239
|
+
|
240
|
+
# Gets the access control policy for a resource. Returns an empty policy if the
|
241
|
+
# resource exists and does not have a policy set.
|
242
|
+
# @param [String] resource
|
243
|
+
# REQUIRED: The resource for which the policy is being requested. See the
|
244
|
+
# operation documentation for the appropriate value for this field.
|
245
|
+
# @param [Fixnum] options_requested_policy_version
|
246
|
+
# Optional. The policy format version to be returned. Valid values are 0, 1, and
|
247
|
+
# 3. Requests specifying an invalid value will be rejected. Requests for
|
248
|
+
# policies with any conditional bindings must specify version 3. Policies
|
249
|
+
# without any conditional bindings may specify any valid value or leave the
|
250
|
+
# field unset. To learn which resources support conditions in their IAM policies,
|
251
|
+
# see the [IAM documentation](https://cloud.google.com/iam/help/conditions/
|
252
|
+
# resource-policies).
|
253
|
+
# @param [String] fields
|
254
|
+
# Selector specifying which fields to include in a partial response.
|
255
|
+
# @param [String] quota_user
|
256
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
257
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
258
|
+
# @param [Google::Apis::RequestOptions] options
|
259
|
+
# Request-specific options
|
260
|
+
#
|
261
|
+
# @yield [result, err] Result & error if block supplied
|
262
|
+
# @yieldparam result [Google::Apis::GkehubV1beta::Policy] parsed result object
|
263
|
+
# @yieldparam err [StandardError] error object if request failed
|
264
|
+
#
|
265
|
+
# @return [Google::Apis::GkehubV1beta::Policy]
|
266
|
+
#
|
267
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
268
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
269
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
270
|
+
def get_project_location_membership_iam_policy(resource, options_requested_policy_version: nil, fields: nil, quota_user: nil, options: nil, &block)
|
271
|
+
command = make_simple_command(:get, 'v1beta/{+resource}:getIamPolicy', options)
|
272
|
+
command.response_representation = Google::Apis::GkehubV1beta::Policy::Representation
|
273
|
+
command.response_class = Google::Apis::GkehubV1beta::Policy
|
274
|
+
command.params['resource'] = resource unless resource.nil?
|
275
|
+
command.query['options.requestedPolicyVersion'] = options_requested_policy_version unless options_requested_policy_version.nil?
|
276
|
+
command.query['fields'] = fields unless fields.nil?
|
277
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
278
|
+
execute_or_queue_command(command, &block)
|
279
|
+
end
|
280
|
+
|
281
|
+
# Sets the access control policy on the specified resource. Replaces any
|
282
|
+
# existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `
|
283
|
+
# PERMISSION_DENIED` errors.
|
284
|
+
# @param [String] resource
|
285
|
+
# REQUIRED: The resource for which the policy is being specified. See the
|
286
|
+
# operation documentation for the appropriate value for this field.
|
287
|
+
# @param [Google::Apis::GkehubV1beta::SetIamPolicyRequest] set_iam_policy_request_object
|
288
|
+
# @param [String] fields
|
289
|
+
# Selector specifying which fields to include in a partial response.
|
290
|
+
# @param [String] quota_user
|
291
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
292
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
293
|
+
# @param [Google::Apis::RequestOptions] options
|
294
|
+
# Request-specific options
|
295
|
+
#
|
296
|
+
# @yield [result, err] Result & error if block supplied
|
297
|
+
# @yieldparam result [Google::Apis::GkehubV1beta::Policy] parsed result object
|
298
|
+
# @yieldparam err [StandardError] error object if request failed
|
299
|
+
#
|
300
|
+
# @return [Google::Apis::GkehubV1beta::Policy]
|
301
|
+
#
|
302
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
303
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
304
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
305
|
+
def set_membership_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
306
|
+
command = make_simple_command(:post, 'v1beta/{+resource}:setIamPolicy', options)
|
307
|
+
command.request_representation = Google::Apis::GkehubV1beta::SetIamPolicyRequest::Representation
|
308
|
+
command.request_object = set_iam_policy_request_object
|
309
|
+
command.response_representation = Google::Apis::GkehubV1beta::Policy::Representation
|
310
|
+
command.response_class = Google::Apis::GkehubV1beta::Policy
|
311
|
+
command.params['resource'] = resource unless resource.nil?
|
312
|
+
command.query['fields'] = fields unless fields.nil?
|
313
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
314
|
+
execute_or_queue_command(command, &block)
|
315
|
+
end
|
316
|
+
|
317
|
+
# Returns permissions that a caller has on the specified resource. If the
|
318
|
+
# resource does not exist, this will return an empty set of permissions, not a `
|
319
|
+
# NOT_FOUND` error. Note: This operation is designed to be used for building
|
320
|
+
# permission-aware UIs and command-line tools, not for authorization checking.
|
321
|
+
# This operation may "fail open" without warning.
|
322
|
+
# @param [String] resource
|
323
|
+
# REQUIRED: The resource for which the policy detail is being requested. See the
|
324
|
+
# operation documentation for the appropriate value for this field.
|
325
|
+
# @param [Google::Apis::GkehubV1beta::TestIamPermissionsRequest] test_iam_permissions_request_object
|
326
|
+
# @param [String] fields
|
327
|
+
# Selector specifying which fields to include in a partial response.
|
328
|
+
# @param [String] quota_user
|
329
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
330
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
331
|
+
# @param [Google::Apis::RequestOptions] options
|
332
|
+
# Request-specific options
|
333
|
+
#
|
334
|
+
# @yield [result, err] Result & error if block supplied
|
335
|
+
# @yieldparam result [Google::Apis::GkehubV1beta::TestIamPermissionsResponse] parsed result object
|
336
|
+
# @yieldparam err [StandardError] error object if request failed
|
337
|
+
#
|
338
|
+
# @return [Google::Apis::GkehubV1beta::TestIamPermissionsResponse]
|
339
|
+
#
|
340
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
341
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
342
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
343
|
+
def test_membership_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
344
|
+
command = make_simple_command(:post, 'v1beta/{+resource}:testIamPermissions', options)
|
345
|
+
command.request_representation = Google::Apis::GkehubV1beta::TestIamPermissionsRequest::Representation
|
346
|
+
command.request_object = test_iam_permissions_request_object
|
347
|
+
command.response_representation = Google::Apis::GkehubV1beta::TestIamPermissionsResponse::Representation
|
348
|
+
command.response_class = Google::Apis::GkehubV1beta::TestIamPermissionsResponse
|
349
|
+
command.params['resource'] = resource unless resource.nil?
|
350
|
+
command.query['fields'] = fields unless fields.nil?
|
351
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
352
|
+
execute_or_queue_command(command, &block)
|
353
|
+
end
|
354
|
+
|
355
|
+
# Starts asynchronous cancellation on a long-running operation. The server makes
|
356
|
+
# a best effort to cancel the operation, but success is not guaranteed. If the
|
357
|
+
# server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.
|
358
|
+
# Clients can use Operations.GetOperation or other methods to check whether the
|
359
|
+
# cancellation succeeded or whether the operation completed despite cancellation.
|
360
|
+
# On successful cancellation, the operation is not deleted; instead, it becomes
|
361
|
+
# an operation with an Operation.error value with a google.rpc.Status.code of 1,
|
362
|
+
# corresponding to `Code.CANCELLED`.
|
363
|
+
# @param [String] name
|
364
|
+
# The name of the operation resource to be cancelled.
|
365
|
+
# @param [Google::Apis::GkehubV1beta::CancelOperationRequest] cancel_operation_request_object
|
366
|
+
# @param [String] fields
|
367
|
+
# Selector specifying which fields to include in a partial response.
|
368
|
+
# @param [String] quota_user
|
369
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
370
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
371
|
+
# @param [Google::Apis::RequestOptions] options
|
372
|
+
# Request-specific options
|
373
|
+
#
|
374
|
+
# @yield [result, err] Result & error if block supplied
|
375
|
+
# @yieldparam result [Google::Apis::GkehubV1beta::Empty] parsed result object
|
376
|
+
# @yieldparam err [StandardError] error object if request failed
|
377
|
+
#
|
378
|
+
# @return [Google::Apis::GkehubV1beta::Empty]
|
379
|
+
#
|
380
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
381
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
382
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
383
|
+
def cancel_operation(name, cancel_operation_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
384
|
+
command = make_simple_command(:post, 'v1beta/{+name}:cancel', options)
|
385
|
+
command.request_representation = Google::Apis::GkehubV1beta::CancelOperationRequest::Representation
|
386
|
+
command.request_object = cancel_operation_request_object
|
387
|
+
command.response_representation = Google::Apis::GkehubV1beta::Empty::Representation
|
388
|
+
command.response_class = Google::Apis::GkehubV1beta::Empty
|
389
|
+
command.params['name'] = name unless name.nil?
|
390
|
+
command.query['fields'] = fields unless fields.nil?
|
391
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
392
|
+
execute_or_queue_command(command, &block)
|
393
|
+
end
|
394
|
+
|
395
|
+
# Deletes a long-running operation. This method indicates that the client is no
|
396
|
+
# longer interested in the operation result. It does not cancel the operation.
|
397
|
+
# If the server doesn't support this method, it returns `google.rpc.Code.
|
398
|
+
# UNIMPLEMENTED`.
|
399
|
+
# @param [String] name
|
400
|
+
# The name of the operation resource to be deleted.
|
401
|
+
# @param [String] fields
|
402
|
+
# Selector specifying which fields to include in a partial response.
|
403
|
+
# @param [String] quota_user
|
404
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
405
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
406
|
+
# @param [Google::Apis::RequestOptions] options
|
407
|
+
# Request-specific options
|
408
|
+
#
|
409
|
+
# @yield [result, err] Result & error if block supplied
|
410
|
+
# @yieldparam result [Google::Apis::GkehubV1beta::Empty] parsed result object
|
411
|
+
# @yieldparam err [StandardError] error object if request failed
|
412
|
+
#
|
413
|
+
# @return [Google::Apis::GkehubV1beta::Empty]
|
414
|
+
#
|
415
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
416
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
417
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
418
|
+
def delete_project_location_operation(name, fields: nil, quota_user: nil, options: nil, &block)
|
419
|
+
command = make_simple_command(:delete, 'v1beta/{+name}', options)
|
420
|
+
command.response_representation = Google::Apis::GkehubV1beta::Empty::Representation
|
421
|
+
command.response_class = Google::Apis::GkehubV1beta::Empty
|
422
|
+
command.params['name'] = name unless name.nil?
|
423
|
+
command.query['fields'] = fields unless fields.nil?
|
424
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
425
|
+
execute_or_queue_command(command, &block)
|
426
|
+
end
|
427
|
+
|
428
|
+
# Gets the latest state of a long-running operation. Clients can use this method
|
429
|
+
# to poll the operation result at intervals as recommended by the API service.
|
430
|
+
# @param [String] name
|
431
|
+
# The name of the operation resource.
|
432
|
+
# @param [String] fields
|
433
|
+
# Selector specifying which fields to include in a partial response.
|
434
|
+
# @param [String] quota_user
|
435
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
436
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
437
|
+
# @param [Google::Apis::RequestOptions] options
|
438
|
+
# Request-specific options
|
439
|
+
#
|
440
|
+
# @yield [result, err] Result & error if block supplied
|
441
|
+
# @yieldparam result [Google::Apis::GkehubV1beta::Operation] parsed result object
|
442
|
+
# @yieldparam err [StandardError] error object if request failed
|
443
|
+
#
|
444
|
+
# @return [Google::Apis::GkehubV1beta::Operation]
|
445
|
+
#
|
446
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
447
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
448
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
449
|
+
def get_project_location_operation(name, fields: nil, quota_user: nil, options: nil, &block)
|
450
|
+
command = make_simple_command(:get, 'v1beta/{+name}', options)
|
451
|
+
command.response_representation = Google::Apis::GkehubV1beta::Operation::Representation
|
452
|
+
command.response_class = Google::Apis::GkehubV1beta::Operation
|
453
|
+
command.params['name'] = name unless name.nil?
|
454
|
+
command.query['fields'] = fields unless fields.nil?
|
455
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
456
|
+
execute_or_queue_command(command, &block)
|
457
|
+
end
|
458
|
+
|
459
|
+
# Lists operations that match the specified filter in the request. If the server
|
460
|
+
# doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name`
|
461
|
+
# binding allows API services to override the binding to use different resource
|
462
|
+
# name schemes, such as `users/*/operations`. To override the binding, API
|
463
|
+
# services can add a binding such as `"/v1/`name=users/*`/operations"` to their
|
464
|
+
# service configuration. For backwards compatibility, the default name includes
|
465
|
+
# the operations collection id, however overriding users must ensure the name
|
466
|
+
# binding is the parent resource, without the operations collection id.
|
467
|
+
# @param [String] name
|
468
|
+
# The name of the operation's parent resource.
|
469
|
+
# @param [String] filter
|
470
|
+
# The standard list filter.
|
471
|
+
# @param [Fixnum] page_size
|
472
|
+
# The standard list page size.
|
473
|
+
# @param [String] page_token
|
474
|
+
# The standard list page token.
|
475
|
+
# @param [String] fields
|
476
|
+
# Selector specifying which fields to include in a partial response.
|
477
|
+
# @param [String] quota_user
|
478
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
479
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
480
|
+
# @param [Google::Apis::RequestOptions] options
|
481
|
+
# Request-specific options
|
482
|
+
#
|
483
|
+
# @yield [result, err] Result & error if block supplied
|
484
|
+
# @yieldparam result [Google::Apis::GkehubV1beta::ListOperationsResponse] parsed result object
|
485
|
+
# @yieldparam err [StandardError] error object if request failed
|
486
|
+
#
|
487
|
+
# @return [Google::Apis::GkehubV1beta::ListOperationsResponse]
|
488
|
+
#
|
489
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
490
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
491
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
492
|
+
def list_project_location_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
|
493
|
+
command = make_simple_command(:get, 'v1beta/{+name}/operations', options)
|
494
|
+
command.response_representation = Google::Apis::GkehubV1beta::ListOperationsResponse::Representation
|
495
|
+
command.response_class = Google::Apis::GkehubV1beta::ListOperationsResponse
|
496
|
+
command.params['name'] = name unless name.nil?
|
497
|
+
command.query['filter'] = filter unless filter.nil?
|
498
|
+
command.query['pageSize'] = page_size unless page_size.nil?
|
499
|
+
command.query['pageToken'] = page_token unless page_token.nil?
|
500
|
+
command.query['fields'] = fields unless fields.nil?
|
501
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
502
|
+
execute_or_queue_command(command, &block)
|
503
|
+
end
|
504
|
+
|
505
|
+
protected
|
506
|
+
|
507
|
+
def apply_command_defaults(command)
|
508
|
+
command.query['key'] = key unless key.nil?
|
509
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
510
|
+
end
|
511
|
+
end
|
512
|
+
end
|
513
|
+
end
|
514
|
+
end
|