google-iam-v3 0.a → 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 +4 -4
- data/.yardopts +12 -0
- data/AUTHENTICATION.md +122 -0
- data/README.md +154 -8
- data/lib/google/iam/v3/operation_metadata_pb.rb +44 -0
- data/lib/google/iam/v3/policy_binding_resources_pb.rb +50 -0
- data/lib/google/iam/v3/policy_bindings/client.rb +1130 -0
- data/lib/google/iam/v3/policy_bindings/credentials.rb +45 -0
- data/lib/google/iam/v3/policy_bindings/operations.rb +811 -0
- data/lib/google/iam/v3/policy_bindings/paths.rb +140 -0
- data/lib/google/iam/v3/policy_bindings/rest/client.rb +1062 -0
- data/lib/google/iam/v3/policy_bindings/rest/operations.rb +926 -0
- data/lib/google/iam/v3/policy_bindings/rest/service_stub.rb +535 -0
- data/lib/google/iam/v3/policy_bindings/rest.rb +52 -0
- data/lib/google/iam/v3/policy_bindings.rb +55 -0
- data/lib/google/iam/v3/policy_bindings_service_pb.rb +59 -0
- data/lib/google/iam/v3/policy_bindings_service_services_pb.rb +63 -0
- data/lib/google/iam/v3/principal_access_boundary_policies/client.rb +1083 -0
- data/lib/google/iam/v3/principal_access_boundary_policies/credentials.rb +45 -0
- data/lib/google/iam/v3/principal_access_boundary_policies/operations.rb +811 -0
- data/lib/google/iam/v3/principal_access_boundary_policies/paths.rb +67 -0
- data/lib/google/iam/v3/principal_access_boundary_policies/rest/client.rb +1015 -0
- data/lib/google/iam/v3/principal_access_boundary_policies/rest/operations.rb +926 -0
- data/lib/google/iam/v3/principal_access_boundary_policies/rest/service_stub.rb +447 -0
- data/lib/google/iam/v3/principal_access_boundary_policies/rest.rb +52 -0
- data/lib/google/iam/v3/principal_access_boundary_policies.rb +55 -0
- data/lib/google/iam/v3/principal_access_boundary_policies_service_pb.rb +61 -0
- data/lib/google/iam/v3/principal_access_boundary_policies_service_services_pb.rb +56 -0
- data/lib/google/iam/v3/principal_access_boundary_policy_resources_pb.rb +49 -0
- data/lib/google/iam/v3/rest.rb +36 -0
- data/lib/google/iam/v3/version.rb +7 -2
- data/lib/google/iam/v3.rb +44 -0
- data/lib/google-iam-v3.rb +21 -0
- data/proto_docs/README.md +4 -0
- data/proto_docs/google/api/client.rb +473 -0
- data/proto_docs/google/api/field_behavior.rb +85 -0
- data/proto_docs/google/api/field_info.rb +88 -0
- data/proto_docs/google/api/launch_stage.rb +71 -0
- data/proto_docs/google/api/resource.rb +227 -0
- data/proto_docs/google/iam/v3/operation_metadata.rb +55 -0
- data/proto_docs/google/iam/v3/policy_binding_resources.rb +171 -0
- data/proto_docs/google/iam/v3/policy_bindings_service.rb +232 -0
- data/proto_docs/google/iam/v3/principal_access_boundary_policies_service.rb +191 -0
- data/proto_docs/google/iam/v3/principal_access_boundary_policy_resources.rb +127 -0
- data/proto_docs/google/longrunning/operations.rb +173 -0
- data/proto_docs/google/protobuf/any.rb +145 -0
- data/proto_docs/google/protobuf/duration.rb +98 -0
- data/proto_docs/google/protobuf/empty.rb +34 -0
- data/proto_docs/google/protobuf/field_mask.rb +229 -0
- data/proto_docs/google/protobuf/timestamp.rb +127 -0
- data/proto_docs/google/rpc/status.rb +48 -0
- data/proto_docs/google/type/expr.rb +75 -0
- metadata +107 -10
@@ -0,0 +1,447 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2025 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
require "google/iam/v3/principal_access_boundary_policies_service_pb"
|
20
|
+
|
21
|
+
module Google
|
22
|
+
module Iam
|
23
|
+
module V3
|
24
|
+
module PrincipalAccessBoundaryPolicies
|
25
|
+
module Rest
|
26
|
+
##
|
27
|
+
# REST service stub for the PrincipalAccessBoundaryPolicies service.
|
28
|
+
# Service stub contains baseline method implementations
|
29
|
+
# including transcoding, making the REST call, and deserialing the response.
|
30
|
+
#
|
31
|
+
class ServiceStub
|
32
|
+
# @private
|
33
|
+
def initialize endpoint:, endpoint_template:, universe_domain:, credentials:, logger:
|
34
|
+
# These require statements are intentionally placed here to initialize
|
35
|
+
# the REST modules only when it's required.
|
36
|
+
require "gapic/rest"
|
37
|
+
|
38
|
+
@client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint,
|
39
|
+
endpoint_template: endpoint_template,
|
40
|
+
universe_domain: universe_domain,
|
41
|
+
credentials: credentials,
|
42
|
+
numeric_enums: true,
|
43
|
+
service_name: self.class,
|
44
|
+
raise_faraday_errors: false,
|
45
|
+
logger: logger
|
46
|
+
end
|
47
|
+
|
48
|
+
##
|
49
|
+
# The effective universe domain
|
50
|
+
#
|
51
|
+
# @return [String]
|
52
|
+
#
|
53
|
+
def universe_domain
|
54
|
+
@client_stub.universe_domain
|
55
|
+
end
|
56
|
+
|
57
|
+
##
|
58
|
+
# The effective endpoint
|
59
|
+
#
|
60
|
+
# @return [String]
|
61
|
+
#
|
62
|
+
def endpoint
|
63
|
+
@client_stub.endpoint
|
64
|
+
end
|
65
|
+
|
66
|
+
##
|
67
|
+
# The logger used for request/response debug logging.
|
68
|
+
#
|
69
|
+
# @return [Logger]
|
70
|
+
#
|
71
|
+
def logger stub: false
|
72
|
+
stub ? @client_stub.stub_logger : @client_stub.logger
|
73
|
+
end
|
74
|
+
|
75
|
+
##
|
76
|
+
# Baseline implementation for the create_principal_access_boundary_policy REST call
|
77
|
+
#
|
78
|
+
# @param request_pb [::Google::Iam::V3::CreatePrincipalAccessBoundaryPolicyRequest]
|
79
|
+
# A request object representing the call parameters. Required.
|
80
|
+
# @param options [::Gapic::CallOptions]
|
81
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
82
|
+
#
|
83
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
84
|
+
# @yieldparam result [::Google::Longrunning::Operation]
|
85
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
86
|
+
#
|
87
|
+
# @return [::Google::Longrunning::Operation]
|
88
|
+
# A result object deserialized from the server's reply
|
89
|
+
def create_principal_access_boundary_policy request_pb, options = nil
|
90
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
91
|
+
|
92
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_create_principal_access_boundary_policy_request request_pb
|
93
|
+
query_string_params = if query_string_params.any?
|
94
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
95
|
+
else
|
96
|
+
{}
|
97
|
+
end
|
98
|
+
|
99
|
+
response = @client_stub.make_http_request(
|
100
|
+
verb,
|
101
|
+
uri: uri,
|
102
|
+
body: body || "",
|
103
|
+
params: query_string_params,
|
104
|
+
method_name: "create_principal_access_boundary_policy",
|
105
|
+
options: options
|
106
|
+
)
|
107
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
108
|
+
result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
|
109
|
+
catch :response do
|
110
|
+
yield result, operation if block_given?
|
111
|
+
result
|
112
|
+
end
|
113
|
+
end
|
114
|
+
|
115
|
+
##
|
116
|
+
# Baseline implementation for the get_principal_access_boundary_policy REST call
|
117
|
+
#
|
118
|
+
# @param request_pb [::Google::Iam::V3::GetPrincipalAccessBoundaryPolicyRequest]
|
119
|
+
# A request object representing the call parameters. Required.
|
120
|
+
# @param options [::Gapic::CallOptions]
|
121
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
122
|
+
#
|
123
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
124
|
+
# @yieldparam result [::Google::Iam::V3::PrincipalAccessBoundaryPolicy]
|
125
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
126
|
+
#
|
127
|
+
# @return [::Google::Iam::V3::PrincipalAccessBoundaryPolicy]
|
128
|
+
# A result object deserialized from the server's reply
|
129
|
+
def get_principal_access_boundary_policy request_pb, options = nil
|
130
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
131
|
+
|
132
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_principal_access_boundary_policy_request request_pb
|
133
|
+
query_string_params = if query_string_params.any?
|
134
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
135
|
+
else
|
136
|
+
{}
|
137
|
+
end
|
138
|
+
|
139
|
+
response = @client_stub.make_http_request(
|
140
|
+
verb,
|
141
|
+
uri: uri,
|
142
|
+
body: body || "",
|
143
|
+
params: query_string_params,
|
144
|
+
method_name: "get_principal_access_boundary_policy",
|
145
|
+
options: options
|
146
|
+
)
|
147
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
148
|
+
result = ::Google::Iam::V3::PrincipalAccessBoundaryPolicy.decode_json response.body, ignore_unknown_fields: true
|
149
|
+
catch :response do
|
150
|
+
yield result, operation if block_given?
|
151
|
+
result
|
152
|
+
end
|
153
|
+
end
|
154
|
+
|
155
|
+
##
|
156
|
+
# Baseline implementation for the update_principal_access_boundary_policy REST call
|
157
|
+
#
|
158
|
+
# @param request_pb [::Google::Iam::V3::UpdatePrincipalAccessBoundaryPolicyRequest]
|
159
|
+
# A request object representing the call parameters. Required.
|
160
|
+
# @param options [::Gapic::CallOptions]
|
161
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
162
|
+
#
|
163
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
164
|
+
# @yieldparam result [::Google::Longrunning::Operation]
|
165
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
166
|
+
#
|
167
|
+
# @return [::Google::Longrunning::Operation]
|
168
|
+
# A result object deserialized from the server's reply
|
169
|
+
def update_principal_access_boundary_policy request_pb, options = nil
|
170
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
171
|
+
|
172
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_update_principal_access_boundary_policy_request request_pb
|
173
|
+
query_string_params = if query_string_params.any?
|
174
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
175
|
+
else
|
176
|
+
{}
|
177
|
+
end
|
178
|
+
|
179
|
+
response = @client_stub.make_http_request(
|
180
|
+
verb,
|
181
|
+
uri: uri,
|
182
|
+
body: body || "",
|
183
|
+
params: query_string_params,
|
184
|
+
method_name: "update_principal_access_boundary_policy",
|
185
|
+
options: options
|
186
|
+
)
|
187
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
188
|
+
result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
|
189
|
+
catch :response do
|
190
|
+
yield result, operation if block_given?
|
191
|
+
result
|
192
|
+
end
|
193
|
+
end
|
194
|
+
|
195
|
+
##
|
196
|
+
# Baseline implementation for the delete_principal_access_boundary_policy REST call
|
197
|
+
#
|
198
|
+
# @param request_pb [::Google::Iam::V3::DeletePrincipalAccessBoundaryPolicyRequest]
|
199
|
+
# A request object representing the call parameters. Required.
|
200
|
+
# @param options [::Gapic::CallOptions]
|
201
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
202
|
+
#
|
203
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
204
|
+
# @yieldparam result [::Google::Longrunning::Operation]
|
205
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
206
|
+
#
|
207
|
+
# @return [::Google::Longrunning::Operation]
|
208
|
+
# A result object deserialized from the server's reply
|
209
|
+
def delete_principal_access_boundary_policy request_pb, options = nil
|
210
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
211
|
+
|
212
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_delete_principal_access_boundary_policy_request request_pb
|
213
|
+
query_string_params = if query_string_params.any?
|
214
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
215
|
+
else
|
216
|
+
{}
|
217
|
+
end
|
218
|
+
|
219
|
+
response = @client_stub.make_http_request(
|
220
|
+
verb,
|
221
|
+
uri: uri,
|
222
|
+
body: body || "",
|
223
|
+
params: query_string_params,
|
224
|
+
method_name: "delete_principal_access_boundary_policy",
|
225
|
+
options: options
|
226
|
+
)
|
227
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
228
|
+
result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
|
229
|
+
catch :response do
|
230
|
+
yield result, operation if block_given?
|
231
|
+
result
|
232
|
+
end
|
233
|
+
end
|
234
|
+
|
235
|
+
##
|
236
|
+
# Baseline implementation for the list_principal_access_boundary_policies REST call
|
237
|
+
#
|
238
|
+
# @param request_pb [::Google::Iam::V3::ListPrincipalAccessBoundaryPoliciesRequest]
|
239
|
+
# A request object representing the call parameters. Required.
|
240
|
+
# @param options [::Gapic::CallOptions]
|
241
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
242
|
+
#
|
243
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
244
|
+
# @yieldparam result [::Google::Iam::V3::ListPrincipalAccessBoundaryPoliciesResponse]
|
245
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
246
|
+
#
|
247
|
+
# @return [::Google::Iam::V3::ListPrincipalAccessBoundaryPoliciesResponse]
|
248
|
+
# A result object deserialized from the server's reply
|
249
|
+
def list_principal_access_boundary_policies request_pb, options = nil
|
250
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
251
|
+
|
252
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_list_principal_access_boundary_policies_request request_pb
|
253
|
+
query_string_params = if query_string_params.any?
|
254
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
255
|
+
else
|
256
|
+
{}
|
257
|
+
end
|
258
|
+
|
259
|
+
response = @client_stub.make_http_request(
|
260
|
+
verb,
|
261
|
+
uri: uri,
|
262
|
+
body: body || "",
|
263
|
+
params: query_string_params,
|
264
|
+
method_name: "list_principal_access_boundary_policies",
|
265
|
+
options: options
|
266
|
+
)
|
267
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
268
|
+
result = ::Google::Iam::V3::ListPrincipalAccessBoundaryPoliciesResponse.decode_json response.body, ignore_unknown_fields: true
|
269
|
+
catch :response do
|
270
|
+
yield result, operation if block_given?
|
271
|
+
result
|
272
|
+
end
|
273
|
+
end
|
274
|
+
|
275
|
+
##
|
276
|
+
# Baseline implementation for the search_principal_access_boundary_policy_bindings REST call
|
277
|
+
#
|
278
|
+
# @param request_pb [::Google::Iam::V3::SearchPrincipalAccessBoundaryPolicyBindingsRequest]
|
279
|
+
# A request object representing the call parameters. Required.
|
280
|
+
# @param options [::Gapic::CallOptions]
|
281
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
282
|
+
#
|
283
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
284
|
+
# @yieldparam result [::Google::Iam::V3::SearchPrincipalAccessBoundaryPolicyBindingsResponse]
|
285
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
286
|
+
#
|
287
|
+
# @return [::Google::Iam::V3::SearchPrincipalAccessBoundaryPolicyBindingsResponse]
|
288
|
+
# A result object deserialized from the server's reply
|
289
|
+
def search_principal_access_boundary_policy_bindings request_pb, options = nil
|
290
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
291
|
+
|
292
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_search_principal_access_boundary_policy_bindings_request request_pb
|
293
|
+
query_string_params = if query_string_params.any?
|
294
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
295
|
+
else
|
296
|
+
{}
|
297
|
+
end
|
298
|
+
|
299
|
+
response = @client_stub.make_http_request(
|
300
|
+
verb,
|
301
|
+
uri: uri,
|
302
|
+
body: body || "",
|
303
|
+
params: query_string_params,
|
304
|
+
method_name: "search_principal_access_boundary_policy_bindings",
|
305
|
+
options: options
|
306
|
+
)
|
307
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
308
|
+
result = ::Google::Iam::V3::SearchPrincipalAccessBoundaryPolicyBindingsResponse.decode_json response.body, ignore_unknown_fields: true
|
309
|
+
catch :response do
|
310
|
+
yield result, operation if block_given?
|
311
|
+
result
|
312
|
+
end
|
313
|
+
end
|
314
|
+
|
315
|
+
##
|
316
|
+
# @private
|
317
|
+
#
|
318
|
+
# GRPC transcoding helper method for the create_principal_access_boundary_policy REST call
|
319
|
+
#
|
320
|
+
# @param request_pb [::Google::Iam::V3::CreatePrincipalAccessBoundaryPolicyRequest]
|
321
|
+
# A request object representing the call parameters. Required.
|
322
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
323
|
+
# Uri, Body, Query string parameters
|
324
|
+
def self.transcode_create_principal_access_boundary_policy_request request_pb
|
325
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
326
|
+
.with_bindings(
|
327
|
+
uri_method: :post,
|
328
|
+
uri_template: "/v3/{parent}/principalAccessBoundaryPolicies",
|
329
|
+
body: "principal_access_boundary_policy",
|
330
|
+
matches: [
|
331
|
+
["parent", %r{^organizations/[^/]+/locations/[^/]+/?$}, false]
|
332
|
+
]
|
333
|
+
)
|
334
|
+
transcoder.transcode request_pb
|
335
|
+
end
|
336
|
+
|
337
|
+
##
|
338
|
+
# @private
|
339
|
+
#
|
340
|
+
# GRPC transcoding helper method for the get_principal_access_boundary_policy REST call
|
341
|
+
#
|
342
|
+
# @param request_pb [::Google::Iam::V3::GetPrincipalAccessBoundaryPolicyRequest]
|
343
|
+
# A request object representing the call parameters. Required.
|
344
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
345
|
+
# Uri, Body, Query string parameters
|
346
|
+
def self.transcode_get_principal_access_boundary_policy_request request_pb
|
347
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
348
|
+
.with_bindings(
|
349
|
+
uri_method: :get,
|
350
|
+
uri_template: "/v3/{name}",
|
351
|
+
matches: [
|
352
|
+
["name", %r{^organizations/[^/]+/locations/[^/]+/principalAccessBoundaryPolicies/[^/]+/?$}, false]
|
353
|
+
]
|
354
|
+
)
|
355
|
+
transcoder.transcode request_pb
|
356
|
+
end
|
357
|
+
|
358
|
+
##
|
359
|
+
# @private
|
360
|
+
#
|
361
|
+
# GRPC transcoding helper method for the update_principal_access_boundary_policy REST call
|
362
|
+
#
|
363
|
+
# @param request_pb [::Google::Iam::V3::UpdatePrincipalAccessBoundaryPolicyRequest]
|
364
|
+
# A request object representing the call parameters. Required.
|
365
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
366
|
+
# Uri, Body, Query string parameters
|
367
|
+
def self.transcode_update_principal_access_boundary_policy_request request_pb
|
368
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
369
|
+
.with_bindings(
|
370
|
+
uri_method: :patch,
|
371
|
+
uri_template: "/v3/{principal_access_boundary_policy.name}",
|
372
|
+
body: "principal_access_boundary_policy",
|
373
|
+
matches: [
|
374
|
+
["principal_access_boundary_policy.name", %r{^organizations/[^/]+/locations/[^/]+/principalAccessBoundaryPolicies/[^/]+/?$}, false]
|
375
|
+
]
|
376
|
+
)
|
377
|
+
transcoder.transcode request_pb
|
378
|
+
end
|
379
|
+
|
380
|
+
##
|
381
|
+
# @private
|
382
|
+
#
|
383
|
+
# GRPC transcoding helper method for the delete_principal_access_boundary_policy REST call
|
384
|
+
#
|
385
|
+
# @param request_pb [::Google::Iam::V3::DeletePrincipalAccessBoundaryPolicyRequest]
|
386
|
+
# A request object representing the call parameters. Required.
|
387
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
388
|
+
# Uri, Body, Query string parameters
|
389
|
+
def self.transcode_delete_principal_access_boundary_policy_request request_pb
|
390
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
391
|
+
.with_bindings(
|
392
|
+
uri_method: :delete,
|
393
|
+
uri_template: "/v3/{name}",
|
394
|
+
matches: [
|
395
|
+
["name", %r{^organizations/[^/]+/locations/[^/]+/principalAccessBoundaryPolicies/[^/]+/?$}, false]
|
396
|
+
]
|
397
|
+
)
|
398
|
+
transcoder.transcode request_pb
|
399
|
+
end
|
400
|
+
|
401
|
+
##
|
402
|
+
# @private
|
403
|
+
#
|
404
|
+
# GRPC transcoding helper method for the list_principal_access_boundary_policies REST call
|
405
|
+
#
|
406
|
+
# @param request_pb [::Google::Iam::V3::ListPrincipalAccessBoundaryPoliciesRequest]
|
407
|
+
# A request object representing the call parameters. Required.
|
408
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
409
|
+
# Uri, Body, Query string parameters
|
410
|
+
def self.transcode_list_principal_access_boundary_policies_request request_pb
|
411
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
412
|
+
.with_bindings(
|
413
|
+
uri_method: :get,
|
414
|
+
uri_template: "/v3/{parent}/principalAccessBoundaryPolicies",
|
415
|
+
matches: [
|
416
|
+
["parent", %r{^organizations/[^/]+/locations/[^/]+/?$}, false]
|
417
|
+
]
|
418
|
+
)
|
419
|
+
transcoder.transcode request_pb
|
420
|
+
end
|
421
|
+
|
422
|
+
##
|
423
|
+
# @private
|
424
|
+
#
|
425
|
+
# GRPC transcoding helper method for the search_principal_access_boundary_policy_bindings REST call
|
426
|
+
#
|
427
|
+
# @param request_pb [::Google::Iam::V3::SearchPrincipalAccessBoundaryPolicyBindingsRequest]
|
428
|
+
# A request object representing the call parameters. Required.
|
429
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
430
|
+
# Uri, Body, Query string parameters
|
431
|
+
def self.transcode_search_principal_access_boundary_policy_bindings_request request_pb
|
432
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
433
|
+
.with_bindings(
|
434
|
+
uri_method: :get,
|
435
|
+
uri_template: "/v3/{name}:searchPolicyBindings",
|
436
|
+
matches: [
|
437
|
+
["name", %r{^organizations/[^/]+/locations/[^/]+/principalAccessBoundaryPolicies/[^/]+/?$}, false]
|
438
|
+
]
|
439
|
+
)
|
440
|
+
transcoder.transcode request_pb
|
441
|
+
end
|
442
|
+
end
|
443
|
+
end
|
444
|
+
end
|
445
|
+
end
|
446
|
+
end
|
447
|
+
end
|
@@ -0,0 +1,52 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2025 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
require "gapic/rest"
|
20
|
+
require "gapic/config"
|
21
|
+
require "gapic/config/method"
|
22
|
+
|
23
|
+
require "google/iam/v3/version"
|
24
|
+
|
25
|
+
require "google/iam/v3/principal_access_boundary_policies/credentials"
|
26
|
+
require "google/iam/v3/principal_access_boundary_policies/paths"
|
27
|
+
require "google/iam/v3/principal_access_boundary_policies/rest/operations"
|
28
|
+
require "google/iam/v3/principal_access_boundary_policies/rest/client"
|
29
|
+
|
30
|
+
module Google
|
31
|
+
module Iam
|
32
|
+
module V3
|
33
|
+
##
|
34
|
+
# Manages Identity and Access Management (IAM) principal access boundary
|
35
|
+
# policies.
|
36
|
+
#
|
37
|
+
# To load this service and instantiate a REST client:
|
38
|
+
#
|
39
|
+
# require "google/iam/v3/principal_access_boundary_policies/rest"
|
40
|
+
# client = ::Google::Iam::V3::PrincipalAccessBoundaryPolicies::Rest::Client.new
|
41
|
+
#
|
42
|
+
module PrincipalAccessBoundaryPolicies
|
43
|
+
# Client for the REST transport
|
44
|
+
module Rest
|
45
|
+
end
|
46
|
+
end
|
47
|
+
end
|
48
|
+
end
|
49
|
+
end
|
50
|
+
|
51
|
+
helper_path = ::File.join __dir__, "rest", "helpers.rb"
|
52
|
+
require "google/iam/v3/principal_access_boundary_policies/rest/helpers" if ::File.file? helper_path
|
@@ -0,0 +1,55 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2025 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
require "gapic/common"
|
20
|
+
require "gapic/config"
|
21
|
+
require "gapic/config/method"
|
22
|
+
|
23
|
+
require "google/iam/v3/version"
|
24
|
+
|
25
|
+
require "google/iam/v3/principal_access_boundary_policies/credentials"
|
26
|
+
require "google/iam/v3/principal_access_boundary_policies/paths"
|
27
|
+
require "google/iam/v3/principal_access_boundary_policies/operations"
|
28
|
+
require "google/iam/v3/principal_access_boundary_policies/client"
|
29
|
+
require "google/iam/v3/principal_access_boundary_policies/rest"
|
30
|
+
|
31
|
+
module Google
|
32
|
+
module Iam
|
33
|
+
module V3
|
34
|
+
##
|
35
|
+
# Manages Identity and Access Management (IAM) principal access boundary
|
36
|
+
# policies.
|
37
|
+
#
|
38
|
+
# @example Load this service and instantiate a gRPC client
|
39
|
+
#
|
40
|
+
# require "google/iam/v3/principal_access_boundary_policies"
|
41
|
+
# client = ::Google::Iam::V3::PrincipalAccessBoundaryPolicies::Client.new
|
42
|
+
#
|
43
|
+
# @example Load this service and instantiate a REST client
|
44
|
+
#
|
45
|
+
# require "google/iam/v3/principal_access_boundary_policies/rest"
|
46
|
+
# client = ::Google::Iam::V3::PrincipalAccessBoundaryPolicies::Rest::Client.new
|
47
|
+
#
|
48
|
+
module PrincipalAccessBoundaryPolicies
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|
52
|
+
end
|
53
|
+
|
54
|
+
helper_path = ::File.join __dir__, "principal_access_boundary_policies", "helpers.rb"
|
55
|
+
require "google/iam/v3/principal_access_boundary_policies/helpers" if ::File.file? helper_path
|
@@ -0,0 +1,61 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
3
|
+
# source: google/iam/v3/principal_access_boundary_policies_service.proto
|
4
|
+
|
5
|
+
require 'google/protobuf'
|
6
|
+
|
7
|
+
require 'google/api/annotations_pb'
|
8
|
+
require 'google/api/client_pb'
|
9
|
+
require 'google/api/field_behavior_pb'
|
10
|
+
require 'google/api/resource_pb'
|
11
|
+
require 'google/iam/v3/operation_metadata_pb'
|
12
|
+
require 'google/iam/v3/policy_binding_resources_pb'
|
13
|
+
require 'google/iam/v3/principal_access_boundary_policy_resources_pb'
|
14
|
+
require 'google/longrunning/operations_pb'
|
15
|
+
require 'google/protobuf/empty_pb'
|
16
|
+
require 'google/protobuf/field_mask_pb'
|
17
|
+
|
18
|
+
|
19
|
+
descriptor_data = "\n>google/iam/v3/principal_access_boundary_policies_service.proto\x12\rgoogle.iam.v3\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a&google/iam/v3/operation_metadata.proto\x1a,google/iam/v3/policy_binding_resources.proto\x1a>google/iam/v3/principal_access_boundary_policy_resources.proto\x1a#google/longrunning/operations.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a google/protobuf/field_mask.proto\"\xa1\x02\n*CreatePrincipalAccessBoundaryPolicyRequest\x12H\n\x06parent\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\x12\x30iam.googleapis.com/PrincipalAccessBoundaryPolicy\x12\x30\n#principal_access_boundary_policy_id\x18\x02 \x01(\tB\x03\xe0\x41\x02\x12[\n principal_access_boundary_policy\x18\x03 \x01(\x0b\x32,.google.iam.v3.PrincipalAccessBoundaryPolicyB\x03\xe0\x41\x02\x12\x1a\n\rvalidate_only\x18\x04 \x01(\x08\x42\x03\xe0\x41\x01\"q\n\'GetPrincipalAccessBoundaryPolicyRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0iam.googleapis.com/PrincipalAccessBoundaryPolicy\"\xdb\x01\n*UpdatePrincipalAccessBoundaryPolicyRequest\x12[\n principal_access_boundary_policy\x18\x01 \x01(\x0b\x32,.google.iam.v3.PrincipalAccessBoundaryPolicyB\x03\xe0\x41\x02\x12\x1a\n\rvalidate_only\x18\x02 \x01(\x08\x42\x03\xe0\x41\x01\x12\x34\n\x0bupdate_mask\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x01\"\xb7\x01\n*DeletePrincipalAccessBoundaryPolicyRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0iam.googleapis.com/PrincipalAccessBoundaryPolicy\x12\x11\n\x04\x65tag\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x1a\n\rvalidate_only\x18\x03 \x01(\x08\x42\x03\xe0\x41\x01\x12\x12\n\x05\x66orce\x18\x04 \x01(\x08\x42\x03\xe0\x41\x01\"\xa7\x01\n*ListPrincipalAccessBoundaryPoliciesRequest\x12H\n\x06parent\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\x12\x30iam.googleapis.com/PrincipalAccessBoundaryPolicy\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\"\xa5\x01\n+ListPrincipalAccessBoundaryPoliciesResponse\x12X\n\"principal_access_boundary_policies\x18\x01 \x03(\x0b\x32,.google.iam.v3.PrincipalAccessBoundaryPolicy\x12\x1c\n\x0fnext_page_token\x18\x02 \x01(\tB\x03\xe0\x41\x01\"\xad\x01\n2SearchPrincipalAccessBoundaryPolicyBindingsRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0iam.googleapis.com/PrincipalAccessBoundaryPolicy\x12\x16\n\tpage_size\x18\x03 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x04 \x01(\tB\x03\xe0\x41\x01\"\x8a\x01\n3SearchPrincipalAccessBoundaryPolicyBindingsResponse\x12\x35\n\x0fpolicy_bindings\x18\x01 \x03(\x0b\x32\x1c.google.iam.v3.PolicyBinding\x12\x1c\n\x0fnext_page_token\x18\x02 \x01(\tB\x03\xe0\x41\x01\x32\xec\x0e\n\x1fPrincipalAccessBoundaryPolicies\x12\xf7\x02\n#CreatePrincipalAccessBoundaryPolicy\x12\x39.google.iam.v3.CreatePrincipalAccessBoundaryPolicyRequest\x1a\x1d.google.longrunning.Operation\"\xf5\x01\xca\x41\x32\n\x1dPrincipalAccessBoundaryPolicy\x12\x11OperationMetadata\xda\x41Kparent,principal_access_boundary_policy,principal_access_boundary_policy_id\x82\xd3\xe4\x93\x02l\"H/v3/{parent=organizations/*/locations/*}/principalAccessBoundaryPolicies: principal_access_boundary_policy\x12\xe1\x01\n GetPrincipalAccessBoundaryPolicy\x12\x36.google.iam.v3.GetPrincipalAccessBoundaryPolicyRequest\x1a,.google.iam.v3.PrincipalAccessBoundaryPolicy\"W\xda\x41\x04name\x82\xd3\xe4\x93\x02J\x12H/v3/{name=organizations/*/locations/*/principalAccessBoundaryPolicies/*}\x12\xfa\x02\n#UpdatePrincipalAccessBoundaryPolicy\x12\x39.google.iam.v3.UpdatePrincipalAccessBoundaryPolicyRequest\x1a\x1d.google.longrunning.Operation\"\xf8\x01\xca\x41\x32\n\x1dPrincipalAccessBoundaryPolicy\x12\x11OperationMetadata\xda\x41,principal_access_boundary_policy,update_mask\x82\xd3\xe4\x93\x02\x8d\x01\x32i/v3/{principal_access_boundary_policy.name=organizations/*/locations/*/principalAccessBoundaryPolicies/*}: principal_access_boundary_policy\x12\x86\x02\n#DeletePrincipalAccessBoundaryPolicy\x12\x39.google.iam.v3.DeletePrincipalAccessBoundaryPolicyRequest\x1a\x1d.google.longrunning.Operation\"\x84\x01\xca\x41*\n\x15google.protobuf.Empty\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02J*H/v3/{name=organizations/*/locations/*/principalAccessBoundaryPolicies/*}\x12\xf7\x01\n#ListPrincipalAccessBoundaryPolicies\x12\x39.google.iam.v3.ListPrincipalAccessBoundaryPoliciesRequest\x1a:.google.iam.v3.ListPrincipalAccessBoundaryPoliciesResponse\"Y\xda\x41\x06parent\x82\xd3\xe4\x93\x02J\x12H/v3/{parent=organizations/*/locations/*}/principalAccessBoundaryPolicies\x12\xa2\x02\n+SearchPrincipalAccessBoundaryPolicyBindings\x12\x41.google.iam.v3.SearchPrincipalAccessBoundaryPolicyBindingsRequest\x1a\x42.google.iam.v3.SearchPrincipalAccessBoundaryPolicyBindingsResponse\"l\xda\x41\x04name\x82\xd3\xe4\x93\x02_\x12]/v3/{name=organizations/*/locations/*/principalAccessBoundaryPolicies/*}:searchPolicyBindings\x1a\x46\xca\x41\x12iam.googleapis.com\xd2\x41.https://www.googleapis.com/auth/cloud-platformB\x99\x01\n\x11\x63om.google.iam.v3B+PrincipalAccessBoundaryPoliciesServiceProtoP\x01Z)cloud.google.com/go/iam/apiv3/iampb;iampb\xaa\x02\x13Google.Cloud.Iam.V3\xca\x02\x13Google\\Cloud\\Iam\\V3b\x06proto3"
|
20
|
+
|
21
|
+
pool = Google::Protobuf::DescriptorPool.generated_pool
|
22
|
+
|
23
|
+
begin
|
24
|
+
pool.add_serialized_file(descriptor_data)
|
25
|
+
rescue TypeError
|
26
|
+
# Compatibility code: will be removed in the next major version.
|
27
|
+
require 'google/protobuf/descriptor_pb'
|
28
|
+
parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data)
|
29
|
+
parsed.clear_dependency
|
30
|
+
serialized = parsed.class.encode(parsed)
|
31
|
+
file = pool.add_serialized_file(serialized)
|
32
|
+
warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}"
|
33
|
+
imports = [
|
34
|
+
["google.iam.v3.PrincipalAccessBoundaryPolicy", "google/iam/v3/principal_access_boundary_policy_resources.proto"],
|
35
|
+
["google.protobuf.FieldMask", "google/protobuf/field_mask.proto"],
|
36
|
+
["google.iam.v3.PolicyBinding", "google/iam/v3/policy_binding_resources.proto"],
|
37
|
+
]
|
38
|
+
imports.each do |type_name, expected_filename|
|
39
|
+
import_file = pool.lookup(type_name).file_descriptor
|
40
|
+
if import_file.name != expected_filename
|
41
|
+
warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}"
|
42
|
+
end
|
43
|
+
end
|
44
|
+
warn "Each proto file must use a consistent fully-qualified name."
|
45
|
+
warn "This will become an error in the next major version."
|
46
|
+
end
|
47
|
+
|
48
|
+
module Google
|
49
|
+
module Iam
|
50
|
+
module V3
|
51
|
+
CreatePrincipalAccessBoundaryPolicyRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.iam.v3.CreatePrincipalAccessBoundaryPolicyRequest").msgclass
|
52
|
+
GetPrincipalAccessBoundaryPolicyRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.iam.v3.GetPrincipalAccessBoundaryPolicyRequest").msgclass
|
53
|
+
UpdatePrincipalAccessBoundaryPolicyRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.iam.v3.UpdatePrincipalAccessBoundaryPolicyRequest").msgclass
|
54
|
+
DeletePrincipalAccessBoundaryPolicyRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.iam.v3.DeletePrincipalAccessBoundaryPolicyRequest").msgclass
|
55
|
+
ListPrincipalAccessBoundaryPoliciesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.iam.v3.ListPrincipalAccessBoundaryPoliciesRequest").msgclass
|
56
|
+
ListPrincipalAccessBoundaryPoliciesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.iam.v3.ListPrincipalAccessBoundaryPoliciesResponse").msgclass
|
57
|
+
SearchPrincipalAccessBoundaryPolicyBindingsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.iam.v3.SearchPrincipalAccessBoundaryPolicyBindingsRequest").msgclass
|
58
|
+
SearchPrincipalAccessBoundaryPolicyBindingsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.iam.v3.SearchPrincipalAccessBoundaryPolicyBindingsResponse").msgclass
|
59
|
+
end
|
60
|
+
end
|
61
|
+
end
|