aws-sdk-sustainability 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.
- checksums.yaml +7 -0
- data/CHANGELOG.md +8 -0
- data/LICENSE.txt +202 -0
- data/VERSION +1 -0
- data/lib/aws-sdk-sustainability/client.rb +775 -0
- data/lib/aws-sdk-sustainability/client_api.rb +187 -0
- data/lib/aws-sdk-sustainability/customizations.rb +0 -0
- data/lib/aws-sdk-sustainability/endpoint_parameters.rb +59 -0
- data/lib/aws-sdk-sustainability/endpoint_provider.rb +41 -0
- data/lib/aws-sdk-sustainability/endpoints.rb +20 -0
- data/lib/aws-sdk-sustainability/errors.rb +110 -0
- data/lib/aws-sdk-sustainability/plugins/endpoints.rb +77 -0
- data/lib/aws-sdk-sustainability/resource.rb +26 -0
- data/lib/aws-sdk-sustainability/types.rb +328 -0
- data/lib/aws-sdk-sustainability.rb +61 -0
- data/sig/client.rbs +125 -0
- data/sig/errors.rbs +28 -0
- data/sig/resource.rbs +85 -0
- data/sig/types.rbs +99 -0
- data/sig/waiters.rbs +13 -0
- metadata +96 -0
|
@@ -0,0 +1,328 @@
|
|
|
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
|
+
module Aws::Sustainability
|
|
11
|
+
module Types
|
|
12
|
+
|
|
13
|
+
# You do not have sufficient access to perform this action.
|
|
14
|
+
#
|
|
15
|
+
# @!attribute [rw] message
|
|
16
|
+
# @return [String]
|
|
17
|
+
#
|
|
18
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sustainability-2018-05-10/AccessDeniedException AWS API Documentation
|
|
19
|
+
#
|
|
20
|
+
class AccessDeniedException < Struct.new(
|
|
21
|
+
:message)
|
|
22
|
+
SENSITIVE = []
|
|
23
|
+
include Aws::Structure
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
# Represents a dimension and its corresponding value.
|
|
27
|
+
#
|
|
28
|
+
# @!attribute [rw] dimension
|
|
29
|
+
# The dimension type that categorizes this entry.
|
|
30
|
+
# @return [String]
|
|
31
|
+
#
|
|
32
|
+
# @!attribute [rw] value
|
|
33
|
+
# The value for the specified dimension. Valid values vary based on
|
|
34
|
+
# the dimension type (e.g., `us-east-1` for the `REGION` dimension,
|
|
35
|
+
# `AmazonEC2` for the `SERVICE` dimension).
|
|
36
|
+
# @return [String]
|
|
37
|
+
#
|
|
38
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sustainability-2018-05-10/DimensionEntry AWS API Documentation
|
|
39
|
+
#
|
|
40
|
+
class DimensionEntry < Struct.new(
|
|
41
|
+
:dimension,
|
|
42
|
+
:value)
|
|
43
|
+
SENSITIVE = []
|
|
44
|
+
include Aws::Structure
|
|
45
|
+
end
|
|
46
|
+
|
|
47
|
+
# Represents a carbon emissions quantity with its value and unit of
|
|
48
|
+
# measurement.
|
|
49
|
+
#
|
|
50
|
+
# @!attribute [rw] value
|
|
51
|
+
# The numeric value of the emissions quantity.
|
|
52
|
+
# @return [Float]
|
|
53
|
+
#
|
|
54
|
+
# @!attribute [rw] unit
|
|
55
|
+
# The unit of measurement for the emissions value.
|
|
56
|
+
# @return [String]
|
|
57
|
+
#
|
|
58
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sustainability-2018-05-10/Emissions AWS API Documentation
|
|
59
|
+
#
|
|
60
|
+
class Emissions < Struct.new(
|
|
61
|
+
:value,
|
|
62
|
+
:unit)
|
|
63
|
+
SENSITIVE = []
|
|
64
|
+
include Aws::Structure
|
|
65
|
+
end
|
|
66
|
+
|
|
67
|
+
# Contains estimated carbon emissions data for a specific time period
|
|
68
|
+
# and dimension grouping.
|
|
69
|
+
#
|
|
70
|
+
# @!attribute [rw] time_period
|
|
71
|
+
# The reporting period for emission values.
|
|
72
|
+
# @return [Types::TimePeriod]
|
|
73
|
+
#
|
|
74
|
+
# @!attribute [rw] dimensions_values
|
|
75
|
+
# The dimensions used to group emissions values.
|
|
76
|
+
# @return [Hash<String,String>]
|
|
77
|
+
#
|
|
78
|
+
# @!attribute [rw] model_version
|
|
79
|
+
# The semantic version-formatted string that indicates the methodology
|
|
80
|
+
# version used to calculate the emission values.
|
|
81
|
+
#
|
|
82
|
+
# <note markdown="1"> The AWS Sustainability service reflects the most recent model
|
|
83
|
+
# version for every month. You will not see two entries for the same
|
|
84
|
+
# month with different `ModelVersion` values. To track the evolution
|
|
85
|
+
# of the methodology and compare emission values from previous
|
|
86
|
+
# versions, we recommend creating a [Data Export][1].
|
|
87
|
+
#
|
|
88
|
+
# </note>
|
|
89
|
+
#
|
|
90
|
+
#
|
|
91
|
+
#
|
|
92
|
+
# [1]: https://docs.aws.amazon.com/cur/latest/userguide/what-is-data-exports.html
|
|
93
|
+
# @return [String]
|
|
94
|
+
#
|
|
95
|
+
# @!attribute [rw] emissions_values
|
|
96
|
+
# The emissions values for the requested emissions types.
|
|
97
|
+
# @return [Hash<String,Types::Emissions>]
|
|
98
|
+
#
|
|
99
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sustainability-2018-05-10/EstimatedCarbonEmissions AWS API Documentation
|
|
100
|
+
#
|
|
101
|
+
class EstimatedCarbonEmissions < Struct.new(
|
|
102
|
+
:time_period,
|
|
103
|
+
:dimensions_values,
|
|
104
|
+
:model_version,
|
|
105
|
+
:emissions_values)
|
|
106
|
+
SENSITIVE = []
|
|
107
|
+
include Aws::Structure
|
|
108
|
+
end
|
|
109
|
+
|
|
110
|
+
# Filters emission values by specific dimension values.
|
|
111
|
+
#
|
|
112
|
+
# @!attribute [rw] dimensions
|
|
113
|
+
# Filters emission values by specific dimension values.
|
|
114
|
+
# @return [Hash<String,Array<String>>]
|
|
115
|
+
#
|
|
116
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sustainability-2018-05-10/FilterExpression AWS API Documentation
|
|
117
|
+
#
|
|
118
|
+
class FilterExpression < Struct.new(
|
|
119
|
+
:dimensions)
|
|
120
|
+
SENSITIVE = []
|
|
121
|
+
include Aws::Structure
|
|
122
|
+
end
|
|
123
|
+
|
|
124
|
+
# @!attribute [rw] time_period
|
|
125
|
+
# The date range for fetching the dimension values.
|
|
126
|
+
# @return [Types::TimePeriod]
|
|
127
|
+
#
|
|
128
|
+
# @!attribute [rw] dimensions
|
|
129
|
+
# The dimensions available for grouping estimated carbon emissions.
|
|
130
|
+
# @return [Array<String>]
|
|
131
|
+
#
|
|
132
|
+
# @!attribute [rw] max_results
|
|
133
|
+
# The maximum number of results to return in a single call. Default is
|
|
134
|
+
# 40.
|
|
135
|
+
# @return [Integer]
|
|
136
|
+
#
|
|
137
|
+
# @!attribute [rw] next_token
|
|
138
|
+
# The pagination token specifying which page of results to return in
|
|
139
|
+
# the response. If no token is provided, the default page is the first
|
|
140
|
+
# page.
|
|
141
|
+
# @return [String]
|
|
142
|
+
#
|
|
143
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sustainability-2018-05-10/GetEstimatedCarbonEmissionsDimensionValuesRequest AWS API Documentation
|
|
144
|
+
#
|
|
145
|
+
class GetEstimatedCarbonEmissionsDimensionValuesRequest < Struct.new(
|
|
146
|
+
:time_period,
|
|
147
|
+
:dimensions,
|
|
148
|
+
:max_results,
|
|
149
|
+
:next_token)
|
|
150
|
+
SENSITIVE = []
|
|
151
|
+
include Aws::Structure
|
|
152
|
+
end
|
|
153
|
+
|
|
154
|
+
# @!attribute [rw] results
|
|
155
|
+
# The list of possible dimensions over which the emissions data is
|
|
156
|
+
# aggregated.
|
|
157
|
+
# @return [Array<Types::DimensionEntry>]
|
|
158
|
+
#
|
|
159
|
+
# @!attribute [rw] next_token
|
|
160
|
+
# The pagination token indicating there are additional pages
|
|
161
|
+
# available. You can use the token in a following request to fetch the
|
|
162
|
+
# next set of results.
|
|
163
|
+
# @return [String]
|
|
164
|
+
#
|
|
165
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sustainability-2018-05-10/GetEstimatedCarbonEmissionsDimensionValuesResponse AWS API Documentation
|
|
166
|
+
#
|
|
167
|
+
class GetEstimatedCarbonEmissionsDimensionValuesResponse < Struct.new(
|
|
168
|
+
:results,
|
|
169
|
+
:next_token)
|
|
170
|
+
SENSITIVE = []
|
|
171
|
+
include Aws::Structure
|
|
172
|
+
end
|
|
173
|
+
|
|
174
|
+
# @!attribute [rw] time_period
|
|
175
|
+
# The date range for fetching estimated carbon emissions.
|
|
176
|
+
# @return [Types::TimePeriod]
|
|
177
|
+
#
|
|
178
|
+
# @!attribute [rw] group_by
|
|
179
|
+
# The dimensions available for grouping estimated carbon emissions.
|
|
180
|
+
# @return [Array<String>]
|
|
181
|
+
#
|
|
182
|
+
# @!attribute [rw] filter_by
|
|
183
|
+
# The criteria for filtering estimated carbon emissions.
|
|
184
|
+
# @return [Types::FilterExpression]
|
|
185
|
+
#
|
|
186
|
+
# @!attribute [rw] emissions_types
|
|
187
|
+
# The emission types to include in the results. If absent, returns
|
|
188
|
+
# `TOTAL_LBM_CARBON_EMISSIONS` and `TOTAL_MBM_CARBON_EMISSIONS`
|
|
189
|
+
# emissions types.
|
|
190
|
+
# @return [Array<String>]
|
|
191
|
+
#
|
|
192
|
+
# @!attribute [rw] granularity
|
|
193
|
+
# The time granularity for the results. If absent, uses `MONTHLY` time
|
|
194
|
+
# granularity.
|
|
195
|
+
# @return [String]
|
|
196
|
+
#
|
|
197
|
+
# @!attribute [rw] granularity_configuration
|
|
198
|
+
# Configuration for fiscal year calculations when using
|
|
199
|
+
# `YEARLY_FISCAL` or `QUARTERLY_FISCAL` granularity.
|
|
200
|
+
# @return [Types::GranularityConfiguration]
|
|
201
|
+
#
|
|
202
|
+
# @!attribute [rw] max_results
|
|
203
|
+
# The maximum number of results to return in a single call. Default is
|
|
204
|
+
# 40.
|
|
205
|
+
# @return [Integer]
|
|
206
|
+
#
|
|
207
|
+
# @!attribute [rw] next_token
|
|
208
|
+
# The pagination token specifying which page of results to return in
|
|
209
|
+
# the response. If no token is provided, the default page is the first
|
|
210
|
+
# page.
|
|
211
|
+
# @return [String]
|
|
212
|
+
#
|
|
213
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sustainability-2018-05-10/GetEstimatedCarbonEmissionsRequest AWS API Documentation
|
|
214
|
+
#
|
|
215
|
+
class GetEstimatedCarbonEmissionsRequest < Struct.new(
|
|
216
|
+
:time_period,
|
|
217
|
+
:group_by,
|
|
218
|
+
:filter_by,
|
|
219
|
+
:emissions_types,
|
|
220
|
+
:granularity,
|
|
221
|
+
:granularity_configuration,
|
|
222
|
+
:max_results,
|
|
223
|
+
:next_token)
|
|
224
|
+
SENSITIVE = []
|
|
225
|
+
include Aws::Structure
|
|
226
|
+
end
|
|
227
|
+
|
|
228
|
+
# @!attribute [rw] results
|
|
229
|
+
# The result of the requested inputs.
|
|
230
|
+
# @return [Array<Types::EstimatedCarbonEmissions>]
|
|
231
|
+
#
|
|
232
|
+
# @!attribute [rw] next_token
|
|
233
|
+
# The pagination token indicating there are additional pages
|
|
234
|
+
# available. You can use the token in a following request to fetch the
|
|
235
|
+
# next set of results.
|
|
236
|
+
# @return [String]
|
|
237
|
+
#
|
|
238
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sustainability-2018-05-10/GetEstimatedCarbonEmissionsResponse AWS API Documentation
|
|
239
|
+
#
|
|
240
|
+
class GetEstimatedCarbonEmissionsResponse < Struct.new(
|
|
241
|
+
:results,
|
|
242
|
+
:next_token)
|
|
243
|
+
SENSITIVE = []
|
|
244
|
+
include Aws::Structure
|
|
245
|
+
end
|
|
246
|
+
|
|
247
|
+
# Contains configuration for the fiscal year granularities (e.g.,
|
|
248
|
+
# `YEARLY_FISCAL`, `QUARTERLY_FISCAL`.
|
|
249
|
+
#
|
|
250
|
+
# @!attribute [rw] fiscal_year_start_month
|
|
251
|
+
# The month (1-12) when the fiscal year begins. Used for
|
|
252
|
+
# `YEARLY_FISCAL` and `QUARTERLY_FISCAL` granularity. Defaults to 1
|
|
253
|
+
# (January).
|
|
254
|
+
# @return [Integer]
|
|
255
|
+
#
|
|
256
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sustainability-2018-05-10/GranularityConfiguration AWS API Documentation
|
|
257
|
+
#
|
|
258
|
+
class GranularityConfiguration < Struct.new(
|
|
259
|
+
:fiscal_year_start_month)
|
|
260
|
+
SENSITIVE = []
|
|
261
|
+
include Aws::Structure
|
|
262
|
+
end
|
|
263
|
+
|
|
264
|
+
# The request processing has failed because of an unknown error,
|
|
265
|
+
# exception, or failure.
|
|
266
|
+
#
|
|
267
|
+
# @!attribute [rw] message
|
|
268
|
+
# @return [String]
|
|
269
|
+
#
|
|
270
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sustainability-2018-05-10/InternalServerException AWS API Documentation
|
|
271
|
+
#
|
|
272
|
+
class InternalServerException < Struct.new(
|
|
273
|
+
:message)
|
|
274
|
+
SENSITIVE = []
|
|
275
|
+
include Aws::Structure
|
|
276
|
+
end
|
|
277
|
+
|
|
278
|
+
# The request was denied due to request throttling.
|
|
279
|
+
#
|
|
280
|
+
# @!attribute [rw] message
|
|
281
|
+
# @return [String]
|
|
282
|
+
#
|
|
283
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sustainability-2018-05-10/ThrottlingException AWS API Documentation
|
|
284
|
+
#
|
|
285
|
+
class ThrottlingException < Struct.new(
|
|
286
|
+
:message)
|
|
287
|
+
SENSITIVE = []
|
|
288
|
+
include Aws::Structure
|
|
289
|
+
end
|
|
290
|
+
|
|
291
|
+
# Represents a duration of time defined by start and end timestamps.
|
|
292
|
+
#
|
|
293
|
+
# @!attribute [rw] start
|
|
294
|
+
# The start (inclusive) of the time period. ISO-8601 formatted
|
|
295
|
+
# timestamp, for example: `YYYY-MM-DDThh:mm:ss.sssZ`
|
|
296
|
+
# @return [Time]
|
|
297
|
+
#
|
|
298
|
+
# @!attribute [rw] end
|
|
299
|
+
# The end (exclusive) of the time period. ISO-8601 formatted
|
|
300
|
+
# timestamp, for example: `YYYY-MM-DDThh:mm:ss.sssZ`
|
|
301
|
+
# @return [Time]
|
|
302
|
+
#
|
|
303
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sustainability-2018-05-10/TimePeriod AWS API Documentation
|
|
304
|
+
#
|
|
305
|
+
class TimePeriod < Struct.new(
|
|
306
|
+
:start,
|
|
307
|
+
:end)
|
|
308
|
+
SENSITIVE = []
|
|
309
|
+
include Aws::Structure
|
|
310
|
+
end
|
|
311
|
+
|
|
312
|
+
# The input fails to satisfy the constraints specified by an Amazon Web
|
|
313
|
+
# Services service.
|
|
314
|
+
#
|
|
315
|
+
# @!attribute [rw] message
|
|
316
|
+
# @return [String]
|
|
317
|
+
#
|
|
318
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sustainability-2018-05-10/ValidationException AWS API Documentation
|
|
319
|
+
#
|
|
320
|
+
class ValidationException < Struct.new(
|
|
321
|
+
:message)
|
|
322
|
+
SENSITIVE = []
|
|
323
|
+
include Aws::Structure
|
|
324
|
+
end
|
|
325
|
+
|
|
326
|
+
end
|
|
327
|
+
end
|
|
328
|
+
|
|
@@ -0,0 +1,61 @@
|
|
|
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
|
+
|
|
11
|
+
require 'aws-sdk-core'
|
|
12
|
+
require 'aws-sigv4'
|
|
13
|
+
|
|
14
|
+
Aws::Plugins::GlobalConfiguration.add_identifier(:sustainability)
|
|
15
|
+
|
|
16
|
+
# This module provides support for AWS Sustainability. This module is available in the
|
|
17
|
+
# `aws-sdk-sustainability` gem.
|
|
18
|
+
#
|
|
19
|
+
# # Client
|
|
20
|
+
#
|
|
21
|
+
# The {Client} class provides one method for each API operation. Operation
|
|
22
|
+
# methods each accept a hash of request parameters and return a response
|
|
23
|
+
# structure.
|
|
24
|
+
#
|
|
25
|
+
# sustainability = Aws::Sustainability::Client.new
|
|
26
|
+
# resp = sustainability.get_estimated_carbon_emissions(params)
|
|
27
|
+
#
|
|
28
|
+
# See {Client} for more information.
|
|
29
|
+
#
|
|
30
|
+
# # Errors
|
|
31
|
+
#
|
|
32
|
+
# Errors returned from AWS Sustainability are defined in the
|
|
33
|
+
# {Errors} module and all extend {Errors::ServiceError}.
|
|
34
|
+
#
|
|
35
|
+
# begin
|
|
36
|
+
# # do stuff
|
|
37
|
+
# rescue Aws::Sustainability::Errors::ServiceError
|
|
38
|
+
# # rescues all AWS Sustainability API errors
|
|
39
|
+
# end
|
|
40
|
+
#
|
|
41
|
+
# See {Errors} for more information.
|
|
42
|
+
#
|
|
43
|
+
# @!group service
|
|
44
|
+
module Aws::Sustainability
|
|
45
|
+
autoload :Types, 'aws-sdk-sustainability/types'
|
|
46
|
+
autoload :ClientApi, 'aws-sdk-sustainability/client_api'
|
|
47
|
+
module Plugins
|
|
48
|
+
autoload :Endpoints, 'aws-sdk-sustainability/plugins/endpoints.rb'
|
|
49
|
+
end
|
|
50
|
+
autoload :Client, 'aws-sdk-sustainability/client'
|
|
51
|
+
autoload :Errors, 'aws-sdk-sustainability/errors'
|
|
52
|
+
autoload :Resource, 'aws-sdk-sustainability/resource'
|
|
53
|
+
autoload :EndpointParameters, 'aws-sdk-sustainability/endpoint_parameters'
|
|
54
|
+
autoload :EndpointProvider, 'aws-sdk-sustainability/endpoint_provider'
|
|
55
|
+
autoload :Endpoints, 'aws-sdk-sustainability/endpoints'
|
|
56
|
+
|
|
57
|
+
GEM_VERSION = '1.0.0'
|
|
58
|
+
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
require_relative 'aws-sdk-sustainability/customizations'
|
data/sig/client.rbs
ADDED
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
# WARNING ABOUT GENERATED CODE
|
|
2
|
+
#
|
|
3
|
+
# This file is generated. See the contributing guide for more information:
|
|
4
|
+
# https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
|
|
5
|
+
#
|
|
6
|
+
# WARNING ABOUT GENERATED CODE
|
|
7
|
+
|
|
8
|
+
module Aws
|
|
9
|
+
module Sustainability
|
|
10
|
+
class Client < ::Seahorse::Client::Base
|
|
11
|
+
include ::Aws::ClientStubs
|
|
12
|
+
|
|
13
|
+
# https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/Sustainability/Client.html#initialize-instance_method
|
|
14
|
+
def self.new: (
|
|
15
|
+
?credentials: untyped,
|
|
16
|
+
?region: String,
|
|
17
|
+
?access_key_id: String,
|
|
18
|
+
?account_id: String,
|
|
19
|
+
?active_endpoint_cache: bool,
|
|
20
|
+
?adaptive_retry_wait_to_fill: bool,
|
|
21
|
+
?auth_scheme_preference: Array[String],
|
|
22
|
+
?client_side_monitoring: bool,
|
|
23
|
+
?client_side_monitoring_client_id: String,
|
|
24
|
+
?client_side_monitoring_host: String,
|
|
25
|
+
?client_side_monitoring_port: Integer,
|
|
26
|
+
?client_side_monitoring_publisher: untyped,
|
|
27
|
+
?convert_params: bool,
|
|
28
|
+
?correct_clock_skew: bool,
|
|
29
|
+
?defaults_mode: String,
|
|
30
|
+
?disable_host_prefix_injection: bool,
|
|
31
|
+
?disable_request_compression: bool,
|
|
32
|
+
?endpoint: String,
|
|
33
|
+
?endpoint_cache_max_entries: Integer,
|
|
34
|
+
?endpoint_cache_max_threads: Integer,
|
|
35
|
+
?endpoint_cache_poll_interval: Integer,
|
|
36
|
+
?endpoint_discovery: bool,
|
|
37
|
+
?ignore_configured_endpoint_urls: bool,
|
|
38
|
+
?log_formatter: untyped,
|
|
39
|
+
?log_level: Symbol,
|
|
40
|
+
?logger: untyped,
|
|
41
|
+
?max_attempts: Integer,
|
|
42
|
+
?profile: String,
|
|
43
|
+
?request_checksum_calculation: String,
|
|
44
|
+
?request_min_compression_size_bytes: Integer,
|
|
45
|
+
?response_checksum_validation: String,
|
|
46
|
+
?retry_backoff: Proc,
|
|
47
|
+
?retry_base_delay: Float,
|
|
48
|
+
?retry_jitter: (:none | :equal | :full | ^(Integer) -> Integer),
|
|
49
|
+
?retry_limit: Integer,
|
|
50
|
+
?retry_max_delay: Integer,
|
|
51
|
+
?retry_mode: ("legacy" | "standard" | "adaptive"),
|
|
52
|
+
?sdk_ua_app_id: String,
|
|
53
|
+
?secret_access_key: String,
|
|
54
|
+
?session_token: String,
|
|
55
|
+
?sigv4a_signing_region_set: Array[String],
|
|
56
|
+
?stub_responses: untyped,
|
|
57
|
+
?telemetry_provider: Aws::Telemetry::TelemetryProviderBase,
|
|
58
|
+
?token_provider: untyped,
|
|
59
|
+
?use_dualstack_endpoint: bool,
|
|
60
|
+
?use_fips_endpoint: bool,
|
|
61
|
+
?validate_params: bool,
|
|
62
|
+
?endpoint_provider: untyped,
|
|
63
|
+
?http_proxy: String,
|
|
64
|
+
?http_open_timeout: (Float | Integer),
|
|
65
|
+
?http_read_timeout: (Float | Integer),
|
|
66
|
+
?http_idle_timeout: (Float | Integer),
|
|
67
|
+
?http_continue_timeout: (Float | Integer),
|
|
68
|
+
?ssl_timeout: (Float | Integer | nil),
|
|
69
|
+
?http_wire_trace: bool,
|
|
70
|
+
?ssl_verify_peer: bool,
|
|
71
|
+
?ssl_ca_bundle: String,
|
|
72
|
+
?ssl_ca_directory: String,
|
|
73
|
+
?ssl_ca_store: String,
|
|
74
|
+
?on_chunk_received: Proc,
|
|
75
|
+
?on_chunk_sent: Proc,
|
|
76
|
+
?raise_response_errors: bool
|
|
77
|
+
) -> instance
|
|
78
|
+
| (?Hash[Symbol, untyped]) -> instance
|
|
79
|
+
|
|
80
|
+
|
|
81
|
+
interface _GetEstimatedCarbonEmissionsResponseSuccess
|
|
82
|
+
include ::Seahorse::Client::_ResponseSuccess[Types::GetEstimatedCarbonEmissionsResponse]
|
|
83
|
+
def results: () -> ::Array[Types::EstimatedCarbonEmissions]
|
|
84
|
+
def next_token: () -> ::String
|
|
85
|
+
end
|
|
86
|
+
# https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/Sustainability/Client.html#get_estimated_carbon_emissions-instance_method
|
|
87
|
+
def get_estimated_carbon_emissions: (
|
|
88
|
+
time_period: {
|
|
89
|
+
start: ::Time,
|
|
90
|
+
end: ::Time
|
|
91
|
+
},
|
|
92
|
+
?group_by: Array[("USAGE_ACCOUNT_ID" | "REGION" | "SERVICE")],
|
|
93
|
+
?filter_by: {
|
|
94
|
+
dimensions: Hash[("USAGE_ACCOUNT_ID" | "REGION" | "SERVICE"), Array[::String]]?
|
|
95
|
+
},
|
|
96
|
+
?emissions_types: Array[("TOTAL_LBM_CARBON_EMISSIONS" | "TOTAL_MBM_CARBON_EMISSIONS" | "TOTAL_SCOPE_1_CARBON_EMISSIONS" | "TOTAL_SCOPE_2_LBM_CARBON_EMISSIONS" | "TOTAL_SCOPE_2_MBM_CARBON_EMISSIONS" | "TOTAL_SCOPE_3_LBM_CARBON_EMISSIONS" | "TOTAL_SCOPE_3_MBM_CARBON_EMISSIONS")],
|
|
97
|
+
?granularity: ("YEARLY_CALENDAR" | "YEARLY_FISCAL" | "QUARTERLY_CALENDAR" | "QUARTERLY_FISCAL" | "MONTHLY"),
|
|
98
|
+
?granularity_configuration: {
|
|
99
|
+
fiscal_year_start_month: ::Integer?
|
|
100
|
+
},
|
|
101
|
+
?max_results: ::Integer,
|
|
102
|
+
?next_token: ::String
|
|
103
|
+
) -> _GetEstimatedCarbonEmissionsResponseSuccess
|
|
104
|
+
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _GetEstimatedCarbonEmissionsResponseSuccess
|
|
105
|
+
|
|
106
|
+
interface _GetEstimatedCarbonEmissionsDimensionValuesResponseSuccess
|
|
107
|
+
include ::Seahorse::Client::_ResponseSuccess[Types::GetEstimatedCarbonEmissionsDimensionValuesResponse]
|
|
108
|
+
def results: () -> ::Array[Types::DimensionEntry]
|
|
109
|
+
def next_token: () -> ::String
|
|
110
|
+
end
|
|
111
|
+
# https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/Sustainability/Client.html#get_estimated_carbon_emissions_dimension_values-instance_method
|
|
112
|
+
def get_estimated_carbon_emissions_dimension_values: (
|
|
113
|
+
time_period: {
|
|
114
|
+
start: ::Time,
|
|
115
|
+
end: ::Time
|
|
116
|
+
},
|
|
117
|
+
dimensions: Array[("USAGE_ACCOUNT_ID" | "REGION" | "SERVICE")],
|
|
118
|
+
?max_results: ::Integer,
|
|
119
|
+
?next_token: ::String
|
|
120
|
+
) -> _GetEstimatedCarbonEmissionsDimensionValuesResponseSuccess
|
|
121
|
+
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _GetEstimatedCarbonEmissionsDimensionValuesResponseSuccess
|
|
122
|
+
end
|
|
123
|
+
end
|
|
124
|
+
end
|
|
125
|
+
|
data/sig/errors.rbs
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# WARNING ABOUT GENERATED CODE
|
|
2
|
+
#
|
|
3
|
+
# This file is generated. See the contributing guide for more information:
|
|
4
|
+
# https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
|
|
5
|
+
#
|
|
6
|
+
# WARNING ABOUT GENERATED CODE
|
|
7
|
+
|
|
8
|
+
module Aws
|
|
9
|
+
module Sustainability
|
|
10
|
+
module Errors
|
|
11
|
+
class ServiceError < ::Aws::Errors::ServiceError
|
|
12
|
+
end
|
|
13
|
+
|
|
14
|
+
class AccessDeniedException < ::Aws::Errors::ServiceError
|
|
15
|
+
def message: () -> ::String
|
|
16
|
+
end
|
|
17
|
+
class InternalServerException < ::Aws::Errors::ServiceError
|
|
18
|
+
def message: () -> ::String
|
|
19
|
+
end
|
|
20
|
+
class ThrottlingException < ::Aws::Errors::ServiceError
|
|
21
|
+
def message: () -> ::String
|
|
22
|
+
end
|
|
23
|
+
class ValidationException < ::Aws::Errors::ServiceError
|
|
24
|
+
def message: () -> ::String
|
|
25
|
+
end
|
|
26
|
+
end
|
|
27
|
+
end
|
|
28
|
+
end
|
data/sig/resource.rbs
ADDED
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
# WARNING ABOUT GENERATED CODE
|
|
2
|
+
#
|
|
3
|
+
# This file is generated. See the contributing guide for more information:
|
|
4
|
+
# https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
|
|
5
|
+
#
|
|
6
|
+
# WARNING ABOUT GENERATED CODE
|
|
7
|
+
|
|
8
|
+
module Aws
|
|
9
|
+
module Sustainability
|
|
10
|
+
# https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/Sustainability/Resource.html
|
|
11
|
+
class Resource
|
|
12
|
+
# https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/Sustainability/Resource.html#initialize-instance_method
|
|
13
|
+
def initialize: (
|
|
14
|
+
?client: Client,
|
|
15
|
+
?credentials: untyped,
|
|
16
|
+
?region: String,
|
|
17
|
+
?access_key_id: String,
|
|
18
|
+
?account_id: String,
|
|
19
|
+
?active_endpoint_cache: bool,
|
|
20
|
+
?adaptive_retry_wait_to_fill: bool,
|
|
21
|
+
?auth_scheme_preference: Array[String],
|
|
22
|
+
?client_side_monitoring: bool,
|
|
23
|
+
?client_side_monitoring_client_id: String,
|
|
24
|
+
?client_side_monitoring_host: String,
|
|
25
|
+
?client_side_monitoring_port: Integer,
|
|
26
|
+
?client_side_monitoring_publisher: untyped,
|
|
27
|
+
?convert_params: bool,
|
|
28
|
+
?correct_clock_skew: bool,
|
|
29
|
+
?defaults_mode: String,
|
|
30
|
+
?disable_host_prefix_injection: bool,
|
|
31
|
+
?disable_request_compression: bool,
|
|
32
|
+
?endpoint: String,
|
|
33
|
+
?endpoint_cache_max_entries: Integer,
|
|
34
|
+
?endpoint_cache_max_threads: Integer,
|
|
35
|
+
?endpoint_cache_poll_interval: Integer,
|
|
36
|
+
?endpoint_discovery: bool,
|
|
37
|
+
?ignore_configured_endpoint_urls: bool,
|
|
38
|
+
?log_formatter: untyped,
|
|
39
|
+
?log_level: Symbol,
|
|
40
|
+
?logger: untyped,
|
|
41
|
+
?max_attempts: Integer,
|
|
42
|
+
?profile: String,
|
|
43
|
+
?request_checksum_calculation: String,
|
|
44
|
+
?request_min_compression_size_bytes: Integer,
|
|
45
|
+
?response_checksum_validation: String,
|
|
46
|
+
?retry_backoff: Proc,
|
|
47
|
+
?retry_base_delay: Float,
|
|
48
|
+
?retry_jitter: (:none | :equal | :full | ^(Integer) -> Integer),
|
|
49
|
+
?retry_limit: Integer,
|
|
50
|
+
?retry_max_delay: Integer,
|
|
51
|
+
?retry_mode: ("legacy" | "standard" | "adaptive"),
|
|
52
|
+
?sdk_ua_app_id: String,
|
|
53
|
+
?secret_access_key: String,
|
|
54
|
+
?session_token: String,
|
|
55
|
+
?sigv4a_signing_region_set: Array[String],
|
|
56
|
+
?stub_responses: untyped,
|
|
57
|
+
?telemetry_provider: Aws::Telemetry::TelemetryProviderBase,
|
|
58
|
+
?token_provider: untyped,
|
|
59
|
+
?use_dualstack_endpoint: bool,
|
|
60
|
+
?use_fips_endpoint: bool,
|
|
61
|
+
?validate_params: bool,
|
|
62
|
+
?endpoint_provider: untyped,
|
|
63
|
+
?http_proxy: String,
|
|
64
|
+
?http_open_timeout: (Float | Integer),
|
|
65
|
+
?http_read_timeout: (Float | Integer),
|
|
66
|
+
?http_idle_timeout: (Float | Integer),
|
|
67
|
+
?http_continue_timeout: (Float | Integer),
|
|
68
|
+
?ssl_timeout: (Float | Integer | nil),
|
|
69
|
+
?http_wire_trace: bool,
|
|
70
|
+
?ssl_verify_peer: bool,
|
|
71
|
+
?ssl_ca_bundle: String,
|
|
72
|
+
?ssl_ca_directory: String,
|
|
73
|
+
?ssl_ca_store: String,
|
|
74
|
+
?on_chunk_received: Proc,
|
|
75
|
+
?on_chunk_sent: Proc,
|
|
76
|
+
?raise_response_errors: bool
|
|
77
|
+
) -> void
|
|
78
|
+
| (?Hash[Symbol, untyped]) -> void
|
|
79
|
+
|
|
80
|
+
def client: () -> Client
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+
end
|
|
84
|
+
end
|
|
85
|
+
end
|