aws-sdk-accountaccessruntime 1.0.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.
@@ -0,0 +1,640 @@
1
+ # frozen_string_literal: true
2
+
3
+ # WARNING ABOUT GENERATED CODE
4
+ #
5
+ # This file is generated. See the contributing guide for more information:
6
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
7
+ #
8
+ # WARNING ABOUT GENERATED CODE
9
+
10
+ require 'seahorse/client/plugins/content_length'
11
+ require 'aws-sdk-core/plugins/credentials_configuration'
12
+ require 'aws-sdk-core/plugins/logging'
13
+ require 'aws-sdk-core/plugins/param_converter'
14
+ require 'aws-sdk-core/plugins/param_validator'
15
+ require 'aws-sdk-core/plugins/user_agent'
16
+ require 'aws-sdk-core/plugins/helpful_socket_errors'
17
+ require 'aws-sdk-core/plugins/retry_errors'
18
+ require 'aws-sdk-core/plugins/global_configuration'
19
+ require 'aws-sdk-core/plugins/regional_endpoint'
20
+ require 'aws-sdk-core/plugins/endpoint_discovery'
21
+ require 'aws-sdk-core/plugins/endpoint_pattern'
22
+ require 'aws-sdk-core/plugins/response_paging'
23
+ require 'aws-sdk-core/plugins/stub_responses'
24
+ require 'aws-sdk-core/plugins/idempotency_token'
25
+ require 'aws-sdk-core/plugins/invocation_id'
26
+ require 'aws-sdk-core/plugins/jsonvalue_converter'
27
+ require 'aws-sdk-core/plugins/client_metrics_plugin'
28
+ require 'aws-sdk-core/plugins/client_metrics_send_plugin'
29
+ require 'aws-sdk-core/plugins/transfer_encoding'
30
+ require 'aws-sdk-core/plugins/http_checksum'
31
+ require 'aws-sdk-core/plugins/checksum_algorithm'
32
+ require 'aws-sdk-core/plugins/request_compression'
33
+ require 'aws-sdk-core/plugins/defaults_mode'
34
+ require 'aws-sdk-core/plugins/recursion_detection'
35
+ require 'aws-sdk-core/plugins/telemetry'
36
+ require 'aws-sdk-core/plugins/sign'
37
+ require 'aws-sdk-core/plugins/protocols/rest_json'
38
+
39
+ module Aws::AccountAccessRuntime
40
+ # An API client for AccountAccessRuntime. To construct a client, you need to configure a `:region` and `:credentials`.
41
+ #
42
+ # client = Aws::AccountAccessRuntime::Client.new(
43
+ # region: region_name,
44
+ # credentials: credentials,
45
+ # # ...
46
+ # )
47
+ #
48
+ # For details on configuring region and credentials see
49
+ # the [developer guide](/sdk-for-ruby/v3/developer-guide/setup-config.html).
50
+ #
51
+ # See {#initialize} for a full list of supported configuration options.
52
+ class Client < Seahorse::Client::Base
53
+
54
+ include Aws::ClientStubs
55
+
56
+ @identifier = :accountaccessruntime
57
+
58
+ set_api(ClientApi::API)
59
+
60
+ add_plugin(Seahorse::Client::Plugins::ContentLength)
61
+ add_plugin(Aws::Plugins::CredentialsConfiguration)
62
+ add_plugin(Aws::Plugins::Logging)
63
+ add_plugin(Aws::Plugins::ParamConverter)
64
+ add_plugin(Aws::Plugins::ParamValidator)
65
+ add_plugin(Aws::Plugins::UserAgent)
66
+ add_plugin(Aws::Plugins::HelpfulSocketErrors)
67
+ add_plugin(Aws::Plugins::RetryErrors)
68
+ add_plugin(Aws::Plugins::GlobalConfiguration)
69
+ add_plugin(Aws::Plugins::RegionalEndpoint)
70
+ add_plugin(Aws::Plugins::EndpointDiscovery)
71
+ add_plugin(Aws::Plugins::EndpointPattern)
72
+ add_plugin(Aws::Plugins::ResponsePaging)
73
+ add_plugin(Aws::Plugins::StubResponses)
74
+ add_plugin(Aws::Plugins::IdempotencyToken)
75
+ add_plugin(Aws::Plugins::InvocationId)
76
+ add_plugin(Aws::Plugins::JsonvalueConverter)
77
+ add_plugin(Aws::Plugins::ClientMetricsPlugin)
78
+ add_plugin(Aws::Plugins::ClientMetricsSendPlugin)
79
+ add_plugin(Aws::Plugins::TransferEncoding)
80
+ add_plugin(Aws::Plugins::HttpChecksum)
81
+ add_plugin(Aws::Plugins::ChecksumAlgorithm)
82
+ add_plugin(Aws::Plugins::RequestCompression)
83
+ add_plugin(Aws::Plugins::DefaultsMode)
84
+ add_plugin(Aws::Plugins::RecursionDetection)
85
+ add_plugin(Aws::Plugins::Telemetry)
86
+ add_plugin(Aws::Plugins::Sign)
87
+ add_plugin(Aws::Plugins::Protocols::RestJson)
88
+ add_plugin(Aws::AccountAccessRuntime::Plugins::Endpoints)
89
+
90
+ # @overload initialize(options)
91
+ # @param [Hash] options
92
+ #
93
+ # @option options [Array<Seahorse::Client::Plugin>] :plugins ([]])
94
+ # A list of plugins to apply to the client. Each plugin is either a
95
+ # class name or an instance of a plugin class.
96
+ #
97
+ # @option options [required, Aws::CredentialProvider] :credentials
98
+ # Your AWS credentials used for authentication. This can be any class that includes and implements
99
+ # `Aws::CredentialProvider`, or instance of any one of the following classes:
100
+ #
101
+ # * `Aws::Credentials` - Used for configuring static, non-refreshing
102
+ # credentials.
103
+ #
104
+ # * `Aws::SharedCredentials` - Used for loading static credentials from a
105
+ # shared file, such as `~/.aws/config`.
106
+ #
107
+ # * `Aws::AssumeRoleCredentials` - Used when you need to assume a role.
108
+ #
109
+ # * `Aws::AssumeRoleWebIdentityCredentials` - Used when you need to
110
+ # assume a role after providing credentials via the web.
111
+ #
112
+ # * `Aws::SSOCredentials` - Used for loading credentials from AWS SSO using an
113
+ # access token generated from `aws login`.
114
+ #
115
+ # * `Aws::ProcessCredentials` - Used for loading credentials from a
116
+ # process that outputs to stdout.
117
+ #
118
+ # * `Aws::InstanceProfileCredentials` - Used for loading credentials
119
+ # from an EC2 IMDS on an EC2 instance.
120
+ #
121
+ # * `Aws::ECSCredentials` - Used for loading credentials from
122
+ # instances running in ECS.
123
+ #
124
+ # * `Aws::CognitoIdentityCredentials` - Used for loading credentials
125
+ # from the Cognito Identity service.
126
+ #
127
+ # When `:credentials` are not configured directly, the following locations will be searched for credentials:
128
+ #
129
+ # * `Aws.config[:credentials]`
130
+ #
131
+ # * The `:access_key_id`, `:secret_access_key`, `:session_token`, and
132
+ # `:account_id` options.
133
+ #
134
+ # * `ENV['AWS_ACCESS_KEY_ID']`, `ENV['AWS_SECRET_ACCESS_KEY']`,
135
+ # `ENV['AWS_SESSION_TOKEN']`, and `ENV['AWS_ACCOUNT_ID']`.
136
+ #
137
+ # * `~/.aws/credentials`
138
+ #
139
+ # * `~/.aws/config`
140
+ #
141
+ # * EC2/ECS IMDS instance profile - When used by default, the timeouts are very aggressive.
142
+ # Construct and pass an instance of `Aws::InstanceProfileCredentials` or `Aws::ECSCredentials` to
143
+ # enable retries and extended timeouts. Instance profile credential fetching can be disabled by
144
+ # setting `ENV['AWS_EC2_METADATA_DISABLED']` to `true`.
145
+ #
146
+ # @option options [required, String] :region
147
+ # The AWS region to connect to. The configured `:region` is
148
+ # used to determine the service `:endpoint`. When not passed,
149
+ # a default `:region` is searched for in the following locations:
150
+ #
151
+ # * `Aws.config[:region]`
152
+ # * `ENV['AWS_REGION']`
153
+ # * `ENV['AMAZON_REGION']`
154
+ # * `ENV['AWS_DEFAULT_REGION']`
155
+ # * `~/.aws/credentials`
156
+ # * `~/.aws/config`
157
+ #
158
+ # @option options [String] :access_key_id
159
+ #
160
+ # @option options [String] :account_id
161
+ #
162
+ # @option options [Boolean] :active_endpoint_cache (false)
163
+ # When set to `true`, a thread polling for endpoints will be running in
164
+ # the background every 60 secs (default). Defaults to `false`.
165
+ #
166
+ # @option options [Boolean] :adaptive_retry_wait_to_fill (true)
167
+ # Used only in `adaptive` retry mode. When true, the request will sleep
168
+ # until there is sufficent client side capacity to retry the request.
169
+ # When false, the request will raise a `RetryCapacityNotAvailableError` and will
170
+ # not retry instead of sleeping.
171
+ #
172
+ # @option options [Array<String>] :auth_scheme_preference
173
+ # A list of preferred authentication schemes to use when making a request. Supported values are:
174
+ # `sigv4`, `sigv4a`, `httpBearerAuth`, and `noAuth`. When set using `ENV['AWS_AUTH_SCHEME_PREFERENCE']` or in
175
+ # shared config as `auth_scheme_preference`, the value should be a comma-separated list.
176
+ #
177
+ # @option options [Boolean] :client_side_monitoring (false)
178
+ # When `true`, client-side metrics will be collected for all API requests from
179
+ # this client.
180
+ #
181
+ # @option options [String] :client_side_monitoring_client_id ("")
182
+ # Allows you to provide an identifier for this client which will be attached to
183
+ # all generated client side metrics. Defaults to an empty string.
184
+ #
185
+ # @option options [String] :client_side_monitoring_host ("127.0.0.1")
186
+ # Allows you to specify the DNS hostname or IPv4 or IPv6 address that the client
187
+ # side monitoring agent is running on, where client metrics will be published via UDP.
188
+ #
189
+ # @option options [Integer] :client_side_monitoring_port (31000)
190
+ # Required for publishing client metrics. The port that the client side monitoring
191
+ # agent is running on, where client metrics will be published via UDP.
192
+ #
193
+ # @option options [Aws::ClientSideMonitoring::Publisher] :client_side_monitoring_publisher (Aws::ClientSideMonitoring::Publisher)
194
+ # Allows you to provide a custom client-side monitoring publisher class. By default,
195
+ # will use the Client Side Monitoring Agent Publisher.
196
+ #
197
+ # @option options [Boolean] :convert_params (true)
198
+ # When `true`, an attempt is made to coerce request parameters into
199
+ # the required types.
200
+ #
201
+ # @option options [Boolean] :correct_clock_skew (true)
202
+ # Used only in `standard` and `adaptive` retry modes. Specifies whether
203
+ # to apply a clock skew correction and retry requests with skewed client
204
+ # clocks. Takes effect only when `disable_clock_skew_correction` is not set.
205
+ #
206
+ # @option options [String] :defaults_mode ("legacy")
207
+ # See {Aws::DefaultsModeConfiguration} for a list of the
208
+ # accepted modes and the configuration defaults that are included.
209
+ #
210
+ # @option options [Boolean] :disable_clock_skew_correction
211
+ # Used only in `standard` and `adaptive` retry modes. When `true`, the
212
+ # SDK does not apply a clock skew correction, does not update its stored
213
+ # skew from responses, and does not retry clock skew errors. Clock skew
214
+ # correction is enabled by default.
215
+ #
216
+ # @option options [Boolean] :disable_host_prefix_injection (false)
217
+ # When `true`, the SDK will not prepend the modeled host prefix to the endpoint.
218
+ #
219
+ # @option options [Boolean] :disable_request_compression (false)
220
+ # When set to 'true' the request body will not be compressed
221
+ # for supported operations.
222
+ #
223
+ # @option options [String, URI::HTTPS, URI::HTTP] :endpoint
224
+ # Normally you should not configure the `:endpoint` option
225
+ # directly. This is normally constructed from the `:region`
226
+ # option. Configuring `:endpoint` is normally reserved for
227
+ # connecting to test or custom endpoints. The endpoint should
228
+ # be a URI formatted like:
229
+ #
230
+ # 'http://example.com'
231
+ # 'https://example.com'
232
+ # 'http://example.com:123'
233
+ #
234
+ # @option options [Integer] :endpoint_cache_max_entries (1000)
235
+ # Used for the maximum size limit of the LRU cache storing endpoints data
236
+ # for endpoint discovery enabled operations. Defaults to 1000.
237
+ #
238
+ # @option options [Integer] :endpoint_cache_max_threads (10)
239
+ # Used for the maximum threads in use for polling endpoints to be cached, defaults to 10.
240
+ #
241
+ # @option options [Integer] :endpoint_cache_poll_interval (60)
242
+ # When :endpoint_discovery and :active_endpoint_cache is enabled,
243
+ # Use this option to config the time interval in seconds for making
244
+ # requests fetching endpoints information. Defaults to 60 sec.
245
+ #
246
+ # @option options [Boolean] :endpoint_discovery (false)
247
+ # When set to `true`, endpoint discovery will be enabled for operations when available.
248
+ #
249
+ # @option options [Boolean] :ignore_configured_endpoint_urls
250
+ # Setting to true disables use of endpoint URLs provided via environment
251
+ # variables and the shared configuration file.
252
+ #
253
+ # @option options [Aws::Log::Formatter] :log_formatter (Aws::Log::Formatter.default)
254
+ # The log formatter.
255
+ #
256
+ # @option options [Symbol] :log_level (:info)
257
+ # The log level to send messages to the `:logger` at.
258
+ #
259
+ # @option options [Logger] :logger
260
+ # The Logger instance to send log messages to. If this option
261
+ # is not set, logging will be disabled.
262
+ #
263
+ # @option options [Integer] :max_attempts (3)
264
+ # An integer representing the maximum number attempts that will be made for
265
+ # a single request, including the initial attempt. For example,
266
+ # setting this value to 5 will result in a request being retried up to
267
+ # 4 times. Used in `standard` and `adaptive` retry modes.
268
+ #
269
+ # @option options [String] :profile ("default")
270
+ # Used when loading credentials from the shared credentials file at `HOME/.aws/credentials`.
271
+ # When not specified, 'default' is used.
272
+ #
273
+ # @option options [String] :request_checksum_calculation ("when_supported")
274
+ # Determines when a checksum will be calculated for request payloads. Values are:
275
+ #
276
+ # * `when_supported` - (default) When set, a checksum will be
277
+ # calculated for all request payloads of operations modeled with the
278
+ # `httpChecksum` trait where `requestChecksumRequired` is `true` and/or a
279
+ # `requestAlgorithmMember` is modeled.
280
+ # * `when_required` - When set, a checksum will only be calculated for
281
+ # request payloads of operations modeled with the `httpChecksum` trait where
282
+ # `requestChecksumRequired` is `true` or where a `requestAlgorithmMember`
283
+ # is modeled and supplied.
284
+ #
285
+ # @option options [Integer] :request_min_compression_size_bytes (10240)
286
+ # The minimum size in bytes that triggers compression for request
287
+ # bodies. The value must be non-negative integer value between 0
288
+ # and 10485780 bytes inclusive.
289
+ #
290
+ # @option options [String] :response_checksum_validation ("when_supported")
291
+ # Determines when checksum validation will be performed on response payloads. Values are:
292
+ #
293
+ # * `when_supported` - (default) When set, checksum validation is performed on all
294
+ # response payloads of operations modeled with the `httpChecksum` trait where
295
+ # `responseAlgorithms` is modeled, except when no modeled checksum algorithms
296
+ # are supported.
297
+ # * `when_required` - When set, checksum validation is not performed on
298
+ # response payloads of operations unless the checksum algorithm is supported and
299
+ # the `requestValidationModeMember` member is set to `ENABLED`.
300
+ #
301
+ # @option options [Proc] :retry_backoff
302
+ # A proc or lambda used for backoff. Defaults to 2**retries * retry_base_delay.
303
+ # This option is only used in the `legacy` retry mode.
304
+ #
305
+ # @option options [Float] :retry_base_delay (0.3)
306
+ # The base delay in seconds used by the default backoff function. This option
307
+ # is only used in the `legacy` retry mode.
308
+ #
309
+ # @option options [Symbol] :retry_jitter (:none)
310
+ # A delay randomiser function used by the default backoff function.
311
+ # Some predefined functions can be referenced by name - :none, :equal, :full,
312
+ # otherwise a Proc that takes and returns a number. This option is only used
313
+ # in the `legacy` retry mode.
314
+ #
315
+ # @see https://www.awsarchitectureblog.com/2015/03/backoff.html
316
+ #
317
+ # @option options [Integer] :retry_limit (3)
318
+ # The maximum number of times to retry failed requests. Only
319
+ # ~ 500 level server errors and certain ~ 400 level client errors
320
+ # are retried. Generally, these are throttling errors, data
321
+ # checksum errors, networking errors, timeout errors, auth errors,
322
+ # endpoint discovery, and errors from expired credentials.
323
+ # This option is only used in the `legacy` retry mode.
324
+ #
325
+ # @option options [Integer] :retry_max_delay (0)
326
+ # The maximum number of seconds to delay between retries (0 for no limit)
327
+ # used by the default backoff function. This option is only used in the
328
+ # `legacy` retry mode.
329
+ #
330
+ # @option options [String] :retry_mode ("legacy")
331
+ # Specifies which retry algorithm to use. Values are:
332
+ #
333
+ # * `legacy` - The pre-existing retry behavior. This is the default
334
+ # value if no retry mode is provided.
335
+ #
336
+ # * `standard` - A standardized set of retry rules across the AWS SDKs.
337
+ # This includes support for retry quotas, which limit the number of
338
+ # unsuccessful retries a client can make.
339
+ #
340
+ # * `adaptive` - A retry mode that includes all the functionality of
341
+ # `standard` mode along with automatic client side throttling.
342
+ #
343
+ # @option options [String] :sdk_ua_app_id
344
+ # A unique and opaque application ID that is appended to the
345
+ # User-Agent header as app/sdk_ua_app_id. It should have a
346
+ # maximum length of 50. This variable is sourced from environment
347
+ # variable AWS_SDK_UA_APP_ID or the shared config profile attribute sdk_ua_app_id.
348
+ #
349
+ # @option options [String] :secret_access_key
350
+ #
351
+ # @option options [String] :session_token
352
+ #
353
+ # @option options [Array] :sigv4a_signing_region_set
354
+ # A list of regions that should be signed with SigV4a signing. When
355
+ # not passed, a default `:sigv4a_signing_region_set` is searched for
356
+ # in the following locations:
357
+ #
358
+ # * `Aws.config[:sigv4a_signing_region_set]`
359
+ # * `ENV['AWS_SIGV4A_SIGNING_REGION_SET']`
360
+ # * `~/.aws/config`
361
+ #
362
+ # @option options [Boolean] :stub_responses (false)
363
+ # Causes the client to return stubbed responses. By default
364
+ # fake responses are generated and returned. You can specify
365
+ # the response data to return or errors to raise by calling
366
+ # {ClientStubs#stub_responses}. See {ClientStubs} for more information.
367
+ #
368
+ # ** Please note ** When response stubbing is enabled, no HTTP
369
+ # requests are made, and retries are disabled.
370
+ #
371
+ # @option options [Aws::Telemetry::TelemetryProviderBase] :telemetry_provider (Aws::Telemetry::NoOpTelemetryProvider)
372
+ # Allows you to provide a telemetry provider, which is used to
373
+ # emit telemetry data. By default, uses `NoOpTelemetryProvider` which
374
+ # will not record or emit any telemetry data. The SDK supports the
375
+ # following telemetry providers:
376
+ #
377
+ # * OpenTelemetry (OTel) - To use the OTel provider, install and require the
378
+ # `opentelemetry-sdk` gem and then, pass in an instance of a
379
+ # `Aws::Telemetry::OTelProvider` for telemetry provider.
380
+ #
381
+ # @option options [Aws::TokenProvider] :token_provider
382
+ # Your Bearer token used for authentication. This can be any class that includes and implements
383
+ # `Aws::TokenProvider`, or instance of any one of the following classes:
384
+ #
385
+ # * `Aws::StaticTokenProvider` - Used for configuring static, non-refreshing
386
+ # tokens.
387
+ #
388
+ # * `Aws::SSOTokenProvider` - Used for loading tokens from AWS SSO using an
389
+ # access token generated from `aws login`.
390
+ #
391
+ # When `:token_provider` is not configured directly, the `Aws::TokenProviderChain`
392
+ # will be used to search for tokens configured for your profile in shared configuration files.
393
+ #
394
+ # @option options [Boolean] :use_dualstack_endpoint
395
+ # When set to `true`, dualstack enabled endpoints (with `.aws` TLD)
396
+ # will be used if available.
397
+ #
398
+ # @option options [Boolean] :use_fips_endpoint
399
+ # When set to `true`, fips compatible endpoints will be used if available.
400
+ # When a `fips` region is used, the region is normalized and this config
401
+ # is set to `true`.
402
+ #
403
+ # @option options [Boolean] :validate_params (true)
404
+ # When `true`, request parameters are validated before
405
+ # sending the request.
406
+ #
407
+ # @option options [Aws::AccountAccessRuntime::EndpointProvider] :endpoint_provider
408
+ # The endpoint provider used to resolve endpoints. Any object that responds to
409
+ # `#resolve_endpoint(parameters)` where `parameters` is a Struct similar to
410
+ # `Aws::AccountAccessRuntime::EndpointParameters`.
411
+ #
412
+ # @option options [Float] :http_continue_timeout (1)
413
+ # The number of seconds to wait for a 100-continue response before sending the
414
+ # request body. This option has no effect unless the request has "Expect"
415
+ # header set to "100-continue". Defaults to `nil` which disables this
416
+ # behaviour. This value can safely be set per request on the session.
417
+ #
418
+ # @option options [Float] :http_idle_timeout (5)
419
+ # The number of seconds a connection is allowed to sit idle before it
420
+ # is considered stale. Stale connections are closed and removed from the
421
+ # pool before making a request.
422
+ #
423
+ # @option options [Float] :http_open_timeout (15)
424
+ # The default number of seconds to wait for response data.
425
+ # This value can safely be set per-request on the session.
426
+ #
427
+ # @option options [URI::HTTP,String] :http_proxy
428
+ # A proxy to send requests through. Formatted like 'http://proxy.com:123'.
429
+ #
430
+ # @option options [Float] :http_read_timeout (60)
431
+ # The default number of seconds to wait for response data.
432
+ # This value can safely be set per-request on the session.
433
+ #
434
+ # @option options [Boolean] :http_wire_trace (false)
435
+ # When `true`, HTTP debug output will be sent to the `:logger`.
436
+ #
437
+ # @option options [Proc] :on_chunk_received
438
+ # When a Proc object is provided, it will be used as callback when each chunk
439
+ # of the response body is received. It provides three arguments: the chunk,
440
+ # the number of bytes received, and the total number of
441
+ # bytes in the response (or nil if the server did not send a `content-length`).
442
+ #
443
+ # @option options [Proc] :on_chunk_sent
444
+ # When a Proc object is provided, it will be used as callback when each chunk
445
+ # of the request body is sent. It provides three arguments: the chunk,
446
+ # the number of bytes read from the body, and the total number of
447
+ # bytes in the body.
448
+ #
449
+ # @option options [Boolean] :raise_response_errors (true)
450
+ # When `true`, response errors are raised.
451
+ #
452
+ # @option options [String] :ssl_ca_bundle
453
+ # Full path to the SSL certificate authority bundle file that should be used when
454
+ # verifying peer certificates. If you do not pass `:ssl_ca_bundle` or
455
+ # `:ssl_ca_directory` the the system default will be used if available.
456
+ #
457
+ # @option options [String] :ssl_ca_directory
458
+ # Full path of the directory that contains the unbundled SSL certificate
459
+ # authority files for verifying peer certificates. If you do
460
+ # not pass `:ssl_ca_bundle` or `:ssl_ca_directory` the the system
461
+ # default will be used if available.
462
+ #
463
+ # @option options [String] :ssl_ca_store
464
+ # Sets the X509::Store to verify peer certificate.
465
+ #
466
+ # @option options [OpenSSL::X509::Certificate] :ssl_cert
467
+ # Sets a client certificate when creating http connections.
468
+ #
469
+ # @option options [OpenSSL::PKey] :ssl_key
470
+ # Sets a client key when creating http connections.
471
+ #
472
+ # @option options [Float] :ssl_timeout
473
+ # Sets the SSL timeout in seconds
474
+ #
475
+ # @option options [Boolean] :ssl_verify_peer (true)
476
+ # When `true`, SSL peer certificates are verified when establishing a connection.
477
+ #
478
+ def initialize(*args)
479
+ super
480
+ end
481
+
482
+ # @!group API Operations
483
+
484
+ # Returns temporary Amazon Web Services credentials for a role that you
485
+ # are entitled to assume within a tenant. You can use these credentials
486
+ # for programmatic access with the CLI or an Amazon Web Services SDK. If
487
+ # you aren't entitled to the role, the request fails with an
488
+ # `AccessDeniedException` error.
489
+ #
490
+ # @option params [required, String] :tenant_id
491
+ # The identifier of the tenant that the request applies to. A tenant ID
492
+ # begins with `aa-` and is 3 to 24 characters long. It can contain
493
+ # lowercase letters, numbers, and hyphens.
494
+ #
495
+ # @option params [required, String] :role_arn
496
+ # The Amazon Resource Name (ARN) of the role to retrieve credentials
497
+ # for. You must be entitled to assume this role.
498
+ #
499
+ # @option params [required, String] :access_type
500
+ # The type of access to request for the role. Specify
501
+ # `PROGRAMMATIC_ACCESS` to receive access key credentials for use with
502
+ # the CLI or an Amazon Web Services SDK.
503
+ #
504
+ # @option params [String] :session_name
505
+ # An optional name for the role session. The name can be 2 to 64
506
+ # characters and can contain alphanumeric characters and the following
507
+ # symbols: plus (+), equal (=), comma (,), period (.), at (@), and
508
+ # hyphen (-). The session name appears in CloudTrail logs for the
509
+ # assumed role session.
510
+ #
511
+ # @option params [Integer] :session_duration
512
+ # The duration, in seconds, that the returned credentials remain valid.
513
+ # If you don't specify a value, the service uses the default session
514
+ # duration. The maximum value can't exceed the maximum session duration
515
+ # configured for the role.
516
+ #
517
+ # @return [Types::GetRoleCredentialsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
518
+ #
519
+ # * {Types::GetRoleCredentialsResponse#credentials_details #credentials_details} => Types::CredentialsDetails
520
+ #
521
+ # @example Request syntax with placeholder values
522
+ #
523
+ # resp = client.get_role_credentials({
524
+ # tenant_id: "TenantId", # required
525
+ # role_arn: "String", # required
526
+ # access_type: "PROGRAMMATIC_ACCESS", # required, accepts PROGRAMMATIC_ACCESS
527
+ # session_name: "SessionName",
528
+ # session_duration: 1,
529
+ # })
530
+ #
531
+ # @example Response structure
532
+ #
533
+ # resp.credentials_details.programmatic_access.access_key_id #=> String
534
+ # resp.credentials_details.programmatic_access.secret_access_key #=> String
535
+ # resp.credentials_details.programmatic_access.session_token #=> String
536
+ # resp.credentials_details.programmatic_access.expires_at #=> Time
537
+ #
538
+ # @see http://docs.aws.amazon.com/goto/WebAPI/account-access-runtime-2018-05-10/GetRoleCredentials AWS API Documentation
539
+ #
540
+ # @overload get_role_credentials(params = {})
541
+ # @param [Hash] params ({})
542
+ def get_role_credentials(params = {}, options = {})
543
+ req = build_request(:get_role_credentials, params)
544
+ req.send_request(options)
545
+ end
546
+
547
+ # Returns the roles that you are entitled to access within a tenant. The
548
+ # results are paginated. Use a returned role with `GetRoleCredentials`
549
+ # to obtain temporary credentials.
550
+ #
551
+ # @option params [required, String] :tenant_id
552
+ # The identifier of the tenant whose roles you want to list. A tenant ID
553
+ # begins with `aa-` and is 3 to 24 characters long. It can contain
554
+ # lowercase letters, numbers, and hyphens.
555
+ #
556
+ # @option params [Integer] :max_results
557
+ # The maximum number of roles to return in a single response. If more
558
+ # roles are available than the specified value, the response includes a
559
+ # `nextToken` value that you can use to retrieve the next page of
560
+ # results. If you don't specify a value, the service uses a default
561
+ # page size.
562
+ #
563
+ # @option params [String] :next_token
564
+ # The pagination token from a previous `ListRoles` response. Use it to
565
+ # retrieve the next page of results. Omit this parameter on the first
566
+ # call.
567
+ #
568
+ # @return [Types::ListRolesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
569
+ #
570
+ # * {Types::ListRolesResponse#roles #roles} => Array&lt;Types::AccessDetails&gt;
571
+ # * {Types::ListRolesResponse#next_token #next_token} => String
572
+ #
573
+ # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
574
+ #
575
+ # @example Request syntax with placeholder values
576
+ #
577
+ # resp = client.list_roles({
578
+ # tenant_id: "TenantId", # required
579
+ # max_results: 1,
580
+ # next_token: "Token",
581
+ # })
582
+ #
583
+ # @example Response structure
584
+ #
585
+ # resp.roles #=> Array
586
+ # resp.roles[0].account_id #=> String
587
+ # resp.roles[0].account_name #=> String
588
+ # resp.roles[0].role_arn #=> String
589
+ # resp.next_token #=> String
590
+ #
591
+ # @see http://docs.aws.amazon.com/goto/WebAPI/account-access-runtime-2018-05-10/ListRoles AWS API Documentation
592
+ #
593
+ # @overload list_roles(params = {})
594
+ # @param [Hash] params ({})
595
+ def list_roles(params = {}, options = {})
596
+ req = build_request(:list_roles, params)
597
+ req.send_request(options)
598
+ end
599
+
600
+ # @!endgroup
601
+
602
+ # @param params ({})
603
+ # @api private
604
+ def build_request(operation_name, params = {})
605
+ handlers = @handlers.for(operation_name)
606
+ tracer = config.telemetry_provider.tracer_provider.tracer(
607
+ Aws::Telemetry.module_to_tracer_name('Aws::AccountAccessRuntime')
608
+ )
609
+ context = Seahorse::Client::RequestContext.new(
610
+ operation_name: operation_name,
611
+ operation: config.api.operation(operation_name),
612
+ client: self,
613
+ params: params,
614
+ config: config,
615
+ tracer: tracer
616
+ )
617
+ context[:gem_name] = 'aws-sdk-accountaccessruntime'
618
+ context[:gem_version] = '1.0.0'
619
+ Seahorse::Client::Request.new(handlers, context)
620
+ end
621
+
622
+ # @api private
623
+ # @deprecated
624
+ def waiter_names
625
+ []
626
+ end
627
+
628
+ class << self
629
+
630
+ # @api private
631
+ attr_reader :identifier
632
+
633
+ # @api private
634
+ def errors_module
635
+ Errors
636
+ end
637
+
638
+ end
639
+ end
640
+ end