blib/lib/Paws/CostExplorer/GetSavingsPlansCoverage.pm untested

filter: Statementstmt 0.0% 0 / 17 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 2 Podpod n/a totaltotal 0.0% 0 / 19 CC 1 SCAR 6.9
CC
1
Cov
0%
BEGIN
2.0
BEGIN
2.0
CRAP 2.0
1  
2 package Paws::CostExplorer::GetSavingsPlansCoverage;
3 use Moose;
4 has Filter => (is => 'ro', isa => 'Paws::CostExplorer::Expression');
5 has Granularity => (is => 'ro', isa => 'Str');
6 has GroupBy => (is => 'ro', isa => 'ArrayRef[Paws::CostExplorer::GroupDefinition]');
7 has MaxResults => (is => 'ro', isa => 'Int');
8 has Metrics => (is => 'ro', isa => 'ArrayRef[Str|Undef]');
9 has NextToken => (is => 'ro', isa => 'Str');
10 has SortBy => (is => 'ro', isa => 'Paws::CostExplorer::SortDefinition');
11 has TimePeriod => (is => 'ro', isa => 'Paws::CostExplorer::DateInterval', required => 1);
12  
13 use MooseX::ClassAttribute;
14  
15 class_has _api_call => (isa => 'Str', is => 'ro', default => 'GetSavingsPlansCoverage');
16 class_has _returns => (isa => 'Str', is => 'ro', default => 'Paws::CostExplorer::GetSavingsPlansCoverageResponse');
17 class_has _result_key => (isa => 'Str', is => 'ro');
18 1;
19  
20 ### main pod documentation begin ###
21  
22 =head1 NAME
23  
24 Paws::CostExplorer::GetSavingsPlansCoverage - Arguments for method GetSavingsPlansCoverage on L<Paws::CostExplorer>
25  
26 =head1 DESCRIPTION
27  
28 This class represents the parameters used for calling the method GetSavingsPlansCoverage on the
29 L<AWS Cost Explorer Service|Paws::CostExplorer> service. Use the attributes of this class
30 as arguments to method GetSavingsPlansCoverage.
31  
32 You shouldn't make instances of this class. Each attribute should be used as a named argument in the call to GetSavingsPlansCoverage.
33  
34 =head1 SYNOPSIS
35  
36 my $ce = Paws->service('CostExplorer');
37 my $GetSavingsPlansCoverageResponse = $ce->GetSavingsPlansCoverage(
38 TimePeriod => {
39 End => 'MyYearMonthDay', # max: 40
40 Start => 'MyYearMonthDay', # max: 40
41  
42 },
43 Filter => {
44 And => [ <Expression>, ... ], # OPTIONAL
45 CostCategories => {
46 Key => 'MyCostCategoryName', # min: 1, max: 50; OPTIONAL
47 MatchOptions => [
48 'EQUALS',
49 ... # values: EQUALS, ABSENT, STARTS_WITH, ENDS_WITH, CONTAINS, CASE_SENSITIVE, CASE_INSENSITIVE
50 ], # OPTIONAL
51 Values => [
52 'MyValue', ... # max: 1024
53 ], # OPTIONAL
54 }, # OPTIONAL
55 Dimensions => {
56 Key => 'AZ'
57 , # values: AZ, INSTANCE_TYPE, LINKED_ACCOUNT, LINKED_ACCOUNT_NAME, OPERATION, PURCHASE_TYPE, REGION, SERVICE, SERVICE_CODE, USAGE_TYPE, USAGE_TYPE_GROUP, RECORD_TYPE, OPERATING_SYSTEM, TENANCY, SCOPE, PLATFORM, SUBSCRIPTION_ID, LEGAL_ENTITY_NAME, DEPLOYMENT_OPTION, DATABASE_ENGINE, CACHE_ENGINE, INSTANCE_TYPE_FAMILY, BILLING_ENTITY, RESERVATION_ID, RESOURCE_ID, RIGHTSIZING_TYPE, SAVINGS_PLANS_TYPE, SAVINGS_PLAN_ARN, PAYMENT_OPTION, AGREEMENT_END_DATE_TIME_AFTER, AGREEMENT_END_DATE_TIME_BEFORE; OPTIONAL
58 MatchOptions => [
59 'EQUALS',
60 ... # values: EQUALS, ABSENT, STARTS_WITH, ENDS_WITH, CONTAINS, CASE_SENSITIVE, CASE_INSENSITIVE
61 ], # OPTIONAL
62 Values => [
63 'MyValue', ... # max: 1024
64 ], # OPTIONAL
65 }, # OPTIONAL
66 Not => <Expression>,
67 Or => [ <Expression>, ... ], # OPTIONAL
68 Tags => {
69 Key => 'MyTagKey', # max: 1024; OPTIONAL
70 MatchOptions => [
71 'EQUALS',
72 ... # values: EQUALS, ABSENT, STARTS_WITH, ENDS_WITH, CONTAINS, CASE_SENSITIVE, CASE_INSENSITIVE
73 ], # OPTIONAL
74 Values => [
75 'MyValue', ... # max: 1024
76 ], # OPTIONAL
77 }, # OPTIONAL
78 }, # OPTIONAL
79 Granularity => 'DAILY', # OPTIONAL
80 GroupBy => [
81 {
82 Key => 'MyGroupDefinitionKey', # max: 1024; OPTIONAL
83 Type => 'DIMENSION', # values: DIMENSION, TAG, COST_CATEGORY; OPTIONAL
84 },
85 ...
86 ], # OPTIONAL
87 MaxResults => 1, # OPTIONAL
88 Metrics => [
89 'MyMetricName', ... # max: 1024
90 ], # OPTIONAL
91 NextToken => 'MyNextPageToken', # OPTIONAL
92 SortBy => {
93 Key => 'MySortDefinitionKey', # max: 1024
94 SortOrder => 'ASCENDING', # values: ASCENDING, DESCENDING; OPTIONAL
95 }, # OPTIONAL
96 );
97  
98 # Results:
99 my $NextToken = $GetSavingsPlansCoverageResponse->NextToken;
100 my $SavingsPlansCoverages =
101 $GetSavingsPlansCoverageResponse->SavingsPlansCoverages;
102  
103 # Returns a L<Paws::CostExplorer::GetSavingsPlansCoverageResponse> object.
104  
105 Values for attributes that are native types (Int, String, Float, etc) can passed as-is (scalar values). Values for complex Types (objects) can be passed as a HashRef. The keys and values of the hashref will be used to instance the underlying object.
106 For the AWS API documentation, see L<https://docs.aws.amazon.com/goto/WebAPI/ce/GetSavingsPlansCoverage>
107  
108 =head1 ATTRIBUTES
109  
110  
111 =head2 Filter => L<Paws::CostExplorer::Expression>
112  
113 Filters Savings Plans coverage data by dimensions. You can filter data
114 for Savings Plans usage with the following dimensions:
115  
116 =over
117  
118 =item *
119  
120 C<LINKED_ACCOUNT>
121  
122 =item *
123  
124 C<REGION>
125  
126 =item *
127  
128 C<SERVICE>
129  
130 =item *
131  
132 C<INSTANCE_FAMILY>
133  
134 =back
135  
136 C<GetSavingsPlansCoverage> uses the same Expression
137 (https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_Expression.html)
138 object as the other operations, but only C<AND> is supported among each
139 dimension. If there are multiple values for a dimension, they are OR'd
140 together.
141  
142 Cost category is also supported.
143  
144  
145  
146 =head2 Granularity => Str
147  
148 The granularity of the Amazon Web Services cost data for your Savings
149 Plans. C<Granularity> can't be set if C<GroupBy> is set.
150  
151 The C<GetSavingsPlansCoverage> operation supports only C<DAILY> and
152 C<MONTHLY> granularities.
153  
154 Valid values are: C<"DAILY">, C<"MONTHLY">, C<"HOURLY">
155  
156 =head2 GroupBy => ArrayRef[L<Paws::CostExplorer::GroupDefinition>]
157  
158 You can group the data using the attributes C<INSTANCE_FAMILY>,
159 C<REGION>, or C<SERVICE>.
160  
161  
162  
163 =head2 MaxResults => Int
164  
165 The number of items to be returned in a response. The default is C<20>,
166 with a minimum value of C<1>.
167  
168  
169  
170 =head2 Metrics => ArrayRef[Str|Undef]
171  
172 The measurement that you want your Savings Plans coverage reported in.
173 The only valid value is C<SpendCoveredBySavingsPlans>.
174  
175  
176  
177 =head2 NextToken => Str
178  
179 The token to retrieve the next set of results. Amazon Web Services
180 provides the token when the response from a previous call has more
181 results than the maximum page size.
182  
183  
184  
185 =head2 SortBy => L<Paws::CostExplorer::SortDefinition>
186  
187 The value by which you want to sort the data.
188  
189 The following values are supported for C<Key>:
190  
191 =over
192  
193 =item *
194  
195 C<SpendCoveredBySavingsPlan>
196  
197 =item *
198  
199 C<OnDemandCost>
200  
201 =item *
202  
203 C<CoveragePercentage>
204  
205 =item *
206  
207 C<TotalCost>
208  
209 =item *
210  
211 C<InstanceFamily>
212  
213 =item *
214  
215 C<Region>
216  
217 =item *
218  
219 C<Service>
220  
221 =back
222  
223 Supported values for C<SortOrder> are C<ASCENDING> or C<DESCENDING>.
224  
225  
226  
227 =head2 B<REQUIRED> TimePeriod => L<Paws::CostExplorer::DateInterval>
228  
229 The time period that you want the usage and costs for. The C<Start>
230 date must be within 13 months. The C<End> date must be after the
231 C<Start> date, and before the current date. Future dates can't be used
232 as an C<End> date.
233  
234  
235  
236  
237 =head1 SEE ALSO
238  
239 This class forms part of L<Paws>, documenting arguments for method GetSavingsPlansCoverage in L<Paws::CostExplorer>
240  
241 =head1 BUGS and CONTRIBUTIONS
242  
243 The source code is located here: L<https://github.com/pplu/aws-sdk-perl>
244  
245 Please report bugs to: L<https://github.com/pplu/aws-sdk-perl/issues>
246  
247 =cut
248