1// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. 2 3package costexplorer 4 5import ( 6 "fmt" 7 8 "github.com/aws/aws-sdk-go/aws" 9 "github.com/aws/aws-sdk-go/aws/awsutil" 10 "github.com/aws/aws-sdk-go/aws/request" 11 "github.com/aws/aws-sdk-go/private/protocol" 12 "github.com/aws/aws-sdk-go/private/protocol/jsonrpc" 13) 14 15const opCreateAnomalyMonitor = "CreateAnomalyMonitor" 16 17// CreateAnomalyMonitorRequest generates a "aws/request.Request" representing the 18// client's request for the CreateAnomalyMonitor operation. The "output" return 19// value will be populated with the request's response once the request completes 20// successfully. 21// 22// Use "Send" method on the returned Request to send the API call to the service. 23// the "output" return value is not valid until after Send returns without error. 24// 25// See CreateAnomalyMonitor for more information on using the CreateAnomalyMonitor 26// API call, and error handling. 27// 28// This method is useful when you want to inject custom logic or configuration 29// into the SDK's request lifecycle. Such as custom headers, or retry logic. 30// 31// 32// // Example sending a request using the CreateAnomalyMonitorRequest method. 33// req, resp := client.CreateAnomalyMonitorRequest(params) 34// 35// err := req.Send() 36// if err == nil { // resp is now filled 37// fmt.Println(resp) 38// } 39// 40// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/CreateAnomalyMonitor 41func (c *CostExplorer) CreateAnomalyMonitorRequest(input *CreateAnomalyMonitorInput) (req *request.Request, output *CreateAnomalyMonitorOutput) { 42 op := &request.Operation{ 43 Name: opCreateAnomalyMonitor, 44 HTTPMethod: "POST", 45 HTTPPath: "/", 46 } 47 48 if input == nil { 49 input = &CreateAnomalyMonitorInput{} 50 } 51 52 output = &CreateAnomalyMonitorOutput{} 53 req = c.newRequest(op, input, output) 54 return 55} 56 57// CreateAnomalyMonitor API operation for AWS Cost Explorer Service. 58// 59// Creates a new cost anomaly detection monitor with the requested type and 60// monitor specification. 61// 62// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 63// with awserr.Error's Code and Message methods to get detailed information about 64// the error. 65// 66// See the AWS API reference guide for AWS Cost Explorer Service's 67// API operation CreateAnomalyMonitor for usage and error information. 68// 69// Returned Error Types: 70// * LimitExceededException 71// You made too many calls in a short period of time. Try again later. 72// 73// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/CreateAnomalyMonitor 74func (c *CostExplorer) CreateAnomalyMonitor(input *CreateAnomalyMonitorInput) (*CreateAnomalyMonitorOutput, error) { 75 req, out := c.CreateAnomalyMonitorRequest(input) 76 return out, req.Send() 77} 78 79// CreateAnomalyMonitorWithContext is the same as CreateAnomalyMonitor with the addition of 80// the ability to pass a context and additional request options. 81// 82// See CreateAnomalyMonitor for details on how to use this API operation. 83// 84// The context must be non-nil and will be used for request cancellation. If 85// the context is nil a panic will occur. In the future the SDK may create 86// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 87// for more information on using Contexts. 88func (c *CostExplorer) CreateAnomalyMonitorWithContext(ctx aws.Context, input *CreateAnomalyMonitorInput, opts ...request.Option) (*CreateAnomalyMonitorOutput, error) { 89 req, out := c.CreateAnomalyMonitorRequest(input) 90 req.SetContext(ctx) 91 req.ApplyOptions(opts...) 92 return out, req.Send() 93} 94 95const opCreateAnomalySubscription = "CreateAnomalySubscription" 96 97// CreateAnomalySubscriptionRequest generates a "aws/request.Request" representing the 98// client's request for the CreateAnomalySubscription operation. The "output" return 99// value will be populated with the request's response once the request completes 100// successfully. 101// 102// Use "Send" method on the returned Request to send the API call to the service. 103// the "output" return value is not valid until after Send returns without error. 104// 105// See CreateAnomalySubscription for more information on using the CreateAnomalySubscription 106// API call, and error handling. 107// 108// This method is useful when you want to inject custom logic or configuration 109// into the SDK's request lifecycle. Such as custom headers, or retry logic. 110// 111// 112// // Example sending a request using the CreateAnomalySubscriptionRequest method. 113// req, resp := client.CreateAnomalySubscriptionRequest(params) 114// 115// err := req.Send() 116// if err == nil { // resp is now filled 117// fmt.Println(resp) 118// } 119// 120// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/CreateAnomalySubscription 121func (c *CostExplorer) CreateAnomalySubscriptionRequest(input *CreateAnomalySubscriptionInput) (req *request.Request, output *CreateAnomalySubscriptionOutput) { 122 op := &request.Operation{ 123 Name: opCreateAnomalySubscription, 124 HTTPMethod: "POST", 125 HTTPPath: "/", 126 } 127 128 if input == nil { 129 input = &CreateAnomalySubscriptionInput{} 130 } 131 132 output = &CreateAnomalySubscriptionOutput{} 133 req = c.newRequest(op, input, output) 134 return 135} 136 137// CreateAnomalySubscription API operation for AWS Cost Explorer Service. 138// 139// Adds a subscription to a cost anomaly detection monitor. You can use each 140// subscription to define subscribers with email or SNS notifications. Email 141// subscribers can set a dollar threshold and a time frequency for receiving 142// notifications. 143// 144// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 145// with awserr.Error's Code and Message methods to get detailed information about 146// the error. 147// 148// See the AWS API reference guide for AWS Cost Explorer Service's 149// API operation CreateAnomalySubscription for usage and error information. 150// 151// Returned Error Types: 152// * UnknownMonitorException 153// The cost anomaly monitor does not exist for the account. 154// 155// * LimitExceededException 156// You made too many calls in a short period of time. Try again later. 157// 158// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/CreateAnomalySubscription 159func (c *CostExplorer) CreateAnomalySubscription(input *CreateAnomalySubscriptionInput) (*CreateAnomalySubscriptionOutput, error) { 160 req, out := c.CreateAnomalySubscriptionRequest(input) 161 return out, req.Send() 162} 163 164// CreateAnomalySubscriptionWithContext is the same as CreateAnomalySubscription with the addition of 165// the ability to pass a context and additional request options. 166// 167// See CreateAnomalySubscription for details on how to use this API operation. 168// 169// The context must be non-nil and will be used for request cancellation. If 170// the context is nil a panic will occur. In the future the SDK may create 171// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 172// for more information on using Contexts. 173func (c *CostExplorer) CreateAnomalySubscriptionWithContext(ctx aws.Context, input *CreateAnomalySubscriptionInput, opts ...request.Option) (*CreateAnomalySubscriptionOutput, error) { 174 req, out := c.CreateAnomalySubscriptionRequest(input) 175 req.SetContext(ctx) 176 req.ApplyOptions(opts...) 177 return out, req.Send() 178} 179 180const opCreateCostCategoryDefinition = "CreateCostCategoryDefinition" 181 182// CreateCostCategoryDefinitionRequest generates a "aws/request.Request" representing the 183// client's request for the CreateCostCategoryDefinition operation. The "output" return 184// value will be populated with the request's response once the request completes 185// successfully. 186// 187// Use "Send" method on the returned Request to send the API call to the service. 188// the "output" return value is not valid until after Send returns without error. 189// 190// See CreateCostCategoryDefinition for more information on using the CreateCostCategoryDefinition 191// API call, and error handling. 192// 193// This method is useful when you want to inject custom logic or configuration 194// into the SDK's request lifecycle. Such as custom headers, or retry logic. 195// 196// 197// // Example sending a request using the CreateCostCategoryDefinitionRequest method. 198// req, resp := client.CreateCostCategoryDefinitionRequest(params) 199// 200// err := req.Send() 201// if err == nil { // resp is now filled 202// fmt.Println(resp) 203// } 204// 205// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/CreateCostCategoryDefinition 206func (c *CostExplorer) CreateCostCategoryDefinitionRequest(input *CreateCostCategoryDefinitionInput) (req *request.Request, output *CreateCostCategoryDefinitionOutput) { 207 op := &request.Operation{ 208 Name: opCreateCostCategoryDefinition, 209 HTTPMethod: "POST", 210 HTTPPath: "/", 211 } 212 213 if input == nil { 214 input = &CreateCostCategoryDefinitionInput{} 215 } 216 217 output = &CreateCostCategoryDefinitionOutput{} 218 req = c.newRequest(op, input, output) 219 return 220} 221 222// CreateCostCategoryDefinition API operation for AWS Cost Explorer Service. 223// 224// Creates a new Cost Category with the requested name and rules. 225// 226// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 227// with awserr.Error's Code and Message methods to get detailed information about 228// the error. 229// 230// See the AWS API reference guide for AWS Cost Explorer Service's 231// API operation CreateCostCategoryDefinition for usage and error information. 232// 233// Returned Error Types: 234// * ServiceQuotaExceededException 235// You've reached the limit on the number of resources you can create, or exceeded 236// the size of an individual resource. 237// 238// * LimitExceededException 239// You made too many calls in a short period of time. Try again later. 240// 241// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/CreateCostCategoryDefinition 242func (c *CostExplorer) CreateCostCategoryDefinition(input *CreateCostCategoryDefinitionInput) (*CreateCostCategoryDefinitionOutput, error) { 243 req, out := c.CreateCostCategoryDefinitionRequest(input) 244 return out, req.Send() 245} 246 247// CreateCostCategoryDefinitionWithContext is the same as CreateCostCategoryDefinition with the addition of 248// the ability to pass a context and additional request options. 249// 250// See CreateCostCategoryDefinition for details on how to use this API operation. 251// 252// The context must be non-nil and will be used for request cancellation. If 253// the context is nil a panic will occur. In the future the SDK may create 254// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 255// for more information on using Contexts. 256func (c *CostExplorer) CreateCostCategoryDefinitionWithContext(ctx aws.Context, input *CreateCostCategoryDefinitionInput, opts ...request.Option) (*CreateCostCategoryDefinitionOutput, error) { 257 req, out := c.CreateCostCategoryDefinitionRequest(input) 258 req.SetContext(ctx) 259 req.ApplyOptions(opts...) 260 return out, req.Send() 261} 262 263const opDeleteAnomalyMonitor = "DeleteAnomalyMonitor" 264 265// DeleteAnomalyMonitorRequest generates a "aws/request.Request" representing the 266// client's request for the DeleteAnomalyMonitor operation. The "output" return 267// value will be populated with the request's response once the request completes 268// successfully. 269// 270// Use "Send" method on the returned Request to send the API call to the service. 271// the "output" return value is not valid until after Send returns without error. 272// 273// See DeleteAnomalyMonitor for more information on using the DeleteAnomalyMonitor 274// API call, and error handling. 275// 276// This method is useful when you want to inject custom logic or configuration 277// into the SDK's request lifecycle. Such as custom headers, or retry logic. 278// 279// 280// // Example sending a request using the DeleteAnomalyMonitorRequest method. 281// req, resp := client.DeleteAnomalyMonitorRequest(params) 282// 283// err := req.Send() 284// if err == nil { // resp is now filled 285// fmt.Println(resp) 286// } 287// 288// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/DeleteAnomalyMonitor 289func (c *CostExplorer) DeleteAnomalyMonitorRequest(input *DeleteAnomalyMonitorInput) (req *request.Request, output *DeleteAnomalyMonitorOutput) { 290 op := &request.Operation{ 291 Name: opDeleteAnomalyMonitor, 292 HTTPMethod: "POST", 293 HTTPPath: "/", 294 } 295 296 if input == nil { 297 input = &DeleteAnomalyMonitorInput{} 298 } 299 300 output = &DeleteAnomalyMonitorOutput{} 301 req = c.newRequest(op, input, output) 302 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 303 return 304} 305 306// DeleteAnomalyMonitor API operation for AWS Cost Explorer Service. 307// 308// Deletes a cost anomaly monitor. 309// 310// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 311// with awserr.Error's Code and Message methods to get detailed information about 312// the error. 313// 314// See the AWS API reference guide for AWS Cost Explorer Service's 315// API operation DeleteAnomalyMonitor for usage and error information. 316// 317// Returned Error Types: 318// * LimitExceededException 319// You made too many calls in a short period of time. Try again later. 320// 321// * UnknownMonitorException 322// The cost anomaly monitor does not exist for the account. 323// 324// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/DeleteAnomalyMonitor 325func (c *CostExplorer) DeleteAnomalyMonitor(input *DeleteAnomalyMonitorInput) (*DeleteAnomalyMonitorOutput, error) { 326 req, out := c.DeleteAnomalyMonitorRequest(input) 327 return out, req.Send() 328} 329 330// DeleteAnomalyMonitorWithContext is the same as DeleteAnomalyMonitor with the addition of 331// the ability to pass a context and additional request options. 332// 333// See DeleteAnomalyMonitor for details on how to use this API operation. 334// 335// The context must be non-nil and will be used for request cancellation. If 336// the context is nil a panic will occur. In the future the SDK may create 337// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 338// for more information on using Contexts. 339func (c *CostExplorer) DeleteAnomalyMonitorWithContext(ctx aws.Context, input *DeleteAnomalyMonitorInput, opts ...request.Option) (*DeleteAnomalyMonitorOutput, error) { 340 req, out := c.DeleteAnomalyMonitorRequest(input) 341 req.SetContext(ctx) 342 req.ApplyOptions(opts...) 343 return out, req.Send() 344} 345 346const opDeleteAnomalySubscription = "DeleteAnomalySubscription" 347 348// DeleteAnomalySubscriptionRequest generates a "aws/request.Request" representing the 349// client's request for the DeleteAnomalySubscription operation. The "output" return 350// value will be populated with the request's response once the request completes 351// successfully. 352// 353// Use "Send" method on the returned Request to send the API call to the service. 354// the "output" return value is not valid until after Send returns without error. 355// 356// See DeleteAnomalySubscription for more information on using the DeleteAnomalySubscription 357// API call, and error handling. 358// 359// This method is useful when you want to inject custom logic or configuration 360// into the SDK's request lifecycle. Such as custom headers, or retry logic. 361// 362// 363// // Example sending a request using the DeleteAnomalySubscriptionRequest method. 364// req, resp := client.DeleteAnomalySubscriptionRequest(params) 365// 366// err := req.Send() 367// if err == nil { // resp is now filled 368// fmt.Println(resp) 369// } 370// 371// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/DeleteAnomalySubscription 372func (c *CostExplorer) DeleteAnomalySubscriptionRequest(input *DeleteAnomalySubscriptionInput) (req *request.Request, output *DeleteAnomalySubscriptionOutput) { 373 op := &request.Operation{ 374 Name: opDeleteAnomalySubscription, 375 HTTPMethod: "POST", 376 HTTPPath: "/", 377 } 378 379 if input == nil { 380 input = &DeleteAnomalySubscriptionInput{} 381 } 382 383 output = &DeleteAnomalySubscriptionOutput{} 384 req = c.newRequest(op, input, output) 385 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 386 return 387} 388 389// DeleteAnomalySubscription API operation for AWS Cost Explorer Service. 390// 391// Deletes a cost anomaly subscription. 392// 393// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 394// with awserr.Error's Code and Message methods to get detailed information about 395// the error. 396// 397// See the AWS API reference guide for AWS Cost Explorer Service's 398// API operation DeleteAnomalySubscription for usage and error information. 399// 400// Returned Error Types: 401// * LimitExceededException 402// You made too many calls in a short period of time. Try again later. 403// 404// * UnknownSubscriptionException 405// The cost anomaly subscription does not exist for the account. 406// 407// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/DeleteAnomalySubscription 408func (c *CostExplorer) DeleteAnomalySubscription(input *DeleteAnomalySubscriptionInput) (*DeleteAnomalySubscriptionOutput, error) { 409 req, out := c.DeleteAnomalySubscriptionRequest(input) 410 return out, req.Send() 411} 412 413// DeleteAnomalySubscriptionWithContext is the same as DeleteAnomalySubscription with the addition of 414// the ability to pass a context and additional request options. 415// 416// See DeleteAnomalySubscription for details on how to use this API operation. 417// 418// The context must be non-nil and will be used for request cancellation. If 419// the context is nil a panic will occur. In the future the SDK may create 420// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 421// for more information on using Contexts. 422func (c *CostExplorer) DeleteAnomalySubscriptionWithContext(ctx aws.Context, input *DeleteAnomalySubscriptionInput, opts ...request.Option) (*DeleteAnomalySubscriptionOutput, error) { 423 req, out := c.DeleteAnomalySubscriptionRequest(input) 424 req.SetContext(ctx) 425 req.ApplyOptions(opts...) 426 return out, req.Send() 427} 428 429const opDeleteCostCategoryDefinition = "DeleteCostCategoryDefinition" 430 431// DeleteCostCategoryDefinitionRequest generates a "aws/request.Request" representing the 432// client's request for the DeleteCostCategoryDefinition operation. The "output" return 433// value will be populated with the request's response once the request completes 434// successfully. 435// 436// Use "Send" method on the returned Request to send the API call to the service. 437// the "output" return value is not valid until after Send returns without error. 438// 439// See DeleteCostCategoryDefinition for more information on using the DeleteCostCategoryDefinition 440// API call, and error handling. 441// 442// This method is useful when you want to inject custom logic or configuration 443// into the SDK's request lifecycle. Such as custom headers, or retry logic. 444// 445// 446// // Example sending a request using the DeleteCostCategoryDefinitionRequest method. 447// req, resp := client.DeleteCostCategoryDefinitionRequest(params) 448// 449// err := req.Send() 450// if err == nil { // resp is now filled 451// fmt.Println(resp) 452// } 453// 454// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/DeleteCostCategoryDefinition 455func (c *CostExplorer) DeleteCostCategoryDefinitionRequest(input *DeleteCostCategoryDefinitionInput) (req *request.Request, output *DeleteCostCategoryDefinitionOutput) { 456 op := &request.Operation{ 457 Name: opDeleteCostCategoryDefinition, 458 HTTPMethod: "POST", 459 HTTPPath: "/", 460 } 461 462 if input == nil { 463 input = &DeleteCostCategoryDefinitionInput{} 464 } 465 466 output = &DeleteCostCategoryDefinitionOutput{} 467 req = c.newRequest(op, input, output) 468 return 469} 470 471// DeleteCostCategoryDefinition API operation for AWS Cost Explorer Service. 472// 473// Deletes a Cost Category. Expenses from this month going forward will no longer 474// be categorized with this Cost Category. 475// 476// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 477// with awserr.Error's Code and Message methods to get detailed information about 478// the error. 479// 480// See the AWS API reference guide for AWS Cost Explorer Service's 481// API operation DeleteCostCategoryDefinition for usage and error information. 482// 483// Returned Error Types: 484// * ResourceNotFoundException 485// The specified ARN in the request doesn't exist. 486// 487// * LimitExceededException 488// You made too many calls in a short period of time. Try again later. 489// 490// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/DeleteCostCategoryDefinition 491func (c *CostExplorer) DeleteCostCategoryDefinition(input *DeleteCostCategoryDefinitionInput) (*DeleteCostCategoryDefinitionOutput, error) { 492 req, out := c.DeleteCostCategoryDefinitionRequest(input) 493 return out, req.Send() 494} 495 496// DeleteCostCategoryDefinitionWithContext is the same as DeleteCostCategoryDefinition with the addition of 497// the ability to pass a context and additional request options. 498// 499// See DeleteCostCategoryDefinition for details on how to use this API operation. 500// 501// The context must be non-nil and will be used for request cancellation. If 502// the context is nil a panic will occur. In the future the SDK may create 503// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 504// for more information on using Contexts. 505func (c *CostExplorer) DeleteCostCategoryDefinitionWithContext(ctx aws.Context, input *DeleteCostCategoryDefinitionInput, opts ...request.Option) (*DeleteCostCategoryDefinitionOutput, error) { 506 req, out := c.DeleteCostCategoryDefinitionRequest(input) 507 req.SetContext(ctx) 508 req.ApplyOptions(opts...) 509 return out, req.Send() 510} 511 512const opDescribeCostCategoryDefinition = "DescribeCostCategoryDefinition" 513 514// DescribeCostCategoryDefinitionRequest generates a "aws/request.Request" representing the 515// client's request for the DescribeCostCategoryDefinition operation. The "output" return 516// value will be populated with the request's response once the request completes 517// successfully. 518// 519// Use "Send" method on the returned Request to send the API call to the service. 520// the "output" return value is not valid until after Send returns without error. 521// 522// See DescribeCostCategoryDefinition for more information on using the DescribeCostCategoryDefinition 523// API call, and error handling. 524// 525// This method is useful when you want to inject custom logic or configuration 526// into the SDK's request lifecycle. Such as custom headers, or retry logic. 527// 528// 529// // Example sending a request using the DescribeCostCategoryDefinitionRequest method. 530// req, resp := client.DescribeCostCategoryDefinitionRequest(params) 531// 532// err := req.Send() 533// if err == nil { // resp is now filled 534// fmt.Println(resp) 535// } 536// 537// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/DescribeCostCategoryDefinition 538func (c *CostExplorer) DescribeCostCategoryDefinitionRequest(input *DescribeCostCategoryDefinitionInput) (req *request.Request, output *DescribeCostCategoryDefinitionOutput) { 539 op := &request.Operation{ 540 Name: opDescribeCostCategoryDefinition, 541 HTTPMethod: "POST", 542 HTTPPath: "/", 543 } 544 545 if input == nil { 546 input = &DescribeCostCategoryDefinitionInput{} 547 } 548 549 output = &DescribeCostCategoryDefinitionOutput{} 550 req = c.newRequest(op, input, output) 551 return 552} 553 554// DescribeCostCategoryDefinition API operation for AWS Cost Explorer Service. 555// 556// Returns the name, ARN, rules, definition, and effective dates of a Cost Category 557// that's defined in the account. 558// 559// You have the option to use EffectiveOn to return a Cost Category that is 560// active on a specific date. If there is no EffectiveOn specified, you’ll 561// see a Cost Category that is effective on the current date. If Cost Category 562// is still effective, EffectiveEnd is omitted in the response. 563// 564// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 565// with awserr.Error's Code and Message methods to get detailed information about 566// the error. 567// 568// See the AWS API reference guide for AWS Cost Explorer Service's 569// API operation DescribeCostCategoryDefinition for usage and error information. 570// 571// Returned Error Types: 572// * ResourceNotFoundException 573// The specified ARN in the request doesn't exist. 574// 575// * LimitExceededException 576// You made too many calls in a short period of time. Try again later. 577// 578// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/DescribeCostCategoryDefinition 579func (c *CostExplorer) DescribeCostCategoryDefinition(input *DescribeCostCategoryDefinitionInput) (*DescribeCostCategoryDefinitionOutput, error) { 580 req, out := c.DescribeCostCategoryDefinitionRequest(input) 581 return out, req.Send() 582} 583 584// DescribeCostCategoryDefinitionWithContext is the same as DescribeCostCategoryDefinition with the addition of 585// the ability to pass a context and additional request options. 586// 587// See DescribeCostCategoryDefinition for details on how to use this API operation. 588// 589// The context must be non-nil and will be used for request cancellation. If 590// the context is nil a panic will occur. In the future the SDK may create 591// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 592// for more information on using Contexts. 593func (c *CostExplorer) DescribeCostCategoryDefinitionWithContext(ctx aws.Context, input *DescribeCostCategoryDefinitionInput, opts ...request.Option) (*DescribeCostCategoryDefinitionOutput, error) { 594 req, out := c.DescribeCostCategoryDefinitionRequest(input) 595 req.SetContext(ctx) 596 req.ApplyOptions(opts...) 597 return out, req.Send() 598} 599 600const opGetAnomalies = "GetAnomalies" 601 602// GetAnomaliesRequest generates a "aws/request.Request" representing the 603// client's request for the GetAnomalies operation. The "output" return 604// value will be populated with the request's response once the request completes 605// successfully. 606// 607// Use "Send" method on the returned Request to send the API call to the service. 608// the "output" return value is not valid until after Send returns without error. 609// 610// See GetAnomalies for more information on using the GetAnomalies 611// API call, and error handling. 612// 613// This method is useful when you want to inject custom logic or configuration 614// into the SDK's request lifecycle. Such as custom headers, or retry logic. 615// 616// 617// // Example sending a request using the GetAnomaliesRequest method. 618// req, resp := client.GetAnomaliesRequest(params) 619// 620// err := req.Send() 621// if err == nil { // resp is now filled 622// fmt.Println(resp) 623// } 624// 625// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetAnomalies 626func (c *CostExplorer) GetAnomaliesRequest(input *GetAnomaliesInput) (req *request.Request, output *GetAnomaliesOutput) { 627 op := &request.Operation{ 628 Name: opGetAnomalies, 629 HTTPMethod: "POST", 630 HTTPPath: "/", 631 } 632 633 if input == nil { 634 input = &GetAnomaliesInput{} 635 } 636 637 output = &GetAnomaliesOutput{} 638 req = c.newRequest(op, input, output) 639 return 640} 641 642// GetAnomalies API operation for AWS Cost Explorer Service. 643// 644// Retrieves all of the cost anomalies detected on your account, during the 645// time period specified by the DateInterval object. 646// 647// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 648// with awserr.Error's Code and Message methods to get detailed information about 649// the error. 650// 651// See the AWS API reference guide for AWS Cost Explorer Service's 652// API operation GetAnomalies for usage and error information. 653// 654// Returned Error Types: 655// * LimitExceededException 656// You made too many calls in a short period of time. Try again later. 657// 658// * InvalidNextTokenException 659// The pagination token is invalid. Try again without a pagination token. 660// 661// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetAnomalies 662func (c *CostExplorer) GetAnomalies(input *GetAnomaliesInput) (*GetAnomaliesOutput, error) { 663 req, out := c.GetAnomaliesRequest(input) 664 return out, req.Send() 665} 666 667// GetAnomaliesWithContext is the same as GetAnomalies with the addition of 668// the ability to pass a context and additional request options. 669// 670// See GetAnomalies for details on how to use this API operation. 671// 672// The context must be non-nil and will be used for request cancellation. If 673// the context is nil a panic will occur. In the future the SDK may create 674// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 675// for more information on using Contexts. 676func (c *CostExplorer) GetAnomaliesWithContext(ctx aws.Context, input *GetAnomaliesInput, opts ...request.Option) (*GetAnomaliesOutput, error) { 677 req, out := c.GetAnomaliesRequest(input) 678 req.SetContext(ctx) 679 req.ApplyOptions(opts...) 680 return out, req.Send() 681} 682 683const opGetAnomalyMonitors = "GetAnomalyMonitors" 684 685// GetAnomalyMonitorsRequest generates a "aws/request.Request" representing the 686// client's request for the GetAnomalyMonitors operation. The "output" return 687// value will be populated with the request's response once the request completes 688// successfully. 689// 690// Use "Send" method on the returned Request to send the API call to the service. 691// the "output" return value is not valid until after Send returns without error. 692// 693// See GetAnomalyMonitors for more information on using the GetAnomalyMonitors 694// API call, and error handling. 695// 696// This method is useful when you want to inject custom logic or configuration 697// into the SDK's request lifecycle. Such as custom headers, or retry logic. 698// 699// 700// // Example sending a request using the GetAnomalyMonitorsRequest method. 701// req, resp := client.GetAnomalyMonitorsRequest(params) 702// 703// err := req.Send() 704// if err == nil { // resp is now filled 705// fmt.Println(resp) 706// } 707// 708// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetAnomalyMonitors 709func (c *CostExplorer) GetAnomalyMonitorsRequest(input *GetAnomalyMonitorsInput) (req *request.Request, output *GetAnomalyMonitorsOutput) { 710 op := &request.Operation{ 711 Name: opGetAnomalyMonitors, 712 HTTPMethod: "POST", 713 HTTPPath: "/", 714 } 715 716 if input == nil { 717 input = &GetAnomalyMonitorsInput{} 718 } 719 720 output = &GetAnomalyMonitorsOutput{} 721 req = c.newRequest(op, input, output) 722 return 723} 724 725// GetAnomalyMonitors API operation for AWS Cost Explorer Service. 726// 727// Retrieves the cost anomaly monitor definitions for your account. You can 728// filter using a list of cost anomaly monitor Amazon Resource Names (ARNs). 729// 730// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 731// with awserr.Error's Code and Message methods to get detailed information about 732// the error. 733// 734// See the AWS API reference guide for AWS Cost Explorer Service's 735// API operation GetAnomalyMonitors for usage and error information. 736// 737// Returned Error Types: 738// * LimitExceededException 739// You made too many calls in a short period of time. Try again later. 740// 741// * UnknownMonitorException 742// The cost anomaly monitor does not exist for the account. 743// 744// * InvalidNextTokenException 745// The pagination token is invalid. Try again without a pagination token. 746// 747// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetAnomalyMonitors 748func (c *CostExplorer) GetAnomalyMonitors(input *GetAnomalyMonitorsInput) (*GetAnomalyMonitorsOutput, error) { 749 req, out := c.GetAnomalyMonitorsRequest(input) 750 return out, req.Send() 751} 752 753// GetAnomalyMonitorsWithContext is the same as GetAnomalyMonitors with the addition of 754// the ability to pass a context and additional request options. 755// 756// See GetAnomalyMonitors for details on how to use this API operation. 757// 758// The context must be non-nil and will be used for request cancellation. If 759// the context is nil a panic will occur. In the future the SDK may create 760// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 761// for more information on using Contexts. 762func (c *CostExplorer) GetAnomalyMonitorsWithContext(ctx aws.Context, input *GetAnomalyMonitorsInput, opts ...request.Option) (*GetAnomalyMonitorsOutput, error) { 763 req, out := c.GetAnomalyMonitorsRequest(input) 764 req.SetContext(ctx) 765 req.ApplyOptions(opts...) 766 return out, req.Send() 767} 768 769const opGetAnomalySubscriptions = "GetAnomalySubscriptions" 770 771// GetAnomalySubscriptionsRequest generates a "aws/request.Request" representing the 772// client's request for the GetAnomalySubscriptions operation. The "output" return 773// value will be populated with the request's response once the request completes 774// successfully. 775// 776// Use "Send" method on the returned Request to send the API call to the service. 777// the "output" return value is not valid until after Send returns without error. 778// 779// See GetAnomalySubscriptions for more information on using the GetAnomalySubscriptions 780// API call, and error handling. 781// 782// This method is useful when you want to inject custom logic or configuration 783// into the SDK's request lifecycle. Such as custom headers, or retry logic. 784// 785// 786// // Example sending a request using the GetAnomalySubscriptionsRequest method. 787// req, resp := client.GetAnomalySubscriptionsRequest(params) 788// 789// err := req.Send() 790// if err == nil { // resp is now filled 791// fmt.Println(resp) 792// } 793// 794// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetAnomalySubscriptions 795func (c *CostExplorer) GetAnomalySubscriptionsRequest(input *GetAnomalySubscriptionsInput) (req *request.Request, output *GetAnomalySubscriptionsOutput) { 796 op := &request.Operation{ 797 Name: opGetAnomalySubscriptions, 798 HTTPMethod: "POST", 799 HTTPPath: "/", 800 } 801 802 if input == nil { 803 input = &GetAnomalySubscriptionsInput{} 804 } 805 806 output = &GetAnomalySubscriptionsOutput{} 807 req = c.newRequest(op, input, output) 808 return 809} 810 811// GetAnomalySubscriptions API operation for AWS Cost Explorer Service. 812// 813// Retrieves the cost anomaly subscription objects for your account. You can 814// filter using a list of cost anomaly monitor Amazon Resource Names (ARNs). 815// 816// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 817// with awserr.Error's Code and Message methods to get detailed information about 818// the error. 819// 820// See the AWS API reference guide for AWS Cost Explorer Service's 821// API operation GetAnomalySubscriptions for usage and error information. 822// 823// Returned Error Types: 824// * LimitExceededException 825// You made too many calls in a short period of time. Try again later. 826// 827// * UnknownSubscriptionException 828// The cost anomaly subscription does not exist for the account. 829// 830// * InvalidNextTokenException 831// The pagination token is invalid. Try again without a pagination token. 832// 833// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetAnomalySubscriptions 834func (c *CostExplorer) GetAnomalySubscriptions(input *GetAnomalySubscriptionsInput) (*GetAnomalySubscriptionsOutput, error) { 835 req, out := c.GetAnomalySubscriptionsRequest(input) 836 return out, req.Send() 837} 838 839// GetAnomalySubscriptionsWithContext is the same as GetAnomalySubscriptions with the addition of 840// the ability to pass a context and additional request options. 841// 842// See GetAnomalySubscriptions for details on how to use this API operation. 843// 844// The context must be non-nil and will be used for request cancellation. If 845// the context is nil a panic will occur. In the future the SDK may create 846// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 847// for more information on using Contexts. 848func (c *CostExplorer) GetAnomalySubscriptionsWithContext(ctx aws.Context, input *GetAnomalySubscriptionsInput, opts ...request.Option) (*GetAnomalySubscriptionsOutput, error) { 849 req, out := c.GetAnomalySubscriptionsRequest(input) 850 req.SetContext(ctx) 851 req.ApplyOptions(opts...) 852 return out, req.Send() 853} 854 855const opGetCostAndUsage = "GetCostAndUsage" 856 857// GetCostAndUsageRequest generates a "aws/request.Request" representing the 858// client's request for the GetCostAndUsage operation. The "output" return 859// value will be populated with the request's response once the request completes 860// successfully. 861// 862// Use "Send" method on the returned Request to send the API call to the service. 863// the "output" return value is not valid until after Send returns without error. 864// 865// See GetCostAndUsage for more information on using the GetCostAndUsage 866// API call, and error handling. 867// 868// This method is useful when you want to inject custom logic or configuration 869// into the SDK's request lifecycle. Such as custom headers, or retry logic. 870// 871// 872// // Example sending a request using the GetCostAndUsageRequest method. 873// req, resp := client.GetCostAndUsageRequest(params) 874// 875// err := req.Send() 876// if err == nil { // resp is now filled 877// fmt.Println(resp) 878// } 879// 880// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetCostAndUsage 881func (c *CostExplorer) GetCostAndUsageRequest(input *GetCostAndUsageInput) (req *request.Request, output *GetCostAndUsageOutput) { 882 op := &request.Operation{ 883 Name: opGetCostAndUsage, 884 HTTPMethod: "POST", 885 HTTPPath: "/", 886 } 887 888 if input == nil { 889 input = &GetCostAndUsageInput{} 890 } 891 892 output = &GetCostAndUsageOutput{} 893 req = c.newRequest(op, input, output) 894 return 895} 896 897// GetCostAndUsage API operation for AWS Cost Explorer Service. 898// 899// Retrieves cost and usage metrics for your account. You can specify which 900// cost and usage-related metric, such as BlendedCosts or UsageQuantity, that 901// you want the request to return. You can also filter and group your data by 902// various dimensions, such as SERVICE or AZ, in a specific time range. For 903// a complete list of valid dimensions, see the GetDimensionValues (https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_GetDimensionValues.html) 904// operation. Management account in an organization in AWS Organizations have 905// access to all member accounts. 906// 907// For information about filter limitations, see Quotas and restrictions (https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/billing-limits.html) 908// in the Billing and Cost Management User Guide. 909// 910// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 911// with awserr.Error's Code and Message methods to get detailed information about 912// the error. 913// 914// See the AWS API reference guide for AWS Cost Explorer Service's 915// API operation GetCostAndUsage for usage and error information. 916// 917// Returned Error Types: 918// * LimitExceededException 919// You made too many calls in a short period of time. Try again later. 920// 921// * BillExpirationException 922// The requested report expired. Update the date interval and try again. 923// 924// * DataUnavailableException 925// The requested data is unavailable. 926// 927// * InvalidNextTokenException 928// The pagination token is invalid. Try again without a pagination token. 929// 930// * RequestChangedException 931// Your request parameters changed between pages. Try again with the old parameters 932// or without a pagination token. 933// 934// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetCostAndUsage 935func (c *CostExplorer) GetCostAndUsage(input *GetCostAndUsageInput) (*GetCostAndUsageOutput, error) { 936 req, out := c.GetCostAndUsageRequest(input) 937 return out, req.Send() 938} 939 940// GetCostAndUsageWithContext is the same as GetCostAndUsage with the addition of 941// the ability to pass a context and additional request options. 942// 943// See GetCostAndUsage for details on how to use this API operation. 944// 945// The context must be non-nil and will be used for request cancellation. If 946// the context is nil a panic will occur. In the future the SDK may create 947// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 948// for more information on using Contexts. 949func (c *CostExplorer) GetCostAndUsageWithContext(ctx aws.Context, input *GetCostAndUsageInput, opts ...request.Option) (*GetCostAndUsageOutput, error) { 950 req, out := c.GetCostAndUsageRequest(input) 951 req.SetContext(ctx) 952 req.ApplyOptions(opts...) 953 return out, req.Send() 954} 955 956const opGetCostAndUsageWithResources = "GetCostAndUsageWithResources" 957 958// GetCostAndUsageWithResourcesRequest generates a "aws/request.Request" representing the 959// client's request for the GetCostAndUsageWithResources operation. The "output" return 960// value will be populated with the request's response once the request completes 961// successfully. 962// 963// Use "Send" method on the returned Request to send the API call to the service. 964// the "output" return value is not valid until after Send returns without error. 965// 966// See GetCostAndUsageWithResources for more information on using the GetCostAndUsageWithResources 967// API call, and error handling. 968// 969// This method is useful when you want to inject custom logic or configuration 970// into the SDK's request lifecycle. Such as custom headers, or retry logic. 971// 972// 973// // Example sending a request using the GetCostAndUsageWithResourcesRequest method. 974// req, resp := client.GetCostAndUsageWithResourcesRequest(params) 975// 976// err := req.Send() 977// if err == nil { // resp is now filled 978// fmt.Println(resp) 979// } 980// 981// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetCostAndUsageWithResources 982func (c *CostExplorer) GetCostAndUsageWithResourcesRequest(input *GetCostAndUsageWithResourcesInput) (req *request.Request, output *GetCostAndUsageWithResourcesOutput) { 983 op := &request.Operation{ 984 Name: opGetCostAndUsageWithResources, 985 HTTPMethod: "POST", 986 HTTPPath: "/", 987 } 988 989 if input == nil { 990 input = &GetCostAndUsageWithResourcesInput{} 991 } 992 993 output = &GetCostAndUsageWithResourcesOutput{} 994 req = c.newRequest(op, input, output) 995 return 996} 997 998// GetCostAndUsageWithResources API operation for AWS Cost Explorer Service. 999// 1000// Retrieves cost and usage metrics with resources for your account. You can 1001// specify which cost and usage-related metric, such as BlendedCosts or UsageQuantity, 1002// that you want the request to return. You can also filter and group your data 1003// by various dimensions, such as SERVICE or AZ, in a specific time range. For 1004// a complete list of valid dimensions, see the GetDimensionValues (https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_GetDimensionValues.html) 1005// operation. Management account in an organization in AWS Organizations have 1006// access to all member accounts. This API is currently available for the Amazon 1007// Elastic Compute Cloud – Compute service only. 1008// 1009// This is an opt-in only feature. You can enable this feature from the Cost 1010// Explorer Settings page. For information on how to access the Settings page, 1011// see Controlling Access for Cost Explorer (https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/ce-access.html) 1012// in the AWS Billing and Cost Management User Guide. 1013// 1014// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1015// with awserr.Error's Code and Message methods to get detailed information about 1016// the error. 1017// 1018// See the AWS API reference guide for AWS Cost Explorer Service's 1019// API operation GetCostAndUsageWithResources for usage and error information. 1020// 1021// Returned Error Types: 1022// * DataUnavailableException 1023// The requested data is unavailable. 1024// 1025// * LimitExceededException 1026// You made too many calls in a short period of time. Try again later. 1027// 1028// * BillExpirationException 1029// The requested report expired. Update the date interval and try again. 1030// 1031// * InvalidNextTokenException 1032// The pagination token is invalid. Try again without a pagination token. 1033// 1034// * RequestChangedException 1035// Your request parameters changed between pages. Try again with the old parameters 1036// or without a pagination token. 1037// 1038// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetCostAndUsageWithResources 1039func (c *CostExplorer) GetCostAndUsageWithResources(input *GetCostAndUsageWithResourcesInput) (*GetCostAndUsageWithResourcesOutput, error) { 1040 req, out := c.GetCostAndUsageWithResourcesRequest(input) 1041 return out, req.Send() 1042} 1043 1044// GetCostAndUsageWithResourcesWithContext is the same as GetCostAndUsageWithResources with the addition of 1045// the ability to pass a context and additional request options. 1046// 1047// See GetCostAndUsageWithResources for details on how to use this API operation. 1048// 1049// The context must be non-nil and will be used for request cancellation. If 1050// the context is nil a panic will occur. In the future the SDK may create 1051// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1052// for more information on using Contexts. 1053func (c *CostExplorer) GetCostAndUsageWithResourcesWithContext(ctx aws.Context, input *GetCostAndUsageWithResourcesInput, opts ...request.Option) (*GetCostAndUsageWithResourcesOutput, error) { 1054 req, out := c.GetCostAndUsageWithResourcesRequest(input) 1055 req.SetContext(ctx) 1056 req.ApplyOptions(opts...) 1057 return out, req.Send() 1058} 1059 1060const opGetCostCategories = "GetCostCategories" 1061 1062// GetCostCategoriesRequest generates a "aws/request.Request" representing the 1063// client's request for the GetCostCategories operation. The "output" return 1064// value will be populated with the request's response once the request completes 1065// successfully. 1066// 1067// Use "Send" method on the returned Request to send the API call to the service. 1068// the "output" return value is not valid until after Send returns without error. 1069// 1070// See GetCostCategories for more information on using the GetCostCategories 1071// API call, and error handling. 1072// 1073// This method is useful when you want to inject custom logic or configuration 1074// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1075// 1076// 1077// // Example sending a request using the GetCostCategoriesRequest method. 1078// req, resp := client.GetCostCategoriesRequest(params) 1079// 1080// err := req.Send() 1081// if err == nil { // resp is now filled 1082// fmt.Println(resp) 1083// } 1084// 1085// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetCostCategories 1086func (c *CostExplorer) GetCostCategoriesRequest(input *GetCostCategoriesInput) (req *request.Request, output *GetCostCategoriesOutput) { 1087 op := &request.Operation{ 1088 Name: opGetCostCategories, 1089 HTTPMethod: "POST", 1090 HTTPPath: "/", 1091 } 1092 1093 if input == nil { 1094 input = &GetCostCategoriesInput{} 1095 } 1096 1097 output = &GetCostCategoriesOutput{} 1098 req = c.newRequest(op, input, output) 1099 return 1100} 1101 1102// GetCostCategories API operation for AWS Cost Explorer Service. 1103// 1104// Retrieves an array of Cost Category names and values incurred cost. 1105// 1106// If some Cost Category names and values are not associated with any cost, 1107// they will not be returned by this API. 1108// 1109// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1110// with awserr.Error's Code and Message methods to get detailed information about 1111// the error. 1112// 1113// See the AWS API reference guide for AWS Cost Explorer Service's 1114// API operation GetCostCategories for usage and error information. 1115// 1116// Returned Error Types: 1117// * LimitExceededException 1118// You made too many calls in a short period of time. Try again later. 1119// 1120// * BillExpirationException 1121// The requested report expired. Update the date interval and try again. 1122// 1123// * DataUnavailableException 1124// The requested data is unavailable. 1125// 1126// * InvalidNextTokenException 1127// The pagination token is invalid. Try again without a pagination token. 1128// 1129// * RequestChangedException 1130// Your request parameters changed between pages. Try again with the old parameters 1131// or without a pagination token. 1132// 1133// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetCostCategories 1134func (c *CostExplorer) GetCostCategories(input *GetCostCategoriesInput) (*GetCostCategoriesOutput, error) { 1135 req, out := c.GetCostCategoriesRequest(input) 1136 return out, req.Send() 1137} 1138 1139// GetCostCategoriesWithContext is the same as GetCostCategories with the addition of 1140// the ability to pass a context and additional request options. 1141// 1142// See GetCostCategories for details on how to use this API operation. 1143// 1144// The context must be non-nil and will be used for request cancellation. If 1145// the context is nil a panic will occur. In the future the SDK may create 1146// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1147// for more information on using Contexts. 1148func (c *CostExplorer) GetCostCategoriesWithContext(ctx aws.Context, input *GetCostCategoriesInput, opts ...request.Option) (*GetCostCategoriesOutput, error) { 1149 req, out := c.GetCostCategoriesRequest(input) 1150 req.SetContext(ctx) 1151 req.ApplyOptions(opts...) 1152 return out, req.Send() 1153} 1154 1155const opGetCostForecast = "GetCostForecast" 1156 1157// GetCostForecastRequest generates a "aws/request.Request" representing the 1158// client's request for the GetCostForecast operation. The "output" return 1159// value will be populated with the request's response once the request completes 1160// successfully. 1161// 1162// Use "Send" method on the returned Request to send the API call to the service. 1163// the "output" return value is not valid until after Send returns without error. 1164// 1165// See GetCostForecast for more information on using the GetCostForecast 1166// API call, and error handling. 1167// 1168// This method is useful when you want to inject custom logic or configuration 1169// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1170// 1171// 1172// // Example sending a request using the GetCostForecastRequest method. 1173// req, resp := client.GetCostForecastRequest(params) 1174// 1175// err := req.Send() 1176// if err == nil { // resp is now filled 1177// fmt.Println(resp) 1178// } 1179// 1180// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetCostForecast 1181func (c *CostExplorer) GetCostForecastRequest(input *GetCostForecastInput) (req *request.Request, output *GetCostForecastOutput) { 1182 op := &request.Operation{ 1183 Name: opGetCostForecast, 1184 HTTPMethod: "POST", 1185 HTTPPath: "/", 1186 } 1187 1188 if input == nil { 1189 input = &GetCostForecastInput{} 1190 } 1191 1192 output = &GetCostForecastOutput{} 1193 req = c.newRequest(op, input, output) 1194 return 1195} 1196 1197// GetCostForecast API operation for AWS Cost Explorer Service. 1198// 1199// Retrieves a forecast for how much Amazon Web Services predicts that you will 1200// spend over the forecast time period that you select, based on your past costs. 1201// 1202// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1203// with awserr.Error's Code and Message methods to get detailed information about 1204// the error. 1205// 1206// See the AWS API reference guide for AWS Cost Explorer Service's 1207// API operation GetCostForecast for usage and error information. 1208// 1209// Returned Error Types: 1210// * LimitExceededException 1211// You made too many calls in a short period of time. Try again later. 1212// 1213// * DataUnavailableException 1214// The requested data is unavailable. 1215// 1216// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetCostForecast 1217func (c *CostExplorer) GetCostForecast(input *GetCostForecastInput) (*GetCostForecastOutput, error) { 1218 req, out := c.GetCostForecastRequest(input) 1219 return out, req.Send() 1220} 1221 1222// GetCostForecastWithContext is the same as GetCostForecast with the addition of 1223// the ability to pass a context and additional request options. 1224// 1225// See GetCostForecast for details on how to use this API operation. 1226// 1227// The context must be non-nil and will be used for request cancellation. If 1228// the context is nil a panic will occur. In the future the SDK may create 1229// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1230// for more information on using Contexts. 1231func (c *CostExplorer) GetCostForecastWithContext(ctx aws.Context, input *GetCostForecastInput, opts ...request.Option) (*GetCostForecastOutput, error) { 1232 req, out := c.GetCostForecastRequest(input) 1233 req.SetContext(ctx) 1234 req.ApplyOptions(opts...) 1235 return out, req.Send() 1236} 1237 1238const opGetDimensionValues = "GetDimensionValues" 1239 1240// GetDimensionValuesRequest generates a "aws/request.Request" representing the 1241// client's request for the GetDimensionValues operation. The "output" return 1242// value will be populated with the request's response once the request completes 1243// successfully. 1244// 1245// Use "Send" method on the returned Request to send the API call to the service. 1246// the "output" return value is not valid until after Send returns without error. 1247// 1248// See GetDimensionValues for more information on using the GetDimensionValues 1249// API call, and error handling. 1250// 1251// This method is useful when you want to inject custom logic or configuration 1252// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1253// 1254// 1255// // Example sending a request using the GetDimensionValuesRequest method. 1256// req, resp := client.GetDimensionValuesRequest(params) 1257// 1258// err := req.Send() 1259// if err == nil { // resp is now filled 1260// fmt.Println(resp) 1261// } 1262// 1263// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetDimensionValues 1264func (c *CostExplorer) GetDimensionValuesRequest(input *GetDimensionValuesInput) (req *request.Request, output *GetDimensionValuesOutput) { 1265 op := &request.Operation{ 1266 Name: opGetDimensionValues, 1267 HTTPMethod: "POST", 1268 HTTPPath: "/", 1269 } 1270 1271 if input == nil { 1272 input = &GetDimensionValuesInput{} 1273 } 1274 1275 output = &GetDimensionValuesOutput{} 1276 req = c.newRequest(op, input, output) 1277 return 1278} 1279 1280// GetDimensionValues API operation for AWS Cost Explorer Service. 1281// 1282// Retrieves all available filter values for a specified filter over a period 1283// of time. You can search the dimension values for an arbitrary string. 1284// 1285// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1286// with awserr.Error's Code and Message methods to get detailed information about 1287// the error. 1288// 1289// See the AWS API reference guide for AWS Cost Explorer Service's 1290// API operation GetDimensionValues for usage and error information. 1291// 1292// Returned Error Types: 1293// * LimitExceededException 1294// You made too many calls in a short period of time. Try again later. 1295// 1296// * BillExpirationException 1297// The requested report expired. Update the date interval and try again. 1298// 1299// * DataUnavailableException 1300// The requested data is unavailable. 1301// 1302// * InvalidNextTokenException 1303// The pagination token is invalid. Try again without a pagination token. 1304// 1305// * RequestChangedException 1306// Your request parameters changed between pages. Try again with the old parameters 1307// or without a pagination token. 1308// 1309// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetDimensionValues 1310func (c *CostExplorer) GetDimensionValues(input *GetDimensionValuesInput) (*GetDimensionValuesOutput, error) { 1311 req, out := c.GetDimensionValuesRequest(input) 1312 return out, req.Send() 1313} 1314 1315// GetDimensionValuesWithContext is the same as GetDimensionValues with the addition of 1316// the ability to pass a context and additional request options. 1317// 1318// See GetDimensionValues for details on how to use this API operation. 1319// 1320// The context must be non-nil and will be used for request cancellation. If 1321// the context is nil a panic will occur. In the future the SDK may create 1322// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1323// for more information on using Contexts. 1324func (c *CostExplorer) GetDimensionValuesWithContext(ctx aws.Context, input *GetDimensionValuesInput, opts ...request.Option) (*GetDimensionValuesOutput, error) { 1325 req, out := c.GetDimensionValuesRequest(input) 1326 req.SetContext(ctx) 1327 req.ApplyOptions(opts...) 1328 return out, req.Send() 1329} 1330 1331const opGetReservationCoverage = "GetReservationCoverage" 1332 1333// GetReservationCoverageRequest generates a "aws/request.Request" representing the 1334// client's request for the GetReservationCoverage operation. The "output" return 1335// value will be populated with the request's response once the request completes 1336// successfully. 1337// 1338// Use "Send" method on the returned Request to send the API call to the service. 1339// the "output" return value is not valid until after Send returns without error. 1340// 1341// See GetReservationCoverage for more information on using the GetReservationCoverage 1342// API call, and error handling. 1343// 1344// This method is useful when you want to inject custom logic or configuration 1345// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1346// 1347// 1348// // Example sending a request using the GetReservationCoverageRequest method. 1349// req, resp := client.GetReservationCoverageRequest(params) 1350// 1351// err := req.Send() 1352// if err == nil { // resp is now filled 1353// fmt.Println(resp) 1354// } 1355// 1356// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetReservationCoverage 1357func (c *CostExplorer) GetReservationCoverageRequest(input *GetReservationCoverageInput) (req *request.Request, output *GetReservationCoverageOutput) { 1358 op := &request.Operation{ 1359 Name: opGetReservationCoverage, 1360 HTTPMethod: "POST", 1361 HTTPPath: "/", 1362 } 1363 1364 if input == nil { 1365 input = &GetReservationCoverageInput{} 1366 } 1367 1368 output = &GetReservationCoverageOutput{} 1369 req = c.newRequest(op, input, output) 1370 return 1371} 1372 1373// GetReservationCoverage API operation for AWS Cost Explorer Service. 1374// 1375// Retrieves the reservation coverage for your account. This enables you to 1376// see how much of your Amazon Elastic Compute Cloud, Amazon ElastiCache, Amazon 1377// Relational Database Service, or Amazon Redshift usage is covered by a reservation. 1378// An organization's management account can see the coverage of the associated 1379// member accounts. This supports dimensions, Cost Categories, and nested expressions. 1380// For any time period, you can filter data about reservation usage by the following 1381// dimensions: 1382// 1383// * AZ 1384// 1385// * CACHE_ENGINE 1386// 1387// * DATABASE_ENGINE 1388// 1389// * DEPLOYMENT_OPTION 1390// 1391// * INSTANCE_TYPE 1392// 1393// * LINKED_ACCOUNT 1394// 1395// * OPERATING_SYSTEM 1396// 1397// * PLATFORM 1398// 1399// * REGION 1400// 1401// * SERVICE 1402// 1403// * TAG 1404// 1405// * TENANCY 1406// 1407// To determine valid values for a dimension, use the GetDimensionValues operation. 1408// 1409// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1410// with awserr.Error's Code and Message methods to get detailed information about 1411// the error. 1412// 1413// See the AWS API reference guide for AWS Cost Explorer Service's 1414// API operation GetReservationCoverage for usage and error information. 1415// 1416// Returned Error Types: 1417// * LimitExceededException 1418// You made too many calls in a short period of time. Try again later. 1419// 1420// * DataUnavailableException 1421// The requested data is unavailable. 1422// 1423// * InvalidNextTokenException 1424// The pagination token is invalid. Try again without a pagination token. 1425// 1426// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetReservationCoverage 1427func (c *CostExplorer) GetReservationCoverage(input *GetReservationCoverageInput) (*GetReservationCoverageOutput, error) { 1428 req, out := c.GetReservationCoverageRequest(input) 1429 return out, req.Send() 1430} 1431 1432// GetReservationCoverageWithContext is the same as GetReservationCoverage with the addition of 1433// the ability to pass a context and additional request options. 1434// 1435// See GetReservationCoverage for details on how to use this API operation. 1436// 1437// The context must be non-nil and will be used for request cancellation. If 1438// the context is nil a panic will occur. In the future the SDK may create 1439// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1440// for more information on using Contexts. 1441func (c *CostExplorer) GetReservationCoverageWithContext(ctx aws.Context, input *GetReservationCoverageInput, opts ...request.Option) (*GetReservationCoverageOutput, error) { 1442 req, out := c.GetReservationCoverageRequest(input) 1443 req.SetContext(ctx) 1444 req.ApplyOptions(opts...) 1445 return out, req.Send() 1446} 1447 1448const opGetReservationPurchaseRecommendation = "GetReservationPurchaseRecommendation" 1449 1450// GetReservationPurchaseRecommendationRequest generates a "aws/request.Request" representing the 1451// client's request for the GetReservationPurchaseRecommendation operation. The "output" return 1452// value will be populated with the request's response once the request completes 1453// successfully. 1454// 1455// Use "Send" method on the returned Request to send the API call to the service. 1456// the "output" return value is not valid until after Send returns without error. 1457// 1458// See GetReservationPurchaseRecommendation for more information on using the GetReservationPurchaseRecommendation 1459// API call, and error handling. 1460// 1461// This method is useful when you want to inject custom logic or configuration 1462// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1463// 1464// 1465// // Example sending a request using the GetReservationPurchaseRecommendationRequest method. 1466// req, resp := client.GetReservationPurchaseRecommendationRequest(params) 1467// 1468// err := req.Send() 1469// if err == nil { // resp is now filled 1470// fmt.Println(resp) 1471// } 1472// 1473// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetReservationPurchaseRecommendation 1474func (c *CostExplorer) GetReservationPurchaseRecommendationRequest(input *GetReservationPurchaseRecommendationInput) (req *request.Request, output *GetReservationPurchaseRecommendationOutput) { 1475 op := &request.Operation{ 1476 Name: opGetReservationPurchaseRecommendation, 1477 HTTPMethod: "POST", 1478 HTTPPath: "/", 1479 } 1480 1481 if input == nil { 1482 input = &GetReservationPurchaseRecommendationInput{} 1483 } 1484 1485 output = &GetReservationPurchaseRecommendationOutput{} 1486 req = c.newRequest(op, input, output) 1487 return 1488} 1489 1490// GetReservationPurchaseRecommendation API operation for AWS Cost Explorer Service. 1491// 1492// Gets recommendations for which reservations to purchase. These recommendations 1493// could help you reduce your costs. Reservations provide a discounted hourly 1494// rate (up to 75%) compared to On-Demand pricing. 1495// 1496// AWS generates your recommendations by identifying your On-Demand usage during 1497// a specific time period and collecting your usage into categories that are 1498// eligible for a reservation. After AWS has these categories, it simulates 1499// every combination of reservations in each category of usage to identify the 1500// best number of each type of RI to purchase to maximize your estimated savings. 1501// 1502// For example, AWS automatically aggregates your Amazon EC2 Linux, shared tenancy, 1503// and c4 family usage in the US West (Oregon) Region and recommends that you 1504// buy size-flexible regional reservations to apply to the c4 family usage. 1505// AWS recommends the smallest size instance in an instance family. This makes 1506// it easier to purchase a size-flexible RI. AWS also shows the equal number 1507// of normalized units so that you can purchase any instance size that you want. 1508// For this example, your RI recommendation would be for c4.large because that 1509// is the smallest size instance in the c4 instance family. 1510// 1511// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1512// with awserr.Error's Code and Message methods to get detailed information about 1513// the error. 1514// 1515// See the AWS API reference guide for AWS Cost Explorer Service's 1516// API operation GetReservationPurchaseRecommendation for usage and error information. 1517// 1518// Returned Error Types: 1519// * LimitExceededException 1520// You made too many calls in a short period of time. Try again later. 1521// 1522// * DataUnavailableException 1523// The requested data is unavailable. 1524// 1525// * InvalidNextTokenException 1526// The pagination token is invalid. Try again without a pagination token. 1527// 1528// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetReservationPurchaseRecommendation 1529func (c *CostExplorer) GetReservationPurchaseRecommendation(input *GetReservationPurchaseRecommendationInput) (*GetReservationPurchaseRecommendationOutput, error) { 1530 req, out := c.GetReservationPurchaseRecommendationRequest(input) 1531 return out, req.Send() 1532} 1533 1534// GetReservationPurchaseRecommendationWithContext is the same as GetReservationPurchaseRecommendation with the addition of 1535// the ability to pass a context and additional request options. 1536// 1537// See GetReservationPurchaseRecommendation for details on how to use this API operation. 1538// 1539// The context must be non-nil and will be used for request cancellation. If 1540// the context is nil a panic will occur. In the future the SDK may create 1541// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1542// for more information on using Contexts. 1543func (c *CostExplorer) GetReservationPurchaseRecommendationWithContext(ctx aws.Context, input *GetReservationPurchaseRecommendationInput, opts ...request.Option) (*GetReservationPurchaseRecommendationOutput, error) { 1544 req, out := c.GetReservationPurchaseRecommendationRequest(input) 1545 req.SetContext(ctx) 1546 req.ApplyOptions(opts...) 1547 return out, req.Send() 1548} 1549 1550const opGetReservationUtilization = "GetReservationUtilization" 1551 1552// GetReservationUtilizationRequest generates a "aws/request.Request" representing the 1553// client's request for the GetReservationUtilization operation. The "output" return 1554// value will be populated with the request's response once the request completes 1555// successfully. 1556// 1557// Use "Send" method on the returned Request to send the API call to the service. 1558// the "output" return value is not valid until after Send returns without error. 1559// 1560// See GetReservationUtilization for more information on using the GetReservationUtilization 1561// API call, and error handling. 1562// 1563// This method is useful when you want to inject custom logic or configuration 1564// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1565// 1566// 1567// // Example sending a request using the GetReservationUtilizationRequest method. 1568// req, resp := client.GetReservationUtilizationRequest(params) 1569// 1570// err := req.Send() 1571// if err == nil { // resp is now filled 1572// fmt.Println(resp) 1573// } 1574// 1575// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetReservationUtilization 1576func (c *CostExplorer) GetReservationUtilizationRequest(input *GetReservationUtilizationInput) (req *request.Request, output *GetReservationUtilizationOutput) { 1577 op := &request.Operation{ 1578 Name: opGetReservationUtilization, 1579 HTTPMethod: "POST", 1580 HTTPPath: "/", 1581 } 1582 1583 if input == nil { 1584 input = &GetReservationUtilizationInput{} 1585 } 1586 1587 output = &GetReservationUtilizationOutput{} 1588 req = c.newRequest(op, input, output) 1589 return 1590} 1591 1592// GetReservationUtilization API operation for AWS Cost Explorer Service. 1593// 1594// Retrieves the reservation utilization for your account. Management account 1595// in an organization have access to member accounts. You can filter data by 1596// dimensions in a time period. You can use GetDimensionValues to determine 1597// the possible dimension values. Currently, you can group only by SUBSCRIPTION_ID. 1598// 1599// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1600// with awserr.Error's Code and Message methods to get detailed information about 1601// the error. 1602// 1603// See the AWS API reference guide for AWS Cost Explorer Service's 1604// API operation GetReservationUtilization for usage and error information. 1605// 1606// Returned Error Types: 1607// * LimitExceededException 1608// You made too many calls in a short period of time. Try again later. 1609// 1610// * DataUnavailableException 1611// The requested data is unavailable. 1612// 1613// * InvalidNextTokenException 1614// The pagination token is invalid. Try again without a pagination token. 1615// 1616// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetReservationUtilization 1617func (c *CostExplorer) GetReservationUtilization(input *GetReservationUtilizationInput) (*GetReservationUtilizationOutput, error) { 1618 req, out := c.GetReservationUtilizationRequest(input) 1619 return out, req.Send() 1620} 1621 1622// GetReservationUtilizationWithContext is the same as GetReservationUtilization with the addition of 1623// the ability to pass a context and additional request options. 1624// 1625// See GetReservationUtilization for details on how to use this API operation. 1626// 1627// The context must be non-nil and will be used for request cancellation. If 1628// the context is nil a panic will occur. In the future the SDK may create 1629// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1630// for more information on using Contexts. 1631func (c *CostExplorer) GetReservationUtilizationWithContext(ctx aws.Context, input *GetReservationUtilizationInput, opts ...request.Option) (*GetReservationUtilizationOutput, error) { 1632 req, out := c.GetReservationUtilizationRequest(input) 1633 req.SetContext(ctx) 1634 req.ApplyOptions(opts...) 1635 return out, req.Send() 1636} 1637 1638const opGetRightsizingRecommendation = "GetRightsizingRecommendation" 1639 1640// GetRightsizingRecommendationRequest generates a "aws/request.Request" representing the 1641// client's request for the GetRightsizingRecommendation operation. The "output" return 1642// value will be populated with the request's response once the request completes 1643// successfully. 1644// 1645// Use "Send" method on the returned Request to send the API call to the service. 1646// the "output" return value is not valid until after Send returns without error. 1647// 1648// See GetRightsizingRecommendation for more information on using the GetRightsizingRecommendation 1649// API call, and error handling. 1650// 1651// This method is useful when you want to inject custom logic or configuration 1652// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1653// 1654// 1655// // Example sending a request using the GetRightsizingRecommendationRequest method. 1656// req, resp := client.GetRightsizingRecommendationRequest(params) 1657// 1658// err := req.Send() 1659// if err == nil { // resp is now filled 1660// fmt.Println(resp) 1661// } 1662// 1663// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetRightsizingRecommendation 1664func (c *CostExplorer) GetRightsizingRecommendationRequest(input *GetRightsizingRecommendationInput) (req *request.Request, output *GetRightsizingRecommendationOutput) { 1665 op := &request.Operation{ 1666 Name: opGetRightsizingRecommendation, 1667 HTTPMethod: "POST", 1668 HTTPPath: "/", 1669 } 1670 1671 if input == nil { 1672 input = &GetRightsizingRecommendationInput{} 1673 } 1674 1675 output = &GetRightsizingRecommendationOutput{} 1676 req = c.newRequest(op, input, output) 1677 return 1678} 1679 1680// GetRightsizingRecommendation API operation for AWS Cost Explorer Service. 1681// 1682// Creates recommendations that help you save cost by identifying idle and underutilized 1683// Amazon EC2 instances. 1684// 1685// Recommendations are generated to either downsize or terminate instances, 1686// along with providing savings detail and metrics. For details on calculation 1687// and function, see Optimizing Your Cost with Rightsizing Recommendations (https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/ce-rightsizing.html) 1688// in the AWS Billing and Cost Management User Guide. 1689// 1690// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1691// with awserr.Error's Code and Message methods to get detailed information about 1692// the error. 1693// 1694// See the AWS API reference guide for AWS Cost Explorer Service's 1695// API operation GetRightsizingRecommendation for usage and error information. 1696// 1697// Returned Error Types: 1698// * LimitExceededException 1699// You made too many calls in a short period of time. Try again later. 1700// 1701// * InvalidNextTokenException 1702// The pagination token is invalid. Try again without a pagination token. 1703// 1704// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetRightsizingRecommendation 1705func (c *CostExplorer) GetRightsizingRecommendation(input *GetRightsizingRecommendationInput) (*GetRightsizingRecommendationOutput, error) { 1706 req, out := c.GetRightsizingRecommendationRequest(input) 1707 return out, req.Send() 1708} 1709 1710// GetRightsizingRecommendationWithContext is the same as GetRightsizingRecommendation with the addition of 1711// the ability to pass a context and additional request options. 1712// 1713// See GetRightsizingRecommendation for details on how to use this API operation. 1714// 1715// The context must be non-nil and will be used for request cancellation. If 1716// the context is nil a panic will occur. In the future the SDK may create 1717// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1718// for more information on using Contexts. 1719func (c *CostExplorer) GetRightsizingRecommendationWithContext(ctx aws.Context, input *GetRightsizingRecommendationInput, opts ...request.Option) (*GetRightsizingRecommendationOutput, error) { 1720 req, out := c.GetRightsizingRecommendationRequest(input) 1721 req.SetContext(ctx) 1722 req.ApplyOptions(opts...) 1723 return out, req.Send() 1724} 1725 1726const opGetSavingsPlansCoverage = "GetSavingsPlansCoverage" 1727 1728// GetSavingsPlansCoverageRequest generates a "aws/request.Request" representing the 1729// client's request for the GetSavingsPlansCoverage operation. The "output" return 1730// value will be populated with the request's response once the request completes 1731// successfully. 1732// 1733// Use "Send" method on the returned Request to send the API call to the service. 1734// the "output" return value is not valid until after Send returns without error. 1735// 1736// See GetSavingsPlansCoverage for more information on using the GetSavingsPlansCoverage 1737// API call, and error handling. 1738// 1739// This method is useful when you want to inject custom logic or configuration 1740// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1741// 1742// 1743// // Example sending a request using the GetSavingsPlansCoverageRequest method. 1744// req, resp := client.GetSavingsPlansCoverageRequest(params) 1745// 1746// err := req.Send() 1747// if err == nil { // resp is now filled 1748// fmt.Println(resp) 1749// } 1750// 1751// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetSavingsPlansCoverage 1752func (c *CostExplorer) GetSavingsPlansCoverageRequest(input *GetSavingsPlansCoverageInput) (req *request.Request, output *GetSavingsPlansCoverageOutput) { 1753 op := &request.Operation{ 1754 Name: opGetSavingsPlansCoverage, 1755 HTTPMethod: "POST", 1756 HTTPPath: "/", 1757 Paginator: &request.Paginator{ 1758 InputTokens: []string{"NextToken"}, 1759 OutputTokens: []string{"NextToken"}, 1760 LimitToken: "MaxResults", 1761 TruncationToken: "", 1762 }, 1763 } 1764 1765 if input == nil { 1766 input = &GetSavingsPlansCoverageInput{} 1767 } 1768 1769 output = &GetSavingsPlansCoverageOutput{} 1770 req = c.newRequest(op, input, output) 1771 return 1772} 1773 1774// GetSavingsPlansCoverage API operation for AWS Cost Explorer Service. 1775// 1776// Retrieves the Savings Plans covered for your account. This enables you to 1777// see how much of your cost is covered by a Savings Plan. An organization’s 1778// management account can see the coverage of the associated member accounts. 1779// This supports dimensions, Cost Categories, and nested expressions. For any 1780// time period, you can filter data for Savings Plans usage with the following 1781// dimensions: 1782// 1783// * LINKED_ACCOUNT 1784// 1785// * REGION 1786// 1787// * SERVICE 1788// 1789// * INSTANCE_FAMILY 1790// 1791// To determine valid values for a dimension, use the GetDimensionValues operation. 1792// 1793// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1794// with awserr.Error's Code and Message methods to get detailed information about 1795// the error. 1796// 1797// See the AWS API reference guide for AWS Cost Explorer Service's 1798// API operation GetSavingsPlansCoverage for usage and error information. 1799// 1800// Returned Error Types: 1801// * LimitExceededException 1802// You made too many calls in a short period of time. Try again later. 1803// 1804// * DataUnavailableException 1805// The requested data is unavailable. 1806// 1807// * InvalidNextTokenException 1808// The pagination token is invalid. Try again without a pagination token. 1809// 1810// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetSavingsPlansCoverage 1811func (c *CostExplorer) GetSavingsPlansCoverage(input *GetSavingsPlansCoverageInput) (*GetSavingsPlansCoverageOutput, error) { 1812 req, out := c.GetSavingsPlansCoverageRequest(input) 1813 return out, req.Send() 1814} 1815 1816// GetSavingsPlansCoverageWithContext is the same as GetSavingsPlansCoverage with the addition of 1817// the ability to pass a context and additional request options. 1818// 1819// See GetSavingsPlansCoverage for details on how to use this API operation. 1820// 1821// The context must be non-nil and will be used for request cancellation. If 1822// the context is nil a panic will occur. In the future the SDK may create 1823// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1824// for more information on using Contexts. 1825func (c *CostExplorer) GetSavingsPlansCoverageWithContext(ctx aws.Context, input *GetSavingsPlansCoverageInput, opts ...request.Option) (*GetSavingsPlansCoverageOutput, error) { 1826 req, out := c.GetSavingsPlansCoverageRequest(input) 1827 req.SetContext(ctx) 1828 req.ApplyOptions(opts...) 1829 return out, req.Send() 1830} 1831 1832// GetSavingsPlansCoveragePages iterates over the pages of a GetSavingsPlansCoverage operation, 1833// calling the "fn" function with the response data for each page. To stop 1834// iterating, return false from the fn function. 1835// 1836// See GetSavingsPlansCoverage method for more information on how to use this operation. 1837// 1838// Note: This operation can generate multiple requests to a service. 1839// 1840// // Example iterating over at most 3 pages of a GetSavingsPlansCoverage operation. 1841// pageNum := 0 1842// err := client.GetSavingsPlansCoveragePages(params, 1843// func(page *costexplorer.GetSavingsPlansCoverageOutput, lastPage bool) bool { 1844// pageNum++ 1845// fmt.Println(page) 1846// return pageNum <= 3 1847// }) 1848// 1849func (c *CostExplorer) GetSavingsPlansCoveragePages(input *GetSavingsPlansCoverageInput, fn func(*GetSavingsPlansCoverageOutput, bool) bool) error { 1850 return c.GetSavingsPlansCoveragePagesWithContext(aws.BackgroundContext(), input, fn) 1851} 1852 1853// GetSavingsPlansCoveragePagesWithContext same as GetSavingsPlansCoveragePages except 1854// it takes a Context and allows setting request options on the pages. 1855// 1856// The context must be non-nil and will be used for request cancellation. If 1857// the context is nil a panic will occur. In the future the SDK may create 1858// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1859// for more information on using Contexts. 1860func (c *CostExplorer) GetSavingsPlansCoveragePagesWithContext(ctx aws.Context, input *GetSavingsPlansCoverageInput, fn func(*GetSavingsPlansCoverageOutput, bool) bool, opts ...request.Option) error { 1861 p := request.Pagination{ 1862 NewRequest: func() (*request.Request, error) { 1863 var inCpy *GetSavingsPlansCoverageInput 1864 if input != nil { 1865 tmp := *input 1866 inCpy = &tmp 1867 } 1868 req, _ := c.GetSavingsPlansCoverageRequest(inCpy) 1869 req.SetContext(ctx) 1870 req.ApplyOptions(opts...) 1871 return req, nil 1872 }, 1873 } 1874 1875 for p.Next() { 1876 if !fn(p.Page().(*GetSavingsPlansCoverageOutput), !p.HasNextPage()) { 1877 break 1878 } 1879 } 1880 1881 return p.Err() 1882} 1883 1884const opGetSavingsPlansPurchaseRecommendation = "GetSavingsPlansPurchaseRecommendation" 1885 1886// GetSavingsPlansPurchaseRecommendationRequest generates a "aws/request.Request" representing the 1887// client's request for the GetSavingsPlansPurchaseRecommendation operation. The "output" return 1888// value will be populated with the request's response once the request completes 1889// successfully. 1890// 1891// Use "Send" method on the returned Request to send the API call to the service. 1892// the "output" return value is not valid until after Send returns without error. 1893// 1894// See GetSavingsPlansPurchaseRecommendation for more information on using the GetSavingsPlansPurchaseRecommendation 1895// API call, and error handling. 1896// 1897// This method is useful when you want to inject custom logic or configuration 1898// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1899// 1900// 1901// // Example sending a request using the GetSavingsPlansPurchaseRecommendationRequest method. 1902// req, resp := client.GetSavingsPlansPurchaseRecommendationRequest(params) 1903// 1904// err := req.Send() 1905// if err == nil { // resp is now filled 1906// fmt.Println(resp) 1907// } 1908// 1909// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetSavingsPlansPurchaseRecommendation 1910func (c *CostExplorer) GetSavingsPlansPurchaseRecommendationRequest(input *GetSavingsPlansPurchaseRecommendationInput) (req *request.Request, output *GetSavingsPlansPurchaseRecommendationOutput) { 1911 op := &request.Operation{ 1912 Name: opGetSavingsPlansPurchaseRecommendation, 1913 HTTPMethod: "POST", 1914 HTTPPath: "/", 1915 } 1916 1917 if input == nil { 1918 input = &GetSavingsPlansPurchaseRecommendationInput{} 1919 } 1920 1921 output = &GetSavingsPlansPurchaseRecommendationOutput{} 1922 req = c.newRequest(op, input, output) 1923 return 1924} 1925 1926// GetSavingsPlansPurchaseRecommendation API operation for AWS Cost Explorer Service. 1927// 1928// Retrieves your request parameters, Savings Plan Recommendations Summary and 1929// Details. 1930// 1931// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1932// with awserr.Error's Code and Message methods to get detailed information about 1933// the error. 1934// 1935// See the AWS API reference guide for AWS Cost Explorer Service's 1936// API operation GetSavingsPlansPurchaseRecommendation for usage and error information. 1937// 1938// Returned Error Types: 1939// * LimitExceededException 1940// You made too many calls in a short period of time. Try again later. 1941// 1942// * InvalidNextTokenException 1943// The pagination token is invalid. Try again without a pagination token. 1944// 1945// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetSavingsPlansPurchaseRecommendation 1946func (c *CostExplorer) GetSavingsPlansPurchaseRecommendation(input *GetSavingsPlansPurchaseRecommendationInput) (*GetSavingsPlansPurchaseRecommendationOutput, error) { 1947 req, out := c.GetSavingsPlansPurchaseRecommendationRequest(input) 1948 return out, req.Send() 1949} 1950 1951// GetSavingsPlansPurchaseRecommendationWithContext is the same as GetSavingsPlansPurchaseRecommendation with the addition of 1952// the ability to pass a context and additional request options. 1953// 1954// See GetSavingsPlansPurchaseRecommendation for details on how to use this API operation. 1955// 1956// The context must be non-nil and will be used for request cancellation. If 1957// the context is nil a panic will occur. In the future the SDK may create 1958// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1959// for more information on using Contexts. 1960func (c *CostExplorer) GetSavingsPlansPurchaseRecommendationWithContext(ctx aws.Context, input *GetSavingsPlansPurchaseRecommendationInput, opts ...request.Option) (*GetSavingsPlansPurchaseRecommendationOutput, error) { 1961 req, out := c.GetSavingsPlansPurchaseRecommendationRequest(input) 1962 req.SetContext(ctx) 1963 req.ApplyOptions(opts...) 1964 return out, req.Send() 1965} 1966 1967const opGetSavingsPlansUtilization = "GetSavingsPlansUtilization" 1968 1969// GetSavingsPlansUtilizationRequest generates a "aws/request.Request" representing the 1970// client's request for the GetSavingsPlansUtilization operation. The "output" return 1971// value will be populated with the request's response once the request completes 1972// successfully. 1973// 1974// Use "Send" method on the returned Request to send the API call to the service. 1975// the "output" return value is not valid until after Send returns without error. 1976// 1977// See GetSavingsPlansUtilization for more information on using the GetSavingsPlansUtilization 1978// API call, and error handling. 1979// 1980// This method is useful when you want to inject custom logic or configuration 1981// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1982// 1983// 1984// // Example sending a request using the GetSavingsPlansUtilizationRequest method. 1985// req, resp := client.GetSavingsPlansUtilizationRequest(params) 1986// 1987// err := req.Send() 1988// if err == nil { // resp is now filled 1989// fmt.Println(resp) 1990// } 1991// 1992// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetSavingsPlansUtilization 1993func (c *CostExplorer) GetSavingsPlansUtilizationRequest(input *GetSavingsPlansUtilizationInput) (req *request.Request, output *GetSavingsPlansUtilizationOutput) { 1994 op := &request.Operation{ 1995 Name: opGetSavingsPlansUtilization, 1996 HTTPMethod: "POST", 1997 HTTPPath: "/", 1998 } 1999 2000 if input == nil { 2001 input = &GetSavingsPlansUtilizationInput{} 2002 } 2003 2004 output = &GetSavingsPlansUtilizationOutput{} 2005 req = c.newRequest(op, input, output) 2006 return 2007} 2008 2009// GetSavingsPlansUtilization API operation for AWS Cost Explorer Service. 2010// 2011// Retrieves the Savings Plans utilization for your account across date ranges 2012// with daily or monthly granularity. Management account in an organization 2013// have access to member accounts. You can use GetDimensionValues in SAVINGS_PLANS 2014// to determine the possible dimension values. 2015// 2016// You cannot group by any dimension values for GetSavingsPlansUtilization. 2017// 2018// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2019// with awserr.Error's Code and Message methods to get detailed information about 2020// the error. 2021// 2022// See the AWS API reference guide for AWS Cost Explorer Service's 2023// API operation GetSavingsPlansUtilization for usage and error information. 2024// 2025// Returned Error Types: 2026// * LimitExceededException 2027// You made too many calls in a short period of time. Try again later. 2028// 2029// * DataUnavailableException 2030// The requested data is unavailable. 2031// 2032// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetSavingsPlansUtilization 2033func (c *CostExplorer) GetSavingsPlansUtilization(input *GetSavingsPlansUtilizationInput) (*GetSavingsPlansUtilizationOutput, error) { 2034 req, out := c.GetSavingsPlansUtilizationRequest(input) 2035 return out, req.Send() 2036} 2037 2038// GetSavingsPlansUtilizationWithContext is the same as GetSavingsPlansUtilization with the addition of 2039// the ability to pass a context and additional request options. 2040// 2041// See GetSavingsPlansUtilization for details on how to use this API operation. 2042// 2043// The context must be non-nil and will be used for request cancellation. If 2044// the context is nil a panic will occur. In the future the SDK may create 2045// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2046// for more information on using Contexts. 2047func (c *CostExplorer) GetSavingsPlansUtilizationWithContext(ctx aws.Context, input *GetSavingsPlansUtilizationInput, opts ...request.Option) (*GetSavingsPlansUtilizationOutput, error) { 2048 req, out := c.GetSavingsPlansUtilizationRequest(input) 2049 req.SetContext(ctx) 2050 req.ApplyOptions(opts...) 2051 return out, req.Send() 2052} 2053 2054const opGetSavingsPlansUtilizationDetails = "GetSavingsPlansUtilizationDetails" 2055 2056// GetSavingsPlansUtilizationDetailsRequest generates a "aws/request.Request" representing the 2057// client's request for the GetSavingsPlansUtilizationDetails operation. The "output" return 2058// value will be populated with the request's response once the request completes 2059// successfully. 2060// 2061// Use "Send" method on the returned Request to send the API call to the service. 2062// the "output" return value is not valid until after Send returns without error. 2063// 2064// See GetSavingsPlansUtilizationDetails for more information on using the GetSavingsPlansUtilizationDetails 2065// API call, and error handling. 2066// 2067// This method is useful when you want to inject custom logic or configuration 2068// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2069// 2070// 2071// // Example sending a request using the GetSavingsPlansUtilizationDetailsRequest method. 2072// req, resp := client.GetSavingsPlansUtilizationDetailsRequest(params) 2073// 2074// err := req.Send() 2075// if err == nil { // resp is now filled 2076// fmt.Println(resp) 2077// } 2078// 2079// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetSavingsPlansUtilizationDetails 2080func (c *CostExplorer) GetSavingsPlansUtilizationDetailsRequest(input *GetSavingsPlansUtilizationDetailsInput) (req *request.Request, output *GetSavingsPlansUtilizationDetailsOutput) { 2081 op := &request.Operation{ 2082 Name: opGetSavingsPlansUtilizationDetails, 2083 HTTPMethod: "POST", 2084 HTTPPath: "/", 2085 Paginator: &request.Paginator{ 2086 InputTokens: []string{"NextToken"}, 2087 OutputTokens: []string{"NextToken"}, 2088 LimitToken: "MaxResults", 2089 TruncationToken: "", 2090 }, 2091 } 2092 2093 if input == nil { 2094 input = &GetSavingsPlansUtilizationDetailsInput{} 2095 } 2096 2097 output = &GetSavingsPlansUtilizationDetailsOutput{} 2098 req = c.newRequest(op, input, output) 2099 return 2100} 2101 2102// GetSavingsPlansUtilizationDetails API operation for AWS Cost Explorer Service. 2103// 2104// Retrieves attribute data along with aggregate utilization and savings data 2105// for a given time period. This doesn't support granular or grouped data (daily/monthly) 2106// in response. You can't retrieve data by dates in a single response similar 2107// to GetSavingsPlanUtilization, but you have the option to make multiple calls 2108// to GetSavingsPlanUtilizationDetails by providing individual dates. You can 2109// use GetDimensionValues in SAVINGS_PLANS to determine the possible dimension 2110// values. 2111// 2112// GetSavingsPlanUtilizationDetails internally groups data by SavingsPlansArn. 2113// 2114// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2115// with awserr.Error's Code and Message methods to get detailed information about 2116// the error. 2117// 2118// See the AWS API reference guide for AWS Cost Explorer Service's 2119// API operation GetSavingsPlansUtilizationDetails for usage and error information. 2120// 2121// Returned Error Types: 2122// * LimitExceededException 2123// You made too many calls in a short period of time. Try again later. 2124// 2125// * DataUnavailableException 2126// The requested data is unavailable. 2127// 2128// * InvalidNextTokenException 2129// The pagination token is invalid. Try again without a pagination token. 2130// 2131// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetSavingsPlansUtilizationDetails 2132func (c *CostExplorer) GetSavingsPlansUtilizationDetails(input *GetSavingsPlansUtilizationDetailsInput) (*GetSavingsPlansUtilizationDetailsOutput, error) { 2133 req, out := c.GetSavingsPlansUtilizationDetailsRequest(input) 2134 return out, req.Send() 2135} 2136 2137// GetSavingsPlansUtilizationDetailsWithContext is the same as GetSavingsPlansUtilizationDetails with the addition of 2138// the ability to pass a context and additional request options. 2139// 2140// See GetSavingsPlansUtilizationDetails for details on how to use this API operation. 2141// 2142// The context must be non-nil and will be used for request cancellation. If 2143// the context is nil a panic will occur. In the future the SDK may create 2144// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2145// for more information on using Contexts. 2146func (c *CostExplorer) GetSavingsPlansUtilizationDetailsWithContext(ctx aws.Context, input *GetSavingsPlansUtilizationDetailsInput, opts ...request.Option) (*GetSavingsPlansUtilizationDetailsOutput, error) { 2147 req, out := c.GetSavingsPlansUtilizationDetailsRequest(input) 2148 req.SetContext(ctx) 2149 req.ApplyOptions(opts...) 2150 return out, req.Send() 2151} 2152 2153// GetSavingsPlansUtilizationDetailsPages iterates over the pages of a GetSavingsPlansUtilizationDetails operation, 2154// calling the "fn" function with the response data for each page. To stop 2155// iterating, return false from the fn function. 2156// 2157// See GetSavingsPlansUtilizationDetails method for more information on how to use this operation. 2158// 2159// Note: This operation can generate multiple requests to a service. 2160// 2161// // Example iterating over at most 3 pages of a GetSavingsPlansUtilizationDetails operation. 2162// pageNum := 0 2163// err := client.GetSavingsPlansUtilizationDetailsPages(params, 2164// func(page *costexplorer.GetSavingsPlansUtilizationDetailsOutput, lastPage bool) bool { 2165// pageNum++ 2166// fmt.Println(page) 2167// return pageNum <= 3 2168// }) 2169// 2170func (c *CostExplorer) GetSavingsPlansUtilizationDetailsPages(input *GetSavingsPlansUtilizationDetailsInput, fn func(*GetSavingsPlansUtilizationDetailsOutput, bool) bool) error { 2171 return c.GetSavingsPlansUtilizationDetailsPagesWithContext(aws.BackgroundContext(), input, fn) 2172} 2173 2174// GetSavingsPlansUtilizationDetailsPagesWithContext same as GetSavingsPlansUtilizationDetailsPages except 2175// it takes a Context and allows setting request options on the pages. 2176// 2177// The context must be non-nil and will be used for request cancellation. If 2178// the context is nil a panic will occur. In the future the SDK may create 2179// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2180// for more information on using Contexts. 2181func (c *CostExplorer) GetSavingsPlansUtilizationDetailsPagesWithContext(ctx aws.Context, input *GetSavingsPlansUtilizationDetailsInput, fn func(*GetSavingsPlansUtilizationDetailsOutput, bool) bool, opts ...request.Option) error { 2182 p := request.Pagination{ 2183 NewRequest: func() (*request.Request, error) { 2184 var inCpy *GetSavingsPlansUtilizationDetailsInput 2185 if input != nil { 2186 tmp := *input 2187 inCpy = &tmp 2188 } 2189 req, _ := c.GetSavingsPlansUtilizationDetailsRequest(inCpy) 2190 req.SetContext(ctx) 2191 req.ApplyOptions(opts...) 2192 return req, nil 2193 }, 2194 } 2195 2196 for p.Next() { 2197 if !fn(p.Page().(*GetSavingsPlansUtilizationDetailsOutput), !p.HasNextPage()) { 2198 break 2199 } 2200 } 2201 2202 return p.Err() 2203} 2204 2205const opGetTags = "GetTags" 2206 2207// GetTagsRequest generates a "aws/request.Request" representing the 2208// client's request for the GetTags operation. The "output" return 2209// value will be populated with the request's response once the request completes 2210// successfully. 2211// 2212// Use "Send" method on the returned Request to send the API call to the service. 2213// the "output" return value is not valid until after Send returns without error. 2214// 2215// See GetTags for more information on using the GetTags 2216// API call, and error handling. 2217// 2218// This method is useful when you want to inject custom logic or configuration 2219// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2220// 2221// 2222// // Example sending a request using the GetTagsRequest method. 2223// req, resp := client.GetTagsRequest(params) 2224// 2225// err := req.Send() 2226// if err == nil { // resp is now filled 2227// fmt.Println(resp) 2228// } 2229// 2230// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetTags 2231func (c *CostExplorer) GetTagsRequest(input *GetTagsInput) (req *request.Request, output *GetTagsOutput) { 2232 op := &request.Operation{ 2233 Name: opGetTags, 2234 HTTPMethod: "POST", 2235 HTTPPath: "/", 2236 } 2237 2238 if input == nil { 2239 input = &GetTagsInput{} 2240 } 2241 2242 output = &GetTagsOutput{} 2243 req = c.newRequest(op, input, output) 2244 return 2245} 2246 2247// GetTags API operation for AWS Cost Explorer Service. 2248// 2249// Queries for available tag keys and tag values for a specified period. You 2250// can search the tag values for an arbitrary string. 2251// 2252// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2253// with awserr.Error's Code and Message methods to get detailed information about 2254// the error. 2255// 2256// See the AWS API reference guide for AWS Cost Explorer Service's 2257// API operation GetTags for usage and error information. 2258// 2259// Returned Error Types: 2260// * LimitExceededException 2261// You made too many calls in a short period of time. Try again later. 2262// 2263// * BillExpirationException 2264// The requested report expired. Update the date interval and try again. 2265// 2266// * DataUnavailableException 2267// The requested data is unavailable. 2268// 2269// * InvalidNextTokenException 2270// The pagination token is invalid. Try again without a pagination token. 2271// 2272// * RequestChangedException 2273// Your request parameters changed between pages. Try again with the old parameters 2274// or without a pagination token. 2275// 2276// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetTags 2277func (c *CostExplorer) GetTags(input *GetTagsInput) (*GetTagsOutput, error) { 2278 req, out := c.GetTagsRequest(input) 2279 return out, req.Send() 2280} 2281 2282// GetTagsWithContext is the same as GetTags with the addition of 2283// the ability to pass a context and additional request options. 2284// 2285// See GetTags for details on how to use this API operation. 2286// 2287// The context must be non-nil and will be used for request cancellation. If 2288// the context is nil a panic will occur. In the future the SDK may create 2289// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2290// for more information on using Contexts. 2291func (c *CostExplorer) GetTagsWithContext(ctx aws.Context, input *GetTagsInput, opts ...request.Option) (*GetTagsOutput, error) { 2292 req, out := c.GetTagsRequest(input) 2293 req.SetContext(ctx) 2294 req.ApplyOptions(opts...) 2295 return out, req.Send() 2296} 2297 2298const opGetUsageForecast = "GetUsageForecast" 2299 2300// GetUsageForecastRequest generates a "aws/request.Request" representing the 2301// client's request for the GetUsageForecast operation. The "output" return 2302// value will be populated with the request's response once the request completes 2303// successfully. 2304// 2305// Use "Send" method on the returned Request to send the API call to the service. 2306// the "output" return value is not valid until after Send returns without error. 2307// 2308// See GetUsageForecast for more information on using the GetUsageForecast 2309// API call, and error handling. 2310// 2311// This method is useful when you want to inject custom logic or configuration 2312// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2313// 2314// 2315// // Example sending a request using the GetUsageForecastRequest method. 2316// req, resp := client.GetUsageForecastRequest(params) 2317// 2318// err := req.Send() 2319// if err == nil { // resp is now filled 2320// fmt.Println(resp) 2321// } 2322// 2323// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetUsageForecast 2324func (c *CostExplorer) GetUsageForecastRequest(input *GetUsageForecastInput) (req *request.Request, output *GetUsageForecastOutput) { 2325 op := &request.Operation{ 2326 Name: opGetUsageForecast, 2327 HTTPMethod: "POST", 2328 HTTPPath: "/", 2329 } 2330 2331 if input == nil { 2332 input = &GetUsageForecastInput{} 2333 } 2334 2335 output = &GetUsageForecastOutput{} 2336 req = c.newRequest(op, input, output) 2337 return 2338} 2339 2340// GetUsageForecast API operation for AWS Cost Explorer Service. 2341// 2342// Retrieves a forecast for how much Amazon Web Services predicts that you will 2343// use over the forecast time period that you select, based on your past usage. 2344// 2345// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2346// with awserr.Error's Code and Message methods to get detailed information about 2347// the error. 2348// 2349// See the AWS API reference guide for AWS Cost Explorer Service's 2350// API operation GetUsageForecast for usage and error information. 2351// 2352// Returned Error Types: 2353// * LimitExceededException 2354// You made too many calls in a short period of time. Try again later. 2355// 2356// * DataUnavailableException 2357// The requested data is unavailable. 2358// 2359// * UnresolvableUsageUnitException 2360// Cost Explorer was unable to identify the usage unit. Provide UsageType/UsageTypeGroup 2361// filter selections that contain matching units, for example: hours. 2362// 2363// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/GetUsageForecast 2364func (c *CostExplorer) GetUsageForecast(input *GetUsageForecastInput) (*GetUsageForecastOutput, error) { 2365 req, out := c.GetUsageForecastRequest(input) 2366 return out, req.Send() 2367} 2368 2369// GetUsageForecastWithContext is the same as GetUsageForecast with the addition of 2370// the ability to pass a context and additional request options. 2371// 2372// See GetUsageForecast for details on how to use this API operation. 2373// 2374// The context must be non-nil and will be used for request cancellation. If 2375// the context is nil a panic will occur. In the future the SDK may create 2376// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2377// for more information on using Contexts. 2378func (c *CostExplorer) GetUsageForecastWithContext(ctx aws.Context, input *GetUsageForecastInput, opts ...request.Option) (*GetUsageForecastOutput, error) { 2379 req, out := c.GetUsageForecastRequest(input) 2380 req.SetContext(ctx) 2381 req.ApplyOptions(opts...) 2382 return out, req.Send() 2383} 2384 2385const opListCostCategoryDefinitions = "ListCostCategoryDefinitions" 2386 2387// ListCostCategoryDefinitionsRequest generates a "aws/request.Request" representing the 2388// client's request for the ListCostCategoryDefinitions operation. The "output" return 2389// value will be populated with the request's response once the request completes 2390// successfully. 2391// 2392// Use "Send" method on the returned Request to send the API call to the service. 2393// the "output" return value is not valid until after Send returns without error. 2394// 2395// See ListCostCategoryDefinitions for more information on using the ListCostCategoryDefinitions 2396// API call, and error handling. 2397// 2398// This method is useful when you want to inject custom logic or configuration 2399// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2400// 2401// 2402// // Example sending a request using the ListCostCategoryDefinitionsRequest method. 2403// req, resp := client.ListCostCategoryDefinitionsRequest(params) 2404// 2405// err := req.Send() 2406// if err == nil { // resp is now filled 2407// fmt.Println(resp) 2408// } 2409// 2410// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/ListCostCategoryDefinitions 2411func (c *CostExplorer) ListCostCategoryDefinitionsRequest(input *ListCostCategoryDefinitionsInput) (req *request.Request, output *ListCostCategoryDefinitionsOutput) { 2412 op := &request.Operation{ 2413 Name: opListCostCategoryDefinitions, 2414 HTTPMethod: "POST", 2415 HTTPPath: "/", 2416 Paginator: &request.Paginator{ 2417 InputTokens: []string{"NextToken"}, 2418 OutputTokens: []string{"NextToken"}, 2419 LimitToken: "MaxResults", 2420 TruncationToken: "", 2421 }, 2422 } 2423 2424 if input == nil { 2425 input = &ListCostCategoryDefinitionsInput{} 2426 } 2427 2428 output = &ListCostCategoryDefinitionsOutput{} 2429 req = c.newRequest(op, input, output) 2430 return 2431} 2432 2433// ListCostCategoryDefinitions API operation for AWS Cost Explorer Service. 2434// 2435// Returns the name, ARN, NumberOfRules and effective dates of all Cost Categories 2436// defined in the account. You have the option to use EffectiveOn to return 2437// a list of Cost Categories that were active on a specific date. If there is 2438// no EffectiveOn specified, you’ll see Cost Categories that are effective 2439// on the current date. If Cost Category is still effective, EffectiveEnd is 2440// omitted in the response. ListCostCategoryDefinitions supports pagination. 2441// The request can have a MaxResults range up to 100. 2442// 2443// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2444// with awserr.Error's Code and Message methods to get detailed information about 2445// the error. 2446// 2447// See the AWS API reference guide for AWS Cost Explorer Service's 2448// API operation ListCostCategoryDefinitions for usage and error information. 2449// 2450// Returned Error Types: 2451// * LimitExceededException 2452// You made too many calls in a short period of time. Try again later. 2453// 2454// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/ListCostCategoryDefinitions 2455func (c *CostExplorer) ListCostCategoryDefinitions(input *ListCostCategoryDefinitionsInput) (*ListCostCategoryDefinitionsOutput, error) { 2456 req, out := c.ListCostCategoryDefinitionsRequest(input) 2457 return out, req.Send() 2458} 2459 2460// ListCostCategoryDefinitionsWithContext is the same as ListCostCategoryDefinitions with the addition of 2461// the ability to pass a context and additional request options. 2462// 2463// See ListCostCategoryDefinitions for details on how to use this API operation. 2464// 2465// The context must be non-nil and will be used for request cancellation. If 2466// the context is nil a panic will occur. In the future the SDK may create 2467// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2468// for more information on using Contexts. 2469func (c *CostExplorer) ListCostCategoryDefinitionsWithContext(ctx aws.Context, input *ListCostCategoryDefinitionsInput, opts ...request.Option) (*ListCostCategoryDefinitionsOutput, error) { 2470 req, out := c.ListCostCategoryDefinitionsRequest(input) 2471 req.SetContext(ctx) 2472 req.ApplyOptions(opts...) 2473 return out, req.Send() 2474} 2475 2476// ListCostCategoryDefinitionsPages iterates over the pages of a ListCostCategoryDefinitions operation, 2477// calling the "fn" function with the response data for each page. To stop 2478// iterating, return false from the fn function. 2479// 2480// See ListCostCategoryDefinitions method for more information on how to use this operation. 2481// 2482// Note: This operation can generate multiple requests to a service. 2483// 2484// // Example iterating over at most 3 pages of a ListCostCategoryDefinitions operation. 2485// pageNum := 0 2486// err := client.ListCostCategoryDefinitionsPages(params, 2487// func(page *costexplorer.ListCostCategoryDefinitionsOutput, lastPage bool) bool { 2488// pageNum++ 2489// fmt.Println(page) 2490// return pageNum <= 3 2491// }) 2492// 2493func (c *CostExplorer) ListCostCategoryDefinitionsPages(input *ListCostCategoryDefinitionsInput, fn func(*ListCostCategoryDefinitionsOutput, bool) bool) error { 2494 return c.ListCostCategoryDefinitionsPagesWithContext(aws.BackgroundContext(), input, fn) 2495} 2496 2497// ListCostCategoryDefinitionsPagesWithContext same as ListCostCategoryDefinitionsPages except 2498// it takes a Context and allows setting request options on the pages. 2499// 2500// The context must be non-nil and will be used for request cancellation. If 2501// the context is nil a panic will occur. In the future the SDK may create 2502// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2503// for more information on using Contexts. 2504func (c *CostExplorer) ListCostCategoryDefinitionsPagesWithContext(ctx aws.Context, input *ListCostCategoryDefinitionsInput, fn func(*ListCostCategoryDefinitionsOutput, bool) bool, opts ...request.Option) error { 2505 p := request.Pagination{ 2506 NewRequest: func() (*request.Request, error) { 2507 var inCpy *ListCostCategoryDefinitionsInput 2508 if input != nil { 2509 tmp := *input 2510 inCpy = &tmp 2511 } 2512 req, _ := c.ListCostCategoryDefinitionsRequest(inCpy) 2513 req.SetContext(ctx) 2514 req.ApplyOptions(opts...) 2515 return req, nil 2516 }, 2517 } 2518 2519 for p.Next() { 2520 if !fn(p.Page().(*ListCostCategoryDefinitionsOutput), !p.HasNextPage()) { 2521 break 2522 } 2523 } 2524 2525 return p.Err() 2526} 2527 2528const opProvideAnomalyFeedback = "ProvideAnomalyFeedback" 2529 2530// ProvideAnomalyFeedbackRequest generates a "aws/request.Request" representing the 2531// client's request for the ProvideAnomalyFeedback operation. The "output" return 2532// value will be populated with the request's response once the request completes 2533// successfully. 2534// 2535// Use "Send" method on the returned Request to send the API call to the service. 2536// the "output" return value is not valid until after Send returns without error. 2537// 2538// See ProvideAnomalyFeedback for more information on using the ProvideAnomalyFeedback 2539// API call, and error handling. 2540// 2541// This method is useful when you want to inject custom logic or configuration 2542// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2543// 2544// 2545// // Example sending a request using the ProvideAnomalyFeedbackRequest method. 2546// req, resp := client.ProvideAnomalyFeedbackRequest(params) 2547// 2548// err := req.Send() 2549// if err == nil { // resp is now filled 2550// fmt.Println(resp) 2551// } 2552// 2553// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/ProvideAnomalyFeedback 2554func (c *CostExplorer) ProvideAnomalyFeedbackRequest(input *ProvideAnomalyFeedbackInput) (req *request.Request, output *ProvideAnomalyFeedbackOutput) { 2555 op := &request.Operation{ 2556 Name: opProvideAnomalyFeedback, 2557 HTTPMethod: "POST", 2558 HTTPPath: "/", 2559 } 2560 2561 if input == nil { 2562 input = &ProvideAnomalyFeedbackInput{} 2563 } 2564 2565 output = &ProvideAnomalyFeedbackOutput{} 2566 req = c.newRequest(op, input, output) 2567 return 2568} 2569 2570// ProvideAnomalyFeedback API operation for AWS Cost Explorer Service. 2571// 2572// Modifies the feedback property of a given cost anomaly. 2573// 2574// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2575// with awserr.Error's Code and Message methods to get detailed information about 2576// the error. 2577// 2578// See the AWS API reference guide for AWS Cost Explorer Service's 2579// API operation ProvideAnomalyFeedback for usage and error information. 2580// 2581// Returned Error Types: 2582// * LimitExceededException 2583// You made too many calls in a short period of time. Try again later. 2584// 2585// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/ProvideAnomalyFeedback 2586func (c *CostExplorer) ProvideAnomalyFeedback(input *ProvideAnomalyFeedbackInput) (*ProvideAnomalyFeedbackOutput, error) { 2587 req, out := c.ProvideAnomalyFeedbackRequest(input) 2588 return out, req.Send() 2589} 2590 2591// ProvideAnomalyFeedbackWithContext is the same as ProvideAnomalyFeedback with the addition of 2592// the ability to pass a context and additional request options. 2593// 2594// See ProvideAnomalyFeedback for details on how to use this API operation. 2595// 2596// The context must be non-nil and will be used for request cancellation. If 2597// the context is nil a panic will occur. In the future the SDK may create 2598// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2599// for more information on using Contexts. 2600func (c *CostExplorer) ProvideAnomalyFeedbackWithContext(ctx aws.Context, input *ProvideAnomalyFeedbackInput, opts ...request.Option) (*ProvideAnomalyFeedbackOutput, error) { 2601 req, out := c.ProvideAnomalyFeedbackRequest(input) 2602 req.SetContext(ctx) 2603 req.ApplyOptions(opts...) 2604 return out, req.Send() 2605} 2606 2607const opUpdateAnomalyMonitor = "UpdateAnomalyMonitor" 2608 2609// UpdateAnomalyMonitorRequest generates a "aws/request.Request" representing the 2610// client's request for the UpdateAnomalyMonitor operation. The "output" return 2611// value will be populated with the request's response once the request completes 2612// successfully. 2613// 2614// Use "Send" method on the returned Request to send the API call to the service. 2615// the "output" return value is not valid until after Send returns without error. 2616// 2617// See UpdateAnomalyMonitor for more information on using the UpdateAnomalyMonitor 2618// API call, and error handling. 2619// 2620// This method is useful when you want to inject custom logic or configuration 2621// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2622// 2623// 2624// // Example sending a request using the UpdateAnomalyMonitorRequest method. 2625// req, resp := client.UpdateAnomalyMonitorRequest(params) 2626// 2627// err := req.Send() 2628// if err == nil { // resp is now filled 2629// fmt.Println(resp) 2630// } 2631// 2632// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/UpdateAnomalyMonitor 2633func (c *CostExplorer) UpdateAnomalyMonitorRequest(input *UpdateAnomalyMonitorInput) (req *request.Request, output *UpdateAnomalyMonitorOutput) { 2634 op := &request.Operation{ 2635 Name: opUpdateAnomalyMonitor, 2636 HTTPMethod: "POST", 2637 HTTPPath: "/", 2638 } 2639 2640 if input == nil { 2641 input = &UpdateAnomalyMonitorInput{} 2642 } 2643 2644 output = &UpdateAnomalyMonitorOutput{} 2645 req = c.newRequest(op, input, output) 2646 return 2647} 2648 2649// UpdateAnomalyMonitor API operation for AWS Cost Explorer Service. 2650// 2651// Updates an existing cost anomaly monitor. The changes made are applied going 2652// forward, and does not change anomalies detected in the past. 2653// 2654// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2655// with awserr.Error's Code and Message methods to get detailed information about 2656// the error. 2657// 2658// See the AWS API reference guide for AWS Cost Explorer Service's 2659// API operation UpdateAnomalyMonitor for usage and error information. 2660// 2661// Returned Error Types: 2662// * LimitExceededException 2663// You made too many calls in a short period of time. Try again later. 2664// 2665// * UnknownMonitorException 2666// The cost anomaly monitor does not exist for the account. 2667// 2668// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/UpdateAnomalyMonitor 2669func (c *CostExplorer) UpdateAnomalyMonitor(input *UpdateAnomalyMonitorInput) (*UpdateAnomalyMonitorOutput, error) { 2670 req, out := c.UpdateAnomalyMonitorRequest(input) 2671 return out, req.Send() 2672} 2673 2674// UpdateAnomalyMonitorWithContext is the same as UpdateAnomalyMonitor with the addition of 2675// the ability to pass a context and additional request options. 2676// 2677// See UpdateAnomalyMonitor for details on how to use this API operation. 2678// 2679// The context must be non-nil and will be used for request cancellation. If 2680// the context is nil a panic will occur. In the future the SDK may create 2681// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2682// for more information on using Contexts. 2683func (c *CostExplorer) UpdateAnomalyMonitorWithContext(ctx aws.Context, input *UpdateAnomalyMonitorInput, opts ...request.Option) (*UpdateAnomalyMonitorOutput, error) { 2684 req, out := c.UpdateAnomalyMonitorRequest(input) 2685 req.SetContext(ctx) 2686 req.ApplyOptions(opts...) 2687 return out, req.Send() 2688} 2689 2690const opUpdateAnomalySubscription = "UpdateAnomalySubscription" 2691 2692// UpdateAnomalySubscriptionRequest generates a "aws/request.Request" representing the 2693// client's request for the UpdateAnomalySubscription operation. The "output" return 2694// value will be populated with the request's response once the request completes 2695// successfully. 2696// 2697// Use "Send" method on the returned Request to send the API call to the service. 2698// the "output" return value is not valid until after Send returns without error. 2699// 2700// See UpdateAnomalySubscription for more information on using the UpdateAnomalySubscription 2701// API call, and error handling. 2702// 2703// This method is useful when you want to inject custom logic or configuration 2704// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2705// 2706// 2707// // Example sending a request using the UpdateAnomalySubscriptionRequest method. 2708// req, resp := client.UpdateAnomalySubscriptionRequest(params) 2709// 2710// err := req.Send() 2711// if err == nil { // resp is now filled 2712// fmt.Println(resp) 2713// } 2714// 2715// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/UpdateAnomalySubscription 2716func (c *CostExplorer) UpdateAnomalySubscriptionRequest(input *UpdateAnomalySubscriptionInput) (req *request.Request, output *UpdateAnomalySubscriptionOutput) { 2717 op := &request.Operation{ 2718 Name: opUpdateAnomalySubscription, 2719 HTTPMethod: "POST", 2720 HTTPPath: "/", 2721 } 2722 2723 if input == nil { 2724 input = &UpdateAnomalySubscriptionInput{} 2725 } 2726 2727 output = &UpdateAnomalySubscriptionOutput{} 2728 req = c.newRequest(op, input, output) 2729 return 2730} 2731 2732// UpdateAnomalySubscription API operation for AWS Cost Explorer Service. 2733// 2734// Updates an existing cost anomaly monitor subscription. 2735// 2736// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2737// with awserr.Error's Code and Message methods to get detailed information about 2738// the error. 2739// 2740// See the AWS API reference guide for AWS Cost Explorer Service's 2741// API operation UpdateAnomalySubscription for usage and error information. 2742// 2743// Returned Error Types: 2744// * LimitExceededException 2745// You made too many calls in a short period of time. Try again later. 2746// 2747// * UnknownMonitorException 2748// The cost anomaly monitor does not exist for the account. 2749// 2750// * UnknownSubscriptionException 2751// The cost anomaly subscription does not exist for the account. 2752// 2753// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/UpdateAnomalySubscription 2754func (c *CostExplorer) UpdateAnomalySubscription(input *UpdateAnomalySubscriptionInput) (*UpdateAnomalySubscriptionOutput, error) { 2755 req, out := c.UpdateAnomalySubscriptionRequest(input) 2756 return out, req.Send() 2757} 2758 2759// UpdateAnomalySubscriptionWithContext is the same as UpdateAnomalySubscription with the addition of 2760// the ability to pass a context and additional request options. 2761// 2762// See UpdateAnomalySubscription for details on how to use this API operation. 2763// 2764// The context must be non-nil and will be used for request cancellation. If 2765// the context is nil a panic will occur. In the future the SDK may create 2766// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2767// for more information on using Contexts. 2768func (c *CostExplorer) UpdateAnomalySubscriptionWithContext(ctx aws.Context, input *UpdateAnomalySubscriptionInput, opts ...request.Option) (*UpdateAnomalySubscriptionOutput, error) { 2769 req, out := c.UpdateAnomalySubscriptionRequest(input) 2770 req.SetContext(ctx) 2771 req.ApplyOptions(opts...) 2772 return out, req.Send() 2773} 2774 2775const opUpdateCostCategoryDefinition = "UpdateCostCategoryDefinition" 2776 2777// UpdateCostCategoryDefinitionRequest generates a "aws/request.Request" representing the 2778// client's request for the UpdateCostCategoryDefinition operation. The "output" return 2779// value will be populated with the request's response once the request completes 2780// successfully. 2781// 2782// Use "Send" method on the returned Request to send the API call to the service. 2783// the "output" return value is not valid until after Send returns without error. 2784// 2785// See UpdateCostCategoryDefinition for more information on using the UpdateCostCategoryDefinition 2786// API call, and error handling. 2787// 2788// This method is useful when you want to inject custom logic or configuration 2789// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2790// 2791// 2792// // Example sending a request using the UpdateCostCategoryDefinitionRequest method. 2793// req, resp := client.UpdateCostCategoryDefinitionRequest(params) 2794// 2795// err := req.Send() 2796// if err == nil { // resp is now filled 2797// fmt.Println(resp) 2798// } 2799// 2800// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/UpdateCostCategoryDefinition 2801func (c *CostExplorer) UpdateCostCategoryDefinitionRequest(input *UpdateCostCategoryDefinitionInput) (req *request.Request, output *UpdateCostCategoryDefinitionOutput) { 2802 op := &request.Operation{ 2803 Name: opUpdateCostCategoryDefinition, 2804 HTTPMethod: "POST", 2805 HTTPPath: "/", 2806 } 2807 2808 if input == nil { 2809 input = &UpdateCostCategoryDefinitionInput{} 2810 } 2811 2812 output = &UpdateCostCategoryDefinitionOutput{} 2813 req = c.newRequest(op, input, output) 2814 return 2815} 2816 2817// UpdateCostCategoryDefinition API operation for AWS Cost Explorer Service. 2818// 2819// Updates an existing Cost Category. Changes made to the Cost Category rules 2820// will be used to categorize the current month’s expenses and future expenses. 2821// This won’t change categorization for the previous months. 2822// 2823// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2824// with awserr.Error's Code and Message methods to get detailed information about 2825// the error. 2826// 2827// See the AWS API reference guide for AWS Cost Explorer Service's 2828// API operation UpdateCostCategoryDefinition for usage and error information. 2829// 2830// Returned Error Types: 2831// * ResourceNotFoundException 2832// The specified ARN in the request doesn't exist. 2833// 2834// * ServiceQuotaExceededException 2835// You've reached the limit on the number of resources you can create, or exceeded 2836// the size of an individual resource. 2837// 2838// * LimitExceededException 2839// You made too many calls in a short period of time. Try again later. 2840// 2841// See also, https://docs.aws.amazon.com/goto/WebAPI/ce-2017-10-25/UpdateCostCategoryDefinition 2842func (c *CostExplorer) UpdateCostCategoryDefinition(input *UpdateCostCategoryDefinitionInput) (*UpdateCostCategoryDefinitionOutput, error) { 2843 req, out := c.UpdateCostCategoryDefinitionRequest(input) 2844 return out, req.Send() 2845} 2846 2847// UpdateCostCategoryDefinitionWithContext is the same as UpdateCostCategoryDefinition with the addition of 2848// the ability to pass a context and additional request options. 2849// 2850// See UpdateCostCategoryDefinition for details on how to use this API operation. 2851// 2852// The context must be non-nil and will be used for request cancellation. If 2853// the context is nil a panic will occur. In the future the SDK may create 2854// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2855// for more information on using Contexts. 2856func (c *CostExplorer) UpdateCostCategoryDefinitionWithContext(ctx aws.Context, input *UpdateCostCategoryDefinitionInput, opts ...request.Option) (*UpdateCostCategoryDefinitionOutput, error) { 2857 req, out := c.UpdateCostCategoryDefinitionRequest(input) 2858 req.SetContext(ctx) 2859 req.ApplyOptions(opts...) 2860 return out, req.Send() 2861} 2862 2863// An unusual cost pattern. This consists of the detailed metadata and the current 2864// status of the anomaly object. 2865type Anomaly struct { 2866 _ struct{} `type:"structure"` 2867 2868 // The last day the anomaly is detected. 2869 AnomalyEndDate *string `type:"string"` 2870 2871 // The unique identifier for the anomaly. 2872 // 2873 // AnomalyId is a required field 2874 AnomalyId *string `type:"string" required:"true"` 2875 2876 // The latest and maximum score for the anomaly. 2877 // 2878 // AnomalyScore is a required field 2879 AnomalyScore *AnomalyScore `type:"structure" required:"true"` 2880 2881 // The first day the anomaly is detected. 2882 AnomalyStartDate *string `type:"string"` 2883 2884 // The dimension for the anomaly. For example, an AWS service in a service monitor. 2885 DimensionValue *string `type:"string"` 2886 2887 // The feedback value. 2888 Feedback *string `type:"string" enum:"AnomalyFeedbackType"` 2889 2890 // The dollar impact for the anomaly. 2891 // 2892 // Impact is a required field 2893 Impact *Impact `type:"structure" required:"true"` 2894 2895 // The Amazon Resource Name (ARN) for the cost monitor that generated this anomaly. 2896 // 2897 // MonitorArn is a required field 2898 MonitorArn *string `type:"string" required:"true"` 2899 2900 // The list of identified root causes for the anomaly. 2901 RootCauses []*RootCause `type:"list"` 2902} 2903 2904// String returns the string representation 2905func (s Anomaly) String() string { 2906 return awsutil.Prettify(s) 2907} 2908 2909// GoString returns the string representation 2910func (s Anomaly) GoString() string { 2911 return s.String() 2912} 2913 2914// SetAnomalyEndDate sets the AnomalyEndDate field's value. 2915func (s *Anomaly) SetAnomalyEndDate(v string) *Anomaly { 2916 s.AnomalyEndDate = &v 2917 return s 2918} 2919 2920// SetAnomalyId sets the AnomalyId field's value. 2921func (s *Anomaly) SetAnomalyId(v string) *Anomaly { 2922 s.AnomalyId = &v 2923 return s 2924} 2925 2926// SetAnomalyScore sets the AnomalyScore field's value. 2927func (s *Anomaly) SetAnomalyScore(v *AnomalyScore) *Anomaly { 2928 s.AnomalyScore = v 2929 return s 2930} 2931 2932// SetAnomalyStartDate sets the AnomalyStartDate field's value. 2933func (s *Anomaly) SetAnomalyStartDate(v string) *Anomaly { 2934 s.AnomalyStartDate = &v 2935 return s 2936} 2937 2938// SetDimensionValue sets the DimensionValue field's value. 2939func (s *Anomaly) SetDimensionValue(v string) *Anomaly { 2940 s.DimensionValue = &v 2941 return s 2942} 2943 2944// SetFeedback sets the Feedback field's value. 2945func (s *Anomaly) SetFeedback(v string) *Anomaly { 2946 s.Feedback = &v 2947 return s 2948} 2949 2950// SetImpact sets the Impact field's value. 2951func (s *Anomaly) SetImpact(v *Impact) *Anomaly { 2952 s.Impact = v 2953 return s 2954} 2955 2956// SetMonitorArn sets the MonitorArn field's value. 2957func (s *Anomaly) SetMonitorArn(v string) *Anomaly { 2958 s.MonitorArn = &v 2959 return s 2960} 2961 2962// SetRootCauses sets the RootCauses field's value. 2963func (s *Anomaly) SetRootCauses(v []*RootCause) *Anomaly { 2964 s.RootCauses = v 2965 return s 2966} 2967 2968// The time period for an anomaly. 2969type AnomalyDateInterval struct { 2970 _ struct{} `type:"structure"` 2971 2972 // The last date an anomaly was observed. 2973 EndDate *string `type:"string"` 2974 2975 // The first date an anomaly was observed. 2976 // 2977 // StartDate is a required field 2978 StartDate *string `type:"string" required:"true"` 2979} 2980 2981// String returns the string representation 2982func (s AnomalyDateInterval) String() string { 2983 return awsutil.Prettify(s) 2984} 2985 2986// GoString returns the string representation 2987func (s AnomalyDateInterval) GoString() string { 2988 return s.String() 2989} 2990 2991// Validate inspects the fields of the type to determine if they are valid. 2992func (s *AnomalyDateInterval) Validate() error { 2993 invalidParams := request.ErrInvalidParams{Context: "AnomalyDateInterval"} 2994 if s.StartDate == nil { 2995 invalidParams.Add(request.NewErrParamRequired("StartDate")) 2996 } 2997 2998 if invalidParams.Len() > 0 { 2999 return invalidParams 3000 } 3001 return nil 3002} 3003 3004// SetEndDate sets the EndDate field's value. 3005func (s *AnomalyDateInterval) SetEndDate(v string) *AnomalyDateInterval { 3006 s.EndDate = &v 3007 return s 3008} 3009 3010// SetStartDate sets the StartDate field's value. 3011func (s *AnomalyDateInterval) SetStartDate(v string) *AnomalyDateInterval { 3012 s.StartDate = &v 3013 return s 3014} 3015 3016// This object continuously inspects your account's cost data for anomalies, 3017// based on MonitorType and MonitorSpecification. The content consists of detailed 3018// metadata and the current status of the monitor object. 3019type AnomalyMonitor struct { 3020 _ struct{} `type:"structure"` 3021 3022 // The date when the monitor was created. 3023 CreationDate *string `type:"string"` 3024 3025 // The value for evaluated dimensions. 3026 DimensionalValueCount *int64 `type:"integer"` 3027 3028 // The date when the monitor last evaluated for anomalies. 3029 LastEvaluatedDate *string `type:"string"` 3030 3031 // The date when the monitor was last updated. 3032 LastUpdatedDate *string `type:"string"` 3033 3034 // The Amazon Resource Name (ARN) value. 3035 MonitorArn *string `type:"string"` 3036 3037 // The dimensions to evaluate. 3038 MonitorDimension *string `type:"string" enum:"MonitorDimension"` 3039 3040 // The name of the monitor. 3041 // 3042 // MonitorName is a required field 3043 MonitorName *string `type:"string" required:"true"` 3044 3045 // Use Expression to filter by cost or by usage. There are two patterns: 3046 // 3047 // * Simple dimension values - You can set the dimension name and values 3048 // for the filters that you plan to use. For example, you can filter for 3049 // REGION==us-east-1 OR REGION==us-west-1. For GetRightsizingRecommendation, 3050 // the Region is a full name (for example, REGION==US East (N. Virginia). 3051 // The Expression example looks like: { "Dimensions": { "Key": "REGION", 3052 // "Values": [ "us-east-1", “us-west-1” ] } } The list of dimension values 3053 // are OR'd together to retrieve cost or usage data. You can create Expression 3054 // and DimensionValues objects using either with* methods or set* methods 3055 // in multiple lines. 3056 // 3057 // * Compound dimension values with logical operations - You can use multiple 3058 // Expression types and the logical operators AND/OR/NOT to create a list 3059 // of one or more Expression objects. This allows you to filter on more advanced 3060 // options. For example, you can filter on ((REGION == us-east-1 OR REGION 3061 // == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer). 3062 // The Expression for that looks like this: { "And": [ {"Or": [ {"Dimensions": 3063 // { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": 3064 // { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": 3065 // { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] } Because each 3066 // Expression can have only one operator, the service returns an error if 3067 // more than one is specified. The following example shows an Expression 3068 // object that creates an error. { "And": [ ... ], "DimensionValues": { "Dimension": 3069 // "USAGE_TYPE", "Values": [ "DataTransfer" ] } } 3070 // 3071 // For the GetRightsizingRecommendation action, a combination of OR and NOT 3072 // is not supported. OR is not supported between different dimensions, or dimensions 3073 // and tags. NOT operators aren't supported. Dimensions are also limited to 3074 // LINKED_ACCOUNT, REGION, or RIGHTSIZING_TYPE. 3075 // 3076 // For the GetReservationPurchaseRecommendation action, only NOT is supported. 3077 // AND and OR are not supported. Dimensions are limited to LINKED_ACCOUNT. 3078 MonitorSpecification *Expression `type:"structure"` 3079 3080 // The possible type values. 3081 // 3082 // MonitorType is a required field 3083 MonitorType *string `type:"string" required:"true" enum:"MonitorType"` 3084} 3085 3086// String returns the string representation 3087func (s AnomalyMonitor) String() string { 3088 return awsutil.Prettify(s) 3089} 3090 3091// GoString returns the string representation 3092func (s AnomalyMonitor) GoString() string { 3093 return s.String() 3094} 3095 3096// Validate inspects the fields of the type to determine if they are valid. 3097func (s *AnomalyMonitor) Validate() error { 3098 invalidParams := request.ErrInvalidParams{Context: "AnomalyMonitor"} 3099 if s.MonitorName == nil { 3100 invalidParams.Add(request.NewErrParamRequired("MonitorName")) 3101 } 3102 if s.MonitorType == nil { 3103 invalidParams.Add(request.NewErrParamRequired("MonitorType")) 3104 } 3105 if s.MonitorSpecification != nil { 3106 if err := s.MonitorSpecification.Validate(); err != nil { 3107 invalidParams.AddNested("MonitorSpecification", err.(request.ErrInvalidParams)) 3108 } 3109 } 3110 3111 if invalidParams.Len() > 0 { 3112 return invalidParams 3113 } 3114 return nil 3115} 3116 3117// SetCreationDate sets the CreationDate field's value. 3118func (s *AnomalyMonitor) SetCreationDate(v string) *AnomalyMonitor { 3119 s.CreationDate = &v 3120 return s 3121} 3122 3123// SetDimensionalValueCount sets the DimensionalValueCount field's value. 3124func (s *AnomalyMonitor) SetDimensionalValueCount(v int64) *AnomalyMonitor { 3125 s.DimensionalValueCount = &v 3126 return s 3127} 3128 3129// SetLastEvaluatedDate sets the LastEvaluatedDate field's value. 3130func (s *AnomalyMonitor) SetLastEvaluatedDate(v string) *AnomalyMonitor { 3131 s.LastEvaluatedDate = &v 3132 return s 3133} 3134 3135// SetLastUpdatedDate sets the LastUpdatedDate field's value. 3136func (s *AnomalyMonitor) SetLastUpdatedDate(v string) *AnomalyMonitor { 3137 s.LastUpdatedDate = &v 3138 return s 3139} 3140 3141// SetMonitorArn sets the MonitorArn field's value. 3142func (s *AnomalyMonitor) SetMonitorArn(v string) *AnomalyMonitor { 3143 s.MonitorArn = &v 3144 return s 3145} 3146 3147// SetMonitorDimension sets the MonitorDimension field's value. 3148func (s *AnomalyMonitor) SetMonitorDimension(v string) *AnomalyMonitor { 3149 s.MonitorDimension = &v 3150 return s 3151} 3152 3153// SetMonitorName sets the MonitorName field's value. 3154func (s *AnomalyMonitor) SetMonitorName(v string) *AnomalyMonitor { 3155 s.MonitorName = &v 3156 return s 3157} 3158 3159// SetMonitorSpecification sets the MonitorSpecification field's value. 3160func (s *AnomalyMonitor) SetMonitorSpecification(v *Expression) *AnomalyMonitor { 3161 s.MonitorSpecification = v 3162 return s 3163} 3164 3165// SetMonitorType sets the MonitorType field's value. 3166func (s *AnomalyMonitor) SetMonitorType(v string) *AnomalyMonitor { 3167 s.MonitorType = &v 3168 return s 3169} 3170 3171// Quantifies the anomaly. The higher score means that it is more anomalous. 3172type AnomalyScore struct { 3173 _ struct{} `type:"structure"` 3174 3175 // The last observed score. 3176 // 3177 // CurrentScore is a required field 3178 CurrentScore *float64 `type:"double" required:"true"` 3179 3180 // The maximum score observed during the AnomalyDateInterval. 3181 // 3182 // MaxScore is a required field 3183 MaxScore *float64 `type:"double" required:"true"` 3184} 3185 3186// String returns the string representation 3187func (s AnomalyScore) String() string { 3188 return awsutil.Prettify(s) 3189} 3190 3191// GoString returns the string representation 3192func (s AnomalyScore) GoString() string { 3193 return s.String() 3194} 3195 3196// SetCurrentScore sets the CurrentScore field's value. 3197func (s *AnomalyScore) SetCurrentScore(v float64) *AnomalyScore { 3198 s.CurrentScore = &v 3199 return s 3200} 3201 3202// SetMaxScore sets the MaxScore field's value. 3203func (s *AnomalyScore) SetMaxScore(v float64) *AnomalyScore { 3204 s.MaxScore = &v 3205 return s 3206} 3207 3208// The association between a monitor, threshold, and list of subscribers used 3209// to deliver notifications about anomalies detected by a monitor that exceeds 3210// a threshold. The content consists of the detailed metadata and the current 3211// status of the AnomalySubscription object. 3212type AnomalySubscription struct { 3213 _ struct{} `type:"structure"` 3214 3215 // Your unique account identifier. 3216 AccountId *string `type:"string"` 3217 3218 // The frequency at which anomaly reports are sent over email. 3219 // 3220 // Frequency is a required field 3221 Frequency *string `type:"string" required:"true" enum:"AnomalySubscriptionFrequency"` 3222 3223 // A list of cost anomaly monitors. 3224 // 3225 // MonitorArnList is a required field 3226 MonitorArnList []*string `type:"list" required:"true"` 3227 3228 // A list of subscribers to notify. 3229 // 3230 // Subscribers is a required field 3231 Subscribers []*Subscriber `type:"list" required:"true"` 3232 3233 // The AnomalySubscription Amazon Resource Name (ARN). 3234 SubscriptionArn *string `type:"string"` 3235 3236 // The name for the subscription. 3237 // 3238 // SubscriptionName is a required field 3239 SubscriptionName *string `type:"string" required:"true"` 3240 3241 // The dollar value that triggers a notification if the threshold is exceeded. 3242 // 3243 // Threshold is a required field 3244 Threshold *float64 `type:"double" required:"true"` 3245} 3246 3247// String returns the string representation 3248func (s AnomalySubscription) String() string { 3249 return awsutil.Prettify(s) 3250} 3251 3252// GoString returns the string representation 3253func (s AnomalySubscription) GoString() string { 3254 return s.String() 3255} 3256 3257// Validate inspects the fields of the type to determine if they are valid. 3258func (s *AnomalySubscription) Validate() error { 3259 invalidParams := request.ErrInvalidParams{Context: "AnomalySubscription"} 3260 if s.Frequency == nil { 3261 invalidParams.Add(request.NewErrParamRequired("Frequency")) 3262 } 3263 if s.MonitorArnList == nil { 3264 invalidParams.Add(request.NewErrParamRequired("MonitorArnList")) 3265 } 3266 if s.Subscribers == nil { 3267 invalidParams.Add(request.NewErrParamRequired("Subscribers")) 3268 } 3269 if s.SubscriptionName == nil { 3270 invalidParams.Add(request.NewErrParamRequired("SubscriptionName")) 3271 } 3272 if s.Threshold == nil { 3273 invalidParams.Add(request.NewErrParamRequired("Threshold")) 3274 } 3275 if s.Subscribers != nil { 3276 for i, v := range s.Subscribers { 3277 if v == nil { 3278 continue 3279 } 3280 if err := v.Validate(); err != nil { 3281 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Subscribers", i), err.(request.ErrInvalidParams)) 3282 } 3283 } 3284 } 3285 3286 if invalidParams.Len() > 0 { 3287 return invalidParams 3288 } 3289 return nil 3290} 3291 3292// SetAccountId sets the AccountId field's value. 3293func (s *AnomalySubscription) SetAccountId(v string) *AnomalySubscription { 3294 s.AccountId = &v 3295 return s 3296} 3297 3298// SetFrequency sets the Frequency field's value. 3299func (s *AnomalySubscription) SetFrequency(v string) *AnomalySubscription { 3300 s.Frequency = &v 3301 return s 3302} 3303 3304// SetMonitorArnList sets the MonitorArnList field's value. 3305func (s *AnomalySubscription) SetMonitorArnList(v []*string) *AnomalySubscription { 3306 s.MonitorArnList = v 3307 return s 3308} 3309 3310// SetSubscribers sets the Subscribers field's value. 3311func (s *AnomalySubscription) SetSubscribers(v []*Subscriber) *AnomalySubscription { 3312 s.Subscribers = v 3313 return s 3314} 3315 3316// SetSubscriptionArn sets the SubscriptionArn field's value. 3317func (s *AnomalySubscription) SetSubscriptionArn(v string) *AnomalySubscription { 3318 s.SubscriptionArn = &v 3319 return s 3320} 3321 3322// SetSubscriptionName sets the SubscriptionName field's value. 3323func (s *AnomalySubscription) SetSubscriptionName(v string) *AnomalySubscription { 3324 s.SubscriptionName = &v 3325 return s 3326} 3327 3328// SetThreshold sets the Threshold field's value. 3329func (s *AnomalySubscription) SetThreshold(v float64) *AnomalySubscription { 3330 s.Threshold = &v 3331 return s 3332} 3333 3334// The requested report expired. Update the date interval and try again. 3335type BillExpirationException struct { 3336 _ struct{} `type:"structure"` 3337 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 3338 3339 Message_ *string `locationName:"Message" type:"string"` 3340} 3341 3342// String returns the string representation 3343func (s BillExpirationException) String() string { 3344 return awsutil.Prettify(s) 3345} 3346 3347// GoString returns the string representation 3348func (s BillExpirationException) GoString() string { 3349 return s.String() 3350} 3351 3352func newErrorBillExpirationException(v protocol.ResponseMetadata) error { 3353 return &BillExpirationException{ 3354 RespMetadata: v, 3355 } 3356} 3357 3358// Code returns the exception type name. 3359func (s *BillExpirationException) Code() string { 3360 return "BillExpirationException" 3361} 3362 3363// Message returns the exception's message. 3364func (s *BillExpirationException) Message() string { 3365 if s.Message_ != nil { 3366 return *s.Message_ 3367 } 3368 return "" 3369} 3370 3371// OrigErr always returns nil, satisfies awserr.Error interface. 3372func (s *BillExpirationException) OrigErr() error { 3373 return nil 3374} 3375 3376func (s *BillExpirationException) Error() string { 3377 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 3378} 3379 3380// Status code returns the HTTP status code for the request's response error. 3381func (s *BillExpirationException) StatusCode() int { 3382 return s.RespMetadata.StatusCode 3383} 3384 3385// RequestID returns the service's response RequestID for request. 3386func (s *BillExpirationException) RequestID() string { 3387 return s.RespMetadata.RequestID 3388} 3389 3390// The structure of Cost Categories. This includes detailed metadata and the 3391// set of rules for the CostCategory object. 3392type CostCategory struct { 3393 _ struct{} `type:"structure"` 3394 3395 // The unique identifier for your Cost Category. 3396 // 3397 // CostCategoryArn is a required field 3398 CostCategoryArn *string `min:"20" type:"string" required:"true"` 3399 3400 // The Cost Category's effective end date. 3401 EffectiveEnd *string `min:"20" type:"string"` 3402 3403 // The Cost Category's effective start date. 3404 // 3405 // EffectiveStart is a required field 3406 EffectiveStart *string `min:"20" type:"string" required:"true"` 3407 3408 // The unique name of the Cost Category. 3409 // 3410 // Name is a required field 3411 Name *string `min:"1" type:"string" required:"true"` 3412 3413 // The list of processing statuses for Cost Management products for a specific 3414 // cost category. 3415 ProcessingStatus []*CostCategoryProcessingStatus `type:"list"` 3416 3417 // The rule schema version in this particular Cost Category. 3418 // 3419 // RuleVersion is a required field 3420 RuleVersion *string `type:"string" required:"true" enum:"CostCategoryRuleVersion"` 3421 3422 // Rules are processed in order. If there are multiple rules that match the 3423 // line item, then the first rule to match is used to determine that Cost Category 3424 // value. 3425 // 3426 // Rules is a required field 3427 Rules []*CostCategoryRule `min:"1" type:"list" required:"true"` 3428} 3429 3430// String returns the string representation 3431func (s CostCategory) String() string { 3432 return awsutil.Prettify(s) 3433} 3434 3435// GoString returns the string representation 3436func (s CostCategory) GoString() string { 3437 return s.String() 3438} 3439 3440// SetCostCategoryArn sets the CostCategoryArn field's value. 3441func (s *CostCategory) SetCostCategoryArn(v string) *CostCategory { 3442 s.CostCategoryArn = &v 3443 return s 3444} 3445 3446// SetEffectiveEnd sets the EffectiveEnd field's value. 3447func (s *CostCategory) SetEffectiveEnd(v string) *CostCategory { 3448 s.EffectiveEnd = &v 3449 return s 3450} 3451 3452// SetEffectiveStart sets the EffectiveStart field's value. 3453func (s *CostCategory) SetEffectiveStart(v string) *CostCategory { 3454 s.EffectiveStart = &v 3455 return s 3456} 3457 3458// SetName sets the Name field's value. 3459func (s *CostCategory) SetName(v string) *CostCategory { 3460 s.Name = &v 3461 return s 3462} 3463 3464// SetProcessingStatus sets the ProcessingStatus field's value. 3465func (s *CostCategory) SetProcessingStatus(v []*CostCategoryProcessingStatus) *CostCategory { 3466 s.ProcessingStatus = v 3467 return s 3468} 3469 3470// SetRuleVersion sets the RuleVersion field's value. 3471func (s *CostCategory) SetRuleVersion(v string) *CostCategory { 3472 s.RuleVersion = &v 3473 return s 3474} 3475 3476// SetRules sets the Rules field's value. 3477func (s *CostCategory) SetRules(v []*CostCategoryRule) *CostCategory { 3478 s.Rules = v 3479 return s 3480} 3481 3482// The list of processing statuses for Cost Management products for a specific 3483// cost category. 3484type CostCategoryProcessingStatus struct { 3485 _ struct{} `type:"structure"` 3486 3487 // The Cost Management product name of the applied status. 3488 Component *string `type:"string" enum:"CostCategoryStatusComponent"` 3489 3490 // The process status for a specific cost category. 3491 Status *string `type:"string" enum:"CostCategoryStatus"` 3492} 3493 3494// String returns the string representation 3495func (s CostCategoryProcessingStatus) String() string { 3496 return awsutil.Prettify(s) 3497} 3498 3499// GoString returns the string representation 3500func (s CostCategoryProcessingStatus) GoString() string { 3501 return s.String() 3502} 3503 3504// SetComponent sets the Component field's value. 3505func (s *CostCategoryProcessingStatus) SetComponent(v string) *CostCategoryProcessingStatus { 3506 s.Component = &v 3507 return s 3508} 3509 3510// SetStatus sets the Status field's value. 3511func (s *CostCategoryProcessingStatus) SetStatus(v string) *CostCategoryProcessingStatus { 3512 s.Status = &v 3513 return s 3514} 3515 3516// A reference to a Cost Category containing only enough information to identify 3517// the Cost Category. 3518// 3519// You can use this information to retrieve the full Cost Category information 3520// using DescribeCostCategory. 3521type CostCategoryReference struct { 3522 _ struct{} `type:"structure"` 3523 3524 // The unique identifier for your Cost Category. 3525 CostCategoryArn *string `min:"20" type:"string"` 3526 3527 // The Cost Category's effective end date. 3528 EffectiveEnd *string `min:"20" type:"string"` 3529 3530 // The Cost Category's effective start date. 3531 EffectiveStart *string `min:"20" type:"string"` 3532 3533 // The unique name of the Cost Category. 3534 Name *string `min:"1" type:"string"` 3535 3536 // The number of rules associated with a specific Cost Category. 3537 NumberOfRules *int64 `type:"integer"` 3538 3539 // The list of processing statuses for Cost Management products for a specific 3540 // cost category. 3541 ProcessingStatus []*CostCategoryProcessingStatus `type:"list"` 3542 3543 // A list of unique cost category values in a specific cost category. 3544 Values []*string `type:"list"` 3545} 3546 3547// String returns the string representation 3548func (s CostCategoryReference) String() string { 3549 return awsutil.Prettify(s) 3550} 3551 3552// GoString returns the string representation 3553func (s CostCategoryReference) GoString() string { 3554 return s.String() 3555} 3556 3557// SetCostCategoryArn sets the CostCategoryArn field's value. 3558func (s *CostCategoryReference) SetCostCategoryArn(v string) *CostCategoryReference { 3559 s.CostCategoryArn = &v 3560 return s 3561} 3562 3563// SetEffectiveEnd sets the EffectiveEnd field's value. 3564func (s *CostCategoryReference) SetEffectiveEnd(v string) *CostCategoryReference { 3565 s.EffectiveEnd = &v 3566 return s 3567} 3568 3569// SetEffectiveStart sets the EffectiveStart field's value. 3570func (s *CostCategoryReference) SetEffectiveStart(v string) *CostCategoryReference { 3571 s.EffectiveStart = &v 3572 return s 3573} 3574 3575// SetName sets the Name field's value. 3576func (s *CostCategoryReference) SetName(v string) *CostCategoryReference { 3577 s.Name = &v 3578 return s 3579} 3580 3581// SetNumberOfRules sets the NumberOfRules field's value. 3582func (s *CostCategoryReference) SetNumberOfRules(v int64) *CostCategoryReference { 3583 s.NumberOfRules = &v 3584 return s 3585} 3586 3587// SetProcessingStatus sets the ProcessingStatus field's value. 3588func (s *CostCategoryReference) SetProcessingStatus(v []*CostCategoryProcessingStatus) *CostCategoryReference { 3589 s.ProcessingStatus = v 3590 return s 3591} 3592 3593// SetValues sets the Values field's value. 3594func (s *CostCategoryReference) SetValues(v []*string) *CostCategoryReference { 3595 s.Values = v 3596 return s 3597} 3598 3599// Rules are processed in order. If there are multiple rules that match the 3600// line item, then the first rule to match is used to determine that Cost Category 3601// value. 3602type CostCategoryRule struct { 3603 _ struct{} `type:"structure"` 3604 3605 // An Expression (https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_Expression.html) 3606 // object used to categorize costs. This supports dimensions, tags, and nested 3607 // expressions. Currently the only dimensions supported are LINKED_ACCOUNT, 3608 // SERVICE_CODE, RECORD_TYPE, and LINKED_ACCOUNT_NAME. 3609 // 3610 // Root level OR is not supported. We recommend that you create a separate rule 3611 // instead. 3612 // 3613 // RECORD_TYPE is a dimension used for Cost Explorer APIs, and is also supported 3614 // for Cost Category expressions. This dimension uses different terms, depending 3615 // on whether you're using the console or API/JSON editor. For a detailed comparison, 3616 // see Term Comparisons (https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/manage-cost-categories.html#cost-categories-terms) 3617 // in the AWS Billing and Cost Management User Guide. 3618 // 3619 // Rule is a required field 3620 Rule *Expression `type:"structure" required:"true"` 3621 3622 // The value a line item will be categorized as, if it matches the rule. 3623 // 3624 // Value is a required field 3625 Value *string `min:"1" type:"string" required:"true"` 3626} 3627 3628// String returns the string representation 3629func (s CostCategoryRule) String() string { 3630 return awsutil.Prettify(s) 3631} 3632 3633// GoString returns the string representation 3634func (s CostCategoryRule) GoString() string { 3635 return s.String() 3636} 3637 3638// Validate inspects the fields of the type to determine if they are valid. 3639func (s *CostCategoryRule) Validate() error { 3640 invalidParams := request.ErrInvalidParams{Context: "CostCategoryRule"} 3641 if s.Rule == nil { 3642 invalidParams.Add(request.NewErrParamRequired("Rule")) 3643 } 3644 if s.Value == nil { 3645 invalidParams.Add(request.NewErrParamRequired("Value")) 3646 } 3647 if s.Value != nil && len(*s.Value) < 1 { 3648 invalidParams.Add(request.NewErrParamMinLen("Value", 1)) 3649 } 3650 if s.Rule != nil { 3651 if err := s.Rule.Validate(); err != nil { 3652 invalidParams.AddNested("Rule", err.(request.ErrInvalidParams)) 3653 } 3654 } 3655 3656 if invalidParams.Len() > 0 { 3657 return invalidParams 3658 } 3659 return nil 3660} 3661 3662// SetRule sets the Rule field's value. 3663func (s *CostCategoryRule) SetRule(v *Expression) *CostCategoryRule { 3664 s.Rule = v 3665 return s 3666} 3667 3668// SetValue sets the Value field's value. 3669func (s *CostCategoryRule) SetValue(v string) *CostCategoryRule { 3670 s.Value = &v 3671 return s 3672} 3673 3674// The Cost Categories values used for filtering the costs. 3675// 3676// If Values and Key are not specified, the ABSENT MatchOption is applied to 3677// all Cost Categories. That is, filtering on resources that are not mapped 3678// to any Cost Categories. 3679// 3680// If Values is provided and Key is not specified, the ABSENT MatchOption is 3681// applied to the Cost Categories Key only. That is, filtering on resources 3682// without the given Cost Categories key. 3683type CostCategoryValues struct { 3684 _ struct{} `type:"structure"` 3685 3686 // The unique name of the Cost Category. 3687 Key *string `min:"1" type:"string"` 3688 3689 // The match options that you can use to filter your results. MatchOptions is 3690 // only applicable for actions related to cost category. The default values 3691 // for MatchOptions is EQUALS and CASE_SENSITIVE. 3692 MatchOptions []*string `type:"list"` 3693 3694 // The specific value of the Cost Category. 3695 Values []*string `type:"list"` 3696} 3697 3698// String returns the string representation 3699func (s CostCategoryValues) String() string { 3700 return awsutil.Prettify(s) 3701} 3702 3703// GoString returns the string representation 3704func (s CostCategoryValues) GoString() string { 3705 return s.String() 3706} 3707 3708// Validate inspects the fields of the type to determine if they are valid. 3709func (s *CostCategoryValues) Validate() error { 3710 invalidParams := request.ErrInvalidParams{Context: "CostCategoryValues"} 3711 if s.Key != nil && len(*s.Key) < 1 { 3712 invalidParams.Add(request.NewErrParamMinLen("Key", 1)) 3713 } 3714 3715 if invalidParams.Len() > 0 { 3716 return invalidParams 3717 } 3718 return nil 3719} 3720 3721// SetKey sets the Key field's value. 3722func (s *CostCategoryValues) SetKey(v string) *CostCategoryValues { 3723 s.Key = &v 3724 return s 3725} 3726 3727// SetMatchOptions sets the MatchOptions field's value. 3728func (s *CostCategoryValues) SetMatchOptions(v []*string) *CostCategoryValues { 3729 s.MatchOptions = v 3730 return s 3731} 3732 3733// SetValues sets the Values field's value. 3734func (s *CostCategoryValues) SetValues(v []*string) *CostCategoryValues { 3735 s.Values = v 3736 return s 3737} 3738 3739// The amount of instance usage that a reservation covered. 3740type Coverage struct { 3741 _ struct{} `type:"structure"` 3742 3743 // The amount of cost that the reservation covered. 3744 CoverageCost *CoverageCost `type:"structure"` 3745 3746 // The amount of instance usage that the reservation covered, in hours. 3747 CoverageHours *CoverageHours `type:"structure"` 3748 3749 // The amount of instance usage that the reservation covered, in normalized 3750 // units. 3751 CoverageNormalizedUnits *CoverageNormalizedUnits `type:"structure"` 3752} 3753 3754// String returns the string representation 3755func (s Coverage) String() string { 3756 return awsutil.Prettify(s) 3757} 3758 3759// GoString returns the string representation 3760func (s Coverage) GoString() string { 3761 return s.String() 3762} 3763 3764// SetCoverageCost sets the CoverageCost field's value. 3765func (s *Coverage) SetCoverageCost(v *CoverageCost) *Coverage { 3766 s.CoverageCost = v 3767 return s 3768} 3769 3770// SetCoverageHours sets the CoverageHours field's value. 3771func (s *Coverage) SetCoverageHours(v *CoverageHours) *Coverage { 3772 s.CoverageHours = v 3773 return s 3774} 3775 3776// SetCoverageNormalizedUnits sets the CoverageNormalizedUnits field's value. 3777func (s *Coverage) SetCoverageNormalizedUnits(v *CoverageNormalizedUnits) *Coverage { 3778 s.CoverageNormalizedUnits = v 3779 return s 3780} 3781 3782// Reservation coverage for a specified period, in hours. 3783type CoverageByTime struct { 3784 _ struct{} `type:"structure"` 3785 3786 // The groups of instances that the reservation covered. 3787 Groups []*ReservationCoverageGroup `type:"list"` 3788 3789 // The period that this coverage was used over. 3790 TimePeriod *DateInterval `type:"structure"` 3791 3792 // The total reservation coverage, in hours. 3793 Total *Coverage `type:"structure"` 3794} 3795 3796// String returns the string representation 3797func (s CoverageByTime) String() string { 3798 return awsutil.Prettify(s) 3799} 3800 3801// GoString returns the string representation 3802func (s CoverageByTime) GoString() string { 3803 return s.String() 3804} 3805 3806// SetGroups sets the Groups field's value. 3807func (s *CoverageByTime) SetGroups(v []*ReservationCoverageGroup) *CoverageByTime { 3808 s.Groups = v 3809 return s 3810} 3811 3812// SetTimePeriod sets the TimePeriod field's value. 3813func (s *CoverageByTime) SetTimePeriod(v *DateInterval) *CoverageByTime { 3814 s.TimePeriod = v 3815 return s 3816} 3817 3818// SetTotal sets the Total field's value. 3819func (s *CoverageByTime) SetTotal(v *Coverage) *CoverageByTime { 3820 s.Total = v 3821 return s 3822} 3823 3824// How much it costs to run an instance. 3825type CoverageCost struct { 3826 _ struct{} `type:"structure"` 3827 3828 // How much an On-Demand Instance costs. 3829 OnDemandCost *string `type:"string"` 3830} 3831 3832// String returns the string representation 3833func (s CoverageCost) String() string { 3834 return awsutil.Prettify(s) 3835} 3836 3837// GoString returns the string representation 3838func (s CoverageCost) GoString() string { 3839 return s.String() 3840} 3841 3842// SetOnDemandCost sets the OnDemandCost field's value. 3843func (s *CoverageCost) SetOnDemandCost(v string) *CoverageCost { 3844 s.OnDemandCost = &v 3845 return s 3846} 3847 3848// How long a running instance either used a reservation or was On-Demand. 3849type CoverageHours struct { 3850 _ struct{} `type:"structure"` 3851 3852 // The percentage of instance hours that a reservation covered. 3853 CoverageHoursPercentage *string `type:"string"` 3854 3855 // The number of instance running hours that On-Demand Instances covered. 3856 OnDemandHours *string `type:"string"` 3857 3858 // The number of instance running hours that reservations covered. 3859 ReservedHours *string `type:"string"` 3860 3861 // The total instance usage, in hours. 3862 TotalRunningHours *string `type:"string"` 3863} 3864 3865// String returns the string representation 3866func (s CoverageHours) String() string { 3867 return awsutil.Prettify(s) 3868} 3869 3870// GoString returns the string representation 3871func (s CoverageHours) GoString() string { 3872 return s.String() 3873} 3874 3875// SetCoverageHoursPercentage sets the CoverageHoursPercentage field's value. 3876func (s *CoverageHours) SetCoverageHoursPercentage(v string) *CoverageHours { 3877 s.CoverageHoursPercentage = &v 3878 return s 3879} 3880 3881// SetOnDemandHours sets the OnDemandHours field's value. 3882func (s *CoverageHours) SetOnDemandHours(v string) *CoverageHours { 3883 s.OnDemandHours = &v 3884 return s 3885} 3886 3887// SetReservedHours sets the ReservedHours field's value. 3888func (s *CoverageHours) SetReservedHours(v string) *CoverageHours { 3889 s.ReservedHours = &v 3890 return s 3891} 3892 3893// SetTotalRunningHours sets the TotalRunningHours field's value. 3894func (s *CoverageHours) SetTotalRunningHours(v string) *CoverageHours { 3895 s.TotalRunningHours = &v 3896 return s 3897} 3898 3899// The amount of instance usage, in normalized units. Normalized units enable 3900// you to see your EC2 usage for multiple sizes of instances in a uniform way. 3901// For example, suppose you run an xlarge instance and a 2xlarge instance. If 3902// you run both instances for the same amount of time, the 2xlarge instance 3903// uses twice as much of your reservation as the xlarge instance, even though 3904// both instances show only one instance-hour. Using normalized units instead 3905// of instance-hours, the xlarge instance used 8 normalized units, and the 2xlarge 3906// instance used 16 normalized units. 3907// 3908// For more information, see Modifying Reserved Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-modifying.html) 3909// in the Amazon Elastic Compute Cloud User Guide for Linux Instances. 3910type CoverageNormalizedUnits struct { 3911 _ struct{} `type:"structure"` 3912 3913 // The percentage of your used instance normalized units that a reservation 3914 // covers. 3915 CoverageNormalizedUnitsPercentage *string `type:"string"` 3916 3917 // The number of normalized units that are covered by On-Demand Instances instead 3918 // of a reservation. 3919 OnDemandNormalizedUnits *string `type:"string"` 3920 3921 // The number of normalized units that a reservation covers. 3922 ReservedNormalizedUnits *string `type:"string"` 3923 3924 // The total number of normalized units that you used. 3925 TotalRunningNormalizedUnits *string `type:"string"` 3926} 3927 3928// String returns the string representation 3929func (s CoverageNormalizedUnits) String() string { 3930 return awsutil.Prettify(s) 3931} 3932 3933// GoString returns the string representation 3934func (s CoverageNormalizedUnits) GoString() string { 3935 return s.String() 3936} 3937 3938// SetCoverageNormalizedUnitsPercentage sets the CoverageNormalizedUnitsPercentage field's value. 3939func (s *CoverageNormalizedUnits) SetCoverageNormalizedUnitsPercentage(v string) *CoverageNormalizedUnits { 3940 s.CoverageNormalizedUnitsPercentage = &v 3941 return s 3942} 3943 3944// SetOnDemandNormalizedUnits sets the OnDemandNormalizedUnits field's value. 3945func (s *CoverageNormalizedUnits) SetOnDemandNormalizedUnits(v string) *CoverageNormalizedUnits { 3946 s.OnDemandNormalizedUnits = &v 3947 return s 3948} 3949 3950// SetReservedNormalizedUnits sets the ReservedNormalizedUnits field's value. 3951func (s *CoverageNormalizedUnits) SetReservedNormalizedUnits(v string) *CoverageNormalizedUnits { 3952 s.ReservedNormalizedUnits = &v 3953 return s 3954} 3955 3956// SetTotalRunningNormalizedUnits sets the TotalRunningNormalizedUnits field's value. 3957func (s *CoverageNormalizedUnits) SetTotalRunningNormalizedUnits(v string) *CoverageNormalizedUnits { 3958 s.TotalRunningNormalizedUnits = &v 3959 return s 3960} 3961 3962type CreateAnomalyMonitorInput struct { 3963 _ struct{} `type:"structure"` 3964 3965 // The cost anomaly detection monitor object that you want to create. 3966 // 3967 // AnomalyMonitor is a required field 3968 AnomalyMonitor *AnomalyMonitor `type:"structure" required:"true"` 3969} 3970 3971// String returns the string representation 3972func (s CreateAnomalyMonitorInput) String() string { 3973 return awsutil.Prettify(s) 3974} 3975 3976// GoString returns the string representation 3977func (s CreateAnomalyMonitorInput) GoString() string { 3978 return s.String() 3979} 3980 3981// Validate inspects the fields of the type to determine if they are valid. 3982func (s *CreateAnomalyMonitorInput) Validate() error { 3983 invalidParams := request.ErrInvalidParams{Context: "CreateAnomalyMonitorInput"} 3984 if s.AnomalyMonitor == nil { 3985 invalidParams.Add(request.NewErrParamRequired("AnomalyMonitor")) 3986 } 3987 if s.AnomalyMonitor != nil { 3988 if err := s.AnomalyMonitor.Validate(); err != nil { 3989 invalidParams.AddNested("AnomalyMonitor", err.(request.ErrInvalidParams)) 3990 } 3991 } 3992 3993 if invalidParams.Len() > 0 { 3994 return invalidParams 3995 } 3996 return nil 3997} 3998 3999// SetAnomalyMonitor sets the AnomalyMonitor field's value. 4000func (s *CreateAnomalyMonitorInput) SetAnomalyMonitor(v *AnomalyMonitor) *CreateAnomalyMonitorInput { 4001 s.AnomalyMonitor = v 4002 return s 4003} 4004 4005type CreateAnomalyMonitorOutput struct { 4006 _ struct{} `type:"structure"` 4007 4008 // The unique identifier of your newly created cost anomaly detection monitor. 4009 // 4010 // MonitorArn is a required field 4011 MonitorArn *string `type:"string" required:"true"` 4012} 4013 4014// String returns the string representation 4015func (s CreateAnomalyMonitorOutput) String() string { 4016 return awsutil.Prettify(s) 4017} 4018 4019// GoString returns the string representation 4020func (s CreateAnomalyMonitorOutput) GoString() string { 4021 return s.String() 4022} 4023 4024// SetMonitorArn sets the MonitorArn field's value. 4025func (s *CreateAnomalyMonitorOutput) SetMonitorArn(v string) *CreateAnomalyMonitorOutput { 4026 s.MonitorArn = &v 4027 return s 4028} 4029 4030type CreateAnomalySubscriptionInput struct { 4031 _ struct{} `type:"structure"` 4032 4033 // The cost anomaly subscription object that you want to create. 4034 // 4035 // AnomalySubscription is a required field 4036 AnomalySubscription *AnomalySubscription `type:"structure" required:"true"` 4037} 4038 4039// String returns the string representation 4040func (s CreateAnomalySubscriptionInput) String() string { 4041 return awsutil.Prettify(s) 4042} 4043 4044// GoString returns the string representation 4045func (s CreateAnomalySubscriptionInput) GoString() string { 4046 return s.String() 4047} 4048 4049// Validate inspects the fields of the type to determine if they are valid. 4050func (s *CreateAnomalySubscriptionInput) Validate() error { 4051 invalidParams := request.ErrInvalidParams{Context: "CreateAnomalySubscriptionInput"} 4052 if s.AnomalySubscription == nil { 4053 invalidParams.Add(request.NewErrParamRequired("AnomalySubscription")) 4054 } 4055 if s.AnomalySubscription != nil { 4056 if err := s.AnomalySubscription.Validate(); err != nil { 4057 invalidParams.AddNested("AnomalySubscription", err.(request.ErrInvalidParams)) 4058 } 4059 } 4060 4061 if invalidParams.Len() > 0 { 4062 return invalidParams 4063 } 4064 return nil 4065} 4066 4067// SetAnomalySubscription sets the AnomalySubscription field's value. 4068func (s *CreateAnomalySubscriptionInput) SetAnomalySubscription(v *AnomalySubscription) *CreateAnomalySubscriptionInput { 4069 s.AnomalySubscription = v 4070 return s 4071} 4072 4073type CreateAnomalySubscriptionOutput struct { 4074 _ struct{} `type:"structure"` 4075 4076 // The unique identifier of your newly created cost anomaly subscription. 4077 // 4078 // SubscriptionArn is a required field 4079 SubscriptionArn *string `type:"string" required:"true"` 4080} 4081 4082// String returns the string representation 4083func (s CreateAnomalySubscriptionOutput) String() string { 4084 return awsutil.Prettify(s) 4085} 4086 4087// GoString returns the string representation 4088func (s CreateAnomalySubscriptionOutput) GoString() string { 4089 return s.String() 4090} 4091 4092// SetSubscriptionArn sets the SubscriptionArn field's value. 4093func (s *CreateAnomalySubscriptionOutput) SetSubscriptionArn(v string) *CreateAnomalySubscriptionOutput { 4094 s.SubscriptionArn = &v 4095 return s 4096} 4097 4098type CreateCostCategoryDefinitionInput struct { 4099 _ struct{} `type:"structure"` 4100 4101 // The unique name of the Cost Category. 4102 // 4103 // Name is a required field 4104 Name *string `min:"1" type:"string" required:"true"` 4105 4106 // The rule schema version in this particular Cost Category. 4107 // 4108 // RuleVersion is a required field 4109 RuleVersion *string `type:"string" required:"true" enum:"CostCategoryRuleVersion"` 4110 4111 // The Cost Category rules used to categorize costs. For more information, see 4112 // CostCategoryRule (https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_CostCategoryRule.html). 4113 // 4114 // Rules is a required field 4115 Rules []*CostCategoryRule `min:"1" type:"list" required:"true"` 4116} 4117 4118// String returns the string representation 4119func (s CreateCostCategoryDefinitionInput) String() string { 4120 return awsutil.Prettify(s) 4121} 4122 4123// GoString returns the string representation 4124func (s CreateCostCategoryDefinitionInput) GoString() string { 4125 return s.String() 4126} 4127 4128// Validate inspects the fields of the type to determine if they are valid. 4129func (s *CreateCostCategoryDefinitionInput) Validate() error { 4130 invalidParams := request.ErrInvalidParams{Context: "CreateCostCategoryDefinitionInput"} 4131 if s.Name == nil { 4132 invalidParams.Add(request.NewErrParamRequired("Name")) 4133 } 4134 if s.Name != nil && len(*s.Name) < 1 { 4135 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 4136 } 4137 if s.RuleVersion == nil { 4138 invalidParams.Add(request.NewErrParamRequired("RuleVersion")) 4139 } 4140 if s.Rules == nil { 4141 invalidParams.Add(request.NewErrParamRequired("Rules")) 4142 } 4143 if s.Rules != nil && len(s.Rules) < 1 { 4144 invalidParams.Add(request.NewErrParamMinLen("Rules", 1)) 4145 } 4146 if s.Rules != nil { 4147 for i, v := range s.Rules { 4148 if v == nil { 4149 continue 4150 } 4151 if err := v.Validate(); err != nil { 4152 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams)) 4153 } 4154 } 4155 } 4156 4157 if invalidParams.Len() > 0 { 4158 return invalidParams 4159 } 4160 return nil 4161} 4162 4163// SetName sets the Name field's value. 4164func (s *CreateCostCategoryDefinitionInput) SetName(v string) *CreateCostCategoryDefinitionInput { 4165 s.Name = &v 4166 return s 4167} 4168 4169// SetRuleVersion sets the RuleVersion field's value. 4170func (s *CreateCostCategoryDefinitionInput) SetRuleVersion(v string) *CreateCostCategoryDefinitionInput { 4171 s.RuleVersion = &v 4172 return s 4173} 4174 4175// SetRules sets the Rules field's value. 4176func (s *CreateCostCategoryDefinitionInput) SetRules(v []*CostCategoryRule) *CreateCostCategoryDefinitionInput { 4177 s.Rules = v 4178 return s 4179} 4180 4181type CreateCostCategoryDefinitionOutput struct { 4182 _ struct{} `type:"structure"` 4183 4184 // The unique identifier for your newly created Cost Category. 4185 CostCategoryArn *string `min:"20" type:"string"` 4186 4187 // The Cost Category's effective start date. 4188 EffectiveStart *string `min:"20" type:"string"` 4189} 4190 4191// String returns the string representation 4192func (s CreateCostCategoryDefinitionOutput) String() string { 4193 return awsutil.Prettify(s) 4194} 4195 4196// GoString returns the string representation 4197func (s CreateCostCategoryDefinitionOutput) GoString() string { 4198 return s.String() 4199} 4200 4201// SetCostCategoryArn sets the CostCategoryArn field's value. 4202func (s *CreateCostCategoryDefinitionOutput) SetCostCategoryArn(v string) *CreateCostCategoryDefinitionOutput { 4203 s.CostCategoryArn = &v 4204 return s 4205} 4206 4207// SetEffectiveStart sets the EffectiveStart field's value. 4208func (s *CreateCostCategoryDefinitionOutput) SetEffectiveStart(v string) *CreateCostCategoryDefinitionOutput { 4209 s.EffectiveStart = &v 4210 return s 4211} 4212 4213// Context about the current instance. 4214type CurrentInstance struct { 4215 _ struct{} `type:"structure"` 4216 4217 // The currency code that AWS used to calculate the costs for this instance. 4218 CurrencyCode *string `type:"string"` 4219 4220 // The name you've given an instance. This field will show as blank if you haven't 4221 // given the instance a name. 4222 InstanceName *string `type:"string"` 4223 4224 // Current On-Demand cost of operating this instance on a monthly basis. 4225 MonthlyCost *string `type:"string"` 4226 4227 // Number of hours during the lookback period billed at On-Demand rates. 4228 OnDemandHoursInLookbackPeriod *string `type:"string"` 4229 4230 // Number of hours during the lookback period covered by reservations. 4231 ReservationCoveredHoursInLookbackPeriod *string `type:"string"` 4232 4233 // Details about the resource and utilization. 4234 ResourceDetails *ResourceDetails `type:"structure"` 4235 4236 // Resource ID of the current instance. 4237 ResourceId *string `type:"string"` 4238 4239 // Utilization information of the current instance during the lookback period. 4240 ResourceUtilization *ResourceUtilization `type:"structure"` 4241 4242 // Number of hours during the lookback period covered by Savings Plans. 4243 SavingsPlansCoveredHoursInLookbackPeriod *string `type:"string"` 4244 4245 // Cost allocation resource tags applied to the instance. 4246 Tags []*TagValues `type:"list"` 4247 4248 // The total number of hours the instance ran during the lookback period. 4249 TotalRunningHoursInLookbackPeriod *string `type:"string"` 4250} 4251 4252// String returns the string representation 4253func (s CurrentInstance) String() string { 4254 return awsutil.Prettify(s) 4255} 4256 4257// GoString returns the string representation 4258func (s CurrentInstance) GoString() string { 4259 return s.String() 4260} 4261 4262// SetCurrencyCode sets the CurrencyCode field's value. 4263func (s *CurrentInstance) SetCurrencyCode(v string) *CurrentInstance { 4264 s.CurrencyCode = &v 4265 return s 4266} 4267 4268// SetInstanceName sets the InstanceName field's value. 4269func (s *CurrentInstance) SetInstanceName(v string) *CurrentInstance { 4270 s.InstanceName = &v 4271 return s 4272} 4273 4274// SetMonthlyCost sets the MonthlyCost field's value. 4275func (s *CurrentInstance) SetMonthlyCost(v string) *CurrentInstance { 4276 s.MonthlyCost = &v 4277 return s 4278} 4279 4280// SetOnDemandHoursInLookbackPeriod sets the OnDemandHoursInLookbackPeriod field's value. 4281func (s *CurrentInstance) SetOnDemandHoursInLookbackPeriod(v string) *CurrentInstance { 4282 s.OnDemandHoursInLookbackPeriod = &v 4283 return s 4284} 4285 4286// SetReservationCoveredHoursInLookbackPeriod sets the ReservationCoveredHoursInLookbackPeriod field's value. 4287func (s *CurrentInstance) SetReservationCoveredHoursInLookbackPeriod(v string) *CurrentInstance { 4288 s.ReservationCoveredHoursInLookbackPeriod = &v 4289 return s 4290} 4291 4292// SetResourceDetails sets the ResourceDetails field's value. 4293func (s *CurrentInstance) SetResourceDetails(v *ResourceDetails) *CurrentInstance { 4294 s.ResourceDetails = v 4295 return s 4296} 4297 4298// SetResourceId sets the ResourceId field's value. 4299func (s *CurrentInstance) SetResourceId(v string) *CurrentInstance { 4300 s.ResourceId = &v 4301 return s 4302} 4303 4304// SetResourceUtilization sets the ResourceUtilization field's value. 4305func (s *CurrentInstance) SetResourceUtilization(v *ResourceUtilization) *CurrentInstance { 4306 s.ResourceUtilization = v 4307 return s 4308} 4309 4310// SetSavingsPlansCoveredHoursInLookbackPeriod sets the SavingsPlansCoveredHoursInLookbackPeriod field's value. 4311func (s *CurrentInstance) SetSavingsPlansCoveredHoursInLookbackPeriod(v string) *CurrentInstance { 4312 s.SavingsPlansCoveredHoursInLookbackPeriod = &v 4313 return s 4314} 4315 4316// SetTags sets the Tags field's value. 4317func (s *CurrentInstance) SetTags(v []*TagValues) *CurrentInstance { 4318 s.Tags = v 4319 return s 4320} 4321 4322// SetTotalRunningHoursInLookbackPeriod sets the TotalRunningHoursInLookbackPeriod field's value. 4323func (s *CurrentInstance) SetTotalRunningHoursInLookbackPeriod(v string) *CurrentInstance { 4324 s.TotalRunningHoursInLookbackPeriod = &v 4325 return s 4326} 4327 4328// The requested data is unavailable. 4329type DataUnavailableException struct { 4330 _ struct{} `type:"structure"` 4331 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 4332 4333 Message_ *string `locationName:"Message" type:"string"` 4334} 4335 4336// String returns the string representation 4337func (s DataUnavailableException) String() string { 4338 return awsutil.Prettify(s) 4339} 4340 4341// GoString returns the string representation 4342func (s DataUnavailableException) GoString() string { 4343 return s.String() 4344} 4345 4346func newErrorDataUnavailableException(v protocol.ResponseMetadata) error { 4347 return &DataUnavailableException{ 4348 RespMetadata: v, 4349 } 4350} 4351 4352// Code returns the exception type name. 4353func (s *DataUnavailableException) Code() string { 4354 return "DataUnavailableException" 4355} 4356 4357// Message returns the exception's message. 4358func (s *DataUnavailableException) Message() string { 4359 if s.Message_ != nil { 4360 return *s.Message_ 4361 } 4362 return "" 4363} 4364 4365// OrigErr always returns nil, satisfies awserr.Error interface. 4366func (s *DataUnavailableException) OrigErr() error { 4367 return nil 4368} 4369 4370func (s *DataUnavailableException) Error() string { 4371 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 4372} 4373 4374// Status code returns the HTTP status code for the request's response error. 4375func (s *DataUnavailableException) StatusCode() int { 4376 return s.RespMetadata.StatusCode 4377} 4378 4379// RequestID returns the service's response RequestID for request. 4380func (s *DataUnavailableException) RequestID() string { 4381 return s.RespMetadata.RequestID 4382} 4383 4384// The time period of the request. 4385type DateInterval struct { 4386 _ struct{} `type:"structure"` 4387 4388 // The end of the time period. The end date is exclusive. For example, if end 4389 // is 2017-05-01, AWS retrieves cost and usage data from the start date up to, 4390 // but not including, 2017-05-01. 4391 // 4392 // End is a required field 4393 End *string `type:"string" required:"true"` 4394 4395 // The beginning of the time period. The start date is inclusive. For example, 4396 // if start is 2017-01-01, AWS retrieves cost and usage data starting at 2017-01-01 4397 // up to the end date. The start date must be equal to or no later than the 4398 // current date to avoid a validation error. 4399 // 4400 // Start is a required field 4401 Start *string `type:"string" required:"true"` 4402} 4403 4404// String returns the string representation 4405func (s DateInterval) String() string { 4406 return awsutil.Prettify(s) 4407} 4408 4409// GoString returns the string representation 4410func (s DateInterval) GoString() string { 4411 return s.String() 4412} 4413 4414// Validate inspects the fields of the type to determine if they are valid. 4415func (s *DateInterval) Validate() error { 4416 invalidParams := request.ErrInvalidParams{Context: "DateInterval"} 4417 if s.End == nil { 4418 invalidParams.Add(request.NewErrParamRequired("End")) 4419 } 4420 if s.Start == nil { 4421 invalidParams.Add(request.NewErrParamRequired("Start")) 4422 } 4423 4424 if invalidParams.Len() > 0 { 4425 return invalidParams 4426 } 4427 return nil 4428} 4429 4430// SetEnd sets the End field's value. 4431func (s *DateInterval) SetEnd(v string) *DateInterval { 4432 s.End = &v 4433 return s 4434} 4435 4436// SetStart sets the Start field's value. 4437func (s *DateInterval) SetStart(v string) *DateInterval { 4438 s.Start = &v 4439 return s 4440} 4441 4442type DeleteAnomalyMonitorInput struct { 4443 _ struct{} `type:"structure"` 4444 4445 // The unique identifier of the cost anomaly monitor that you want to delete. 4446 // 4447 // MonitorArn is a required field 4448 MonitorArn *string `type:"string" required:"true"` 4449} 4450 4451// String returns the string representation 4452func (s DeleteAnomalyMonitorInput) String() string { 4453 return awsutil.Prettify(s) 4454} 4455 4456// GoString returns the string representation 4457func (s DeleteAnomalyMonitorInput) GoString() string { 4458 return s.String() 4459} 4460 4461// Validate inspects the fields of the type to determine if they are valid. 4462func (s *DeleteAnomalyMonitorInput) Validate() error { 4463 invalidParams := request.ErrInvalidParams{Context: "DeleteAnomalyMonitorInput"} 4464 if s.MonitorArn == nil { 4465 invalidParams.Add(request.NewErrParamRequired("MonitorArn")) 4466 } 4467 4468 if invalidParams.Len() > 0 { 4469 return invalidParams 4470 } 4471 return nil 4472} 4473 4474// SetMonitorArn sets the MonitorArn field's value. 4475func (s *DeleteAnomalyMonitorInput) SetMonitorArn(v string) *DeleteAnomalyMonitorInput { 4476 s.MonitorArn = &v 4477 return s 4478} 4479 4480type DeleteAnomalyMonitorOutput struct { 4481 _ struct{} `type:"structure"` 4482} 4483 4484// String returns the string representation 4485func (s DeleteAnomalyMonitorOutput) String() string { 4486 return awsutil.Prettify(s) 4487} 4488 4489// GoString returns the string representation 4490func (s DeleteAnomalyMonitorOutput) GoString() string { 4491 return s.String() 4492} 4493 4494type DeleteAnomalySubscriptionInput struct { 4495 _ struct{} `type:"structure"` 4496 4497 // The unique identifier of the cost anomaly subscription that you want to delete. 4498 // 4499 // SubscriptionArn is a required field 4500 SubscriptionArn *string `type:"string" required:"true"` 4501} 4502 4503// String returns the string representation 4504func (s DeleteAnomalySubscriptionInput) String() string { 4505 return awsutil.Prettify(s) 4506} 4507 4508// GoString returns the string representation 4509func (s DeleteAnomalySubscriptionInput) GoString() string { 4510 return s.String() 4511} 4512 4513// Validate inspects the fields of the type to determine if they are valid. 4514func (s *DeleteAnomalySubscriptionInput) Validate() error { 4515 invalidParams := request.ErrInvalidParams{Context: "DeleteAnomalySubscriptionInput"} 4516 if s.SubscriptionArn == nil { 4517 invalidParams.Add(request.NewErrParamRequired("SubscriptionArn")) 4518 } 4519 4520 if invalidParams.Len() > 0 { 4521 return invalidParams 4522 } 4523 return nil 4524} 4525 4526// SetSubscriptionArn sets the SubscriptionArn field's value. 4527func (s *DeleteAnomalySubscriptionInput) SetSubscriptionArn(v string) *DeleteAnomalySubscriptionInput { 4528 s.SubscriptionArn = &v 4529 return s 4530} 4531 4532type DeleteAnomalySubscriptionOutput struct { 4533 _ struct{} `type:"structure"` 4534} 4535 4536// String returns the string representation 4537func (s DeleteAnomalySubscriptionOutput) String() string { 4538 return awsutil.Prettify(s) 4539} 4540 4541// GoString returns the string representation 4542func (s DeleteAnomalySubscriptionOutput) GoString() string { 4543 return s.String() 4544} 4545 4546type DeleteCostCategoryDefinitionInput struct { 4547 _ struct{} `type:"structure"` 4548 4549 // The unique identifier for your Cost Category. 4550 // 4551 // CostCategoryArn is a required field 4552 CostCategoryArn *string `min:"20" type:"string" required:"true"` 4553} 4554 4555// String returns the string representation 4556func (s DeleteCostCategoryDefinitionInput) String() string { 4557 return awsutil.Prettify(s) 4558} 4559 4560// GoString returns the string representation 4561func (s DeleteCostCategoryDefinitionInput) GoString() string { 4562 return s.String() 4563} 4564 4565// Validate inspects the fields of the type to determine if they are valid. 4566func (s *DeleteCostCategoryDefinitionInput) Validate() error { 4567 invalidParams := request.ErrInvalidParams{Context: "DeleteCostCategoryDefinitionInput"} 4568 if s.CostCategoryArn == nil { 4569 invalidParams.Add(request.NewErrParamRequired("CostCategoryArn")) 4570 } 4571 if s.CostCategoryArn != nil && len(*s.CostCategoryArn) < 20 { 4572 invalidParams.Add(request.NewErrParamMinLen("CostCategoryArn", 20)) 4573 } 4574 4575 if invalidParams.Len() > 0 { 4576 return invalidParams 4577 } 4578 return nil 4579} 4580 4581// SetCostCategoryArn sets the CostCategoryArn field's value. 4582func (s *DeleteCostCategoryDefinitionInput) SetCostCategoryArn(v string) *DeleteCostCategoryDefinitionInput { 4583 s.CostCategoryArn = &v 4584 return s 4585} 4586 4587type DeleteCostCategoryDefinitionOutput struct { 4588 _ struct{} `type:"structure"` 4589 4590 // The unique identifier for your Cost Category. 4591 CostCategoryArn *string `min:"20" type:"string"` 4592 4593 // The effective end date of the Cost Category as a result of deleting it. No 4594 // costs after this date will be categorized by the deleted Cost Category. 4595 EffectiveEnd *string `min:"20" type:"string"` 4596} 4597 4598// String returns the string representation 4599func (s DeleteCostCategoryDefinitionOutput) String() string { 4600 return awsutil.Prettify(s) 4601} 4602 4603// GoString returns the string representation 4604func (s DeleteCostCategoryDefinitionOutput) GoString() string { 4605 return s.String() 4606} 4607 4608// SetCostCategoryArn sets the CostCategoryArn field's value. 4609func (s *DeleteCostCategoryDefinitionOutput) SetCostCategoryArn(v string) *DeleteCostCategoryDefinitionOutput { 4610 s.CostCategoryArn = &v 4611 return s 4612} 4613 4614// SetEffectiveEnd sets the EffectiveEnd field's value. 4615func (s *DeleteCostCategoryDefinitionOutput) SetEffectiveEnd(v string) *DeleteCostCategoryDefinitionOutput { 4616 s.EffectiveEnd = &v 4617 return s 4618} 4619 4620type DescribeCostCategoryDefinitionInput struct { 4621 _ struct{} `type:"structure"` 4622 4623 // The unique identifier for your Cost Category. 4624 // 4625 // CostCategoryArn is a required field 4626 CostCategoryArn *string `min:"20" type:"string" required:"true"` 4627 4628 // The date when the Cost Category was effective. 4629 EffectiveOn *string `min:"20" type:"string"` 4630} 4631 4632// String returns the string representation 4633func (s DescribeCostCategoryDefinitionInput) String() string { 4634 return awsutil.Prettify(s) 4635} 4636 4637// GoString returns the string representation 4638func (s DescribeCostCategoryDefinitionInput) GoString() string { 4639 return s.String() 4640} 4641 4642// Validate inspects the fields of the type to determine if they are valid. 4643func (s *DescribeCostCategoryDefinitionInput) Validate() error { 4644 invalidParams := request.ErrInvalidParams{Context: "DescribeCostCategoryDefinitionInput"} 4645 if s.CostCategoryArn == nil { 4646 invalidParams.Add(request.NewErrParamRequired("CostCategoryArn")) 4647 } 4648 if s.CostCategoryArn != nil && len(*s.CostCategoryArn) < 20 { 4649 invalidParams.Add(request.NewErrParamMinLen("CostCategoryArn", 20)) 4650 } 4651 if s.EffectiveOn != nil && len(*s.EffectiveOn) < 20 { 4652 invalidParams.Add(request.NewErrParamMinLen("EffectiveOn", 20)) 4653 } 4654 4655 if invalidParams.Len() > 0 { 4656 return invalidParams 4657 } 4658 return nil 4659} 4660 4661// SetCostCategoryArn sets the CostCategoryArn field's value. 4662func (s *DescribeCostCategoryDefinitionInput) SetCostCategoryArn(v string) *DescribeCostCategoryDefinitionInput { 4663 s.CostCategoryArn = &v 4664 return s 4665} 4666 4667// SetEffectiveOn sets the EffectiveOn field's value. 4668func (s *DescribeCostCategoryDefinitionInput) SetEffectiveOn(v string) *DescribeCostCategoryDefinitionInput { 4669 s.EffectiveOn = &v 4670 return s 4671} 4672 4673type DescribeCostCategoryDefinitionOutput struct { 4674 _ struct{} `type:"structure"` 4675 4676 // The structure of Cost Categories. This includes detailed metadata and the 4677 // set of rules for the CostCategory object. 4678 CostCategory *CostCategory `type:"structure"` 4679} 4680 4681// String returns the string representation 4682func (s DescribeCostCategoryDefinitionOutput) String() string { 4683 return awsutil.Prettify(s) 4684} 4685 4686// GoString returns the string representation 4687func (s DescribeCostCategoryDefinitionOutput) GoString() string { 4688 return s.String() 4689} 4690 4691// SetCostCategory sets the CostCategory field's value. 4692func (s *DescribeCostCategoryDefinitionOutput) SetCostCategory(v *CostCategory) *DescribeCostCategoryDefinitionOutput { 4693 s.CostCategory = v 4694 return s 4695} 4696 4697// The metadata that you can use to filter and group your results. You can use 4698// GetDimensionValues to find specific values. 4699type DimensionValues struct { 4700 _ struct{} `type:"structure"` 4701 4702 // The names of the metadata types that you can use to filter and group your 4703 // results. For example, AZ returns a list of Availability Zones. 4704 Key *string `type:"string" enum:"Dimension"` 4705 4706 // The match options that you can use to filter your results. MatchOptions is 4707 // only applicable for actions related to Cost Category. The default values 4708 // for MatchOptions are EQUALS and CASE_SENSITIVE. 4709 MatchOptions []*string `type:"list"` 4710 4711 // The metadata values that you can use to filter and group your results. You 4712 // can use GetDimensionValues to find specific values. 4713 Values []*string `type:"list"` 4714} 4715 4716// String returns the string representation 4717func (s DimensionValues) String() string { 4718 return awsutil.Prettify(s) 4719} 4720 4721// GoString returns the string representation 4722func (s DimensionValues) GoString() string { 4723 return s.String() 4724} 4725 4726// SetKey sets the Key field's value. 4727func (s *DimensionValues) SetKey(v string) *DimensionValues { 4728 s.Key = &v 4729 return s 4730} 4731 4732// SetMatchOptions sets the MatchOptions field's value. 4733func (s *DimensionValues) SetMatchOptions(v []*string) *DimensionValues { 4734 s.MatchOptions = v 4735 return s 4736} 4737 4738// SetValues sets the Values field's value. 4739func (s *DimensionValues) SetValues(v []*string) *DimensionValues { 4740 s.Values = v 4741 return s 4742} 4743 4744// The metadata of a specific type that you can use to filter and group your 4745// results. You can use GetDimensionValues to find specific values. 4746type DimensionValuesWithAttributes struct { 4747 _ struct{} `type:"structure"` 4748 4749 // The attribute that applies to a specific Dimension. 4750 Attributes map[string]*string `type:"map"` 4751 4752 // The value of a dimension with a specific attribute. 4753 Value *string `type:"string"` 4754} 4755 4756// String returns the string representation 4757func (s DimensionValuesWithAttributes) String() string { 4758 return awsutil.Prettify(s) 4759} 4760 4761// GoString returns the string representation 4762func (s DimensionValuesWithAttributes) GoString() string { 4763 return s.String() 4764} 4765 4766// SetAttributes sets the Attributes field's value. 4767func (s *DimensionValuesWithAttributes) SetAttributes(v map[string]*string) *DimensionValuesWithAttributes { 4768 s.Attributes = v 4769 return s 4770} 4771 4772// SetValue sets the Value field's value. 4773func (s *DimensionValuesWithAttributes) SetValue(v string) *DimensionValuesWithAttributes { 4774 s.Value = &v 4775 return s 4776} 4777 4778// The EBS field that contains a list of EBS metrics associated with the current 4779// instance. 4780type EBSResourceUtilization struct { 4781 _ struct{} `type:"structure"` 4782 4783 // The maximum size of read operations per second 4784 EbsReadBytesPerSecond *string `type:"string"` 4785 4786 // The maximum number of read operations per second. 4787 EbsReadOpsPerSecond *string `type:"string"` 4788 4789 // The maximum size of write operations per second. 4790 EbsWriteBytesPerSecond *string `type:"string"` 4791 4792 // The maximum number of write operations per second. 4793 EbsWriteOpsPerSecond *string `type:"string"` 4794} 4795 4796// String returns the string representation 4797func (s EBSResourceUtilization) String() string { 4798 return awsutil.Prettify(s) 4799} 4800 4801// GoString returns the string representation 4802func (s EBSResourceUtilization) GoString() string { 4803 return s.String() 4804} 4805 4806// SetEbsReadBytesPerSecond sets the EbsReadBytesPerSecond field's value. 4807func (s *EBSResourceUtilization) SetEbsReadBytesPerSecond(v string) *EBSResourceUtilization { 4808 s.EbsReadBytesPerSecond = &v 4809 return s 4810} 4811 4812// SetEbsReadOpsPerSecond sets the EbsReadOpsPerSecond field's value. 4813func (s *EBSResourceUtilization) SetEbsReadOpsPerSecond(v string) *EBSResourceUtilization { 4814 s.EbsReadOpsPerSecond = &v 4815 return s 4816} 4817 4818// SetEbsWriteBytesPerSecond sets the EbsWriteBytesPerSecond field's value. 4819func (s *EBSResourceUtilization) SetEbsWriteBytesPerSecond(v string) *EBSResourceUtilization { 4820 s.EbsWriteBytesPerSecond = &v 4821 return s 4822} 4823 4824// SetEbsWriteOpsPerSecond sets the EbsWriteOpsPerSecond field's value. 4825func (s *EBSResourceUtilization) SetEbsWriteOpsPerSecond(v string) *EBSResourceUtilization { 4826 s.EbsWriteOpsPerSecond = &v 4827 return s 4828} 4829 4830// Details about the Amazon EC2 instances that AWS recommends that you purchase. 4831type EC2InstanceDetails struct { 4832 _ struct{} `type:"structure"` 4833 4834 // The Availability Zone of the recommended reservation. 4835 AvailabilityZone *string `type:"string"` 4836 4837 // Whether the recommendation is for a current-generation instance. 4838 CurrentGeneration *bool `type:"boolean"` 4839 4840 // The instance family of the recommended reservation. 4841 Family *string `type:"string"` 4842 4843 // The type of instance that AWS recommends. 4844 InstanceType *string `type:"string"` 4845 4846 // The platform of the recommended reservation. The platform is the specific 4847 // combination of operating system, license model, and software on an instance. 4848 Platform *string `type:"string"` 4849 4850 // The AWS Region of the recommended reservation. 4851 Region *string `type:"string"` 4852 4853 // Whether the recommended reservation is size flexible. 4854 SizeFlexEligible *bool `type:"boolean"` 4855 4856 // Whether the recommended reservation is dedicated or shared. 4857 Tenancy *string `type:"string"` 4858} 4859 4860// String returns the string representation 4861func (s EC2InstanceDetails) String() string { 4862 return awsutil.Prettify(s) 4863} 4864 4865// GoString returns the string representation 4866func (s EC2InstanceDetails) GoString() string { 4867 return s.String() 4868} 4869 4870// SetAvailabilityZone sets the AvailabilityZone field's value. 4871func (s *EC2InstanceDetails) SetAvailabilityZone(v string) *EC2InstanceDetails { 4872 s.AvailabilityZone = &v 4873 return s 4874} 4875 4876// SetCurrentGeneration sets the CurrentGeneration field's value. 4877func (s *EC2InstanceDetails) SetCurrentGeneration(v bool) *EC2InstanceDetails { 4878 s.CurrentGeneration = &v 4879 return s 4880} 4881 4882// SetFamily sets the Family field's value. 4883func (s *EC2InstanceDetails) SetFamily(v string) *EC2InstanceDetails { 4884 s.Family = &v 4885 return s 4886} 4887 4888// SetInstanceType sets the InstanceType field's value. 4889func (s *EC2InstanceDetails) SetInstanceType(v string) *EC2InstanceDetails { 4890 s.InstanceType = &v 4891 return s 4892} 4893 4894// SetPlatform sets the Platform field's value. 4895func (s *EC2InstanceDetails) SetPlatform(v string) *EC2InstanceDetails { 4896 s.Platform = &v 4897 return s 4898} 4899 4900// SetRegion sets the Region field's value. 4901func (s *EC2InstanceDetails) SetRegion(v string) *EC2InstanceDetails { 4902 s.Region = &v 4903 return s 4904} 4905 4906// SetSizeFlexEligible sets the SizeFlexEligible field's value. 4907func (s *EC2InstanceDetails) SetSizeFlexEligible(v bool) *EC2InstanceDetails { 4908 s.SizeFlexEligible = &v 4909 return s 4910} 4911 4912// SetTenancy sets the Tenancy field's value. 4913func (s *EC2InstanceDetails) SetTenancy(v string) *EC2InstanceDetails { 4914 s.Tenancy = &v 4915 return s 4916} 4917 4918// Details on the Amazon EC2 Resource. 4919type EC2ResourceDetails struct { 4920 _ struct{} `type:"structure"` 4921 4922 // Hourly public On-Demand rate for the instance type. 4923 HourlyOnDemandRate *string `type:"string"` 4924 4925 // The type of AWS instance. 4926 InstanceType *string `type:"string"` 4927 4928 // Memory capacity of the AWS instance. 4929 Memory *string `type:"string"` 4930 4931 // Network performance capacity of the AWS instance. 4932 NetworkPerformance *string `type:"string"` 4933 4934 // The platform of the AWS instance. The platform is the specific combination 4935 // of operating system, license model, and software on an instance. 4936 Platform *string `type:"string"` 4937 4938 // The AWS Region of the instance. 4939 Region *string `type:"string"` 4940 4941 // The SKU of the product. 4942 Sku *string `type:"string"` 4943 4944 // The disk storage of the AWS instance (not EBS storage). 4945 Storage *string `type:"string"` 4946 4947 // Number of VCPU cores in the AWS instance type. 4948 Vcpu *string `type:"string"` 4949} 4950 4951// String returns the string representation 4952func (s EC2ResourceDetails) String() string { 4953 return awsutil.Prettify(s) 4954} 4955 4956// GoString returns the string representation 4957func (s EC2ResourceDetails) GoString() string { 4958 return s.String() 4959} 4960 4961// SetHourlyOnDemandRate sets the HourlyOnDemandRate field's value. 4962func (s *EC2ResourceDetails) SetHourlyOnDemandRate(v string) *EC2ResourceDetails { 4963 s.HourlyOnDemandRate = &v 4964 return s 4965} 4966 4967// SetInstanceType sets the InstanceType field's value. 4968func (s *EC2ResourceDetails) SetInstanceType(v string) *EC2ResourceDetails { 4969 s.InstanceType = &v 4970 return s 4971} 4972 4973// SetMemory sets the Memory field's value. 4974func (s *EC2ResourceDetails) SetMemory(v string) *EC2ResourceDetails { 4975 s.Memory = &v 4976 return s 4977} 4978 4979// SetNetworkPerformance sets the NetworkPerformance field's value. 4980func (s *EC2ResourceDetails) SetNetworkPerformance(v string) *EC2ResourceDetails { 4981 s.NetworkPerformance = &v 4982 return s 4983} 4984 4985// SetPlatform sets the Platform field's value. 4986func (s *EC2ResourceDetails) SetPlatform(v string) *EC2ResourceDetails { 4987 s.Platform = &v 4988 return s 4989} 4990 4991// SetRegion sets the Region field's value. 4992func (s *EC2ResourceDetails) SetRegion(v string) *EC2ResourceDetails { 4993 s.Region = &v 4994 return s 4995} 4996 4997// SetSku sets the Sku field's value. 4998func (s *EC2ResourceDetails) SetSku(v string) *EC2ResourceDetails { 4999 s.Sku = &v 5000 return s 5001} 5002 5003// SetStorage sets the Storage field's value. 5004func (s *EC2ResourceDetails) SetStorage(v string) *EC2ResourceDetails { 5005 s.Storage = &v 5006 return s 5007} 5008 5009// SetVcpu sets the Vcpu field's value. 5010func (s *EC2ResourceDetails) SetVcpu(v string) *EC2ResourceDetails { 5011 s.Vcpu = &v 5012 return s 5013} 5014 5015// Utilization metrics of the instance. 5016type EC2ResourceUtilization struct { 5017 _ struct{} `type:"structure"` 5018 5019 // The EBS field that contains a list of EBS metrics associated with the current 5020 // instance. 5021 EBSResourceUtilization *EBSResourceUtilization `type:"structure"` 5022 5023 // Maximum observed or expected CPU utilization of the instance. 5024 MaxCpuUtilizationPercentage *string `type:"string"` 5025 5026 // Maximum observed or expected memory utilization of the instance. 5027 MaxMemoryUtilizationPercentage *string `type:"string"` 5028 5029 // Maximum observed or expected storage utilization of the instance (does not 5030 // measure EBS storage). 5031 MaxStorageUtilizationPercentage *string `type:"string"` 5032} 5033 5034// String returns the string representation 5035func (s EC2ResourceUtilization) String() string { 5036 return awsutil.Prettify(s) 5037} 5038 5039// GoString returns the string representation 5040func (s EC2ResourceUtilization) GoString() string { 5041 return s.String() 5042} 5043 5044// SetEBSResourceUtilization sets the EBSResourceUtilization field's value. 5045func (s *EC2ResourceUtilization) SetEBSResourceUtilization(v *EBSResourceUtilization) *EC2ResourceUtilization { 5046 s.EBSResourceUtilization = v 5047 return s 5048} 5049 5050// SetMaxCpuUtilizationPercentage sets the MaxCpuUtilizationPercentage field's value. 5051func (s *EC2ResourceUtilization) SetMaxCpuUtilizationPercentage(v string) *EC2ResourceUtilization { 5052 s.MaxCpuUtilizationPercentage = &v 5053 return s 5054} 5055 5056// SetMaxMemoryUtilizationPercentage sets the MaxMemoryUtilizationPercentage field's value. 5057func (s *EC2ResourceUtilization) SetMaxMemoryUtilizationPercentage(v string) *EC2ResourceUtilization { 5058 s.MaxMemoryUtilizationPercentage = &v 5059 return s 5060} 5061 5062// SetMaxStorageUtilizationPercentage sets the MaxStorageUtilizationPercentage field's value. 5063func (s *EC2ResourceUtilization) SetMaxStorageUtilizationPercentage(v string) *EC2ResourceUtilization { 5064 s.MaxStorageUtilizationPercentage = &v 5065 return s 5066} 5067 5068// The Amazon EC2 hardware specifications that you want AWS to provide recommendations 5069// for. 5070type EC2Specification struct { 5071 _ struct{} `type:"structure"` 5072 5073 // Whether you want a recommendation for standard or convertible reservations. 5074 OfferingClass *string `type:"string" enum:"OfferingClass"` 5075} 5076 5077// String returns the string representation 5078func (s EC2Specification) String() string { 5079 return awsutil.Prettify(s) 5080} 5081 5082// GoString returns the string representation 5083func (s EC2Specification) GoString() string { 5084 return s.String() 5085} 5086 5087// SetOfferingClass sets the OfferingClass field's value. 5088func (s *EC2Specification) SetOfferingClass(v string) *EC2Specification { 5089 s.OfferingClass = &v 5090 return s 5091} 5092 5093// Details about the Amazon ES instances that AWS recommends that you purchase. 5094type ESInstanceDetails struct { 5095 _ struct{} `type:"structure"` 5096 5097 // Whether the recommendation is for a current-generation instance. 5098 CurrentGeneration *bool `type:"boolean"` 5099 5100 // The class of instance that AWS recommends. 5101 InstanceClass *string `type:"string"` 5102 5103 // The size of instance that AWS recommends. 5104 InstanceSize *string `type:"string"` 5105 5106 // The AWS Region of the recommended reservation. 5107 Region *string `type:"string"` 5108 5109 // Whether the recommended reservation is size flexible. 5110 SizeFlexEligible *bool `type:"boolean"` 5111} 5112 5113// String returns the string representation 5114func (s ESInstanceDetails) String() string { 5115 return awsutil.Prettify(s) 5116} 5117 5118// GoString returns the string representation 5119func (s ESInstanceDetails) GoString() string { 5120 return s.String() 5121} 5122 5123// SetCurrentGeneration sets the CurrentGeneration field's value. 5124func (s *ESInstanceDetails) SetCurrentGeneration(v bool) *ESInstanceDetails { 5125 s.CurrentGeneration = &v 5126 return s 5127} 5128 5129// SetInstanceClass sets the InstanceClass field's value. 5130func (s *ESInstanceDetails) SetInstanceClass(v string) *ESInstanceDetails { 5131 s.InstanceClass = &v 5132 return s 5133} 5134 5135// SetInstanceSize sets the InstanceSize field's value. 5136func (s *ESInstanceDetails) SetInstanceSize(v string) *ESInstanceDetails { 5137 s.InstanceSize = &v 5138 return s 5139} 5140 5141// SetRegion sets the Region field's value. 5142func (s *ESInstanceDetails) SetRegion(v string) *ESInstanceDetails { 5143 s.Region = &v 5144 return s 5145} 5146 5147// SetSizeFlexEligible sets the SizeFlexEligible field's value. 5148func (s *ESInstanceDetails) SetSizeFlexEligible(v bool) *ESInstanceDetails { 5149 s.SizeFlexEligible = &v 5150 return s 5151} 5152 5153// Details about the Amazon ElastiCache instances that AWS recommends that you 5154// purchase. 5155type ElastiCacheInstanceDetails struct { 5156 _ struct{} `type:"structure"` 5157 5158 // Whether the recommendation is for a current generation instance. 5159 CurrentGeneration *bool `type:"boolean"` 5160 5161 // The instance family of the recommended reservation. 5162 Family *string `type:"string"` 5163 5164 // The type of node that AWS recommends. 5165 NodeType *string `type:"string"` 5166 5167 // The description of the recommended reservation. 5168 ProductDescription *string `type:"string"` 5169 5170 // The AWS Region of the recommended reservation. 5171 Region *string `type:"string"` 5172 5173 // Whether the recommended reservation is size flexible. 5174 SizeFlexEligible *bool `type:"boolean"` 5175} 5176 5177// String returns the string representation 5178func (s ElastiCacheInstanceDetails) String() string { 5179 return awsutil.Prettify(s) 5180} 5181 5182// GoString returns the string representation 5183func (s ElastiCacheInstanceDetails) GoString() string { 5184 return s.String() 5185} 5186 5187// SetCurrentGeneration sets the CurrentGeneration field's value. 5188func (s *ElastiCacheInstanceDetails) SetCurrentGeneration(v bool) *ElastiCacheInstanceDetails { 5189 s.CurrentGeneration = &v 5190 return s 5191} 5192 5193// SetFamily sets the Family field's value. 5194func (s *ElastiCacheInstanceDetails) SetFamily(v string) *ElastiCacheInstanceDetails { 5195 s.Family = &v 5196 return s 5197} 5198 5199// SetNodeType sets the NodeType field's value. 5200func (s *ElastiCacheInstanceDetails) SetNodeType(v string) *ElastiCacheInstanceDetails { 5201 s.NodeType = &v 5202 return s 5203} 5204 5205// SetProductDescription sets the ProductDescription field's value. 5206func (s *ElastiCacheInstanceDetails) SetProductDescription(v string) *ElastiCacheInstanceDetails { 5207 s.ProductDescription = &v 5208 return s 5209} 5210 5211// SetRegion sets the Region field's value. 5212func (s *ElastiCacheInstanceDetails) SetRegion(v string) *ElastiCacheInstanceDetails { 5213 s.Region = &v 5214 return s 5215} 5216 5217// SetSizeFlexEligible sets the SizeFlexEligible field's value. 5218func (s *ElastiCacheInstanceDetails) SetSizeFlexEligible(v bool) *ElastiCacheInstanceDetails { 5219 s.SizeFlexEligible = &v 5220 return s 5221} 5222 5223// Use Expression to filter by cost or by usage. There are two patterns: 5224// 5225// * Simple dimension values - You can set the dimension name and values 5226// for the filters that you plan to use. For example, you can filter for 5227// REGION==us-east-1 OR REGION==us-west-1. For GetRightsizingRecommendation, 5228// the Region is a full name (for example, REGION==US East (N. Virginia). 5229// The Expression example looks like: { "Dimensions": { "Key": "REGION", 5230// "Values": [ "us-east-1", “us-west-1” ] } } The list of dimension values 5231// are OR'd together to retrieve cost or usage data. You can create Expression 5232// and DimensionValues objects using either with* methods or set* methods 5233// in multiple lines. 5234// 5235// * Compound dimension values with logical operations - You can use multiple 5236// Expression types and the logical operators AND/OR/NOT to create a list 5237// of one or more Expression objects. This allows you to filter on more advanced 5238// options. For example, you can filter on ((REGION == us-east-1 OR REGION 5239// == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer). 5240// The Expression for that looks like this: { "And": [ {"Or": [ {"Dimensions": 5241// { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": 5242// { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": 5243// { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] } Because each 5244// Expression can have only one operator, the service returns an error if 5245// more than one is specified. The following example shows an Expression 5246// object that creates an error. { "And": [ ... ], "DimensionValues": { "Dimension": 5247// "USAGE_TYPE", "Values": [ "DataTransfer" ] } } 5248// 5249// For the GetRightsizingRecommendation action, a combination of OR and NOT 5250// is not supported. OR is not supported between different dimensions, or dimensions 5251// and tags. NOT operators aren't supported. Dimensions are also limited to 5252// LINKED_ACCOUNT, REGION, or RIGHTSIZING_TYPE. 5253// 5254// For the GetReservationPurchaseRecommendation action, only NOT is supported. 5255// AND and OR are not supported. Dimensions are limited to LINKED_ACCOUNT. 5256type Expression struct { 5257 _ struct{} `type:"structure"` 5258 5259 // Return results that match both Dimension objects. 5260 And []*Expression `type:"list"` 5261 5262 // The filter based on CostCategory values. 5263 CostCategories *CostCategoryValues `type:"structure"` 5264 5265 // The specific Dimension to use for Expression. 5266 Dimensions *DimensionValues `type:"structure"` 5267 5268 // Return results that don't match a Dimension object. 5269 Not *Expression `type:"structure"` 5270 5271 // Return results that match either Dimension object. 5272 Or []*Expression `type:"list"` 5273 5274 // The specific Tag to use for Expression. 5275 Tags *TagValues `type:"structure"` 5276} 5277 5278// String returns the string representation 5279func (s Expression) String() string { 5280 return awsutil.Prettify(s) 5281} 5282 5283// GoString returns the string representation 5284func (s Expression) GoString() string { 5285 return s.String() 5286} 5287 5288// Validate inspects the fields of the type to determine if they are valid. 5289func (s *Expression) Validate() error { 5290 invalidParams := request.ErrInvalidParams{Context: "Expression"} 5291 if s.CostCategories != nil { 5292 if err := s.CostCategories.Validate(); err != nil { 5293 invalidParams.AddNested("CostCategories", err.(request.ErrInvalidParams)) 5294 } 5295 } 5296 if s.Not != nil { 5297 if err := s.Not.Validate(); err != nil { 5298 invalidParams.AddNested("Not", err.(request.ErrInvalidParams)) 5299 } 5300 } 5301 if s.Or != nil { 5302 for i, v := range s.Or { 5303 if v == nil { 5304 continue 5305 } 5306 if err := v.Validate(); err != nil { 5307 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Or", i), err.(request.ErrInvalidParams)) 5308 } 5309 } 5310 } 5311 5312 if invalidParams.Len() > 0 { 5313 return invalidParams 5314 } 5315 return nil 5316} 5317 5318// SetAnd sets the And field's value. 5319func (s *Expression) SetAnd(v []*Expression) *Expression { 5320 s.And = v 5321 return s 5322} 5323 5324// SetCostCategories sets the CostCategories field's value. 5325func (s *Expression) SetCostCategories(v *CostCategoryValues) *Expression { 5326 s.CostCategories = v 5327 return s 5328} 5329 5330// SetDimensions sets the Dimensions field's value. 5331func (s *Expression) SetDimensions(v *DimensionValues) *Expression { 5332 s.Dimensions = v 5333 return s 5334} 5335 5336// SetNot sets the Not field's value. 5337func (s *Expression) SetNot(v *Expression) *Expression { 5338 s.Not = v 5339 return s 5340} 5341 5342// SetOr sets the Or field's value. 5343func (s *Expression) SetOr(v []*Expression) *Expression { 5344 s.Or = v 5345 return s 5346} 5347 5348// SetTags sets the Tags field's value. 5349func (s *Expression) SetTags(v *TagValues) *Expression { 5350 s.Tags = v 5351 return s 5352} 5353 5354// The forecast created for your query. 5355type ForecastResult struct { 5356 _ struct{} `type:"structure"` 5357 5358 // The mean value of the forecast. 5359 MeanValue *string `type:"string"` 5360 5361 // The lower limit for the prediction interval. 5362 PredictionIntervalLowerBound *string `type:"string"` 5363 5364 // The upper limit for the prediction interval. 5365 PredictionIntervalUpperBound *string `type:"string"` 5366 5367 // The period of time that the forecast covers. 5368 TimePeriod *DateInterval `type:"structure"` 5369} 5370 5371// String returns the string representation 5372func (s ForecastResult) String() string { 5373 return awsutil.Prettify(s) 5374} 5375 5376// GoString returns the string representation 5377func (s ForecastResult) GoString() string { 5378 return s.String() 5379} 5380 5381// SetMeanValue sets the MeanValue field's value. 5382func (s *ForecastResult) SetMeanValue(v string) *ForecastResult { 5383 s.MeanValue = &v 5384 return s 5385} 5386 5387// SetPredictionIntervalLowerBound sets the PredictionIntervalLowerBound field's value. 5388func (s *ForecastResult) SetPredictionIntervalLowerBound(v string) *ForecastResult { 5389 s.PredictionIntervalLowerBound = &v 5390 return s 5391} 5392 5393// SetPredictionIntervalUpperBound sets the PredictionIntervalUpperBound field's value. 5394func (s *ForecastResult) SetPredictionIntervalUpperBound(v string) *ForecastResult { 5395 s.PredictionIntervalUpperBound = &v 5396 return s 5397} 5398 5399// SetTimePeriod sets the TimePeriod field's value. 5400func (s *ForecastResult) SetTimePeriod(v *DateInterval) *ForecastResult { 5401 s.TimePeriod = v 5402 return s 5403} 5404 5405type GetAnomaliesInput struct { 5406 _ struct{} `type:"structure"` 5407 5408 // Assigns the start and end dates for retrieving cost anomalies. The returned 5409 // anomaly object will have an AnomalyEndDate in the specified time range. 5410 // 5411 // DateInterval is a required field 5412 DateInterval *AnomalyDateInterval `type:"structure" required:"true"` 5413 5414 // Filters anomaly results by the feedback field on the anomaly object. 5415 Feedback *string `type:"string" enum:"AnomalyFeedbackType"` 5416 5417 // The number of entries a paginated response contains. 5418 MaxResults *int64 `type:"integer"` 5419 5420 // Retrieves all of the cost anomalies detected for a specific cost anomaly 5421 // monitor Amazon Resource Name (ARN). 5422 MonitorArn *string `type:"string"` 5423 5424 // The token to retrieve the next set of results. AWS provides the token when 5425 // the response from a previous call has more results than the maximum page 5426 // size. 5427 NextPageToken *string `type:"string"` 5428 5429 // Filters anomaly results by the total impact field on the anomaly object. 5430 // For example, you can filter anomalies GREATER_THAN 200.00 to retrieve anomalies, 5431 // with an estimated dollar impact greater than 200. 5432 TotalImpact *TotalImpactFilter `type:"structure"` 5433} 5434 5435// String returns the string representation 5436func (s GetAnomaliesInput) String() string { 5437 return awsutil.Prettify(s) 5438} 5439 5440// GoString returns the string representation 5441func (s GetAnomaliesInput) GoString() string { 5442 return s.String() 5443} 5444 5445// Validate inspects the fields of the type to determine if they are valid. 5446func (s *GetAnomaliesInput) Validate() error { 5447 invalidParams := request.ErrInvalidParams{Context: "GetAnomaliesInput"} 5448 if s.DateInterval == nil { 5449 invalidParams.Add(request.NewErrParamRequired("DateInterval")) 5450 } 5451 if s.DateInterval != nil { 5452 if err := s.DateInterval.Validate(); err != nil { 5453 invalidParams.AddNested("DateInterval", err.(request.ErrInvalidParams)) 5454 } 5455 } 5456 if s.TotalImpact != nil { 5457 if err := s.TotalImpact.Validate(); err != nil { 5458 invalidParams.AddNested("TotalImpact", err.(request.ErrInvalidParams)) 5459 } 5460 } 5461 5462 if invalidParams.Len() > 0 { 5463 return invalidParams 5464 } 5465 return nil 5466} 5467 5468// SetDateInterval sets the DateInterval field's value. 5469func (s *GetAnomaliesInput) SetDateInterval(v *AnomalyDateInterval) *GetAnomaliesInput { 5470 s.DateInterval = v 5471 return s 5472} 5473 5474// SetFeedback sets the Feedback field's value. 5475func (s *GetAnomaliesInput) SetFeedback(v string) *GetAnomaliesInput { 5476 s.Feedback = &v 5477 return s 5478} 5479 5480// SetMaxResults sets the MaxResults field's value. 5481func (s *GetAnomaliesInput) SetMaxResults(v int64) *GetAnomaliesInput { 5482 s.MaxResults = &v 5483 return s 5484} 5485 5486// SetMonitorArn sets the MonitorArn field's value. 5487func (s *GetAnomaliesInput) SetMonitorArn(v string) *GetAnomaliesInput { 5488 s.MonitorArn = &v 5489 return s 5490} 5491 5492// SetNextPageToken sets the NextPageToken field's value. 5493func (s *GetAnomaliesInput) SetNextPageToken(v string) *GetAnomaliesInput { 5494 s.NextPageToken = &v 5495 return s 5496} 5497 5498// SetTotalImpact sets the TotalImpact field's value. 5499func (s *GetAnomaliesInput) SetTotalImpact(v *TotalImpactFilter) *GetAnomaliesInput { 5500 s.TotalImpact = v 5501 return s 5502} 5503 5504type GetAnomaliesOutput struct { 5505 _ struct{} `type:"structure"` 5506 5507 // A list of cost anomalies. 5508 // 5509 // Anomalies is a required field 5510 Anomalies []*Anomaly `type:"list" required:"true"` 5511 5512 // The token to retrieve the next set of results. AWS provides the token when 5513 // the response from a previous call has more results than the maximum page 5514 // size. 5515 NextPageToken *string `type:"string"` 5516} 5517 5518// String returns the string representation 5519func (s GetAnomaliesOutput) String() string { 5520 return awsutil.Prettify(s) 5521} 5522 5523// GoString returns the string representation 5524func (s GetAnomaliesOutput) GoString() string { 5525 return s.String() 5526} 5527 5528// SetAnomalies sets the Anomalies field's value. 5529func (s *GetAnomaliesOutput) SetAnomalies(v []*Anomaly) *GetAnomaliesOutput { 5530 s.Anomalies = v 5531 return s 5532} 5533 5534// SetNextPageToken sets the NextPageToken field's value. 5535func (s *GetAnomaliesOutput) SetNextPageToken(v string) *GetAnomaliesOutput { 5536 s.NextPageToken = &v 5537 return s 5538} 5539 5540type GetAnomalyMonitorsInput struct { 5541 _ struct{} `type:"structure"` 5542 5543 // The number of entries a paginated response contains. 5544 MaxResults *int64 `type:"integer"` 5545 5546 // A list of cost anomaly monitor ARNs. 5547 MonitorArnList []*string `type:"list"` 5548 5549 // The token to retrieve the next set of results. AWS provides the token when 5550 // the response from a previous call has more results than the maximum page 5551 // size. 5552 NextPageToken *string `type:"string"` 5553} 5554 5555// String returns the string representation 5556func (s GetAnomalyMonitorsInput) String() string { 5557 return awsutil.Prettify(s) 5558} 5559 5560// GoString returns the string representation 5561func (s GetAnomalyMonitorsInput) GoString() string { 5562 return s.String() 5563} 5564 5565// SetMaxResults sets the MaxResults field's value. 5566func (s *GetAnomalyMonitorsInput) SetMaxResults(v int64) *GetAnomalyMonitorsInput { 5567 s.MaxResults = &v 5568 return s 5569} 5570 5571// SetMonitorArnList sets the MonitorArnList field's value. 5572func (s *GetAnomalyMonitorsInput) SetMonitorArnList(v []*string) *GetAnomalyMonitorsInput { 5573 s.MonitorArnList = v 5574 return s 5575} 5576 5577// SetNextPageToken sets the NextPageToken field's value. 5578func (s *GetAnomalyMonitorsInput) SetNextPageToken(v string) *GetAnomalyMonitorsInput { 5579 s.NextPageToken = &v 5580 return s 5581} 5582 5583type GetAnomalyMonitorsOutput struct { 5584 _ struct{} `type:"structure"` 5585 5586 // A list of cost anomaly monitors that includes the detailed metadata for each 5587 // monitor. 5588 // 5589 // AnomalyMonitors is a required field 5590 AnomalyMonitors []*AnomalyMonitor `type:"list" required:"true"` 5591 5592 // The token to retrieve the next set of results. AWS provides the token when 5593 // the response from a previous call has more results than the maximum page 5594 // size. 5595 NextPageToken *string `type:"string"` 5596} 5597 5598// String returns the string representation 5599func (s GetAnomalyMonitorsOutput) String() string { 5600 return awsutil.Prettify(s) 5601} 5602 5603// GoString returns the string representation 5604func (s GetAnomalyMonitorsOutput) GoString() string { 5605 return s.String() 5606} 5607 5608// SetAnomalyMonitors sets the AnomalyMonitors field's value. 5609func (s *GetAnomalyMonitorsOutput) SetAnomalyMonitors(v []*AnomalyMonitor) *GetAnomalyMonitorsOutput { 5610 s.AnomalyMonitors = v 5611 return s 5612} 5613 5614// SetNextPageToken sets the NextPageToken field's value. 5615func (s *GetAnomalyMonitorsOutput) SetNextPageToken(v string) *GetAnomalyMonitorsOutput { 5616 s.NextPageToken = &v 5617 return s 5618} 5619 5620type GetAnomalySubscriptionsInput struct { 5621 _ struct{} `type:"structure"` 5622 5623 // The number of entries a paginated response contains. 5624 MaxResults *int64 `type:"integer"` 5625 5626 // Cost anomaly monitor ARNs. 5627 MonitorArn *string `type:"string"` 5628 5629 // The token to retrieve the next set of results. AWS provides the token when 5630 // the response from a previous call has more results than the maximum page 5631 // size. 5632 NextPageToken *string `type:"string"` 5633 5634 // A list of cost anomaly subscription ARNs. 5635 SubscriptionArnList []*string `type:"list"` 5636} 5637 5638// String returns the string representation 5639func (s GetAnomalySubscriptionsInput) String() string { 5640 return awsutil.Prettify(s) 5641} 5642 5643// GoString returns the string representation 5644func (s GetAnomalySubscriptionsInput) GoString() string { 5645 return s.String() 5646} 5647 5648// SetMaxResults sets the MaxResults field's value. 5649func (s *GetAnomalySubscriptionsInput) SetMaxResults(v int64) *GetAnomalySubscriptionsInput { 5650 s.MaxResults = &v 5651 return s 5652} 5653 5654// SetMonitorArn sets the MonitorArn field's value. 5655func (s *GetAnomalySubscriptionsInput) SetMonitorArn(v string) *GetAnomalySubscriptionsInput { 5656 s.MonitorArn = &v 5657 return s 5658} 5659 5660// SetNextPageToken sets the NextPageToken field's value. 5661func (s *GetAnomalySubscriptionsInput) SetNextPageToken(v string) *GetAnomalySubscriptionsInput { 5662 s.NextPageToken = &v 5663 return s 5664} 5665 5666// SetSubscriptionArnList sets the SubscriptionArnList field's value. 5667func (s *GetAnomalySubscriptionsInput) SetSubscriptionArnList(v []*string) *GetAnomalySubscriptionsInput { 5668 s.SubscriptionArnList = v 5669 return s 5670} 5671 5672type GetAnomalySubscriptionsOutput struct { 5673 _ struct{} `type:"structure"` 5674 5675 // A list of cost anomaly subscriptions that includes the detailed metadata 5676 // for each one. 5677 // 5678 // AnomalySubscriptions is a required field 5679 AnomalySubscriptions []*AnomalySubscription `type:"list" required:"true"` 5680 5681 // The token to retrieve the next set of results. AWS provides the token when 5682 // the response from a previous call has more results than the maximum page 5683 // size. 5684 NextPageToken *string `type:"string"` 5685} 5686 5687// String returns the string representation 5688func (s GetAnomalySubscriptionsOutput) String() string { 5689 return awsutil.Prettify(s) 5690} 5691 5692// GoString returns the string representation 5693func (s GetAnomalySubscriptionsOutput) GoString() string { 5694 return s.String() 5695} 5696 5697// SetAnomalySubscriptions sets the AnomalySubscriptions field's value. 5698func (s *GetAnomalySubscriptionsOutput) SetAnomalySubscriptions(v []*AnomalySubscription) *GetAnomalySubscriptionsOutput { 5699 s.AnomalySubscriptions = v 5700 return s 5701} 5702 5703// SetNextPageToken sets the NextPageToken field's value. 5704func (s *GetAnomalySubscriptionsOutput) SetNextPageToken(v string) *GetAnomalySubscriptionsOutput { 5705 s.NextPageToken = &v 5706 return s 5707} 5708 5709type GetCostAndUsageInput struct { 5710 _ struct{} `type:"structure"` 5711 5712 // Filters AWS costs by different dimensions. For example, you can specify SERVICE 5713 // and LINKED_ACCOUNT and get the costs that are associated with that account's 5714 // usage of that service. You can nest Expression objects to define any combination 5715 // of dimension filters. For more information, see Expression (https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_Expression.html). 5716 Filter *Expression `type:"structure"` 5717 5718 // Sets the AWS cost granularity to MONTHLY or DAILY, or HOURLY. If Granularity 5719 // isn't set, the response object doesn't include the Granularity, either MONTHLY 5720 // or DAILY, or HOURLY. 5721 Granularity *string `type:"string" enum:"Granularity"` 5722 5723 // You can group AWS costs using up to two different groups, either dimensions, 5724 // tag keys, cost categories, or any two group by types. 5725 // 5726 // When you group by tag key, you get all tag values, including empty strings. 5727 // 5728 // Valid values are AZ, INSTANCE_TYPE, LEGAL_ENTITY_NAME, LINKED_ACCOUNT, OPERATION, 5729 // PLATFORM, PURCHASE_TYPE, SERVICE, TAGS, TENANCY, RECORD_TYPE, and USAGE_TYPE. 5730 GroupBy []*GroupDefinition `type:"list"` 5731 5732 // Which metrics are returned in the query. For more information about blended 5733 // and unblended rates, see Why does the "blended" annotation appear on some 5734 // line items in my bill? (http://aws.amazon.com/premiumsupport/knowledge-center/blended-rates-intro/). 5735 // 5736 // Valid values are AmortizedCost, BlendedCost, NetAmortizedCost, NetUnblendedCost, 5737 // NormalizedUsageAmount, UnblendedCost, and UsageQuantity. 5738 // 5739 // If you return the UsageQuantity metric, the service aggregates all usage 5740 // numbers without taking into account the units. For example, if you aggregate 5741 // usageQuantity across all of Amazon EC2, the results aren't meaningful because 5742 // Amazon EC2 compute hours and data transfer are measured in different units 5743 // (for example, hours vs. GB). To get more meaningful UsageQuantity metrics, 5744 // filter by UsageType or UsageTypeGroups. 5745 // 5746 // Metrics is required for GetCostAndUsage requests. 5747 // 5748 // Metrics is a required field 5749 Metrics []*string `type:"list" required:"true"` 5750 5751 // The token to retrieve the next set of results. AWS provides the token when 5752 // the response from a previous call has more results than the maximum page 5753 // size. 5754 NextPageToken *string `type:"string"` 5755 5756 // Sets the start and end dates for retrieving AWS costs. The start date is 5757 // inclusive, but the end date is exclusive. For example, if start is 2017-01-01 5758 // and end is 2017-05-01, then the cost and usage data is retrieved from 2017-01-01 5759 // up to and including 2017-04-30 but not including 2017-05-01. 5760 // 5761 // TimePeriod is a required field 5762 TimePeriod *DateInterval `type:"structure" required:"true"` 5763} 5764 5765// String returns the string representation 5766func (s GetCostAndUsageInput) String() string { 5767 return awsutil.Prettify(s) 5768} 5769 5770// GoString returns the string representation 5771func (s GetCostAndUsageInput) GoString() string { 5772 return s.String() 5773} 5774 5775// Validate inspects the fields of the type to determine if they are valid. 5776func (s *GetCostAndUsageInput) Validate() error { 5777 invalidParams := request.ErrInvalidParams{Context: "GetCostAndUsageInput"} 5778 if s.Metrics == nil { 5779 invalidParams.Add(request.NewErrParamRequired("Metrics")) 5780 } 5781 if s.TimePeriod == nil { 5782 invalidParams.Add(request.NewErrParamRequired("TimePeriod")) 5783 } 5784 if s.Filter != nil { 5785 if err := s.Filter.Validate(); err != nil { 5786 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 5787 } 5788 } 5789 if s.TimePeriod != nil { 5790 if err := s.TimePeriod.Validate(); err != nil { 5791 invalidParams.AddNested("TimePeriod", err.(request.ErrInvalidParams)) 5792 } 5793 } 5794 5795 if invalidParams.Len() > 0 { 5796 return invalidParams 5797 } 5798 return nil 5799} 5800 5801// SetFilter sets the Filter field's value. 5802func (s *GetCostAndUsageInput) SetFilter(v *Expression) *GetCostAndUsageInput { 5803 s.Filter = v 5804 return s 5805} 5806 5807// SetGranularity sets the Granularity field's value. 5808func (s *GetCostAndUsageInput) SetGranularity(v string) *GetCostAndUsageInput { 5809 s.Granularity = &v 5810 return s 5811} 5812 5813// SetGroupBy sets the GroupBy field's value. 5814func (s *GetCostAndUsageInput) SetGroupBy(v []*GroupDefinition) *GetCostAndUsageInput { 5815 s.GroupBy = v 5816 return s 5817} 5818 5819// SetMetrics sets the Metrics field's value. 5820func (s *GetCostAndUsageInput) SetMetrics(v []*string) *GetCostAndUsageInput { 5821 s.Metrics = v 5822 return s 5823} 5824 5825// SetNextPageToken sets the NextPageToken field's value. 5826func (s *GetCostAndUsageInput) SetNextPageToken(v string) *GetCostAndUsageInput { 5827 s.NextPageToken = &v 5828 return s 5829} 5830 5831// SetTimePeriod sets the TimePeriod field's value. 5832func (s *GetCostAndUsageInput) SetTimePeriod(v *DateInterval) *GetCostAndUsageInput { 5833 s.TimePeriod = v 5834 return s 5835} 5836 5837type GetCostAndUsageOutput struct { 5838 _ struct{} `type:"structure"` 5839 5840 // The attributes that apply to a specific dimension value. For example, if 5841 // the value is a linked account, the attribute is that account name. 5842 DimensionValueAttributes []*DimensionValuesWithAttributes `type:"list"` 5843 5844 // The groups that are specified by the Filter or GroupBy parameters in the 5845 // request. 5846 GroupDefinitions []*GroupDefinition `type:"list"` 5847 5848 // The token for the next set of retrievable results. AWS provides the token 5849 // when the response from a previous call has more results than the maximum 5850 // page size. 5851 NextPageToken *string `type:"string"` 5852 5853 // The time period that is covered by the results in the response. 5854 ResultsByTime []*ResultByTime `type:"list"` 5855} 5856 5857// String returns the string representation 5858func (s GetCostAndUsageOutput) String() string { 5859 return awsutil.Prettify(s) 5860} 5861 5862// GoString returns the string representation 5863func (s GetCostAndUsageOutput) GoString() string { 5864 return s.String() 5865} 5866 5867// SetDimensionValueAttributes sets the DimensionValueAttributes field's value. 5868func (s *GetCostAndUsageOutput) SetDimensionValueAttributes(v []*DimensionValuesWithAttributes) *GetCostAndUsageOutput { 5869 s.DimensionValueAttributes = v 5870 return s 5871} 5872 5873// SetGroupDefinitions sets the GroupDefinitions field's value. 5874func (s *GetCostAndUsageOutput) SetGroupDefinitions(v []*GroupDefinition) *GetCostAndUsageOutput { 5875 s.GroupDefinitions = v 5876 return s 5877} 5878 5879// SetNextPageToken sets the NextPageToken field's value. 5880func (s *GetCostAndUsageOutput) SetNextPageToken(v string) *GetCostAndUsageOutput { 5881 s.NextPageToken = &v 5882 return s 5883} 5884 5885// SetResultsByTime sets the ResultsByTime field's value. 5886func (s *GetCostAndUsageOutput) SetResultsByTime(v []*ResultByTime) *GetCostAndUsageOutput { 5887 s.ResultsByTime = v 5888 return s 5889} 5890 5891type GetCostAndUsageWithResourcesInput struct { 5892 _ struct{} `type:"structure"` 5893 5894 // Filters Amazon Web Services costs by different dimensions. For example, you 5895 // can specify SERVICE and LINKED_ACCOUNT and get the costs that are associated 5896 // with that account's usage of that service. You can nest Expression objects 5897 // to define any combination of dimension filters. For more information, see 5898 // Expression (https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_Expression.html). 5899 // 5900 // The GetCostAndUsageWithResources operation requires that you either group 5901 // by or filter by a ResourceId. It requires the Expression (https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_Expression.html) 5902 // "SERVICE = Amazon Elastic Compute Cloud - Compute" in the filter. 5903 // 5904 // Filter is a required field 5905 Filter *Expression `type:"structure" required:"true"` 5906 5907 // Sets the AWS cost granularity to MONTHLY, DAILY, or HOURLY. If Granularity 5908 // isn't set, the response object doesn't include the Granularity, MONTHLY, 5909 // DAILY, or HOURLY. 5910 Granularity *string `type:"string" enum:"Granularity"` 5911 5912 // You can group Amazon Web Services costs using up to two different groups: 5913 // DIMENSION, TAG, COST_CATEGORY. 5914 GroupBy []*GroupDefinition `type:"list"` 5915 5916 // Which metrics are returned in the query. For more information about blended 5917 // and unblended rates, see Why does the "blended" annotation appear on some 5918 // line items in my bill? (http://aws.amazon.com/premiumsupport/knowledge-center/blended-rates-intro/). 5919 // 5920 // Valid values are AmortizedCost, BlendedCost, NetAmortizedCost, NetUnblendedCost, 5921 // NormalizedUsageAmount, UnblendedCost, and UsageQuantity. 5922 // 5923 // If you return the UsageQuantity metric, the service aggregates all usage 5924 // numbers without taking the units into account. For example, if you aggregate 5925 // usageQuantity across all of Amazon EC2, the results aren't meaningful because 5926 // Amazon EC2 compute hours and data transfer are measured in different units 5927 // (for example, hours vs. GB). To get more meaningful UsageQuantity metrics, 5928 // filter by UsageType or UsageTypeGroups. 5929 // 5930 // Metrics is required for GetCostAndUsageWithResources requests. 5931 Metrics []*string `type:"list"` 5932 5933 // The token to retrieve the next set of results. AWS provides the token when 5934 // the response from a previous call has more results than the maximum page 5935 // size. 5936 NextPageToken *string `type:"string"` 5937 5938 // Sets the start and end dates for retrieving Amazon Web Services costs. The 5939 // range must be within the last 14 days (the start date cannot be earlier than 5940 // 14 days ago). The start date is inclusive, but the end date is exclusive. 5941 // For example, if start is 2017-01-01 and end is 2017-05-01, then the cost 5942 // and usage data is retrieved from 2017-01-01 up to and including 2017-04-30 5943 // but not including 2017-05-01. 5944 // 5945 // TimePeriod is a required field 5946 TimePeriod *DateInterval `type:"structure" required:"true"` 5947} 5948 5949// String returns the string representation 5950func (s GetCostAndUsageWithResourcesInput) String() string { 5951 return awsutil.Prettify(s) 5952} 5953 5954// GoString returns the string representation 5955func (s GetCostAndUsageWithResourcesInput) GoString() string { 5956 return s.String() 5957} 5958 5959// Validate inspects the fields of the type to determine if they are valid. 5960func (s *GetCostAndUsageWithResourcesInput) Validate() error { 5961 invalidParams := request.ErrInvalidParams{Context: "GetCostAndUsageWithResourcesInput"} 5962 if s.Filter == nil { 5963 invalidParams.Add(request.NewErrParamRequired("Filter")) 5964 } 5965 if s.TimePeriod == nil { 5966 invalidParams.Add(request.NewErrParamRequired("TimePeriod")) 5967 } 5968 if s.Filter != nil { 5969 if err := s.Filter.Validate(); err != nil { 5970 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 5971 } 5972 } 5973 if s.TimePeriod != nil { 5974 if err := s.TimePeriod.Validate(); err != nil { 5975 invalidParams.AddNested("TimePeriod", err.(request.ErrInvalidParams)) 5976 } 5977 } 5978 5979 if invalidParams.Len() > 0 { 5980 return invalidParams 5981 } 5982 return nil 5983} 5984 5985// SetFilter sets the Filter field's value. 5986func (s *GetCostAndUsageWithResourcesInput) SetFilter(v *Expression) *GetCostAndUsageWithResourcesInput { 5987 s.Filter = v 5988 return s 5989} 5990 5991// SetGranularity sets the Granularity field's value. 5992func (s *GetCostAndUsageWithResourcesInput) SetGranularity(v string) *GetCostAndUsageWithResourcesInput { 5993 s.Granularity = &v 5994 return s 5995} 5996 5997// SetGroupBy sets the GroupBy field's value. 5998func (s *GetCostAndUsageWithResourcesInput) SetGroupBy(v []*GroupDefinition) *GetCostAndUsageWithResourcesInput { 5999 s.GroupBy = v 6000 return s 6001} 6002 6003// SetMetrics sets the Metrics field's value. 6004func (s *GetCostAndUsageWithResourcesInput) SetMetrics(v []*string) *GetCostAndUsageWithResourcesInput { 6005 s.Metrics = v 6006 return s 6007} 6008 6009// SetNextPageToken sets the NextPageToken field's value. 6010func (s *GetCostAndUsageWithResourcesInput) SetNextPageToken(v string) *GetCostAndUsageWithResourcesInput { 6011 s.NextPageToken = &v 6012 return s 6013} 6014 6015// SetTimePeriod sets the TimePeriod field's value. 6016func (s *GetCostAndUsageWithResourcesInput) SetTimePeriod(v *DateInterval) *GetCostAndUsageWithResourcesInput { 6017 s.TimePeriod = v 6018 return s 6019} 6020 6021type GetCostAndUsageWithResourcesOutput struct { 6022 _ struct{} `type:"structure"` 6023 6024 // The attributes that apply to a specific dimension value. For example, if 6025 // the value is a linked account, the attribute is that account name. 6026 DimensionValueAttributes []*DimensionValuesWithAttributes `type:"list"` 6027 6028 // The groups that are specified by the Filter or GroupBy parameters in the 6029 // request. 6030 GroupDefinitions []*GroupDefinition `type:"list"` 6031 6032 // The token for the next set of retrievable results. AWS provides the token 6033 // when the response from a previous call has more results than the maximum 6034 // page size. 6035 NextPageToken *string `type:"string"` 6036 6037 // The time period that is covered by the results in the response. 6038 ResultsByTime []*ResultByTime `type:"list"` 6039} 6040 6041// String returns the string representation 6042func (s GetCostAndUsageWithResourcesOutput) String() string { 6043 return awsutil.Prettify(s) 6044} 6045 6046// GoString returns the string representation 6047func (s GetCostAndUsageWithResourcesOutput) GoString() string { 6048 return s.String() 6049} 6050 6051// SetDimensionValueAttributes sets the DimensionValueAttributes field's value. 6052func (s *GetCostAndUsageWithResourcesOutput) SetDimensionValueAttributes(v []*DimensionValuesWithAttributes) *GetCostAndUsageWithResourcesOutput { 6053 s.DimensionValueAttributes = v 6054 return s 6055} 6056 6057// SetGroupDefinitions sets the GroupDefinitions field's value. 6058func (s *GetCostAndUsageWithResourcesOutput) SetGroupDefinitions(v []*GroupDefinition) *GetCostAndUsageWithResourcesOutput { 6059 s.GroupDefinitions = v 6060 return s 6061} 6062 6063// SetNextPageToken sets the NextPageToken field's value. 6064func (s *GetCostAndUsageWithResourcesOutput) SetNextPageToken(v string) *GetCostAndUsageWithResourcesOutput { 6065 s.NextPageToken = &v 6066 return s 6067} 6068 6069// SetResultsByTime sets the ResultsByTime field's value. 6070func (s *GetCostAndUsageWithResourcesOutput) SetResultsByTime(v []*ResultByTime) *GetCostAndUsageWithResourcesOutput { 6071 s.ResultsByTime = v 6072 return s 6073} 6074 6075type GetCostCategoriesInput struct { 6076 _ struct{} `type:"structure"` 6077 6078 // The unique name of the Cost Category. 6079 CostCategoryName *string `min:"1" type:"string"` 6080 6081 // Use Expression to filter by cost or by usage. There are two patterns: 6082 // 6083 // * Simple dimension values - You can set the dimension name and values 6084 // for the filters that you plan to use. For example, you can filter for 6085 // REGION==us-east-1 OR REGION==us-west-1. For GetRightsizingRecommendation, 6086 // the Region is a full name (for example, REGION==US East (N. Virginia). 6087 // The Expression example looks like: { "Dimensions": { "Key": "REGION", 6088 // "Values": [ "us-east-1", “us-west-1” ] } } The list of dimension values 6089 // are OR'd together to retrieve cost or usage data. You can create Expression 6090 // and DimensionValues objects using either with* methods or set* methods 6091 // in multiple lines. 6092 // 6093 // * Compound dimension values with logical operations - You can use multiple 6094 // Expression types and the logical operators AND/OR/NOT to create a list 6095 // of one or more Expression objects. This allows you to filter on more advanced 6096 // options. For example, you can filter on ((REGION == us-east-1 OR REGION 6097 // == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer). 6098 // The Expression for that looks like this: { "And": [ {"Or": [ {"Dimensions": 6099 // { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": 6100 // { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": 6101 // { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] } Because each 6102 // Expression can have only one operator, the service returns an error if 6103 // more than one is specified. The following example shows an Expression 6104 // object that creates an error. { "And": [ ... ], "DimensionValues": { "Dimension": 6105 // "USAGE_TYPE", "Values": [ "DataTransfer" ] } } 6106 // 6107 // For the GetRightsizingRecommendation action, a combination of OR and NOT 6108 // is not supported. OR is not supported between different dimensions, or dimensions 6109 // and tags. NOT operators aren't supported. Dimensions are also limited to 6110 // LINKED_ACCOUNT, REGION, or RIGHTSIZING_TYPE. 6111 // 6112 // For the GetReservationPurchaseRecommendation action, only NOT is supported. 6113 // AND and OR are not supported. Dimensions are limited to LINKED_ACCOUNT. 6114 Filter *Expression `type:"structure"` 6115 6116 // This field is only used when SortBy is provided in the request. 6117 // 6118 // The maximum number of objects that to be returned for this request. If MaxResults 6119 // is not specified with SortBy, the request will return 1000 results as the 6120 // default value for this parameter. 6121 MaxResults *int64 `min:"1" type:"integer"` 6122 6123 // If the number of objects that are still available for retrieval exceeds the 6124 // limit, AWS returns a NextPageToken value in the response. To retrieve the 6125 // next batch of objects, provide the NextPageToken from the prior call in your 6126 // next request. 6127 NextPageToken *string `type:"string"` 6128 6129 // The value that you want to search the filter values for. 6130 // 6131 // If you do not specify a CostCategoryName, SearchString will be used to filter 6132 // Cost Category names that match the SearchString pattern. If you do specifiy 6133 // a CostCategoryName, SearchString will be used to filter Cost Category values 6134 // that match the SearchString pattern. 6135 SearchString *string `type:"string"` 6136 6137 // The value by which you want to sort the data. 6138 // 6139 // The key represents cost and usage metrics. The following values are supported: 6140 // 6141 // * BlendedCost 6142 // 6143 // * UnblendedCost 6144 // 6145 // * AmortizedCost 6146 // 6147 // * NetAmortizedCost 6148 // 6149 // * NetUnblendedCost 6150 // 6151 // * UsageQuantity 6152 // 6153 // * NormalizedUsageAmount 6154 // 6155 // Supported values for SortOrder are ASCENDING or DESCENDING. 6156 // 6157 // When using SortBy, NextPageToken and SearchString are not supported. 6158 SortBy []*SortDefinition `type:"list"` 6159 6160 // The time period of the request. 6161 // 6162 // TimePeriod is a required field 6163 TimePeriod *DateInterval `type:"structure" required:"true"` 6164} 6165 6166// String returns the string representation 6167func (s GetCostCategoriesInput) String() string { 6168 return awsutil.Prettify(s) 6169} 6170 6171// GoString returns the string representation 6172func (s GetCostCategoriesInput) GoString() string { 6173 return s.String() 6174} 6175 6176// Validate inspects the fields of the type to determine if they are valid. 6177func (s *GetCostCategoriesInput) Validate() error { 6178 invalidParams := request.ErrInvalidParams{Context: "GetCostCategoriesInput"} 6179 if s.CostCategoryName != nil && len(*s.CostCategoryName) < 1 { 6180 invalidParams.Add(request.NewErrParamMinLen("CostCategoryName", 1)) 6181 } 6182 if s.MaxResults != nil && *s.MaxResults < 1 { 6183 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 6184 } 6185 if s.TimePeriod == nil { 6186 invalidParams.Add(request.NewErrParamRequired("TimePeriod")) 6187 } 6188 if s.Filter != nil { 6189 if err := s.Filter.Validate(); err != nil { 6190 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 6191 } 6192 } 6193 if s.SortBy != nil { 6194 for i, v := range s.SortBy { 6195 if v == nil { 6196 continue 6197 } 6198 if err := v.Validate(); err != nil { 6199 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "SortBy", i), err.(request.ErrInvalidParams)) 6200 } 6201 } 6202 } 6203 if s.TimePeriod != nil { 6204 if err := s.TimePeriod.Validate(); err != nil { 6205 invalidParams.AddNested("TimePeriod", err.(request.ErrInvalidParams)) 6206 } 6207 } 6208 6209 if invalidParams.Len() > 0 { 6210 return invalidParams 6211 } 6212 return nil 6213} 6214 6215// SetCostCategoryName sets the CostCategoryName field's value. 6216func (s *GetCostCategoriesInput) SetCostCategoryName(v string) *GetCostCategoriesInput { 6217 s.CostCategoryName = &v 6218 return s 6219} 6220 6221// SetFilter sets the Filter field's value. 6222func (s *GetCostCategoriesInput) SetFilter(v *Expression) *GetCostCategoriesInput { 6223 s.Filter = v 6224 return s 6225} 6226 6227// SetMaxResults sets the MaxResults field's value. 6228func (s *GetCostCategoriesInput) SetMaxResults(v int64) *GetCostCategoriesInput { 6229 s.MaxResults = &v 6230 return s 6231} 6232 6233// SetNextPageToken sets the NextPageToken field's value. 6234func (s *GetCostCategoriesInput) SetNextPageToken(v string) *GetCostCategoriesInput { 6235 s.NextPageToken = &v 6236 return s 6237} 6238 6239// SetSearchString sets the SearchString field's value. 6240func (s *GetCostCategoriesInput) SetSearchString(v string) *GetCostCategoriesInput { 6241 s.SearchString = &v 6242 return s 6243} 6244 6245// SetSortBy sets the SortBy field's value. 6246func (s *GetCostCategoriesInput) SetSortBy(v []*SortDefinition) *GetCostCategoriesInput { 6247 s.SortBy = v 6248 return s 6249} 6250 6251// SetTimePeriod sets the TimePeriod field's value. 6252func (s *GetCostCategoriesInput) SetTimePeriod(v *DateInterval) *GetCostCategoriesInput { 6253 s.TimePeriod = v 6254 return s 6255} 6256 6257type GetCostCategoriesOutput struct { 6258 _ struct{} `type:"structure"` 6259 6260 // The names of the Cost Categories. 6261 CostCategoryNames []*string `type:"list"` 6262 6263 // The Cost Category values. 6264 // 6265 // CostCategoryValues are not returned if CostCategoryName is not specified 6266 // in the request. 6267 CostCategoryValues []*string `type:"list"` 6268 6269 // If the number of objects that are still available for retrieval exceeds the 6270 // limit, AWS returns a NextPageToken value in the response. To retrieve the 6271 // next batch of objects, provide the marker from the prior call in your next 6272 // request. 6273 NextPageToken *string `type:"string"` 6274 6275 // The number of objects returned. 6276 // 6277 // ReturnSize is a required field 6278 ReturnSize *int64 `type:"integer" required:"true"` 6279 6280 // The total number of objects. 6281 // 6282 // TotalSize is a required field 6283 TotalSize *int64 `type:"integer" required:"true"` 6284} 6285 6286// String returns the string representation 6287func (s GetCostCategoriesOutput) String() string { 6288 return awsutil.Prettify(s) 6289} 6290 6291// GoString returns the string representation 6292func (s GetCostCategoriesOutput) GoString() string { 6293 return s.String() 6294} 6295 6296// SetCostCategoryNames sets the CostCategoryNames field's value. 6297func (s *GetCostCategoriesOutput) SetCostCategoryNames(v []*string) *GetCostCategoriesOutput { 6298 s.CostCategoryNames = v 6299 return s 6300} 6301 6302// SetCostCategoryValues sets the CostCategoryValues field's value. 6303func (s *GetCostCategoriesOutput) SetCostCategoryValues(v []*string) *GetCostCategoriesOutput { 6304 s.CostCategoryValues = v 6305 return s 6306} 6307 6308// SetNextPageToken sets the NextPageToken field's value. 6309func (s *GetCostCategoriesOutput) SetNextPageToken(v string) *GetCostCategoriesOutput { 6310 s.NextPageToken = &v 6311 return s 6312} 6313 6314// SetReturnSize sets the ReturnSize field's value. 6315func (s *GetCostCategoriesOutput) SetReturnSize(v int64) *GetCostCategoriesOutput { 6316 s.ReturnSize = &v 6317 return s 6318} 6319 6320// SetTotalSize sets the TotalSize field's value. 6321func (s *GetCostCategoriesOutput) SetTotalSize(v int64) *GetCostCategoriesOutput { 6322 s.TotalSize = &v 6323 return s 6324} 6325 6326type GetCostForecastInput struct { 6327 _ struct{} `type:"structure"` 6328 6329 // The filters that you want to use to filter your forecast. Cost Explorer API 6330 // supports all of the Cost Explorer filters. 6331 Filter *Expression `type:"structure"` 6332 6333 // How granular you want the forecast to be. You can get 3 months of DAILY forecasts 6334 // or 12 months of MONTHLY forecasts. 6335 // 6336 // The GetCostForecast operation supports only DAILY and MONTHLY granularities. 6337 // 6338 // Granularity is a required field 6339 Granularity *string `type:"string" required:"true" enum:"Granularity"` 6340 6341 // Which metric Cost Explorer uses to create your forecast. For more information 6342 // about blended and unblended rates, see Why does the "blended" annotation 6343 // appear on some line items in my bill? (http://aws.amazon.com/premiumsupport/knowledge-center/blended-rates-intro/). 6344 // 6345 // Valid values for a GetCostForecast call are the following: 6346 // 6347 // * AMORTIZED_COST 6348 // 6349 // * BLENDED_COST 6350 // 6351 // * NET_AMORTIZED_COST 6352 // 6353 // * NET_UNBLENDED_COST 6354 // 6355 // * UNBLENDED_COST 6356 // 6357 // Metric is a required field 6358 Metric *string `type:"string" required:"true" enum:"Metric"` 6359 6360 // Cost Explorer always returns the mean forecast as a single point. You can 6361 // request a prediction interval around the mean by specifying a confidence 6362 // level. The higher the confidence level, the more confident Cost Explorer 6363 // is about the actual value falling in the prediction interval. Higher confidence 6364 // levels result in wider prediction intervals. 6365 PredictionIntervalLevel *int64 `min:"51" type:"integer"` 6366 6367 // The period of time that you want the forecast to cover. The start date must 6368 // be equal to or no later than the current date to avoid a validation error. 6369 // 6370 // TimePeriod is a required field 6371 TimePeriod *DateInterval `type:"structure" required:"true"` 6372} 6373 6374// String returns the string representation 6375func (s GetCostForecastInput) String() string { 6376 return awsutil.Prettify(s) 6377} 6378 6379// GoString returns the string representation 6380func (s GetCostForecastInput) GoString() string { 6381 return s.String() 6382} 6383 6384// Validate inspects the fields of the type to determine if they are valid. 6385func (s *GetCostForecastInput) Validate() error { 6386 invalidParams := request.ErrInvalidParams{Context: "GetCostForecastInput"} 6387 if s.Granularity == nil { 6388 invalidParams.Add(request.NewErrParamRequired("Granularity")) 6389 } 6390 if s.Metric == nil { 6391 invalidParams.Add(request.NewErrParamRequired("Metric")) 6392 } 6393 if s.PredictionIntervalLevel != nil && *s.PredictionIntervalLevel < 51 { 6394 invalidParams.Add(request.NewErrParamMinValue("PredictionIntervalLevel", 51)) 6395 } 6396 if s.TimePeriod == nil { 6397 invalidParams.Add(request.NewErrParamRequired("TimePeriod")) 6398 } 6399 if s.Filter != nil { 6400 if err := s.Filter.Validate(); err != nil { 6401 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 6402 } 6403 } 6404 if s.TimePeriod != nil { 6405 if err := s.TimePeriod.Validate(); err != nil { 6406 invalidParams.AddNested("TimePeriod", err.(request.ErrInvalidParams)) 6407 } 6408 } 6409 6410 if invalidParams.Len() > 0 { 6411 return invalidParams 6412 } 6413 return nil 6414} 6415 6416// SetFilter sets the Filter field's value. 6417func (s *GetCostForecastInput) SetFilter(v *Expression) *GetCostForecastInput { 6418 s.Filter = v 6419 return s 6420} 6421 6422// SetGranularity sets the Granularity field's value. 6423func (s *GetCostForecastInput) SetGranularity(v string) *GetCostForecastInput { 6424 s.Granularity = &v 6425 return s 6426} 6427 6428// SetMetric sets the Metric field's value. 6429func (s *GetCostForecastInput) SetMetric(v string) *GetCostForecastInput { 6430 s.Metric = &v 6431 return s 6432} 6433 6434// SetPredictionIntervalLevel sets the PredictionIntervalLevel field's value. 6435func (s *GetCostForecastInput) SetPredictionIntervalLevel(v int64) *GetCostForecastInput { 6436 s.PredictionIntervalLevel = &v 6437 return s 6438} 6439 6440// SetTimePeriod sets the TimePeriod field's value. 6441func (s *GetCostForecastInput) SetTimePeriod(v *DateInterval) *GetCostForecastInput { 6442 s.TimePeriod = v 6443 return s 6444} 6445 6446type GetCostForecastOutput struct { 6447 _ struct{} `type:"structure"` 6448 6449 // The forecasts for your query, in order. For DAILY forecasts, this is a list 6450 // of days. For MONTHLY forecasts, this is a list of months. 6451 ForecastResultsByTime []*ForecastResult `type:"list"` 6452 6453 // How much you are forecasted to spend over the forecast period, in USD. 6454 Total *MetricValue `type:"structure"` 6455} 6456 6457// String returns the string representation 6458func (s GetCostForecastOutput) String() string { 6459 return awsutil.Prettify(s) 6460} 6461 6462// GoString returns the string representation 6463func (s GetCostForecastOutput) GoString() string { 6464 return s.String() 6465} 6466 6467// SetForecastResultsByTime sets the ForecastResultsByTime field's value. 6468func (s *GetCostForecastOutput) SetForecastResultsByTime(v []*ForecastResult) *GetCostForecastOutput { 6469 s.ForecastResultsByTime = v 6470 return s 6471} 6472 6473// SetTotal sets the Total field's value. 6474func (s *GetCostForecastOutput) SetTotal(v *MetricValue) *GetCostForecastOutput { 6475 s.Total = v 6476 return s 6477} 6478 6479type GetDimensionValuesInput struct { 6480 _ struct{} `type:"structure"` 6481 6482 // The context for the call to GetDimensionValues. This can be RESERVATIONS 6483 // or COST_AND_USAGE. The default value is COST_AND_USAGE. If the context is 6484 // set to RESERVATIONS, the resulting dimension values can be used in the GetReservationUtilization 6485 // operation. If the context is set to COST_AND_USAGE, the resulting dimension 6486 // values can be used in the GetCostAndUsage operation. 6487 // 6488 // If you set the context to COST_AND_USAGE, you can use the following dimensions 6489 // for searching: 6490 // 6491 // * AZ - The Availability Zone. An example is us-east-1a. 6492 // 6493 // * DATABASE_ENGINE - The Amazon Relational Database Service database. Examples 6494 // are Aurora or MySQL. 6495 // 6496 // * INSTANCE_TYPE - The type of Amazon EC2 instance. An example is m4.xlarge. 6497 // 6498 // * LEGAL_ENTITY_NAME - The name of the organization that sells you AWS 6499 // services, such as Amazon Web Services. 6500 // 6501 // * LINKED_ACCOUNT - The description in the attribute map that includes 6502 // the full name of the member account. The value field contains the AWS 6503 // ID of the member account. 6504 // 6505 // * OPERATING_SYSTEM - The operating system. Examples are Windows or Linux. 6506 // 6507 // * OPERATION - The action performed. Examples include RunInstance and CreateBucket. 6508 // 6509 // * PLATFORM - The Amazon EC2 operating system. Examples are Windows or 6510 // Linux. 6511 // 6512 // * PURCHASE_TYPE - The reservation type of the purchase to which this usage 6513 // is related. Examples include On-Demand Instances and Standard Reserved 6514 // Instances. 6515 // 6516 // * SERVICE - The AWS service such as Amazon DynamoDB. 6517 // 6518 // * USAGE_TYPE - The type of usage. An example is DataTransfer-In-Bytes. 6519 // The response for the GetDimensionValues operation includes a unit attribute. 6520 // Examples include GB and Hrs. 6521 // 6522 // * USAGE_TYPE_GROUP - The grouping of common usage types. An example is 6523 // Amazon EC2: CloudWatch – Alarms. The response for this operation includes 6524 // a unit attribute. 6525 // 6526 // * REGION - The AWS Region. 6527 // 6528 // * RECORD_TYPE - The different types of charges such as RI fees, usage 6529 // costs, tax refunds, and credits. 6530 // 6531 // * RESOURCE_ID - The unique identifier of the resource. ResourceId is an 6532 // opt-in feature only available for last 14 days for EC2-Compute Service. 6533 // 6534 // If you set the context to RESERVATIONS, you can use the following dimensions 6535 // for searching: 6536 // 6537 // * AZ - The Availability Zone. An example is us-east-1a. 6538 // 6539 // * CACHE_ENGINE - The Amazon ElastiCache operating system. Examples are 6540 // Windows or Linux. 6541 // 6542 // * DEPLOYMENT_OPTION - The scope of Amazon Relational Database Service 6543 // deployments. Valid values are SingleAZ and MultiAZ. 6544 // 6545 // * INSTANCE_TYPE - The type of Amazon EC2 instance. An example is m4.xlarge. 6546 // 6547 // * LINKED_ACCOUNT - The description in the attribute map that includes 6548 // the full name of the member account. The value field contains the AWS 6549 // ID of the member account. 6550 // 6551 // * PLATFORM - The Amazon EC2 operating system. Examples are Windows or 6552 // Linux. 6553 // 6554 // * REGION - The AWS Region. 6555 // 6556 // * SCOPE (Utilization only) - The scope of a Reserved Instance (RI). Values 6557 // are regional or a single Availability Zone. 6558 // 6559 // * TAG (Coverage only) - The tags that are associated with a Reserved Instance 6560 // (RI). 6561 // 6562 // * TENANCY - The tenancy of a resource. Examples are shared or dedicated. 6563 // 6564 // If you set the context to SAVINGS_PLANS, you can use the following dimensions 6565 // for searching: 6566 // 6567 // * SAVINGS_PLANS_TYPE - Type of Savings Plans (EC2 Instance or Compute) 6568 // 6569 // * PAYMENT_OPTION - Payment option for the given Savings Plans (for example, 6570 // All Upfront) 6571 // 6572 // * REGION - The AWS Region. 6573 // 6574 // * INSTANCE_TYPE_FAMILY - The family of instances (For example, m5) 6575 // 6576 // * LINKED_ACCOUNT - The description in the attribute map that includes 6577 // the full name of the member account. The value field contains the AWS 6578 // ID of the member account. 6579 // 6580 // * SAVINGS_PLAN_ARN - The unique identifier for your Savings Plan 6581 Context *string `type:"string" enum:"Context"` 6582 6583 // The name of the dimension. Each Dimension is available for a different Context. 6584 // For more information, see Context. 6585 // 6586 // Dimension is a required field 6587 Dimension *string `type:"string" required:"true" enum:"Dimension"` 6588 6589 // Use Expression to filter by cost or by usage. There are two patterns: 6590 // 6591 // * Simple dimension values - You can set the dimension name and values 6592 // for the filters that you plan to use. For example, you can filter for 6593 // REGION==us-east-1 OR REGION==us-west-1. For GetRightsizingRecommendation, 6594 // the Region is a full name (for example, REGION==US East (N. Virginia). 6595 // The Expression example looks like: { "Dimensions": { "Key": "REGION", 6596 // "Values": [ "us-east-1", “us-west-1” ] } } The list of dimension values 6597 // are OR'd together to retrieve cost or usage data. You can create Expression 6598 // and DimensionValues objects using either with* methods or set* methods 6599 // in multiple lines. 6600 // 6601 // * Compound dimension values with logical operations - You can use multiple 6602 // Expression types and the logical operators AND/OR/NOT to create a list 6603 // of one or more Expression objects. This allows you to filter on more advanced 6604 // options. For example, you can filter on ((REGION == us-east-1 OR REGION 6605 // == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer). 6606 // The Expression for that looks like this: { "And": [ {"Or": [ {"Dimensions": 6607 // { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": 6608 // { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": 6609 // { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] } Because each 6610 // Expression can have only one operator, the service returns an error if 6611 // more than one is specified. The following example shows an Expression 6612 // object that creates an error. { "And": [ ... ], "DimensionValues": { "Dimension": 6613 // "USAGE_TYPE", "Values": [ "DataTransfer" ] } } 6614 // 6615 // For the GetRightsizingRecommendation action, a combination of OR and NOT 6616 // is not supported. OR is not supported between different dimensions, or dimensions 6617 // and tags. NOT operators aren't supported. Dimensions are also limited to 6618 // LINKED_ACCOUNT, REGION, or RIGHTSIZING_TYPE. 6619 // 6620 // For the GetReservationPurchaseRecommendation action, only NOT is supported. 6621 // AND and OR are not supported. Dimensions are limited to LINKED_ACCOUNT. 6622 Filter *Expression `type:"structure"` 6623 6624 // This field is only used when SortBy is provided in the request. The maximum 6625 // number of objects that to be returned for this request. If MaxResults is 6626 // not specified with SortBy, the request will return 1000 results as the default 6627 // value for this parameter. 6628 MaxResults *int64 `min:"1" type:"integer"` 6629 6630 // The token to retrieve the next set of results. AWS provides the token when 6631 // the response from a previous call has more results than the maximum page 6632 // size. 6633 NextPageToken *string `type:"string"` 6634 6635 // The value that you want to search the filter values for. 6636 SearchString *string `type:"string"` 6637 6638 // The value by which you want to sort the data. 6639 // 6640 // The key represents cost and usage metrics. The following values are supported: 6641 // 6642 // * BlendedCost 6643 // 6644 // * UnblendedCost 6645 // 6646 // * AmortizedCost 6647 // 6648 // * NetAmortizedCost 6649 // 6650 // * NetUnblendedCost 6651 // 6652 // * UsageQuantity 6653 // 6654 // * NormalizedUsageAmount 6655 // 6656 // Supported values for SortOrder are ASCENDING or DESCENDING. 6657 // 6658 // When you specify a SortBy paramater, the context must be COST_AND_USAGE. 6659 // Further, when using SortBy, NextPageToken and SearchString are not supported. 6660 SortBy []*SortDefinition `type:"list"` 6661 6662 // The start and end dates for retrieving the dimension values. The start date 6663 // is inclusive, but the end date is exclusive. For example, if start is 2017-01-01 6664 // and end is 2017-05-01, then the cost and usage data is retrieved from 2017-01-01 6665 // up to and including 2017-04-30 but not including 2017-05-01. 6666 // 6667 // TimePeriod is a required field 6668 TimePeriod *DateInterval `type:"structure" required:"true"` 6669} 6670 6671// String returns the string representation 6672func (s GetDimensionValuesInput) String() string { 6673 return awsutil.Prettify(s) 6674} 6675 6676// GoString returns the string representation 6677func (s GetDimensionValuesInput) GoString() string { 6678 return s.String() 6679} 6680 6681// Validate inspects the fields of the type to determine if they are valid. 6682func (s *GetDimensionValuesInput) Validate() error { 6683 invalidParams := request.ErrInvalidParams{Context: "GetDimensionValuesInput"} 6684 if s.Dimension == nil { 6685 invalidParams.Add(request.NewErrParamRequired("Dimension")) 6686 } 6687 if s.MaxResults != nil && *s.MaxResults < 1 { 6688 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 6689 } 6690 if s.TimePeriod == nil { 6691 invalidParams.Add(request.NewErrParamRequired("TimePeriod")) 6692 } 6693 if s.Filter != nil { 6694 if err := s.Filter.Validate(); err != nil { 6695 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 6696 } 6697 } 6698 if s.SortBy != nil { 6699 for i, v := range s.SortBy { 6700 if v == nil { 6701 continue 6702 } 6703 if err := v.Validate(); err != nil { 6704 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "SortBy", i), err.(request.ErrInvalidParams)) 6705 } 6706 } 6707 } 6708 if s.TimePeriod != nil { 6709 if err := s.TimePeriod.Validate(); err != nil { 6710 invalidParams.AddNested("TimePeriod", err.(request.ErrInvalidParams)) 6711 } 6712 } 6713 6714 if invalidParams.Len() > 0 { 6715 return invalidParams 6716 } 6717 return nil 6718} 6719 6720// SetContext sets the Context field's value. 6721func (s *GetDimensionValuesInput) SetContext(v string) *GetDimensionValuesInput { 6722 s.Context = &v 6723 return s 6724} 6725 6726// SetDimension sets the Dimension field's value. 6727func (s *GetDimensionValuesInput) SetDimension(v string) *GetDimensionValuesInput { 6728 s.Dimension = &v 6729 return s 6730} 6731 6732// SetFilter sets the Filter field's value. 6733func (s *GetDimensionValuesInput) SetFilter(v *Expression) *GetDimensionValuesInput { 6734 s.Filter = v 6735 return s 6736} 6737 6738// SetMaxResults sets the MaxResults field's value. 6739func (s *GetDimensionValuesInput) SetMaxResults(v int64) *GetDimensionValuesInput { 6740 s.MaxResults = &v 6741 return s 6742} 6743 6744// SetNextPageToken sets the NextPageToken field's value. 6745func (s *GetDimensionValuesInput) SetNextPageToken(v string) *GetDimensionValuesInput { 6746 s.NextPageToken = &v 6747 return s 6748} 6749 6750// SetSearchString sets the SearchString field's value. 6751func (s *GetDimensionValuesInput) SetSearchString(v string) *GetDimensionValuesInput { 6752 s.SearchString = &v 6753 return s 6754} 6755 6756// SetSortBy sets the SortBy field's value. 6757func (s *GetDimensionValuesInput) SetSortBy(v []*SortDefinition) *GetDimensionValuesInput { 6758 s.SortBy = v 6759 return s 6760} 6761 6762// SetTimePeriod sets the TimePeriod field's value. 6763func (s *GetDimensionValuesInput) SetTimePeriod(v *DateInterval) *GetDimensionValuesInput { 6764 s.TimePeriod = v 6765 return s 6766} 6767 6768type GetDimensionValuesOutput struct { 6769 _ struct{} `type:"structure"` 6770 6771 // The filters that you used to filter your request. Some dimensions are available 6772 // only for a specific context. 6773 // 6774 // If you set the context to COST_AND_USAGE, you can use the following dimensions 6775 // for searching: 6776 // 6777 // * AZ - The Availability Zone. An example is us-east-1a. 6778 // 6779 // * DATABASE_ENGINE - The Amazon Relational Database Service database. Examples 6780 // are Aurora or MySQL. 6781 // 6782 // * INSTANCE_TYPE - The type of Amazon EC2 instance. An example is m4.xlarge. 6783 // 6784 // * LEGAL_ENTITY_NAME - The name of the organization that sells you AWS 6785 // services, such as Amazon Web Services. 6786 // 6787 // * LINKED_ACCOUNT - The description in the attribute map that includes 6788 // the full name of the member account. The value field contains the AWS 6789 // ID of the member account. 6790 // 6791 // * OPERATING_SYSTEM - The operating system. Examples are Windows or Linux. 6792 // 6793 // * OPERATION - The action performed. Examples include RunInstance and CreateBucket. 6794 // 6795 // * PLATFORM - The Amazon EC2 operating system. Examples are Windows or 6796 // Linux. 6797 // 6798 // * PURCHASE_TYPE - The reservation type of the purchase to which this usage 6799 // is related. Examples include On-Demand Instances and Standard Reserved 6800 // Instances. 6801 // 6802 // * SERVICE - The AWS service such as Amazon DynamoDB. 6803 // 6804 // * USAGE_TYPE - The type of usage. An example is DataTransfer-In-Bytes. 6805 // The response for the GetDimensionValues operation includes a unit attribute. 6806 // Examples include GB and Hrs. 6807 // 6808 // * USAGE_TYPE_GROUP - The grouping of common usage types. An example is 6809 // Amazon EC2: CloudWatch – Alarms. The response for this operation includes 6810 // a unit attribute. 6811 // 6812 // * RECORD_TYPE - The different types of charges such as RI fees, usage 6813 // costs, tax refunds, and credits. 6814 // 6815 // * RESOURCE_ID - The unique identifier of the resource. ResourceId is an 6816 // opt-in feature only available for last 14 days for EC2-Compute Service. 6817 // 6818 // If you set the context to RESERVATIONS, you can use the following dimensions 6819 // for searching: 6820 // 6821 // * AZ - The Availability Zone. An example is us-east-1a. 6822 // 6823 // * CACHE_ENGINE - The Amazon ElastiCache operating system. Examples are 6824 // Windows or Linux. 6825 // 6826 // * DEPLOYMENT_OPTION - The scope of Amazon Relational Database Service 6827 // deployments. Valid values are SingleAZ and MultiAZ. 6828 // 6829 // * INSTANCE_TYPE - The type of Amazon EC2 instance. An example is m4.xlarge. 6830 // 6831 // * LINKED_ACCOUNT - The description in the attribute map that includes 6832 // the full name of the member account. The value field contains the AWS 6833 // ID of the member account. 6834 // 6835 // * PLATFORM - The Amazon EC2 operating system. Examples are Windows or 6836 // Linux. 6837 // 6838 // * REGION - The AWS Region. 6839 // 6840 // * SCOPE (Utilization only) - The scope of a Reserved Instance (RI). Values 6841 // are regional or a single Availability Zone. 6842 // 6843 // * TAG (Coverage only) - The tags that are associated with a Reserved Instance 6844 // (RI). 6845 // 6846 // * TENANCY - The tenancy of a resource. Examples are shared or dedicated. 6847 // 6848 // If you set the context to SAVINGS_PLANS, you can use the following dimensions 6849 // for searching: 6850 // 6851 // * SAVINGS_PLANS_TYPE - Type of Savings Plans (EC2 Instance or Compute) 6852 // 6853 // * PAYMENT_OPTION - Payment option for the given Savings Plans (for example, 6854 // All Upfront) 6855 // 6856 // * REGION - The AWS Region. 6857 // 6858 // * INSTANCE_TYPE_FAMILY - The family of instances (For example, m5) 6859 // 6860 // * LINKED_ACCOUNT - The description in the attribute map that includes 6861 // the full name of the member account. The value field contains the AWS 6862 // ID of the member account. 6863 // 6864 // * SAVINGS_PLAN_ARN - The unique identifier for your Savings Plan 6865 // 6866 // DimensionValues is a required field 6867 DimensionValues []*DimensionValuesWithAttributes `type:"list" required:"true"` 6868 6869 // The token for the next set of retrievable results. AWS provides the token 6870 // when the response from a previous call has more results than the maximum 6871 // page size. 6872 NextPageToken *string `type:"string"` 6873 6874 // The number of results that AWS returned at one time. 6875 // 6876 // ReturnSize is a required field 6877 ReturnSize *int64 `type:"integer" required:"true"` 6878 6879 // The total number of search results. 6880 // 6881 // TotalSize is a required field 6882 TotalSize *int64 `type:"integer" required:"true"` 6883} 6884 6885// String returns the string representation 6886func (s GetDimensionValuesOutput) String() string { 6887 return awsutil.Prettify(s) 6888} 6889 6890// GoString returns the string representation 6891func (s GetDimensionValuesOutput) GoString() string { 6892 return s.String() 6893} 6894 6895// SetDimensionValues sets the DimensionValues field's value. 6896func (s *GetDimensionValuesOutput) SetDimensionValues(v []*DimensionValuesWithAttributes) *GetDimensionValuesOutput { 6897 s.DimensionValues = v 6898 return s 6899} 6900 6901// SetNextPageToken sets the NextPageToken field's value. 6902func (s *GetDimensionValuesOutput) SetNextPageToken(v string) *GetDimensionValuesOutput { 6903 s.NextPageToken = &v 6904 return s 6905} 6906 6907// SetReturnSize sets the ReturnSize field's value. 6908func (s *GetDimensionValuesOutput) SetReturnSize(v int64) *GetDimensionValuesOutput { 6909 s.ReturnSize = &v 6910 return s 6911} 6912 6913// SetTotalSize sets the TotalSize field's value. 6914func (s *GetDimensionValuesOutput) SetTotalSize(v int64) *GetDimensionValuesOutput { 6915 s.TotalSize = &v 6916 return s 6917} 6918 6919// You can use the following request parameters to query for how much of your 6920// instance usage a reservation covered. 6921type GetReservationCoverageInput struct { 6922 _ struct{} `type:"structure"` 6923 6924 // Filters utilization data by dimensions. You can filter by the following dimensions: 6925 // 6926 // * AZ 6927 // 6928 // * CACHE_ENGINE 6929 // 6930 // * DATABASE_ENGINE 6931 // 6932 // * DEPLOYMENT_OPTION 6933 // 6934 // * INSTANCE_TYPE 6935 // 6936 // * LINKED_ACCOUNT 6937 // 6938 // * OPERATING_SYSTEM 6939 // 6940 // * PLATFORM 6941 // 6942 // * REGION 6943 // 6944 // * SERVICE 6945 // 6946 // * TAG 6947 // 6948 // * TENANCY 6949 // 6950 // GetReservationCoverage uses the same Expression (https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_Expression.html) 6951 // object as the other operations, but only AND is supported among each dimension. 6952 // You can nest only one level deep. If there are multiple values for a dimension, 6953 // they are OR'd together. 6954 // 6955 // If you don't provide a SERVICE filter, Cost Explorer defaults to EC2. 6956 // 6957 // Cost category is also supported. 6958 Filter *Expression `type:"structure"` 6959 6960 // The granularity of the AWS cost data for the reservation. Valid values are 6961 // MONTHLY and DAILY. 6962 // 6963 // If GroupBy is set, Granularity can't be set. If Granularity isn't set, the 6964 // response object doesn't include Granularity, either MONTHLY or DAILY. 6965 // 6966 // The GetReservationCoverage operation supports only DAILY and MONTHLY granularities. 6967 Granularity *string `type:"string" enum:"Granularity"` 6968 6969 // You can group the data by the following attributes: 6970 // 6971 // * AZ 6972 // 6973 // * CACHE_ENGINE 6974 // 6975 // * DATABASE_ENGINE 6976 // 6977 // * DEPLOYMENT_OPTION 6978 // 6979 // * INSTANCE_TYPE 6980 // 6981 // * LINKED_ACCOUNT 6982 // 6983 // * OPERATING_SYSTEM 6984 // 6985 // * PLATFORM 6986 // 6987 // * REGION 6988 // 6989 // * TENANCY 6990 GroupBy []*GroupDefinition `type:"list"` 6991 6992 // The maximum number of objects that you returned for this request. If more 6993 // objects are available, in the response, AWS provides a NextPageToken value 6994 // that you can use in a subsequent call to get the next batch of objects. 6995 MaxResults *int64 `min:"1" type:"integer"` 6996 6997 // The measurement that you want your reservation coverage reported in. 6998 // 6999 // Valid values are Hour, Unit, and Cost. You can use multiple values in a request. 7000 Metrics []*string `type:"list"` 7001 7002 // The token to retrieve the next set of results. AWS provides the token when 7003 // the response from a previous call has more results than the maximum page 7004 // size. 7005 NextPageToken *string `type:"string"` 7006 7007 // The value by which you want to sort the data. 7008 // 7009 // The following values are supported for Key: 7010 // 7011 // * OnDemandCost 7012 // 7013 // * CoverageHoursPercentage 7014 // 7015 // * OnDemandHours 7016 // 7017 // * ReservedHours 7018 // 7019 // * TotalRunningHours 7020 // 7021 // * CoverageNormalizedUnitsPercentage 7022 // 7023 // * OnDemandNormalizedUnits 7024 // 7025 // * ReservedNormalizedUnits 7026 // 7027 // * TotalRunningNormalizedUnits 7028 // 7029 // * Time 7030 // 7031 // Supported values for SortOrder are ASCENDING or DESCENDING. 7032 SortBy *SortDefinition `type:"structure"` 7033 7034 // The start and end dates of the period that you want to retrieve data about 7035 // reservation coverage for. You can retrieve data for a maximum of 13 months: 7036 // the last 12 months and the current month. The start date is inclusive, but 7037 // the end date is exclusive. For example, if start is 2017-01-01 and end is 7038 // 2017-05-01, then the cost and usage data is retrieved from 2017-01-01 up 7039 // to and including 2017-04-30 but not including 2017-05-01. 7040 // 7041 // TimePeriod is a required field 7042 TimePeriod *DateInterval `type:"structure" required:"true"` 7043} 7044 7045// String returns the string representation 7046func (s GetReservationCoverageInput) String() string { 7047 return awsutil.Prettify(s) 7048} 7049 7050// GoString returns the string representation 7051func (s GetReservationCoverageInput) GoString() string { 7052 return s.String() 7053} 7054 7055// Validate inspects the fields of the type to determine if they are valid. 7056func (s *GetReservationCoverageInput) Validate() error { 7057 invalidParams := request.ErrInvalidParams{Context: "GetReservationCoverageInput"} 7058 if s.MaxResults != nil && *s.MaxResults < 1 { 7059 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 7060 } 7061 if s.TimePeriod == nil { 7062 invalidParams.Add(request.NewErrParamRequired("TimePeriod")) 7063 } 7064 if s.Filter != nil { 7065 if err := s.Filter.Validate(); err != nil { 7066 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 7067 } 7068 } 7069 if s.SortBy != nil { 7070 if err := s.SortBy.Validate(); err != nil { 7071 invalidParams.AddNested("SortBy", err.(request.ErrInvalidParams)) 7072 } 7073 } 7074 if s.TimePeriod != nil { 7075 if err := s.TimePeriod.Validate(); err != nil { 7076 invalidParams.AddNested("TimePeriod", err.(request.ErrInvalidParams)) 7077 } 7078 } 7079 7080 if invalidParams.Len() > 0 { 7081 return invalidParams 7082 } 7083 return nil 7084} 7085 7086// SetFilter sets the Filter field's value. 7087func (s *GetReservationCoverageInput) SetFilter(v *Expression) *GetReservationCoverageInput { 7088 s.Filter = v 7089 return s 7090} 7091 7092// SetGranularity sets the Granularity field's value. 7093func (s *GetReservationCoverageInput) SetGranularity(v string) *GetReservationCoverageInput { 7094 s.Granularity = &v 7095 return s 7096} 7097 7098// SetGroupBy sets the GroupBy field's value. 7099func (s *GetReservationCoverageInput) SetGroupBy(v []*GroupDefinition) *GetReservationCoverageInput { 7100 s.GroupBy = v 7101 return s 7102} 7103 7104// SetMaxResults sets the MaxResults field's value. 7105func (s *GetReservationCoverageInput) SetMaxResults(v int64) *GetReservationCoverageInput { 7106 s.MaxResults = &v 7107 return s 7108} 7109 7110// SetMetrics sets the Metrics field's value. 7111func (s *GetReservationCoverageInput) SetMetrics(v []*string) *GetReservationCoverageInput { 7112 s.Metrics = v 7113 return s 7114} 7115 7116// SetNextPageToken sets the NextPageToken field's value. 7117func (s *GetReservationCoverageInput) SetNextPageToken(v string) *GetReservationCoverageInput { 7118 s.NextPageToken = &v 7119 return s 7120} 7121 7122// SetSortBy sets the SortBy field's value. 7123func (s *GetReservationCoverageInput) SetSortBy(v *SortDefinition) *GetReservationCoverageInput { 7124 s.SortBy = v 7125 return s 7126} 7127 7128// SetTimePeriod sets the TimePeriod field's value. 7129func (s *GetReservationCoverageInput) SetTimePeriod(v *DateInterval) *GetReservationCoverageInput { 7130 s.TimePeriod = v 7131 return s 7132} 7133 7134type GetReservationCoverageOutput struct { 7135 _ struct{} `type:"structure"` 7136 7137 // The amount of time that your reservations covered. 7138 // 7139 // CoveragesByTime is a required field 7140 CoveragesByTime []*CoverageByTime `type:"list" required:"true"` 7141 7142 // The token for the next set of retrievable results. AWS provides the token 7143 // when the response from a previous call has more results than the maximum 7144 // page size. 7145 NextPageToken *string `type:"string"` 7146 7147 // The total amount of instance usage that a reservation covered. 7148 Total *Coverage `type:"structure"` 7149} 7150 7151// String returns the string representation 7152func (s GetReservationCoverageOutput) String() string { 7153 return awsutil.Prettify(s) 7154} 7155 7156// GoString returns the string representation 7157func (s GetReservationCoverageOutput) GoString() string { 7158 return s.String() 7159} 7160 7161// SetCoveragesByTime sets the CoveragesByTime field's value. 7162func (s *GetReservationCoverageOutput) SetCoveragesByTime(v []*CoverageByTime) *GetReservationCoverageOutput { 7163 s.CoveragesByTime = v 7164 return s 7165} 7166 7167// SetNextPageToken sets the NextPageToken field's value. 7168func (s *GetReservationCoverageOutput) SetNextPageToken(v string) *GetReservationCoverageOutput { 7169 s.NextPageToken = &v 7170 return s 7171} 7172 7173// SetTotal sets the Total field's value. 7174func (s *GetReservationCoverageOutput) SetTotal(v *Coverage) *GetReservationCoverageOutput { 7175 s.Total = v 7176 return s 7177} 7178 7179type GetReservationPurchaseRecommendationInput struct { 7180 _ struct{} `type:"structure"` 7181 7182 // The account ID that is associated with the recommendation. 7183 AccountId *string `type:"string"` 7184 7185 // The account scope that you want your recommendations for. Amazon Web Services 7186 // calculates recommendations including the management account and member accounts 7187 // if the value is set to PAYER. If the value is LINKED, recommendations are 7188 // calculated for individual member accounts only. 7189 AccountScope *string `type:"string" enum:"AccountScope"` 7190 7191 // Use Expression to filter by cost or by usage. There are two patterns: 7192 // 7193 // * Simple dimension values - You can set the dimension name and values 7194 // for the filters that you plan to use. For example, you can filter for 7195 // REGION==us-east-1 OR REGION==us-west-1. For GetRightsizingRecommendation, 7196 // the Region is a full name (for example, REGION==US East (N. Virginia). 7197 // The Expression example looks like: { "Dimensions": { "Key": "REGION", 7198 // "Values": [ "us-east-1", “us-west-1” ] } } The list of dimension values 7199 // are OR'd together to retrieve cost or usage data. You can create Expression 7200 // and DimensionValues objects using either with* methods or set* methods 7201 // in multiple lines. 7202 // 7203 // * Compound dimension values with logical operations - You can use multiple 7204 // Expression types and the logical operators AND/OR/NOT to create a list 7205 // of one or more Expression objects. This allows you to filter on more advanced 7206 // options. For example, you can filter on ((REGION == us-east-1 OR REGION 7207 // == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer). 7208 // The Expression for that looks like this: { "And": [ {"Or": [ {"Dimensions": 7209 // { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": 7210 // { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": 7211 // { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] } Because each 7212 // Expression can have only one operator, the service returns an error if 7213 // more than one is specified. The following example shows an Expression 7214 // object that creates an error. { "And": [ ... ], "DimensionValues": { "Dimension": 7215 // "USAGE_TYPE", "Values": [ "DataTransfer" ] } } 7216 // 7217 // For the GetRightsizingRecommendation action, a combination of OR and NOT 7218 // is not supported. OR is not supported between different dimensions, or dimensions 7219 // and tags. NOT operators aren't supported. Dimensions are also limited to 7220 // LINKED_ACCOUNT, REGION, or RIGHTSIZING_TYPE. 7221 // 7222 // For the GetReservationPurchaseRecommendation action, only NOT is supported. 7223 // AND and OR are not supported. Dimensions are limited to LINKED_ACCOUNT. 7224 Filter *Expression `type:"structure"` 7225 7226 // The number of previous days that you want AWS to consider when it calculates 7227 // your recommendations. 7228 LookbackPeriodInDays *string `type:"string" enum:"LookbackPeriodInDays"` 7229 7230 // The pagination token that indicates the next set of results that you want 7231 // to retrieve. 7232 NextPageToken *string `type:"string"` 7233 7234 // The number of recommendations that you want returned in a single response 7235 // object. 7236 PageSize *int64 `type:"integer"` 7237 7238 // The reservation purchase option that you want recommendations for. 7239 PaymentOption *string `type:"string" enum:"PaymentOption"` 7240 7241 // The specific service that you want recommendations for. 7242 // 7243 // Service is a required field 7244 Service *string `type:"string" required:"true"` 7245 7246 // The hardware specifications for the service instances that you want recommendations 7247 // for, such as standard or convertible Amazon EC2 instances. 7248 ServiceSpecification *ServiceSpecification `type:"structure"` 7249 7250 // The reservation term that you want recommendations for. 7251 TermInYears *string `type:"string" enum:"TermInYears"` 7252} 7253 7254// String returns the string representation 7255func (s GetReservationPurchaseRecommendationInput) String() string { 7256 return awsutil.Prettify(s) 7257} 7258 7259// GoString returns the string representation 7260func (s GetReservationPurchaseRecommendationInput) GoString() string { 7261 return s.String() 7262} 7263 7264// Validate inspects the fields of the type to determine if they are valid. 7265func (s *GetReservationPurchaseRecommendationInput) Validate() error { 7266 invalidParams := request.ErrInvalidParams{Context: "GetReservationPurchaseRecommendationInput"} 7267 if s.Service == nil { 7268 invalidParams.Add(request.NewErrParamRequired("Service")) 7269 } 7270 if s.Filter != nil { 7271 if err := s.Filter.Validate(); err != nil { 7272 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 7273 } 7274 } 7275 7276 if invalidParams.Len() > 0 { 7277 return invalidParams 7278 } 7279 return nil 7280} 7281 7282// SetAccountId sets the AccountId field's value. 7283func (s *GetReservationPurchaseRecommendationInput) SetAccountId(v string) *GetReservationPurchaseRecommendationInput { 7284 s.AccountId = &v 7285 return s 7286} 7287 7288// SetAccountScope sets the AccountScope field's value. 7289func (s *GetReservationPurchaseRecommendationInput) SetAccountScope(v string) *GetReservationPurchaseRecommendationInput { 7290 s.AccountScope = &v 7291 return s 7292} 7293 7294// SetFilter sets the Filter field's value. 7295func (s *GetReservationPurchaseRecommendationInput) SetFilter(v *Expression) *GetReservationPurchaseRecommendationInput { 7296 s.Filter = v 7297 return s 7298} 7299 7300// SetLookbackPeriodInDays sets the LookbackPeriodInDays field's value. 7301func (s *GetReservationPurchaseRecommendationInput) SetLookbackPeriodInDays(v string) *GetReservationPurchaseRecommendationInput { 7302 s.LookbackPeriodInDays = &v 7303 return s 7304} 7305 7306// SetNextPageToken sets the NextPageToken field's value. 7307func (s *GetReservationPurchaseRecommendationInput) SetNextPageToken(v string) *GetReservationPurchaseRecommendationInput { 7308 s.NextPageToken = &v 7309 return s 7310} 7311 7312// SetPageSize sets the PageSize field's value. 7313func (s *GetReservationPurchaseRecommendationInput) SetPageSize(v int64) *GetReservationPurchaseRecommendationInput { 7314 s.PageSize = &v 7315 return s 7316} 7317 7318// SetPaymentOption sets the PaymentOption field's value. 7319func (s *GetReservationPurchaseRecommendationInput) SetPaymentOption(v string) *GetReservationPurchaseRecommendationInput { 7320 s.PaymentOption = &v 7321 return s 7322} 7323 7324// SetService sets the Service field's value. 7325func (s *GetReservationPurchaseRecommendationInput) SetService(v string) *GetReservationPurchaseRecommendationInput { 7326 s.Service = &v 7327 return s 7328} 7329 7330// SetServiceSpecification sets the ServiceSpecification field's value. 7331func (s *GetReservationPurchaseRecommendationInput) SetServiceSpecification(v *ServiceSpecification) *GetReservationPurchaseRecommendationInput { 7332 s.ServiceSpecification = v 7333 return s 7334} 7335 7336// SetTermInYears sets the TermInYears field's value. 7337func (s *GetReservationPurchaseRecommendationInput) SetTermInYears(v string) *GetReservationPurchaseRecommendationInput { 7338 s.TermInYears = &v 7339 return s 7340} 7341 7342type GetReservationPurchaseRecommendationOutput struct { 7343 _ struct{} `type:"structure"` 7344 7345 // Information about this specific recommendation call, such as the time stamp 7346 // for when Cost Explorer generated this recommendation. 7347 Metadata *ReservationPurchaseRecommendationMetadata `type:"structure"` 7348 7349 // The pagination token for the next set of retrievable results. 7350 NextPageToken *string `type:"string"` 7351 7352 // Recommendations for reservations to purchase. 7353 Recommendations []*ReservationPurchaseRecommendation `type:"list"` 7354} 7355 7356// String returns the string representation 7357func (s GetReservationPurchaseRecommendationOutput) String() string { 7358 return awsutil.Prettify(s) 7359} 7360 7361// GoString returns the string representation 7362func (s GetReservationPurchaseRecommendationOutput) GoString() string { 7363 return s.String() 7364} 7365 7366// SetMetadata sets the Metadata field's value. 7367func (s *GetReservationPurchaseRecommendationOutput) SetMetadata(v *ReservationPurchaseRecommendationMetadata) *GetReservationPurchaseRecommendationOutput { 7368 s.Metadata = v 7369 return s 7370} 7371 7372// SetNextPageToken sets the NextPageToken field's value. 7373func (s *GetReservationPurchaseRecommendationOutput) SetNextPageToken(v string) *GetReservationPurchaseRecommendationOutput { 7374 s.NextPageToken = &v 7375 return s 7376} 7377 7378// SetRecommendations sets the Recommendations field's value. 7379func (s *GetReservationPurchaseRecommendationOutput) SetRecommendations(v []*ReservationPurchaseRecommendation) *GetReservationPurchaseRecommendationOutput { 7380 s.Recommendations = v 7381 return s 7382} 7383 7384type GetReservationUtilizationInput struct { 7385 _ struct{} `type:"structure"` 7386 7387 // Filters utilization data by dimensions. You can filter by the following dimensions: 7388 // 7389 // * AZ 7390 // 7391 // * CACHE_ENGINE 7392 // 7393 // * DEPLOYMENT_OPTION 7394 // 7395 // * INSTANCE_TYPE 7396 // 7397 // * LINKED_ACCOUNT 7398 // 7399 // * OPERATING_SYSTEM 7400 // 7401 // * PLATFORM 7402 // 7403 // * REGION 7404 // 7405 // * SERVICE 7406 // 7407 // * SCOPE 7408 // 7409 // * TENANCY 7410 // 7411 // GetReservationUtilization uses the same Expression (https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_Expression.html) 7412 // object as the other operations, but only AND is supported among each dimension, 7413 // and nesting is supported up to only one level deep. If there are multiple 7414 // values for a dimension, they are OR'd together. 7415 Filter *Expression `type:"structure"` 7416 7417 // If GroupBy is set, Granularity can't be set. If Granularity isn't set, the 7418 // response object doesn't include Granularity, either MONTHLY or DAILY. If 7419 // both GroupBy and Granularity aren't set, GetReservationUtilization defaults 7420 // to DAILY. 7421 // 7422 // The GetReservationUtilization operation supports only DAILY and MONTHLY granularities. 7423 Granularity *string `type:"string" enum:"Granularity"` 7424 7425 // Groups only by SUBSCRIPTION_ID. Metadata is included. 7426 GroupBy []*GroupDefinition `type:"list"` 7427 7428 // The maximum number of objects that you returned for this request. If more 7429 // objects are available, in the response, AWS provides a NextPageToken value 7430 // that you can use in a subsequent call to get the next batch of objects. 7431 MaxResults *int64 `min:"1" type:"integer"` 7432 7433 // The token to retrieve the next set of results. AWS provides the token when 7434 // the response from a previous call has more results than the maximum page 7435 // size. 7436 NextPageToken *string `type:"string"` 7437 7438 // The value by which you want to sort the data. 7439 // 7440 // The following values are supported for Key: 7441 // 7442 // * UtilizationPercentage 7443 // 7444 // * UtilizationPercentageInUnits 7445 // 7446 // * PurchasedHours 7447 // 7448 // * PurchasedUnits 7449 // 7450 // * TotalActualHours 7451 // 7452 // * TotalActualUnits 7453 // 7454 // * UnusedHours 7455 // 7456 // * UnusedUnits 7457 // 7458 // * OnDemandCostOfRIHoursUsed 7459 // 7460 // * NetRISavings 7461 // 7462 // * TotalPotentialRISavings 7463 // 7464 // * AmortizedUpfrontFee 7465 // 7466 // * AmortizedRecurringFee 7467 // 7468 // * TotalAmortizedFee 7469 // 7470 // * RICostForUnusedHours 7471 // 7472 // * RealizedSavings 7473 // 7474 // * UnrealizedSavings 7475 // 7476 // Supported values for SortOrder are ASCENDING or DESCENDING. 7477 SortBy *SortDefinition `type:"structure"` 7478 7479 // Sets the start and end dates for retrieving RI utilization. The start date 7480 // is inclusive, but the end date is exclusive. For example, if start is 2017-01-01 7481 // and end is 2017-05-01, then the cost and usage data is retrieved from 2017-01-01 7482 // up to and including 2017-04-30 but not including 2017-05-01. 7483 // 7484 // TimePeriod is a required field 7485 TimePeriod *DateInterval `type:"structure" required:"true"` 7486} 7487 7488// String returns the string representation 7489func (s GetReservationUtilizationInput) String() string { 7490 return awsutil.Prettify(s) 7491} 7492 7493// GoString returns the string representation 7494func (s GetReservationUtilizationInput) GoString() string { 7495 return s.String() 7496} 7497 7498// Validate inspects the fields of the type to determine if they are valid. 7499func (s *GetReservationUtilizationInput) Validate() error { 7500 invalidParams := request.ErrInvalidParams{Context: "GetReservationUtilizationInput"} 7501 if s.MaxResults != nil && *s.MaxResults < 1 { 7502 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 7503 } 7504 if s.TimePeriod == nil { 7505 invalidParams.Add(request.NewErrParamRequired("TimePeriod")) 7506 } 7507 if s.Filter != nil { 7508 if err := s.Filter.Validate(); err != nil { 7509 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 7510 } 7511 } 7512 if s.SortBy != nil { 7513 if err := s.SortBy.Validate(); err != nil { 7514 invalidParams.AddNested("SortBy", err.(request.ErrInvalidParams)) 7515 } 7516 } 7517 if s.TimePeriod != nil { 7518 if err := s.TimePeriod.Validate(); err != nil { 7519 invalidParams.AddNested("TimePeriod", err.(request.ErrInvalidParams)) 7520 } 7521 } 7522 7523 if invalidParams.Len() > 0 { 7524 return invalidParams 7525 } 7526 return nil 7527} 7528 7529// SetFilter sets the Filter field's value. 7530func (s *GetReservationUtilizationInput) SetFilter(v *Expression) *GetReservationUtilizationInput { 7531 s.Filter = v 7532 return s 7533} 7534 7535// SetGranularity sets the Granularity field's value. 7536func (s *GetReservationUtilizationInput) SetGranularity(v string) *GetReservationUtilizationInput { 7537 s.Granularity = &v 7538 return s 7539} 7540 7541// SetGroupBy sets the GroupBy field's value. 7542func (s *GetReservationUtilizationInput) SetGroupBy(v []*GroupDefinition) *GetReservationUtilizationInput { 7543 s.GroupBy = v 7544 return s 7545} 7546 7547// SetMaxResults sets the MaxResults field's value. 7548func (s *GetReservationUtilizationInput) SetMaxResults(v int64) *GetReservationUtilizationInput { 7549 s.MaxResults = &v 7550 return s 7551} 7552 7553// SetNextPageToken sets the NextPageToken field's value. 7554func (s *GetReservationUtilizationInput) SetNextPageToken(v string) *GetReservationUtilizationInput { 7555 s.NextPageToken = &v 7556 return s 7557} 7558 7559// SetSortBy sets the SortBy field's value. 7560func (s *GetReservationUtilizationInput) SetSortBy(v *SortDefinition) *GetReservationUtilizationInput { 7561 s.SortBy = v 7562 return s 7563} 7564 7565// SetTimePeriod sets the TimePeriod field's value. 7566func (s *GetReservationUtilizationInput) SetTimePeriod(v *DateInterval) *GetReservationUtilizationInput { 7567 s.TimePeriod = v 7568 return s 7569} 7570 7571type GetReservationUtilizationOutput struct { 7572 _ struct{} `type:"structure"` 7573 7574 // The token for the next set of retrievable results. AWS provides the token 7575 // when the response from a previous call has more results than the maximum 7576 // page size. 7577 NextPageToken *string `type:"string"` 7578 7579 // The total amount of time that you used your RIs. 7580 Total *ReservationAggregates `type:"structure"` 7581 7582 // The amount of time that you used your RIs. 7583 // 7584 // UtilizationsByTime is a required field 7585 UtilizationsByTime []*UtilizationByTime `type:"list" required:"true"` 7586} 7587 7588// String returns the string representation 7589func (s GetReservationUtilizationOutput) String() string { 7590 return awsutil.Prettify(s) 7591} 7592 7593// GoString returns the string representation 7594func (s GetReservationUtilizationOutput) GoString() string { 7595 return s.String() 7596} 7597 7598// SetNextPageToken sets the NextPageToken field's value. 7599func (s *GetReservationUtilizationOutput) SetNextPageToken(v string) *GetReservationUtilizationOutput { 7600 s.NextPageToken = &v 7601 return s 7602} 7603 7604// SetTotal sets the Total field's value. 7605func (s *GetReservationUtilizationOutput) SetTotal(v *ReservationAggregates) *GetReservationUtilizationOutput { 7606 s.Total = v 7607 return s 7608} 7609 7610// SetUtilizationsByTime sets the UtilizationsByTime field's value. 7611func (s *GetReservationUtilizationOutput) SetUtilizationsByTime(v []*UtilizationByTime) *GetReservationUtilizationOutput { 7612 s.UtilizationsByTime = v 7613 return s 7614} 7615 7616type GetRightsizingRecommendationInput struct { 7617 _ struct{} `type:"structure"` 7618 7619 // Enables you to customize recommendations across two attributes. You can choose 7620 // to view recommendations for instances within the same instance families or 7621 // across different instance families. You can also choose to view your estimated 7622 // savings associated with recommendations with consideration of existing Savings 7623 // Plans or RI benefits, or neither. 7624 Configuration *RightsizingRecommendationConfiguration `type:"structure"` 7625 7626 // Use Expression to filter by cost or by usage. There are two patterns: 7627 // 7628 // * Simple dimension values - You can set the dimension name and values 7629 // for the filters that you plan to use. For example, you can filter for 7630 // REGION==us-east-1 OR REGION==us-west-1. For GetRightsizingRecommendation, 7631 // the Region is a full name (for example, REGION==US East (N. Virginia). 7632 // The Expression example looks like: { "Dimensions": { "Key": "REGION", 7633 // "Values": [ "us-east-1", “us-west-1” ] } } The list of dimension values 7634 // are OR'd together to retrieve cost or usage data. You can create Expression 7635 // and DimensionValues objects using either with* methods or set* methods 7636 // in multiple lines. 7637 // 7638 // * Compound dimension values with logical operations - You can use multiple 7639 // Expression types and the logical operators AND/OR/NOT to create a list 7640 // of one or more Expression objects. This allows you to filter on more advanced 7641 // options. For example, you can filter on ((REGION == us-east-1 OR REGION 7642 // == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer). 7643 // The Expression for that looks like this: { "And": [ {"Or": [ {"Dimensions": 7644 // { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": 7645 // { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": 7646 // { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] } Because each 7647 // Expression can have only one operator, the service returns an error if 7648 // more than one is specified. The following example shows an Expression 7649 // object that creates an error. { "And": [ ... ], "DimensionValues": { "Dimension": 7650 // "USAGE_TYPE", "Values": [ "DataTransfer" ] } } 7651 // 7652 // For the GetRightsizingRecommendation action, a combination of OR and NOT 7653 // is not supported. OR is not supported between different dimensions, or dimensions 7654 // and tags. NOT operators aren't supported. Dimensions are also limited to 7655 // LINKED_ACCOUNT, REGION, or RIGHTSIZING_TYPE. 7656 // 7657 // For the GetReservationPurchaseRecommendation action, only NOT is supported. 7658 // AND and OR are not supported. Dimensions are limited to LINKED_ACCOUNT. 7659 Filter *Expression `type:"structure"` 7660 7661 // The pagination token that indicates the next set of results that you want 7662 // to retrieve. 7663 NextPageToken *string `type:"string"` 7664 7665 // The number of recommendations that you want returned in a single response 7666 // object. 7667 PageSize *int64 `type:"integer"` 7668 7669 // The specific service that you want recommendations for. The only valid value 7670 // for GetRightsizingRecommendation is "AmazonEC2". 7671 // 7672 // Service is a required field 7673 Service *string `type:"string" required:"true"` 7674} 7675 7676// String returns the string representation 7677func (s GetRightsizingRecommendationInput) String() string { 7678 return awsutil.Prettify(s) 7679} 7680 7681// GoString returns the string representation 7682func (s GetRightsizingRecommendationInput) GoString() string { 7683 return s.String() 7684} 7685 7686// Validate inspects the fields of the type to determine if they are valid. 7687func (s *GetRightsizingRecommendationInput) Validate() error { 7688 invalidParams := request.ErrInvalidParams{Context: "GetRightsizingRecommendationInput"} 7689 if s.Service == nil { 7690 invalidParams.Add(request.NewErrParamRequired("Service")) 7691 } 7692 if s.Configuration != nil { 7693 if err := s.Configuration.Validate(); err != nil { 7694 invalidParams.AddNested("Configuration", err.(request.ErrInvalidParams)) 7695 } 7696 } 7697 if s.Filter != nil { 7698 if err := s.Filter.Validate(); err != nil { 7699 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 7700 } 7701 } 7702 7703 if invalidParams.Len() > 0 { 7704 return invalidParams 7705 } 7706 return nil 7707} 7708 7709// SetConfiguration sets the Configuration field's value. 7710func (s *GetRightsizingRecommendationInput) SetConfiguration(v *RightsizingRecommendationConfiguration) *GetRightsizingRecommendationInput { 7711 s.Configuration = v 7712 return s 7713} 7714 7715// SetFilter sets the Filter field's value. 7716func (s *GetRightsizingRecommendationInput) SetFilter(v *Expression) *GetRightsizingRecommendationInput { 7717 s.Filter = v 7718 return s 7719} 7720 7721// SetNextPageToken sets the NextPageToken field's value. 7722func (s *GetRightsizingRecommendationInput) SetNextPageToken(v string) *GetRightsizingRecommendationInput { 7723 s.NextPageToken = &v 7724 return s 7725} 7726 7727// SetPageSize sets the PageSize field's value. 7728func (s *GetRightsizingRecommendationInput) SetPageSize(v int64) *GetRightsizingRecommendationInput { 7729 s.PageSize = &v 7730 return s 7731} 7732 7733// SetService sets the Service field's value. 7734func (s *GetRightsizingRecommendationInput) SetService(v string) *GetRightsizingRecommendationInput { 7735 s.Service = &v 7736 return s 7737} 7738 7739type GetRightsizingRecommendationOutput struct { 7740 _ struct{} `type:"structure"` 7741 7742 // Enables you to customize recommendations across two attributes. You can choose 7743 // to view recommendations for instances within the same instance families or 7744 // across different instance families. You can also choose to view your estimated 7745 // savings associated with recommendations with consideration of existing Savings 7746 // Plans or RI benefits, or neither. 7747 Configuration *RightsizingRecommendationConfiguration `type:"structure"` 7748 7749 // Information regarding this specific recommendation set. 7750 Metadata *RightsizingRecommendationMetadata `type:"structure"` 7751 7752 // The token to retrieve the next set of results. 7753 NextPageToken *string `type:"string"` 7754 7755 // Recommendations to rightsize resources. 7756 RightsizingRecommendations []*RightsizingRecommendation `type:"list"` 7757 7758 // Summary of this recommendation set. 7759 Summary *RightsizingRecommendationSummary `type:"structure"` 7760} 7761 7762// String returns the string representation 7763func (s GetRightsizingRecommendationOutput) String() string { 7764 return awsutil.Prettify(s) 7765} 7766 7767// GoString returns the string representation 7768func (s GetRightsizingRecommendationOutput) GoString() string { 7769 return s.String() 7770} 7771 7772// SetConfiguration sets the Configuration field's value. 7773func (s *GetRightsizingRecommendationOutput) SetConfiguration(v *RightsizingRecommendationConfiguration) *GetRightsizingRecommendationOutput { 7774 s.Configuration = v 7775 return s 7776} 7777 7778// SetMetadata sets the Metadata field's value. 7779func (s *GetRightsizingRecommendationOutput) SetMetadata(v *RightsizingRecommendationMetadata) *GetRightsizingRecommendationOutput { 7780 s.Metadata = v 7781 return s 7782} 7783 7784// SetNextPageToken sets the NextPageToken field's value. 7785func (s *GetRightsizingRecommendationOutput) SetNextPageToken(v string) *GetRightsizingRecommendationOutput { 7786 s.NextPageToken = &v 7787 return s 7788} 7789 7790// SetRightsizingRecommendations sets the RightsizingRecommendations field's value. 7791func (s *GetRightsizingRecommendationOutput) SetRightsizingRecommendations(v []*RightsizingRecommendation) *GetRightsizingRecommendationOutput { 7792 s.RightsizingRecommendations = v 7793 return s 7794} 7795 7796// SetSummary sets the Summary field's value. 7797func (s *GetRightsizingRecommendationOutput) SetSummary(v *RightsizingRecommendationSummary) *GetRightsizingRecommendationOutput { 7798 s.Summary = v 7799 return s 7800} 7801 7802type GetSavingsPlansCoverageInput struct { 7803 _ struct{} `type:"structure"` 7804 7805 // Filters Savings Plans coverage data by dimensions. You can filter data for 7806 // Savings Plans usage with the following dimensions: 7807 // 7808 // * LINKED_ACCOUNT 7809 // 7810 // * REGION 7811 // 7812 // * SERVICE 7813 // 7814 // * INSTANCE_FAMILY 7815 // 7816 // GetSavingsPlansCoverage uses the same Expression (https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_Expression.html) 7817 // object as the other operations, but only AND is supported among each dimension. 7818 // If there are multiple values for a dimension, they are OR'd together. 7819 // 7820 // Cost category is also supported. 7821 Filter *Expression `type:"structure"` 7822 7823 // The granularity of the Amazon Web Services cost data for your Savings Plans. 7824 // Granularity can't be set if GroupBy is set. 7825 // 7826 // The GetSavingsPlansCoverage operation supports only DAILY and MONTHLY granularities. 7827 Granularity *string `type:"string" enum:"Granularity"` 7828 7829 // You can group the data using the attributes INSTANCE_FAMILY, REGION, or SERVICE. 7830 GroupBy []*GroupDefinition `type:"list"` 7831 7832 // The number of items to be returned in a response. The default is 20, with 7833 // a minimum value of 1. 7834 MaxResults *int64 `min:"1" type:"integer"` 7835 7836 // The measurement that you want your Savings Plans coverage reported in. The 7837 // only valid value is SpendCoveredBySavingsPlans. 7838 Metrics []*string `type:"list"` 7839 7840 // The token to retrieve the next set of results. Amazon Web Services provides 7841 // the token when the response from a previous call has more results than the 7842 // maximum page size. 7843 NextToken *string `type:"string"` 7844 7845 // The value by which you want to sort the data. 7846 // 7847 // The following values are supported for Key: 7848 // 7849 // * SpendCoveredBySavingsPlan 7850 // 7851 // * OnDemandCost 7852 // 7853 // * CoveragePercentage 7854 // 7855 // * TotalCost 7856 // 7857 // * InstanceFamily 7858 // 7859 // * Region 7860 // 7861 // * Service 7862 // 7863 // Supported values for SortOrder are ASCENDING or DESCENDING. 7864 SortBy *SortDefinition `type:"structure"` 7865 7866 // The time period that you want the usage and costs for. The Start date must 7867 // be within 13 months. The End date must be after the Start date, and before 7868 // the current date. Future dates can't be used as an End date. 7869 // 7870 // TimePeriod is a required field 7871 TimePeriod *DateInterval `type:"structure" required:"true"` 7872} 7873 7874// String returns the string representation 7875func (s GetSavingsPlansCoverageInput) String() string { 7876 return awsutil.Prettify(s) 7877} 7878 7879// GoString returns the string representation 7880func (s GetSavingsPlansCoverageInput) GoString() string { 7881 return s.String() 7882} 7883 7884// Validate inspects the fields of the type to determine if they are valid. 7885func (s *GetSavingsPlansCoverageInput) Validate() error { 7886 invalidParams := request.ErrInvalidParams{Context: "GetSavingsPlansCoverageInput"} 7887 if s.MaxResults != nil && *s.MaxResults < 1 { 7888 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 7889 } 7890 if s.TimePeriod == nil { 7891 invalidParams.Add(request.NewErrParamRequired("TimePeriod")) 7892 } 7893 if s.Filter != nil { 7894 if err := s.Filter.Validate(); err != nil { 7895 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 7896 } 7897 } 7898 if s.SortBy != nil { 7899 if err := s.SortBy.Validate(); err != nil { 7900 invalidParams.AddNested("SortBy", err.(request.ErrInvalidParams)) 7901 } 7902 } 7903 if s.TimePeriod != nil { 7904 if err := s.TimePeriod.Validate(); err != nil { 7905 invalidParams.AddNested("TimePeriod", err.(request.ErrInvalidParams)) 7906 } 7907 } 7908 7909 if invalidParams.Len() > 0 { 7910 return invalidParams 7911 } 7912 return nil 7913} 7914 7915// SetFilter sets the Filter field's value. 7916func (s *GetSavingsPlansCoverageInput) SetFilter(v *Expression) *GetSavingsPlansCoverageInput { 7917 s.Filter = v 7918 return s 7919} 7920 7921// SetGranularity sets the Granularity field's value. 7922func (s *GetSavingsPlansCoverageInput) SetGranularity(v string) *GetSavingsPlansCoverageInput { 7923 s.Granularity = &v 7924 return s 7925} 7926 7927// SetGroupBy sets the GroupBy field's value. 7928func (s *GetSavingsPlansCoverageInput) SetGroupBy(v []*GroupDefinition) *GetSavingsPlansCoverageInput { 7929 s.GroupBy = v 7930 return s 7931} 7932 7933// SetMaxResults sets the MaxResults field's value. 7934func (s *GetSavingsPlansCoverageInput) SetMaxResults(v int64) *GetSavingsPlansCoverageInput { 7935 s.MaxResults = &v 7936 return s 7937} 7938 7939// SetMetrics sets the Metrics field's value. 7940func (s *GetSavingsPlansCoverageInput) SetMetrics(v []*string) *GetSavingsPlansCoverageInput { 7941 s.Metrics = v 7942 return s 7943} 7944 7945// SetNextToken sets the NextToken field's value. 7946func (s *GetSavingsPlansCoverageInput) SetNextToken(v string) *GetSavingsPlansCoverageInput { 7947 s.NextToken = &v 7948 return s 7949} 7950 7951// SetSortBy sets the SortBy field's value. 7952func (s *GetSavingsPlansCoverageInput) SetSortBy(v *SortDefinition) *GetSavingsPlansCoverageInput { 7953 s.SortBy = v 7954 return s 7955} 7956 7957// SetTimePeriod sets the TimePeriod field's value. 7958func (s *GetSavingsPlansCoverageInput) SetTimePeriod(v *DateInterval) *GetSavingsPlansCoverageInput { 7959 s.TimePeriod = v 7960 return s 7961} 7962 7963type GetSavingsPlansCoverageOutput struct { 7964 _ struct{} `type:"structure"` 7965 7966 // The token to retrieve the next set of results. Amazon Web Services provides 7967 // the token when the response from a previous call has more results than the 7968 // maximum page size. 7969 NextToken *string `type:"string"` 7970 7971 // The amount of spend that your Savings Plans covered. 7972 // 7973 // SavingsPlansCoverages is a required field 7974 SavingsPlansCoverages []*SavingsPlansCoverage `type:"list" required:"true"` 7975} 7976 7977// String returns the string representation 7978func (s GetSavingsPlansCoverageOutput) String() string { 7979 return awsutil.Prettify(s) 7980} 7981 7982// GoString returns the string representation 7983func (s GetSavingsPlansCoverageOutput) GoString() string { 7984 return s.String() 7985} 7986 7987// SetNextToken sets the NextToken field's value. 7988func (s *GetSavingsPlansCoverageOutput) SetNextToken(v string) *GetSavingsPlansCoverageOutput { 7989 s.NextToken = &v 7990 return s 7991} 7992 7993// SetSavingsPlansCoverages sets the SavingsPlansCoverages field's value. 7994func (s *GetSavingsPlansCoverageOutput) SetSavingsPlansCoverages(v []*SavingsPlansCoverage) *GetSavingsPlansCoverageOutput { 7995 s.SavingsPlansCoverages = v 7996 return s 7997} 7998 7999type GetSavingsPlansPurchaseRecommendationInput struct { 8000 _ struct{} `type:"structure"` 8001 8002 // The account scope that you want your recommendations for. Amazon Web Services 8003 // calculates recommendations including the management account and member accounts 8004 // if the value is set to PAYER. If the value is LINKED, recommendations are 8005 // calculated for individual member accounts only. 8006 AccountScope *string `type:"string" enum:"AccountScope"` 8007 8008 // You can filter your recommendations by Account ID with the LINKED_ACCOUNT 8009 // dimension. To filter your recommendations by Account ID, specify Key as LINKED_ACCOUNT 8010 // and Value as the comma-separated Acount ID(s) for which you want to see Savings 8011 // Plans purchase recommendations. 8012 // 8013 // For GetSavingsPlansPurchaseRecommendation, the Filter does not include CostCategories 8014 // or Tags. It only includes Dimensions. With Dimensions, Key must be LINKED_ACCOUNT 8015 // and Value can be a single Account ID or multiple comma-separated Account 8016 // IDs for which you want to see Savings Plans Purchase Recommendations. AND 8017 // and OR operators are not supported. 8018 Filter *Expression `type:"structure"` 8019 8020 // The lookback period used to generate the recommendation. 8021 // 8022 // LookbackPeriodInDays is a required field 8023 LookbackPeriodInDays *string `type:"string" required:"true" enum:"LookbackPeriodInDays"` 8024 8025 // The token to retrieve the next set of results. Amazon Web Services provides 8026 // the token when the response from a previous call has more results than the 8027 // maximum page size. 8028 NextPageToken *string `type:"string"` 8029 8030 // The number of recommendations that you want returned in a single response 8031 // object. 8032 PageSize *int64 `type:"integer"` 8033 8034 // The payment option used to generate these recommendations. 8035 // 8036 // PaymentOption is a required field 8037 PaymentOption *string `type:"string" required:"true" enum:"PaymentOption"` 8038 8039 // The Savings Plans recommendation type requested. 8040 // 8041 // SavingsPlansType is a required field 8042 SavingsPlansType *string `type:"string" required:"true" enum:"SupportedSavingsPlansType"` 8043 8044 // The savings plan recommendation term used to generate these recommendations. 8045 // 8046 // TermInYears is a required field 8047 TermInYears *string `type:"string" required:"true" enum:"TermInYears"` 8048} 8049 8050// String returns the string representation 8051func (s GetSavingsPlansPurchaseRecommendationInput) String() string { 8052 return awsutil.Prettify(s) 8053} 8054 8055// GoString returns the string representation 8056func (s GetSavingsPlansPurchaseRecommendationInput) GoString() string { 8057 return s.String() 8058} 8059 8060// Validate inspects the fields of the type to determine if they are valid. 8061func (s *GetSavingsPlansPurchaseRecommendationInput) Validate() error { 8062 invalidParams := request.ErrInvalidParams{Context: "GetSavingsPlansPurchaseRecommendationInput"} 8063 if s.LookbackPeriodInDays == nil { 8064 invalidParams.Add(request.NewErrParamRequired("LookbackPeriodInDays")) 8065 } 8066 if s.PaymentOption == nil { 8067 invalidParams.Add(request.NewErrParamRequired("PaymentOption")) 8068 } 8069 if s.SavingsPlansType == nil { 8070 invalidParams.Add(request.NewErrParamRequired("SavingsPlansType")) 8071 } 8072 if s.TermInYears == nil { 8073 invalidParams.Add(request.NewErrParamRequired("TermInYears")) 8074 } 8075 if s.Filter != nil { 8076 if err := s.Filter.Validate(); err != nil { 8077 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 8078 } 8079 } 8080 8081 if invalidParams.Len() > 0 { 8082 return invalidParams 8083 } 8084 return nil 8085} 8086 8087// SetAccountScope sets the AccountScope field's value. 8088func (s *GetSavingsPlansPurchaseRecommendationInput) SetAccountScope(v string) *GetSavingsPlansPurchaseRecommendationInput { 8089 s.AccountScope = &v 8090 return s 8091} 8092 8093// SetFilter sets the Filter field's value. 8094func (s *GetSavingsPlansPurchaseRecommendationInput) SetFilter(v *Expression) *GetSavingsPlansPurchaseRecommendationInput { 8095 s.Filter = v 8096 return s 8097} 8098 8099// SetLookbackPeriodInDays sets the LookbackPeriodInDays field's value. 8100func (s *GetSavingsPlansPurchaseRecommendationInput) SetLookbackPeriodInDays(v string) *GetSavingsPlansPurchaseRecommendationInput { 8101 s.LookbackPeriodInDays = &v 8102 return s 8103} 8104 8105// SetNextPageToken sets the NextPageToken field's value. 8106func (s *GetSavingsPlansPurchaseRecommendationInput) SetNextPageToken(v string) *GetSavingsPlansPurchaseRecommendationInput { 8107 s.NextPageToken = &v 8108 return s 8109} 8110 8111// SetPageSize sets the PageSize field's value. 8112func (s *GetSavingsPlansPurchaseRecommendationInput) SetPageSize(v int64) *GetSavingsPlansPurchaseRecommendationInput { 8113 s.PageSize = &v 8114 return s 8115} 8116 8117// SetPaymentOption sets the PaymentOption field's value. 8118func (s *GetSavingsPlansPurchaseRecommendationInput) SetPaymentOption(v string) *GetSavingsPlansPurchaseRecommendationInput { 8119 s.PaymentOption = &v 8120 return s 8121} 8122 8123// SetSavingsPlansType sets the SavingsPlansType field's value. 8124func (s *GetSavingsPlansPurchaseRecommendationInput) SetSavingsPlansType(v string) *GetSavingsPlansPurchaseRecommendationInput { 8125 s.SavingsPlansType = &v 8126 return s 8127} 8128 8129// SetTermInYears sets the TermInYears field's value. 8130func (s *GetSavingsPlansPurchaseRecommendationInput) SetTermInYears(v string) *GetSavingsPlansPurchaseRecommendationInput { 8131 s.TermInYears = &v 8132 return s 8133} 8134 8135type GetSavingsPlansPurchaseRecommendationOutput struct { 8136 _ struct{} `type:"structure"` 8137 8138 // Information regarding this specific recommendation set. 8139 Metadata *SavingsPlansPurchaseRecommendationMetadata `type:"structure"` 8140 8141 // The token for the next set of retrievable results. AWS provides the token 8142 // when the response from a previous call has more results than the maximum 8143 // page size. 8144 NextPageToken *string `type:"string"` 8145 8146 // Contains your request parameters, Savings Plan Recommendations Summary, and 8147 // Details. 8148 SavingsPlansPurchaseRecommendation *SavingsPlansPurchaseRecommendation `type:"structure"` 8149} 8150 8151// String returns the string representation 8152func (s GetSavingsPlansPurchaseRecommendationOutput) String() string { 8153 return awsutil.Prettify(s) 8154} 8155 8156// GoString returns the string representation 8157func (s GetSavingsPlansPurchaseRecommendationOutput) GoString() string { 8158 return s.String() 8159} 8160 8161// SetMetadata sets the Metadata field's value. 8162func (s *GetSavingsPlansPurchaseRecommendationOutput) SetMetadata(v *SavingsPlansPurchaseRecommendationMetadata) *GetSavingsPlansPurchaseRecommendationOutput { 8163 s.Metadata = v 8164 return s 8165} 8166 8167// SetNextPageToken sets the NextPageToken field's value. 8168func (s *GetSavingsPlansPurchaseRecommendationOutput) SetNextPageToken(v string) *GetSavingsPlansPurchaseRecommendationOutput { 8169 s.NextPageToken = &v 8170 return s 8171} 8172 8173// SetSavingsPlansPurchaseRecommendation sets the SavingsPlansPurchaseRecommendation field's value. 8174func (s *GetSavingsPlansPurchaseRecommendationOutput) SetSavingsPlansPurchaseRecommendation(v *SavingsPlansPurchaseRecommendation) *GetSavingsPlansPurchaseRecommendationOutput { 8175 s.SavingsPlansPurchaseRecommendation = v 8176 return s 8177} 8178 8179type GetSavingsPlansUtilizationDetailsInput struct { 8180 _ struct{} `type:"structure"` 8181 8182 // The data type. 8183 DataType []*string `type:"list"` 8184 8185 // Filters Savings Plans utilization coverage data for active Savings Plans 8186 // dimensions. You can filter data with the following dimensions: 8187 // 8188 // * LINKED_ACCOUNT 8189 // 8190 // * SAVINGS_PLAN_ARN 8191 // 8192 // * REGION 8193 // 8194 // * PAYMENT_OPTION 8195 // 8196 // * INSTANCE_TYPE_FAMILY 8197 // 8198 // GetSavingsPlansUtilizationDetails uses the same Expression (https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_Expression.html) 8199 // object as the other operations, but only AND is supported among each dimension. 8200 Filter *Expression `type:"structure"` 8201 8202 // The number of items to be returned in a response. The default is 20, with 8203 // a minimum value of 1. 8204 MaxResults *int64 `min:"1" type:"integer"` 8205 8206 // The token to retrieve the next set of results. Amazon Web Services provides 8207 // the token when the response from a previous call has more results than the 8208 // maximum page size. 8209 NextToken *string `type:"string"` 8210 8211 // The value by which you want to sort the data. 8212 // 8213 // The following values are supported for Key: 8214 // 8215 // * UtilizationPercentage 8216 // 8217 // * TotalCommitment 8218 // 8219 // * UsedCommitment 8220 // 8221 // * UnusedCommitment 8222 // 8223 // * NetSavings 8224 // 8225 // * AmortizedRecurringCommitment 8226 // 8227 // * AmortizedUpfrontCommitment 8228 // 8229 // Supported values for SortOrder are ASCENDING or DESCENDING. 8230 SortBy *SortDefinition `type:"structure"` 8231 8232 // The time period that you want the usage and costs for. The Start date must 8233 // be within 13 months. The End date must be after the Start date, and before 8234 // the current date. Future dates can't be used as an End date. 8235 // 8236 // TimePeriod is a required field 8237 TimePeriod *DateInterval `type:"structure" required:"true"` 8238} 8239 8240// String returns the string representation 8241func (s GetSavingsPlansUtilizationDetailsInput) String() string { 8242 return awsutil.Prettify(s) 8243} 8244 8245// GoString returns the string representation 8246func (s GetSavingsPlansUtilizationDetailsInput) GoString() string { 8247 return s.String() 8248} 8249 8250// Validate inspects the fields of the type to determine if they are valid. 8251func (s *GetSavingsPlansUtilizationDetailsInput) Validate() error { 8252 invalidParams := request.ErrInvalidParams{Context: "GetSavingsPlansUtilizationDetailsInput"} 8253 if s.MaxResults != nil && *s.MaxResults < 1 { 8254 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 8255 } 8256 if s.TimePeriod == nil { 8257 invalidParams.Add(request.NewErrParamRequired("TimePeriod")) 8258 } 8259 if s.Filter != nil { 8260 if err := s.Filter.Validate(); err != nil { 8261 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 8262 } 8263 } 8264 if s.SortBy != nil { 8265 if err := s.SortBy.Validate(); err != nil { 8266 invalidParams.AddNested("SortBy", err.(request.ErrInvalidParams)) 8267 } 8268 } 8269 if s.TimePeriod != nil { 8270 if err := s.TimePeriod.Validate(); err != nil { 8271 invalidParams.AddNested("TimePeriod", err.(request.ErrInvalidParams)) 8272 } 8273 } 8274 8275 if invalidParams.Len() > 0 { 8276 return invalidParams 8277 } 8278 return nil 8279} 8280 8281// SetDataType sets the DataType field's value. 8282func (s *GetSavingsPlansUtilizationDetailsInput) SetDataType(v []*string) *GetSavingsPlansUtilizationDetailsInput { 8283 s.DataType = v 8284 return s 8285} 8286 8287// SetFilter sets the Filter field's value. 8288func (s *GetSavingsPlansUtilizationDetailsInput) SetFilter(v *Expression) *GetSavingsPlansUtilizationDetailsInput { 8289 s.Filter = v 8290 return s 8291} 8292 8293// SetMaxResults sets the MaxResults field's value. 8294func (s *GetSavingsPlansUtilizationDetailsInput) SetMaxResults(v int64) *GetSavingsPlansUtilizationDetailsInput { 8295 s.MaxResults = &v 8296 return s 8297} 8298 8299// SetNextToken sets the NextToken field's value. 8300func (s *GetSavingsPlansUtilizationDetailsInput) SetNextToken(v string) *GetSavingsPlansUtilizationDetailsInput { 8301 s.NextToken = &v 8302 return s 8303} 8304 8305// SetSortBy sets the SortBy field's value. 8306func (s *GetSavingsPlansUtilizationDetailsInput) SetSortBy(v *SortDefinition) *GetSavingsPlansUtilizationDetailsInput { 8307 s.SortBy = v 8308 return s 8309} 8310 8311// SetTimePeriod sets the TimePeriod field's value. 8312func (s *GetSavingsPlansUtilizationDetailsInput) SetTimePeriod(v *DateInterval) *GetSavingsPlansUtilizationDetailsInput { 8313 s.TimePeriod = v 8314 return s 8315} 8316 8317type GetSavingsPlansUtilizationDetailsOutput struct { 8318 _ struct{} `type:"structure"` 8319 8320 // The token to retrieve the next set of results. Amazon Web Services provides 8321 // the token when the response from a previous call has more results than the 8322 // maximum page size. 8323 NextToken *string `type:"string"` 8324 8325 // Retrieves a single daily or monthly Savings Plans utilization rate and details 8326 // for your account. 8327 // 8328 // SavingsPlansUtilizationDetails is a required field 8329 SavingsPlansUtilizationDetails []*SavingsPlansUtilizationDetail `type:"list" required:"true"` 8330 8331 // The time period of the request. 8332 // 8333 // TimePeriod is a required field 8334 TimePeriod *DateInterval `type:"structure" required:"true"` 8335 8336 // The total Savings Plans utilization, regardless of time period. 8337 Total *SavingsPlansUtilizationAggregates `type:"structure"` 8338} 8339 8340// String returns the string representation 8341func (s GetSavingsPlansUtilizationDetailsOutput) String() string { 8342 return awsutil.Prettify(s) 8343} 8344 8345// GoString returns the string representation 8346func (s GetSavingsPlansUtilizationDetailsOutput) GoString() string { 8347 return s.String() 8348} 8349 8350// SetNextToken sets the NextToken field's value. 8351func (s *GetSavingsPlansUtilizationDetailsOutput) SetNextToken(v string) *GetSavingsPlansUtilizationDetailsOutput { 8352 s.NextToken = &v 8353 return s 8354} 8355 8356// SetSavingsPlansUtilizationDetails sets the SavingsPlansUtilizationDetails field's value. 8357func (s *GetSavingsPlansUtilizationDetailsOutput) SetSavingsPlansUtilizationDetails(v []*SavingsPlansUtilizationDetail) *GetSavingsPlansUtilizationDetailsOutput { 8358 s.SavingsPlansUtilizationDetails = v 8359 return s 8360} 8361 8362// SetTimePeriod sets the TimePeriod field's value. 8363func (s *GetSavingsPlansUtilizationDetailsOutput) SetTimePeriod(v *DateInterval) *GetSavingsPlansUtilizationDetailsOutput { 8364 s.TimePeriod = v 8365 return s 8366} 8367 8368// SetTotal sets the Total field's value. 8369func (s *GetSavingsPlansUtilizationDetailsOutput) SetTotal(v *SavingsPlansUtilizationAggregates) *GetSavingsPlansUtilizationDetailsOutput { 8370 s.Total = v 8371 return s 8372} 8373 8374type GetSavingsPlansUtilizationInput struct { 8375 _ struct{} `type:"structure"` 8376 8377 // Filters Savings Plans utilization coverage data for active Savings Plans 8378 // dimensions. You can filter data with the following dimensions: 8379 // 8380 // * LINKED_ACCOUNT 8381 // 8382 // * SAVINGS_PLAN_ARN 8383 // 8384 // * SAVINGS_PLANS_TYPE 8385 // 8386 // * REGION 8387 // 8388 // * PAYMENT_OPTION 8389 // 8390 // * INSTANCE_TYPE_FAMILY 8391 // 8392 // GetSavingsPlansUtilization uses the same Expression (https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_Expression.html) 8393 // object as the other operations, but only AND is supported among each dimension. 8394 Filter *Expression `type:"structure"` 8395 8396 // The granularity of the Amazon Web Services utillization data for your Savings 8397 // Plans. 8398 // 8399 // The GetSavingsPlansUtilization operation supports only DAILY and MONTHLY 8400 // granularities. 8401 Granularity *string `type:"string" enum:"Granularity"` 8402 8403 // The value by which you want to sort the data. 8404 // 8405 // The following values are supported for Key: 8406 // 8407 // * UtilizationPercentage 8408 // 8409 // * TotalCommitment 8410 // 8411 // * UsedCommitment 8412 // 8413 // * UnusedCommitment 8414 // 8415 // * NetSavings 8416 // 8417 // Supported values for SortOrder are ASCENDING or DESCENDING. 8418 SortBy *SortDefinition `type:"structure"` 8419 8420 // The time period that you want the usage and costs for. The Start date must 8421 // be within 13 months. The End date must be after the Start date, and before 8422 // the current date. Future dates can't be used as an End date. 8423 // 8424 // TimePeriod is a required field 8425 TimePeriod *DateInterval `type:"structure" required:"true"` 8426} 8427 8428// String returns the string representation 8429func (s GetSavingsPlansUtilizationInput) String() string { 8430 return awsutil.Prettify(s) 8431} 8432 8433// GoString returns the string representation 8434func (s GetSavingsPlansUtilizationInput) GoString() string { 8435 return s.String() 8436} 8437 8438// Validate inspects the fields of the type to determine if they are valid. 8439func (s *GetSavingsPlansUtilizationInput) Validate() error { 8440 invalidParams := request.ErrInvalidParams{Context: "GetSavingsPlansUtilizationInput"} 8441 if s.TimePeriod == nil { 8442 invalidParams.Add(request.NewErrParamRequired("TimePeriod")) 8443 } 8444 if s.Filter != nil { 8445 if err := s.Filter.Validate(); err != nil { 8446 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 8447 } 8448 } 8449 if s.SortBy != nil { 8450 if err := s.SortBy.Validate(); err != nil { 8451 invalidParams.AddNested("SortBy", err.(request.ErrInvalidParams)) 8452 } 8453 } 8454 if s.TimePeriod != nil { 8455 if err := s.TimePeriod.Validate(); err != nil { 8456 invalidParams.AddNested("TimePeriod", err.(request.ErrInvalidParams)) 8457 } 8458 } 8459 8460 if invalidParams.Len() > 0 { 8461 return invalidParams 8462 } 8463 return nil 8464} 8465 8466// SetFilter sets the Filter field's value. 8467func (s *GetSavingsPlansUtilizationInput) SetFilter(v *Expression) *GetSavingsPlansUtilizationInput { 8468 s.Filter = v 8469 return s 8470} 8471 8472// SetGranularity sets the Granularity field's value. 8473func (s *GetSavingsPlansUtilizationInput) SetGranularity(v string) *GetSavingsPlansUtilizationInput { 8474 s.Granularity = &v 8475 return s 8476} 8477 8478// SetSortBy sets the SortBy field's value. 8479func (s *GetSavingsPlansUtilizationInput) SetSortBy(v *SortDefinition) *GetSavingsPlansUtilizationInput { 8480 s.SortBy = v 8481 return s 8482} 8483 8484// SetTimePeriod sets the TimePeriod field's value. 8485func (s *GetSavingsPlansUtilizationInput) SetTimePeriod(v *DateInterval) *GetSavingsPlansUtilizationInput { 8486 s.TimePeriod = v 8487 return s 8488} 8489 8490type GetSavingsPlansUtilizationOutput struct { 8491 _ struct{} `type:"structure"` 8492 8493 // The amount of cost/commitment you used your Savings Plans. This allows you 8494 // to specify date ranges. 8495 SavingsPlansUtilizationsByTime []*SavingsPlansUtilizationByTime `type:"list"` 8496 8497 // The total amount of cost/commitment that you used your Savings Plans, regardless 8498 // of date ranges. 8499 // 8500 // Total is a required field 8501 Total *SavingsPlansUtilizationAggregates `type:"structure" required:"true"` 8502} 8503 8504// String returns the string representation 8505func (s GetSavingsPlansUtilizationOutput) String() string { 8506 return awsutil.Prettify(s) 8507} 8508 8509// GoString returns the string representation 8510func (s GetSavingsPlansUtilizationOutput) GoString() string { 8511 return s.String() 8512} 8513 8514// SetSavingsPlansUtilizationsByTime sets the SavingsPlansUtilizationsByTime field's value. 8515func (s *GetSavingsPlansUtilizationOutput) SetSavingsPlansUtilizationsByTime(v []*SavingsPlansUtilizationByTime) *GetSavingsPlansUtilizationOutput { 8516 s.SavingsPlansUtilizationsByTime = v 8517 return s 8518} 8519 8520// SetTotal sets the Total field's value. 8521func (s *GetSavingsPlansUtilizationOutput) SetTotal(v *SavingsPlansUtilizationAggregates) *GetSavingsPlansUtilizationOutput { 8522 s.Total = v 8523 return s 8524} 8525 8526type GetTagsInput struct { 8527 _ struct{} `type:"structure"` 8528 8529 // Use Expression to filter by cost or by usage. There are two patterns: 8530 // 8531 // * Simple dimension values - You can set the dimension name and values 8532 // for the filters that you plan to use. For example, you can filter for 8533 // REGION==us-east-1 OR REGION==us-west-1. For GetRightsizingRecommendation, 8534 // the Region is a full name (for example, REGION==US East (N. Virginia). 8535 // The Expression example looks like: { "Dimensions": { "Key": "REGION", 8536 // "Values": [ "us-east-1", “us-west-1” ] } } The list of dimension values 8537 // are OR'd together to retrieve cost or usage data. You can create Expression 8538 // and DimensionValues objects using either with* methods or set* methods 8539 // in multiple lines. 8540 // 8541 // * Compound dimension values with logical operations - You can use multiple 8542 // Expression types and the logical operators AND/OR/NOT to create a list 8543 // of one or more Expression objects. This allows you to filter on more advanced 8544 // options. For example, you can filter on ((REGION == us-east-1 OR REGION 8545 // == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer). 8546 // The Expression for that looks like this: { "And": [ {"Or": [ {"Dimensions": 8547 // { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": 8548 // { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": 8549 // { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] } Because each 8550 // Expression can have only one operator, the service returns an error if 8551 // more than one is specified. The following example shows an Expression 8552 // object that creates an error. { "And": [ ... ], "DimensionValues": { "Dimension": 8553 // "USAGE_TYPE", "Values": [ "DataTransfer" ] } } 8554 // 8555 // For the GetRightsizingRecommendation action, a combination of OR and NOT 8556 // is not supported. OR is not supported between different dimensions, or dimensions 8557 // and tags. NOT operators aren't supported. Dimensions are also limited to 8558 // LINKED_ACCOUNT, REGION, or RIGHTSIZING_TYPE. 8559 // 8560 // For the GetReservationPurchaseRecommendation action, only NOT is supported. 8561 // AND and OR are not supported. Dimensions are limited to LINKED_ACCOUNT. 8562 Filter *Expression `type:"structure"` 8563 8564 // This field is only used when SortBy is provided in the request. The maximum 8565 // number of objects that to be returned for this request. If MaxResults is 8566 // not specified with SortBy, the request will return 1000 results as the default 8567 // value for this parameter. 8568 MaxResults *int64 `min:"1" type:"integer"` 8569 8570 // The token to retrieve the next set of results. AWS provides the token when 8571 // the response from a previous call has more results than the maximum page 8572 // size. 8573 NextPageToken *string `type:"string"` 8574 8575 // The value that you want to search for. 8576 SearchString *string `type:"string"` 8577 8578 // The value by which you want to sort the data. 8579 // 8580 // The key represents cost and usage metrics. The following values are supported: 8581 // 8582 // * BlendedCost 8583 // 8584 // * UnblendedCost 8585 // 8586 // * AmortizedCost 8587 // 8588 // * NetAmortizedCost 8589 // 8590 // * NetUnblendedCost 8591 // 8592 // * UsageQuantity 8593 // 8594 // * NormalizedUsageAmount 8595 // 8596 // Supported values for SortOrder are ASCENDING or DESCENDING. 8597 // 8598 // When using SortBy, NextPageToken and SearchString are not supported. 8599 SortBy []*SortDefinition `type:"list"` 8600 8601 // The key of the tag that you want to return values for. 8602 TagKey *string `type:"string"` 8603 8604 // The start and end dates for retrieving the dimension values. The start date 8605 // is inclusive, but the end date is exclusive. For example, if start is 2017-01-01 8606 // and end is 2017-05-01, then the cost and usage data is retrieved from 2017-01-01 8607 // up to and including 2017-04-30 but not including 2017-05-01. 8608 // 8609 // TimePeriod is a required field 8610 TimePeriod *DateInterval `type:"structure" required:"true"` 8611} 8612 8613// String returns the string representation 8614func (s GetTagsInput) String() string { 8615 return awsutil.Prettify(s) 8616} 8617 8618// GoString returns the string representation 8619func (s GetTagsInput) GoString() string { 8620 return s.String() 8621} 8622 8623// Validate inspects the fields of the type to determine if they are valid. 8624func (s *GetTagsInput) Validate() error { 8625 invalidParams := request.ErrInvalidParams{Context: "GetTagsInput"} 8626 if s.MaxResults != nil && *s.MaxResults < 1 { 8627 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 8628 } 8629 if s.TimePeriod == nil { 8630 invalidParams.Add(request.NewErrParamRequired("TimePeriod")) 8631 } 8632 if s.Filter != nil { 8633 if err := s.Filter.Validate(); err != nil { 8634 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 8635 } 8636 } 8637 if s.SortBy != nil { 8638 for i, v := range s.SortBy { 8639 if v == nil { 8640 continue 8641 } 8642 if err := v.Validate(); err != nil { 8643 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "SortBy", i), err.(request.ErrInvalidParams)) 8644 } 8645 } 8646 } 8647 if s.TimePeriod != nil { 8648 if err := s.TimePeriod.Validate(); err != nil { 8649 invalidParams.AddNested("TimePeriod", err.(request.ErrInvalidParams)) 8650 } 8651 } 8652 8653 if invalidParams.Len() > 0 { 8654 return invalidParams 8655 } 8656 return nil 8657} 8658 8659// SetFilter sets the Filter field's value. 8660func (s *GetTagsInput) SetFilter(v *Expression) *GetTagsInput { 8661 s.Filter = v 8662 return s 8663} 8664 8665// SetMaxResults sets the MaxResults field's value. 8666func (s *GetTagsInput) SetMaxResults(v int64) *GetTagsInput { 8667 s.MaxResults = &v 8668 return s 8669} 8670 8671// SetNextPageToken sets the NextPageToken field's value. 8672func (s *GetTagsInput) SetNextPageToken(v string) *GetTagsInput { 8673 s.NextPageToken = &v 8674 return s 8675} 8676 8677// SetSearchString sets the SearchString field's value. 8678func (s *GetTagsInput) SetSearchString(v string) *GetTagsInput { 8679 s.SearchString = &v 8680 return s 8681} 8682 8683// SetSortBy sets the SortBy field's value. 8684func (s *GetTagsInput) SetSortBy(v []*SortDefinition) *GetTagsInput { 8685 s.SortBy = v 8686 return s 8687} 8688 8689// SetTagKey sets the TagKey field's value. 8690func (s *GetTagsInput) SetTagKey(v string) *GetTagsInput { 8691 s.TagKey = &v 8692 return s 8693} 8694 8695// SetTimePeriod sets the TimePeriod field's value. 8696func (s *GetTagsInput) SetTimePeriod(v *DateInterval) *GetTagsInput { 8697 s.TimePeriod = v 8698 return s 8699} 8700 8701type GetTagsOutput struct { 8702 _ struct{} `type:"structure"` 8703 8704 // The token for the next set of retrievable results. AWS provides the token 8705 // when the response from a previous call has more results than the maximum 8706 // page size. 8707 NextPageToken *string `type:"string"` 8708 8709 // The number of query results that AWS returns at a time. 8710 // 8711 // ReturnSize is a required field 8712 ReturnSize *int64 `type:"integer" required:"true"` 8713 8714 // The tags that match your request. 8715 // 8716 // Tags is a required field 8717 Tags []*string `type:"list" required:"true"` 8718 8719 // The total number of query results. 8720 // 8721 // TotalSize is a required field 8722 TotalSize *int64 `type:"integer" required:"true"` 8723} 8724 8725// String returns the string representation 8726func (s GetTagsOutput) String() string { 8727 return awsutil.Prettify(s) 8728} 8729 8730// GoString returns the string representation 8731func (s GetTagsOutput) GoString() string { 8732 return s.String() 8733} 8734 8735// SetNextPageToken sets the NextPageToken field's value. 8736func (s *GetTagsOutput) SetNextPageToken(v string) *GetTagsOutput { 8737 s.NextPageToken = &v 8738 return s 8739} 8740 8741// SetReturnSize sets the ReturnSize field's value. 8742func (s *GetTagsOutput) SetReturnSize(v int64) *GetTagsOutput { 8743 s.ReturnSize = &v 8744 return s 8745} 8746 8747// SetTags sets the Tags field's value. 8748func (s *GetTagsOutput) SetTags(v []*string) *GetTagsOutput { 8749 s.Tags = v 8750 return s 8751} 8752 8753// SetTotalSize sets the TotalSize field's value. 8754func (s *GetTagsOutput) SetTotalSize(v int64) *GetTagsOutput { 8755 s.TotalSize = &v 8756 return s 8757} 8758 8759type GetUsageForecastInput struct { 8760 _ struct{} `type:"structure"` 8761 8762 // The filters that you want to use to filter your forecast. Cost Explorer API 8763 // supports all of the Cost Explorer filters. 8764 Filter *Expression `type:"structure"` 8765 8766 // How granular you want the forecast to be. You can get 3 months of DAILY forecasts 8767 // or 12 months of MONTHLY forecasts. 8768 // 8769 // The GetUsageForecast operation supports only DAILY and MONTHLY granularities. 8770 // 8771 // Granularity is a required field 8772 Granularity *string `type:"string" required:"true" enum:"Granularity"` 8773 8774 // Which metric Cost Explorer uses to create your forecast. 8775 // 8776 // Valid values for a GetUsageForecast call are the following: 8777 // 8778 // * USAGE_QUANTITY 8779 // 8780 // * NORMALIZED_USAGE_AMOUNT 8781 // 8782 // Metric is a required field 8783 Metric *string `type:"string" required:"true" enum:"Metric"` 8784 8785 // Cost Explorer always returns the mean forecast as a single point. You can 8786 // request a prediction interval around the mean by specifying a confidence 8787 // level. The higher the confidence level, the more confident Cost Explorer 8788 // is about the actual value falling in the prediction interval. Higher confidence 8789 // levels result in wider prediction intervals. 8790 PredictionIntervalLevel *int64 `min:"51" type:"integer"` 8791 8792 // The start and end dates of the period that you want to retrieve usage forecast 8793 // for. The start date is inclusive, but the end date is exclusive. For example, 8794 // if start is 2017-01-01 and end is 2017-05-01, then the cost and usage data 8795 // is retrieved from 2017-01-01 up to and including 2017-04-30 but not including 8796 // 2017-05-01. The start date must be equal to or later than the current date 8797 // to avoid a validation error. 8798 // 8799 // TimePeriod is a required field 8800 TimePeriod *DateInterval `type:"structure" required:"true"` 8801} 8802 8803// String returns the string representation 8804func (s GetUsageForecastInput) String() string { 8805 return awsutil.Prettify(s) 8806} 8807 8808// GoString returns the string representation 8809func (s GetUsageForecastInput) GoString() string { 8810 return s.String() 8811} 8812 8813// Validate inspects the fields of the type to determine if they are valid. 8814func (s *GetUsageForecastInput) Validate() error { 8815 invalidParams := request.ErrInvalidParams{Context: "GetUsageForecastInput"} 8816 if s.Granularity == nil { 8817 invalidParams.Add(request.NewErrParamRequired("Granularity")) 8818 } 8819 if s.Metric == nil { 8820 invalidParams.Add(request.NewErrParamRequired("Metric")) 8821 } 8822 if s.PredictionIntervalLevel != nil && *s.PredictionIntervalLevel < 51 { 8823 invalidParams.Add(request.NewErrParamMinValue("PredictionIntervalLevel", 51)) 8824 } 8825 if s.TimePeriod == nil { 8826 invalidParams.Add(request.NewErrParamRequired("TimePeriod")) 8827 } 8828 if s.Filter != nil { 8829 if err := s.Filter.Validate(); err != nil { 8830 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 8831 } 8832 } 8833 if s.TimePeriod != nil { 8834 if err := s.TimePeriod.Validate(); err != nil { 8835 invalidParams.AddNested("TimePeriod", err.(request.ErrInvalidParams)) 8836 } 8837 } 8838 8839 if invalidParams.Len() > 0 { 8840 return invalidParams 8841 } 8842 return nil 8843} 8844 8845// SetFilter sets the Filter field's value. 8846func (s *GetUsageForecastInput) SetFilter(v *Expression) *GetUsageForecastInput { 8847 s.Filter = v 8848 return s 8849} 8850 8851// SetGranularity sets the Granularity field's value. 8852func (s *GetUsageForecastInput) SetGranularity(v string) *GetUsageForecastInput { 8853 s.Granularity = &v 8854 return s 8855} 8856 8857// SetMetric sets the Metric field's value. 8858func (s *GetUsageForecastInput) SetMetric(v string) *GetUsageForecastInput { 8859 s.Metric = &v 8860 return s 8861} 8862 8863// SetPredictionIntervalLevel sets the PredictionIntervalLevel field's value. 8864func (s *GetUsageForecastInput) SetPredictionIntervalLevel(v int64) *GetUsageForecastInput { 8865 s.PredictionIntervalLevel = &v 8866 return s 8867} 8868 8869// SetTimePeriod sets the TimePeriod field's value. 8870func (s *GetUsageForecastInput) SetTimePeriod(v *DateInterval) *GetUsageForecastInput { 8871 s.TimePeriod = v 8872 return s 8873} 8874 8875type GetUsageForecastOutput struct { 8876 _ struct{} `type:"structure"` 8877 8878 // The forecasts for your query, in order. For DAILY forecasts, this is a list 8879 // of days. For MONTHLY forecasts, this is a list of months. 8880 ForecastResultsByTime []*ForecastResult `type:"list"` 8881 8882 // How much you're forecasted to use over the forecast period. 8883 Total *MetricValue `type:"structure"` 8884} 8885 8886// String returns the string representation 8887func (s GetUsageForecastOutput) String() string { 8888 return awsutil.Prettify(s) 8889} 8890 8891// GoString returns the string representation 8892func (s GetUsageForecastOutput) GoString() string { 8893 return s.String() 8894} 8895 8896// SetForecastResultsByTime sets the ForecastResultsByTime field's value. 8897func (s *GetUsageForecastOutput) SetForecastResultsByTime(v []*ForecastResult) *GetUsageForecastOutput { 8898 s.ForecastResultsByTime = v 8899 return s 8900} 8901 8902// SetTotal sets the Total field's value. 8903func (s *GetUsageForecastOutput) SetTotal(v *MetricValue) *GetUsageForecastOutput { 8904 s.Total = v 8905 return s 8906} 8907 8908// One level of grouped data in the results. 8909type Group struct { 8910 _ struct{} `type:"structure"` 8911 8912 // The keys that are included in this group. 8913 Keys []*string `type:"list"` 8914 8915 // The metrics that are included in this group. 8916 Metrics map[string]*MetricValue `type:"map"` 8917} 8918 8919// String returns the string representation 8920func (s Group) String() string { 8921 return awsutil.Prettify(s) 8922} 8923 8924// GoString returns the string representation 8925func (s Group) GoString() string { 8926 return s.String() 8927} 8928 8929// SetKeys sets the Keys field's value. 8930func (s *Group) SetKeys(v []*string) *Group { 8931 s.Keys = v 8932 return s 8933} 8934 8935// SetMetrics sets the Metrics field's value. 8936func (s *Group) SetMetrics(v map[string]*MetricValue) *Group { 8937 s.Metrics = v 8938 return s 8939} 8940 8941// Represents a group when you specify a group by criteria or in the response 8942// to a query with a specific grouping. 8943type GroupDefinition struct { 8944 _ struct{} `type:"structure"` 8945 8946 // The string that represents a key for a specified group. 8947 Key *string `type:"string"` 8948 8949 // The string that represents the type of group. 8950 Type *string `type:"string" enum:"GroupDefinitionType"` 8951} 8952 8953// String returns the string representation 8954func (s GroupDefinition) String() string { 8955 return awsutil.Prettify(s) 8956} 8957 8958// GoString returns the string representation 8959func (s GroupDefinition) GoString() string { 8960 return s.String() 8961} 8962 8963// SetKey sets the Key field's value. 8964func (s *GroupDefinition) SetKey(v string) *GroupDefinition { 8965 s.Key = &v 8966 return s 8967} 8968 8969// SetType sets the Type field's value. 8970func (s *GroupDefinition) SetType(v string) *GroupDefinition { 8971 s.Type = &v 8972 return s 8973} 8974 8975// The anomaly's dollar value. 8976type Impact struct { 8977 _ struct{} `type:"structure"` 8978 8979 // The maximum dollar value observed for an anomaly. 8980 // 8981 // MaxImpact is a required field 8982 MaxImpact *float64 `type:"double" required:"true"` 8983 8984 // The cumulative dollar value observed for an anomaly. 8985 TotalImpact *float64 `type:"double"` 8986} 8987 8988// String returns the string representation 8989func (s Impact) String() string { 8990 return awsutil.Prettify(s) 8991} 8992 8993// GoString returns the string representation 8994func (s Impact) GoString() string { 8995 return s.String() 8996} 8997 8998// SetMaxImpact sets the MaxImpact field's value. 8999func (s *Impact) SetMaxImpact(v float64) *Impact { 9000 s.MaxImpact = &v 9001 return s 9002} 9003 9004// SetTotalImpact sets the TotalImpact field's value. 9005func (s *Impact) SetTotalImpact(v float64) *Impact { 9006 s.TotalImpact = &v 9007 return s 9008} 9009 9010// Details about the instances that AWS recommends that you purchase. 9011type InstanceDetails struct { 9012 _ struct{} `type:"structure"` 9013 9014 // The Amazon EC2 instances that AWS recommends that you purchase. 9015 EC2InstanceDetails *EC2InstanceDetails `type:"structure"` 9016 9017 // The Amazon ES instances that AWS recommends that you purchase. 9018 ESInstanceDetails *ESInstanceDetails `type:"structure"` 9019 9020 // The ElastiCache instances that AWS recommends that you purchase. 9021 ElastiCacheInstanceDetails *ElastiCacheInstanceDetails `type:"structure"` 9022 9023 // The Amazon RDS instances that AWS recommends that you purchase. 9024 RDSInstanceDetails *RDSInstanceDetails `type:"structure"` 9025 9026 // The Amazon Redshift instances that AWS recommends that you purchase. 9027 RedshiftInstanceDetails *RedshiftInstanceDetails `type:"structure"` 9028} 9029 9030// String returns the string representation 9031func (s InstanceDetails) String() string { 9032 return awsutil.Prettify(s) 9033} 9034 9035// GoString returns the string representation 9036func (s InstanceDetails) GoString() string { 9037 return s.String() 9038} 9039 9040// SetEC2InstanceDetails sets the EC2InstanceDetails field's value. 9041func (s *InstanceDetails) SetEC2InstanceDetails(v *EC2InstanceDetails) *InstanceDetails { 9042 s.EC2InstanceDetails = v 9043 return s 9044} 9045 9046// SetESInstanceDetails sets the ESInstanceDetails field's value. 9047func (s *InstanceDetails) SetESInstanceDetails(v *ESInstanceDetails) *InstanceDetails { 9048 s.ESInstanceDetails = v 9049 return s 9050} 9051 9052// SetElastiCacheInstanceDetails sets the ElastiCacheInstanceDetails field's value. 9053func (s *InstanceDetails) SetElastiCacheInstanceDetails(v *ElastiCacheInstanceDetails) *InstanceDetails { 9054 s.ElastiCacheInstanceDetails = v 9055 return s 9056} 9057 9058// SetRDSInstanceDetails sets the RDSInstanceDetails field's value. 9059func (s *InstanceDetails) SetRDSInstanceDetails(v *RDSInstanceDetails) *InstanceDetails { 9060 s.RDSInstanceDetails = v 9061 return s 9062} 9063 9064// SetRedshiftInstanceDetails sets the RedshiftInstanceDetails field's value. 9065func (s *InstanceDetails) SetRedshiftInstanceDetails(v *RedshiftInstanceDetails) *InstanceDetails { 9066 s.RedshiftInstanceDetails = v 9067 return s 9068} 9069 9070// The pagination token is invalid. Try again without a pagination token. 9071type InvalidNextTokenException struct { 9072 _ struct{} `type:"structure"` 9073 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 9074 9075 Message_ *string `locationName:"Message" type:"string"` 9076} 9077 9078// String returns the string representation 9079func (s InvalidNextTokenException) String() string { 9080 return awsutil.Prettify(s) 9081} 9082 9083// GoString returns the string representation 9084func (s InvalidNextTokenException) GoString() string { 9085 return s.String() 9086} 9087 9088func newErrorInvalidNextTokenException(v protocol.ResponseMetadata) error { 9089 return &InvalidNextTokenException{ 9090 RespMetadata: v, 9091 } 9092} 9093 9094// Code returns the exception type name. 9095func (s *InvalidNextTokenException) Code() string { 9096 return "InvalidNextTokenException" 9097} 9098 9099// Message returns the exception's message. 9100func (s *InvalidNextTokenException) Message() string { 9101 if s.Message_ != nil { 9102 return *s.Message_ 9103 } 9104 return "" 9105} 9106 9107// OrigErr always returns nil, satisfies awserr.Error interface. 9108func (s *InvalidNextTokenException) OrigErr() error { 9109 return nil 9110} 9111 9112func (s *InvalidNextTokenException) Error() string { 9113 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 9114} 9115 9116// Status code returns the HTTP status code for the request's response error. 9117func (s *InvalidNextTokenException) StatusCode() int { 9118 return s.RespMetadata.StatusCode 9119} 9120 9121// RequestID returns the service's response RequestID for request. 9122func (s *InvalidNextTokenException) RequestID() string { 9123 return s.RespMetadata.RequestID 9124} 9125 9126// You made too many calls in a short period of time. Try again later. 9127type LimitExceededException struct { 9128 _ struct{} `type:"structure"` 9129 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 9130 9131 Message_ *string `locationName:"Message" type:"string"` 9132} 9133 9134// String returns the string representation 9135func (s LimitExceededException) String() string { 9136 return awsutil.Prettify(s) 9137} 9138 9139// GoString returns the string representation 9140func (s LimitExceededException) GoString() string { 9141 return s.String() 9142} 9143 9144func newErrorLimitExceededException(v protocol.ResponseMetadata) error { 9145 return &LimitExceededException{ 9146 RespMetadata: v, 9147 } 9148} 9149 9150// Code returns the exception type name. 9151func (s *LimitExceededException) Code() string { 9152 return "LimitExceededException" 9153} 9154 9155// Message returns the exception's message. 9156func (s *LimitExceededException) Message() string { 9157 if s.Message_ != nil { 9158 return *s.Message_ 9159 } 9160 return "" 9161} 9162 9163// OrigErr always returns nil, satisfies awserr.Error interface. 9164func (s *LimitExceededException) OrigErr() error { 9165 return nil 9166} 9167 9168func (s *LimitExceededException) Error() string { 9169 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 9170} 9171 9172// Status code returns the HTTP status code for the request's response error. 9173func (s *LimitExceededException) StatusCode() int { 9174 return s.RespMetadata.StatusCode 9175} 9176 9177// RequestID returns the service's response RequestID for request. 9178func (s *LimitExceededException) RequestID() string { 9179 return s.RespMetadata.RequestID 9180} 9181 9182type ListCostCategoryDefinitionsInput struct { 9183 _ struct{} `type:"structure"` 9184 9185 // The date when the Cost Category was effective. 9186 EffectiveOn *string `min:"20" type:"string"` 9187 9188 // The number of entries a paginated response contains. 9189 MaxResults *int64 `min:"1" type:"integer"` 9190 9191 // The token to retrieve the next set of results. Amazon Web Services provides 9192 // the token when the response from a previous call has more results than the 9193 // maximum page size. 9194 NextToken *string `type:"string"` 9195} 9196 9197// String returns the string representation 9198func (s ListCostCategoryDefinitionsInput) String() string { 9199 return awsutil.Prettify(s) 9200} 9201 9202// GoString returns the string representation 9203func (s ListCostCategoryDefinitionsInput) GoString() string { 9204 return s.String() 9205} 9206 9207// Validate inspects the fields of the type to determine if they are valid. 9208func (s *ListCostCategoryDefinitionsInput) Validate() error { 9209 invalidParams := request.ErrInvalidParams{Context: "ListCostCategoryDefinitionsInput"} 9210 if s.EffectiveOn != nil && len(*s.EffectiveOn) < 20 { 9211 invalidParams.Add(request.NewErrParamMinLen("EffectiveOn", 20)) 9212 } 9213 if s.MaxResults != nil && *s.MaxResults < 1 { 9214 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 9215 } 9216 9217 if invalidParams.Len() > 0 { 9218 return invalidParams 9219 } 9220 return nil 9221} 9222 9223// SetEffectiveOn sets the EffectiveOn field's value. 9224func (s *ListCostCategoryDefinitionsInput) SetEffectiveOn(v string) *ListCostCategoryDefinitionsInput { 9225 s.EffectiveOn = &v 9226 return s 9227} 9228 9229// SetMaxResults sets the MaxResults field's value. 9230func (s *ListCostCategoryDefinitionsInput) SetMaxResults(v int64) *ListCostCategoryDefinitionsInput { 9231 s.MaxResults = &v 9232 return s 9233} 9234 9235// SetNextToken sets the NextToken field's value. 9236func (s *ListCostCategoryDefinitionsInput) SetNextToken(v string) *ListCostCategoryDefinitionsInput { 9237 s.NextToken = &v 9238 return s 9239} 9240 9241type ListCostCategoryDefinitionsOutput struct { 9242 _ struct{} `type:"structure"` 9243 9244 // A reference to a Cost Category containing enough information to identify 9245 // the Cost Category. 9246 CostCategoryReferences []*CostCategoryReference `type:"list"` 9247 9248 // The token to retrieve the next set of results. Amazon Web Services provides 9249 // the token when the response from a previous call has more results than the 9250 // maximum page size. 9251 NextToken *string `type:"string"` 9252} 9253 9254// String returns the string representation 9255func (s ListCostCategoryDefinitionsOutput) String() string { 9256 return awsutil.Prettify(s) 9257} 9258 9259// GoString returns the string representation 9260func (s ListCostCategoryDefinitionsOutput) GoString() string { 9261 return s.String() 9262} 9263 9264// SetCostCategoryReferences sets the CostCategoryReferences field's value. 9265func (s *ListCostCategoryDefinitionsOutput) SetCostCategoryReferences(v []*CostCategoryReference) *ListCostCategoryDefinitionsOutput { 9266 s.CostCategoryReferences = v 9267 return s 9268} 9269 9270// SetNextToken sets the NextToken field's value. 9271func (s *ListCostCategoryDefinitionsOutput) SetNextToken(v string) *ListCostCategoryDefinitionsOutput { 9272 s.NextToken = &v 9273 return s 9274} 9275 9276// The aggregated value for a metric. 9277type MetricValue struct { 9278 _ struct{} `type:"structure"` 9279 9280 // The actual number that represents the metric. 9281 Amount *string `type:"string"` 9282 9283 // The unit that the metric is given in. 9284 Unit *string `type:"string"` 9285} 9286 9287// String returns the string representation 9288func (s MetricValue) String() string { 9289 return awsutil.Prettify(s) 9290} 9291 9292// GoString returns the string representation 9293func (s MetricValue) GoString() string { 9294 return s.String() 9295} 9296 9297// SetAmount sets the Amount field's value. 9298func (s *MetricValue) SetAmount(v string) *MetricValue { 9299 s.Amount = &v 9300 return s 9301} 9302 9303// SetUnit sets the Unit field's value. 9304func (s *MetricValue) SetUnit(v string) *MetricValue { 9305 s.Unit = &v 9306 return s 9307} 9308 9309// Details on the modification recommendation. 9310type ModifyRecommendationDetail struct { 9311 _ struct{} `type:"structure"` 9312 9313 // Identifies whether this instance type is the AWS default recommendation. 9314 TargetInstances []*TargetInstance `type:"list"` 9315} 9316 9317// String returns the string representation 9318func (s ModifyRecommendationDetail) String() string { 9319 return awsutil.Prettify(s) 9320} 9321 9322// GoString returns the string representation 9323func (s ModifyRecommendationDetail) GoString() string { 9324 return s.String() 9325} 9326 9327// SetTargetInstances sets the TargetInstances field's value. 9328func (s *ModifyRecommendationDetail) SetTargetInstances(v []*TargetInstance) *ModifyRecommendationDetail { 9329 s.TargetInstances = v 9330 return s 9331} 9332 9333type ProvideAnomalyFeedbackInput struct { 9334 _ struct{} `type:"structure"` 9335 9336 // A cost anomaly ID. 9337 // 9338 // AnomalyId is a required field 9339 AnomalyId *string `type:"string" required:"true"` 9340 9341 // Describes whether the cost anomaly was a planned activity or you considered 9342 // it an anomaly. 9343 // 9344 // Feedback is a required field 9345 Feedback *string `type:"string" required:"true" enum:"AnomalyFeedbackType"` 9346} 9347 9348// String returns the string representation 9349func (s ProvideAnomalyFeedbackInput) String() string { 9350 return awsutil.Prettify(s) 9351} 9352 9353// GoString returns the string representation 9354func (s ProvideAnomalyFeedbackInput) GoString() string { 9355 return s.String() 9356} 9357 9358// Validate inspects the fields of the type to determine if they are valid. 9359func (s *ProvideAnomalyFeedbackInput) Validate() error { 9360 invalidParams := request.ErrInvalidParams{Context: "ProvideAnomalyFeedbackInput"} 9361 if s.AnomalyId == nil { 9362 invalidParams.Add(request.NewErrParamRequired("AnomalyId")) 9363 } 9364 if s.Feedback == nil { 9365 invalidParams.Add(request.NewErrParamRequired("Feedback")) 9366 } 9367 9368 if invalidParams.Len() > 0 { 9369 return invalidParams 9370 } 9371 return nil 9372} 9373 9374// SetAnomalyId sets the AnomalyId field's value. 9375func (s *ProvideAnomalyFeedbackInput) SetAnomalyId(v string) *ProvideAnomalyFeedbackInput { 9376 s.AnomalyId = &v 9377 return s 9378} 9379 9380// SetFeedback sets the Feedback field's value. 9381func (s *ProvideAnomalyFeedbackInput) SetFeedback(v string) *ProvideAnomalyFeedbackInput { 9382 s.Feedback = &v 9383 return s 9384} 9385 9386type ProvideAnomalyFeedbackOutput struct { 9387 _ struct{} `type:"structure"` 9388 9389 // The ID of the modified cost anomaly. 9390 // 9391 // AnomalyId is a required field 9392 AnomalyId *string `type:"string" required:"true"` 9393} 9394 9395// String returns the string representation 9396func (s ProvideAnomalyFeedbackOutput) String() string { 9397 return awsutil.Prettify(s) 9398} 9399 9400// GoString returns the string representation 9401func (s ProvideAnomalyFeedbackOutput) GoString() string { 9402 return s.String() 9403} 9404 9405// SetAnomalyId sets the AnomalyId field's value. 9406func (s *ProvideAnomalyFeedbackOutput) SetAnomalyId(v string) *ProvideAnomalyFeedbackOutput { 9407 s.AnomalyId = &v 9408 return s 9409} 9410 9411// Details about the Amazon RDS instances that AWS recommends that you purchase. 9412type RDSInstanceDetails struct { 9413 _ struct{} `type:"structure"` 9414 9415 // Whether the recommendation is for a current-generation instance. 9416 CurrentGeneration *bool `type:"boolean"` 9417 9418 // The database edition that the recommended reservation supports. 9419 DatabaseEdition *string `type:"string"` 9420 9421 // The database engine that the recommended reservation supports. 9422 DatabaseEngine *string `type:"string"` 9423 9424 // Whether the recommendation is for a reservation in a single Availability 9425 // Zone or a reservation with a backup in a second Availability Zone. 9426 DeploymentOption *string `type:"string"` 9427 9428 // The instance family of the recommended reservation. 9429 Family *string `type:"string"` 9430 9431 // The type of instance that AWS recommends. 9432 InstanceType *string `type:"string"` 9433 9434 // The license model that the recommended reservation supports. 9435 LicenseModel *string `type:"string"` 9436 9437 // The AWS Region of the recommended reservation. 9438 Region *string `type:"string"` 9439 9440 // Whether the recommended reservation is size flexible. 9441 SizeFlexEligible *bool `type:"boolean"` 9442} 9443 9444// String returns the string representation 9445func (s RDSInstanceDetails) String() string { 9446 return awsutil.Prettify(s) 9447} 9448 9449// GoString returns the string representation 9450func (s RDSInstanceDetails) GoString() string { 9451 return s.String() 9452} 9453 9454// SetCurrentGeneration sets the CurrentGeneration field's value. 9455func (s *RDSInstanceDetails) SetCurrentGeneration(v bool) *RDSInstanceDetails { 9456 s.CurrentGeneration = &v 9457 return s 9458} 9459 9460// SetDatabaseEdition sets the DatabaseEdition field's value. 9461func (s *RDSInstanceDetails) SetDatabaseEdition(v string) *RDSInstanceDetails { 9462 s.DatabaseEdition = &v 9463 return s 9464} 9465 9466// SetDatabaseEngine sets the DatabaseEngine field's value. 9467func (s *RDSInstanceDetails) SetDatabaseEngine(v string) *RDSInstanceDetails { 9468 s.DatabaseEngine = &v 9469 return s 9470} 9471 9472// SetDeploymentOption sets the DeploymentOption field's value. 9473func (s *RDSInstanceDetails) SetDeploymentOption(v string) *RDSInstanceDetails { 9474 s.DeploymentOption = &v 9475 return s 9476} 9477 9478// SetFamily sets the Family field's value. 9479func (s *RDSInstanceDetails) SetFamily(v string) *RDSInstanceDetails { 9480 s.Family = &v 9481 return s 9482} 9483 9484// SetInstanceType sets the InstanceType field's value. 9485func (s *RDSInstanceDetails) SetInstanceType(v string) *RDSInstanceDetails { 9486 s.InstanceType = &v 9487 return s 9488} 9489 9490// SetLicenseModel sets the LicenseModel field's value. 9491func (s *RDSInstanceDetails) SetLicenseModel(v string) *RDSInstanceDetails { 9492 s.LicenseModel = &v 9493 return s 9494} 9495 9496// SetRegion sets the Region field's value. 9497func (s *RDSInstanceDetails) SetRegion(v string) *RDSInstanceDetails { 9498 s.Region = &v 9499 return s 9500} 9501 9502// SetSizeFlexEligible sets the SizeFlexEligible field's value. 9503func (s *RDSInstanceDetails) SetSizeFlexEligible(v bool) *RDSInstanceDetails { 9504 s.SizeFlexEligible = &v 9505 return s 9506} 9507 9508// Details about the Amazon Redshift instances that AWS recommends that you 9509// purchase. 9510type RedshiftInstanceDetails struct { 9511 _ struct{} `type:"structure"` 9512 9513 // Whether the recommendation is for a current-generation instance. 9514 CurrentGeneration *bool `type:"boolean"` 9515 9516 // The instance family of the recommended reservation. 9517 Family *string `type:"string"` 9518 9519 // The type of node that AWS recommends. 9520 NodeType *string `type:"string"` 9521 9522 // The AWS Region of the recommended reservation. 9523 Region *string `type:"string"` 9524 9525 // Whether the recommended reservation is size flexible. 9526 SizeFlexEligible *bool `type:"boolean"` 9527} 9528 9529// String returns the string representation 9530func (s RedshiftInstanceDetails) String() string { 9531 return awsutil.Prettify(s) 9532} 9533 9534// GoString returns the string representation 9535func (s RedshiftInstanceDetails) GoString() string { 9536 return s.String() 9537} 9538 9539// SetCurrentGeneration sets the CurrentGeneration field's value. 9540func (s *RedshiftInstanceDetails) SetCurrentGeneration(v bool) *RedshiftInstanceDetails { 9541 s.CurrentGeneration = &v 9542 return s 9543} 9544 9545// SetFamily sets the Family field's value. 9546func (s *RedshiftInstanceDetails) SetFamily(v string) *RedshiftInstanceDetails { 9547 s.Family = &v 9548 return s 9549} 9550 9551// SetNodeType sets the NodeType field's value. 9552func (s *RedshiftInstanceDetails) SetNodeType(v string) *RedshiftInstanceDetails { 9553 s.NodeType = &v 9554 return s 9555} 9556 9557// SetRegion sets the Region field's value. 9558func (s *RedshiftInstanceDetails) SetRegion(v string) *RedshiftInstanceDetails { 9559 s.Region = &v 9560 return s 9561} 9562 9563// SetSizeFlexEligible sets the SizeFlexEligible field's value. 9564func (s *RedshiftInstanceDetails) SetSizeFlexEligible(v bool) *RedshiftInstanceDetails { 9565 s.SizeFlexEligible = &v 9566 return s 9567} 9568 9569// Your request parameters changed between pages. Try again with the old parameters 9570// or without a pagination token. 9571type RequestChangedException struct { 9572 _ struct{} `type:"structure"` 9573 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 9574 9575 Message_ *string `locationName:"Message" type:"string"` 9576} 9577 9578// String returns the string representation 9579func (s RequestChangedException) String() string { 9580 return awsutil.Prettify(s) 9581} 9582 9583// GoString returns the string representation 9584func (s RequestChangedException) GoString() string { 9585 return s.String() 9586} 9587 9588func newErrorRequestChangedException(v protocol.ResponseMetadata) error { 9589 return &RequestChangedException{ 9590 RespMetadata: v, 9591 } 9592} 9593 9594// Code returns the exception type name. 9595func (s *RequestChangedException) Code() string { 9596 return "RequestChangedException" 9597} 9598 9599// Message returns the exception's message. 9600func (s *RequestChangedException) Message() string { 9601 if s.Message_ != nil { 9602 return *s.Message_ 9603 } 9604 return "" 9605} 9606 9607// OrigErr always returns nil, satisfies awserr.Error interface. 9608func (s *RequestChangedException) OrigErr() error { 9609 return nil 9610} 9611 9612func (s *RequestChangedException) Error() string { 9613 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 9614} 9615 9616// Status code returns the HTTP status code for the request's response error. 9617func (s *RequestChangedException) StatusCode() int { 9618 return s.RespMetadata.StatusCode 9619} 9620 9621// RequestID returns the service's response RequestID for request. 9622func (s *RequestChangedException) RequestID() string { 9623 return s.RespMetadata.RequestID 9624} 9625 9626// The aggregated numbers for your reservation usage. 9627type ReservationAggregates struct { 9628 _ struct{} `type:"structure"` 9629 9630 // The monthly cost of your reservation, amortized over the reservation period. 9631 AmortizedRecurringFee *string `type:"string"` 9632 9633 // The upfront cost of your reservation, amortized over the reservation period. 9634 AmortizedUpfrontFee *string `type:"string"` 9635 9636 // How much you saved due to purchasing and utilizing reservation. AWS calculates 9637 // this by subtracting TotalAmortizedFee from OnDemandCostOfRIHoursUsed. 9638 NetRISavings *string `type:"string"` 9639 9640 // How much your reservation would cost if charged On-Demand rates. 9641 OnDemandCostOfRIHoursUsed *string `type:"string"` 9642 9643 // How many reservation hours that you purchased. 9644 PurchasedHours *string `type:"string"` 9645 9646 // How many Amazon EC2 reservation hours that you purchased, converted to normalized 9647 // units. Normalized units are available only for Amazon EC2 usage after November 9648 // 11, 2017. 9649 PurchasedUnits *string `type:"string"` 9650 9651 // The cost of unused hours for your reservation. 9652 RICostForUnusedHours *string `type:"string"` 9653 9654 // The realized savings due to purchasing and using a reservation. 9655 RealizedSavings *string `type:"string"` 9656 9657 // The total number of reservation hours that you used. 9658 TotalActualHours *string `type:"string"` 9659 9660 // The total number of Amazon EC2 reservation hours that you used, converted 9661 // to normalized units. Normalized units are available only for Amazon EC2 usage 9662 // after November 11, 2017. 9663 TotalActualUnits *string `type:"string"` 9664 9665 // The total cost of your reservation, amortized over the reservation period. 9666 TotalAmortizedFee *string `type:"string"` 9667 9668 // How much you could save if you use your entire reservation. 9669 TotalPotentialRISavings *string `type:"string"` 9670 9671 // The unrealized savings due to purchasing and using a reservation. 9672 UnrealizedSavings *string `type:"string"` 9673 9674 // The number of reservation hours that you didn't use. 9675 UnusedHours *string `type:"string"` 9676 9677 // The number of Amazon EC2 reservation hours that you didn't use, converted 9678 // to normalized units. Normalized units are available only for Amazon EC2 usage 9679 // after November 11, 2017. 9680 UnusedUnits *string `type:"string"` 9681 9682 // The percentage of reservation time that you used. 9683 UtilizationPercentage *string `type:"string"` 9684 9685 // The percentage of Amazon EC2 reservation time that you used, converted to 9686 // normalized units. Normalized units are available only for Amazon EC2 usage 9687 // after November 11, 2017. 9688 UtilizationPercentageInUnits *string `type:"string"` 9689} 9690 9691// String returns the string representation 9692func (s ReservationAggregates) String() string { 9693 return awsutil.Prettify(s) 9694} 9695 9696// GoString returns the string representation 9697func (s ReservationAggregates) GoString() string { 9698 return s.String() 9699} 9700 9701// SetAmortizedRecurringFee sets the AmortizedRecurringFee field's value. 9702func (s *ReservationAggregates) SetAmortizedRecurringFee(v string) *ReservationAggregates { 9703 s.AmortizedRecurringFee = &v 9704 return s 9705} 9706 9707// SetAmortizedUpfrontFee sets the AmortizedUpfrontFee field's value. 9708func (s *ReservationAggregates) SetAmortizedUpfrontFee(v string) *ReservationAggregates { 9709 s.AmortizedUpfrontFee = &v 9710 return s 9711} 9712 9713// SetNetRISavings sets the NetRISavings field's value. 9714func (s *ReservationAggregates) SetNetRISavings(v string) *ReservationAggregates { 9715 s.NetRISavings = &v 9716 return s 9717} 9718 9719// SetOnDemandCostOfRIHoursUsed sets the OnDemandCostOfRIHoursUsed field's value. 9720func (s *ReservationAggregates) SetOnDemandCostOfRIHoursUsed(v string) *ReservationAggregates { 9721 s.OnDemandCostOfRIHoursUsed = &v 9722 return s 9723} 9724 9725// SetPurchasedHours sets the PurchasedHours field's value. 9726func (s *ReservationAggregates) SetPurchasedHours(v string) *ReservationAggregates { 9727 s.PurchasedHours = &v 9728 return s 9729} 9730 9731// SetPurchasedUnits sets the PurchasedUnits field's value. 9732func (s *ReservationAggregates) SetPurchasedUnits(v string) *ReservationAggregates { 9733 s.PurchasedUnits = &v 9734 return s 9735} 9736 9737// SetRICostForUnusedHours sets the RICostForUnusedHours field's value. 9738func (s *ReservationAggregates) SetRICostForUnusedHours(v string) *ReservationAggregates { 9739 s.RICostForUnusedHours = &v 9740 return s 9741} 9742 9743// SetRealizedSavings sets the RealizedSavings field's value. 9744func (s *ReservationAggregates) SetRealizedSavings(v string) *ReservationAggregates { 9745 s.RealizedSavings = &v 9746 return s 9747} 9748 9749// SetTotalActualHours sets the TotalActualHours field's value. 9750func (s *ReservationAggregates) SetTotalActualHours(v string) *ReservationAggregates { 9751 s.TotalActualHours = &v 9752 return s 9753} 9754 9755// SetTotalActualUnits sets the TotalActualUnits field's value. 9756func (s *ReservationAggregates) SetTotalActualUnits(v string) *ReservationAggregates { 9757 s.TotalActualUnits = &v 9758 return s 9759} 9760 9761// SetTotalAmortizedFee sets the TotalAmortizedFee field's value. 9762func (s *ReservationAggregates) SetTotalAmortizedFee(v string) *ReservationAggregates { 9763 s.TotalAmortizedFee = &v 9764 return s 9765} 9766 9767// SetTotalPotentialRISavings sets the TotalPotentialRISavings field's value. 9768func (s *ReservationAggregates) SetTotalPotentialRISavings(v string) *ReservationAggregates { 9769 s.TotalPotentialRISavings = &v 9770 return s 9771} 9772 9773// SetUnrealizedSavings sets the UnrealizedSavings field's value. 9774func (s *ReservationAggregates) SetUnrealizedSavings(v string) *ReservationAggregates { 9775 s.UnrealizedSavings = &v 9776 return s 9777} 9778 9779// SetUnusedHours sets the UnusedHours field's value. 9780func (s *ReservationAggregates) SetUnusedHours(v string) *ReservationAggregates { 9781 s.UnusedHours = &v 9782 return s 9783} 9784 9785// SetUnusedUnits sets the UnusedUnits field's value. 9786func (s *ReservationAggregates) SetUnusedUnits(v string) *ReservationAggregates { 9787 s.UnusedUnits = &v 9788 return s 9789} 9790 9791// SetUtilizationPercentage sets the UtilizationPercentage field's value. 9792func (s *ReservationAggregates) SetUtilizationPercentage(v string) *ReservationAggregates { 9793 s.UtilizationPercentage = &v 9794 return s 9795} 9796 9797// SetUtilizationPercentageInUnits sets the UtilizationPercentageInUnits field's value. 9798func (s *ReservationAggregates) SetUtilizationPercentageInUnits(v string) *ReservationAggregates { 9799 s.UtilizationPercentageInUnits = &v 9800 return s 9801} 9802 9803// A group of reservations that share a set of attributes. 9804type ReservationCoverageGroup struct { 9805 _ struct{} `type:"structure"` 9806 9807 // The attributes for this group of reservations. 9808 Attributes map[string]*string `type:"map"` 9809 9810 // How much instance usage this group of reservations covered. 9811 Coverage *Coverage `type:"structure"` 9812} 9813 9814// String returns the string representation 9815func (s ReservationCoverageGroup) String() string { 9816 return awsutil.Prettify(s) 9817} 9818 9819// GoString returns the string representation 9820func (s ReservationCoverageGroup) GoString() string { 9821 return s.String() 9822} 9823 9824// SetAttributes sets the Attributes field's value. 9825func (s *ReservationCoverageGroup) SetAttributes(v map[string]*string) *ReservationCoverageGroup { 9826 s.Attributes = v 9827 return s 9828} 9829 9830// SetCoverage sets the Coverage field's value. 9831func (s *ReservationCoverageGroup) SetCoverage(v *Coverage) *ReservationCoverageGroup { 9832 s.Coverage = v 9833 return s 9834} 9835 9836// A specific reservation that AWS recommends for purchase. 9837type ReservationPurchaseRecommendation struct { 9838 _ struct{} `type:"structure"` 9839 9840 // The account scope that AWS recommends that you purchase this instance for. 9841 // For example, you can purchase this reservation for an entire organization 9842 // in AWS Organizations. 9843 AccountScope *string `type:"string" enum:"AccountScope"` 9844 9845 // How many days of previous usage that AWS considers when making this recommendation. 9846 LookbackPeriodInDays *string `type:"string" enum:"LookbackPeriodInDays"` 9847 9848 // The payment option for the reservation. For example, AllUpfront or NoUpfront. 9849 PaymentOption *string `type:"string" enum:"PaymentOption"` 9850 9851 // Details about the recommended purchases. 9852 RecommendationDetails []*ReservationPurchaseRecommendationDetail `type:"list"` 9853 9854 // A summary about the recommended purchase. 9855 RecommendationSummary *ReservationPurchaseRecommendationSummary `type:"structure"` 9856 9857 // Hardware specifications for the service that you want recommendations for. 9858 ServiceSpecification *ServiceSpecification `type:"structure"` 9859 9860 // The term of the reservation that you want recommendations for, in years. 9861 TermInYears *string `type:"string" enum:"TermInYears"` 9862} 9863 9864// String returns the string representation 9865func (s ReservationPurchaseRecommendation) String() string { 9866 return awsutil.Prettify(s) 9867} 9868 9869// GoString returns the string representation 9870func (s ReservationPurchaseRecommendation) GoString() string { 9871 return s.String() 9872} 9873 9874// SetAccountScope sets the AccountScope field's value. 9875func (s *ReservationPurchaseRecommendation) SetAccountScope(v string) *ReservationPurchaseRecommendation { 9876 s.AccountScope = &v 9877 return s 9878} 9879 9880// SetLookbackPeriodInDays sets the LookbackPeriodInDays field's value. 9881func (s *ReservationPurchaseRecommendation) SetLookbackPeriodInDays(v string) *ReservationPurchaseRecommendation { 9882 s.LookbackPeriodInDays = &v 9883 return s 9884} 9885 9886// SetPaymentOption sets the PaymentOption field's value. 9887func (s *ReservationPurchaseRecommendation) SetPaymentOption(v string) *ReservationPurchaseRecommendation { 9888 s.PaymentOption = &v 9889 return s 9890} 9891 9892// SetRecommendationDetails sets the RecommendationDetails field's value. 9893func (s *ReservationPurchaseRecommendation) SetRecommendationDetails(v []*ReservationPurchaseRecommendationDetail) *ReservationPurchaseRecommendation { 9894 s.RecommendationDetails = v 9895 return s 9896} 9897 9898// SetRecommendationSummary sets the RecommendationSummary field's value. 9899func (s *ReservationPurchaseRecommendation) SetRecommendationSummary(v *ReservationPurchaseRecommendationSummary) *ReservationPurchaseRecommendation { 9900 s.RecommendationSummary = v 9901 return s 9902} 9903 9904// SetServiceSpecification sets the ServiceSpecification field's value. 9905func (s *ReservationPurchaseRecommendation) SetServiceSpecification(v *ServiceSpecification) *ReservationPurchaseRecommendation { 9906 s.ServiceSpecification = v 9907 return s 9908} 9909 9910// SetTermInYears sets the TermInYears field's value. 9911func (s *ReservationPurchaseRecommendation) SetTermInYears(v string) *ReservationPurchaseRecommendation { 9912 s.TermInYears = &v 9913 return s 9914} 9915 9916// Details about your recommended reservation purchase. 9917type ReservationPurchaseRecommendationDetail struct { 9918 _ struct{} `type:"structure"` 9919 9920 // The account that this RI recommendation is for. 9921 AccountId *string `type:"string"` 9922 9923 // The average number of normalized units that you used in an hour during the 9924 // historical period. AWS uses this to calculate your recommended reservation 9925 // purchases. 9926 AverageNormalizedUnitsUsedPerHour *string `type:"string"` 9927 9928 // The average number of instances that you used in an hour during the historical 9929 // period. AWS uses this to calculate your recommended reservation purchases. 9930 AverageNumberOfInstancesUsedPerHour *string `type:"string"` 9931 9932 // The average utilization of your instances. AWS uses this to calculate your 9933 // recommended reservation purchases. 9934 AverageUtilization *string `type:"string"` 9935 9936 // The currency code that AWS used to calculate the costs for this instance. 9937 CurrencyCode *string `type:"string"` 9938 9939 // How long AWS estimates that it takes for this instance to start saving you 9940 // money, in months. 9941 EstimatedBreakEvenInMonths *string `type:"string"` 9942 9943 // How much AWS estimates that you spend on On-Demand Instances in a month. 9944 EstimatedMonthlyOnDemandCost *string `type:"string"` 9945 9946 // How much AWS estimates that this specific recommendation could save you in 9947 // a month. 9948 EstimatedMonthlySavingsAmount *string `type:"string"` 9949 9950 // How much AWS estimates that this specific recommendation could save you in 9951 // a month, as a percentage of your overall costs. 9952 EstimatedMonthlySavingsPercentage *string `type:"string"` 9953 9954 // How much AWS estimates that you would have spent for all usage during the 9955 // specified historical period if you had a reservation. 9956 EstimatedReservationCostForLookbackPeriod *string `type:"string"` 9957 9958 // Details about the instances that AWS recommends that you purchase. 9959 InstanceDetails *InstanceDetails `type:"structure"` 9960 9961 // The maximum number of normalized units that you used in an hour during the 9962 // historical period. AWS uses this to calculate your recommended reservation 9963 // purchases. 9964 MaximumNormalizedUnitsUsedPerHour *string `type:"string"` 9965 9966 // The maximum number of instances that you used in an hour during the historical 9967 // period. AWS uses this to calculate your recommended reservation purchases. 9968 MaximumNumberOfInstancesUsedPerHour *string `type:"string"` 9969 9970 // The minimum number of normalized units that you used in an hour during the 9971 // historical period. AWS uses this to calculate your recommended reservation 9972 // purchases. 9973 MinimumNormalizedUnitsUsedPerHour *string `type:"string"` 9974 9975 // The minimum number of instances that you used in an hour during the historical 9976 // period. AWS uses this to calculate your recommended reservation purchases. 9977 MinimumNumberOfInstancesUsedPerHour *string `type:"string"` 9978 9979 // The number of normalized units that AWS recommends that you purchase. 9980 RecommendedNormalizedUnitsToPurchase *string `type:"string"` 9981 9982 // The number of instances that AWS recommends that you purchase. 9983 RecommendedNumberOfInstancesToPurchase *string `type:"string"` 9984 9985 // How much purchasing this instance costs you on a monthly basis. 9986 RecurringStandardMonthlyCost *string `type:"string"` 9987 9988 // How much purchasing this instance costs you upfront. 9989 UpfrontCost *string `type:"string"` 9990} 9991 9992// String returns the string representation 9993func (s ReservationPurchaseRecommendationDetail) String() string { 9994 return awsutil.Prettify(s) 9995} 9996 9997// GoString returns the string representation 9998func (s ReservationPurchaseRecommendationDetail) GoString() string { 9999 return s.String() 10000} 10001 10002// SetAccountId sets the AccountId field's value. 10003func (s *ReservationPurchaseRecommendationDetail) SetAccountId(v string) *ReservationPurchaseRecommendationDetail { 10004 s.AccountId = &v 10005 return s 10006} 10007 10008// SetAverageNormalizedUnitsUsedPerHour sets the AverageNormalizedUnitsUsedPerHour field's value. 10009func (s *ReservationPurchaseRecommendationDetail) SetAverageNormalizedUnitsUsedPerHour(v string) *ReservationPurchaseRecommendationDetail { 10010 s.AverageNormalizedUnitsUsedPerHour = &v 10011 return s 10012} 10013 10014// SetAverageNumberOfInstancesUsedPerHour sets the AverageNumberOfInstancesUsedPerHour field's value. 10015func (s *ReservationPurchaseRecommendationDetail) SetAverageNumberOfInstancesUsedPerHour(v string) *ReservationPurchaseRecommendationDetail { 10016 s.AverageNumberOfInstancesUsedPerHour = &v 10017 return s 10018} 10019 10020// SetAverageUtilization sets the AverageUtilization field's value. 10021func (s *ReservationPurchaseRecommendationDetail) SetAverageUtilization(v string) *ReservationPurchaseRecommendationDetail { 10022 s.AverageUtilization = &v 10023 return s 10024} 10025 10026// SetCurrencyCode sets the CurrencyCode field's value. 10027func (s *ReservationPurchaseRecommendationDetail) SetCurrencyCode(v string) *ReservationPurchaseRecommendationDetail { 10028 s.CurrencyCode = &v 10029 return s 10030} 10031 10032// SetEstimatedBreakEvenInMonths sets the EstimatedBreakEvenInMonths field's value. 10033func (s *ReservationPurchaseRecommendationDetail) SetEstimatedBreakEvenInMonths(v string) *ReservationPurchaseRecommendationDetail { 10034 s.EstimatedBreakEvenInMonths = &v 10035 return s 10036} 10037 10038// SetEstimatedMonthlyOnDemandCost sets the EstimatedMonthlyOnDemandCost field's value. 10039func (s *ReservationPurchaseRecommendationDetail) SetEstimatedMonthlyOnDemandCost(v string) *ReservationPurchaseRecommendationDetail { 10040 s.EstimatedMonthlyOnDemandCost = &v 10041 return s 10042} 10043 10044// SetEstimatedMonthlySavingsAmount sets the EstimatedMonthlySavingsAmount field's value. 10045func (s *ReservationPurchaseRecommendationDetail) SetEstimatedMonthlySavingsAmount(v string) *ReservationPurchaseRecommendationDetail { 10046 s.EstimatedMonthlySavingsAmount = &v 10047 return s 10048} 10049 10050// SetEstimatedMonthlySavingsPercentage sets the EstimatedMonthlySavingsPercentage field's value. 10051func (s *ReservationPurchaseRecommendationDetail) SetEstimatedMonthlySavingsPercentage(v string) *ReservationPurchaseRecommendationDetail { 10052 s.EstimatedMonthlySavingsPercentage = &v 10053 return s 10054} 10055 10056// SetEstimatedReservationCostForLookbackPeriod sets the EstimatedReservationCostForLookbackPeriod field's value. 10057func (s *ReservationPurchaseRecommendationDetail) SetEstimatedReservationCostForLookbackPeriod(v string) *ReservationPurchaseRecommendationDetail { 10058 s.EstimatedReservationCostForLookbackPeriod = &v 10059 return s 10060} 10061 10062// SetInstanceDetails sets the InstanceDetails field's value. 10063func (s *ReservationPurchaseRecommendationDetail) SetInstanceDetails(v *InstanceDetails) *ReservationPurchaseRecommendationDetail { 10064 s.InstanceDetails = v 10065 return s 10066} 10067 10068// SetMaximumNormalizedUnitsUsedPerHour sets the MaximumNormalizedUnitsUsedPerHour field's value. 10069func (s *ReservationPurchaseRecommendationDetail) SetMaximumNormalizedUnitsUsedPerHour(v string) *ReservationPurchaseRecommendationDetail { 10070 s.MaximumNormalizedUnitsUsedPerHour = &v 10071 return s 10072} 10073 10074// SetMaximumNumberOfInstancesUsedPerHour sets the MaximumNumberOfInstancesUsedPerHour field's value. 10075func (s *ReservationPurchaseRecommendationDetail) SetMaximumNumberOfInstancesUsedPerHour(v string) *ReservationPurchaseRecommendationDetail { 10076 s.MaximumNumberOfInstancesUsedPerHour = &v 10077 return s 10078} 10079 10080// SetMinimumNormalizedUnitsUsedPerHour sets the MinimumNormalizedUnitsUsedPerHour field's value. 10081func (s *ReservationPurchaseRecommendationDetail) SetMinimumNormalizedUnitsUsedPerHour(v string) *ReservationPurchaseRecommendationDetail { 10082 s.MinimumNormalizedUnitsUsedPerHour = &v 10083 return s 10084} 10085 10086// SetMinimumNumberOfInstancesUsedPerHour sets the MinimumNumberOfInstancesUsedPerHour field's value. 10087func (s *ReservationPurchaseRecommendationDetail) SetMinimumNumberOfInstancesUsedPerHour(v string) *ReservationPurchaseRecommendationDetail { 10088 s.MinimumNumberOfInstancesUsedPerHour = &v 10089 return s 10090} 10091 10092// SetRecommendedNormalizedUnitsToPurchase sets the RecommendedNormalizedUnitsToPurchase field's value. 10093func (s *ReservationPurchaseRecommendationDetail) SetRecommendedNormalizedUnitsToPurchase(v string) *ReservationPurchaseRecommendationDetail { 10094 s.RecommendedNormalizedUnitsToPurchase = &v 10095 return s 10096} 10097 10098// SetRecommendedNumberOfInstancesToPurchase sets the RecommendedNumberOfInstancesToPurchase field's value. 10099func (s *ReservationPurchaseRecommendationDetail) SetRecommendedNumberOfInstancesToPurchase(v string) *ReservationPurchaseRecommendationDetail { 10100 s.RecommendedNumberOfInstancesToPurchase = &v 10101 return s 10102} 10103 10104// SetRecurringStandardMonthlyCost sets the RecurringStandardMonthlyCost field's value. 10105func (s *ReservationPurchaseRecommendationDetail) SetRecurringStandardMonthlyCost(v string) *ReservationPurchaseRecommendationDetail { 10106 s.RecurringStandardMonthlyCost = &v 10107 return s 10108} 10109 10110// SetUpfrontCost sets the UpfrontCost field's value. 10111func (s *ReservationPurchaseRecommendationDetail) SetUpfrontCost(v string) *ReservationPurchaseRecommendationDetail { 10112 s.UpfrontCost = &v 10113 return s 10114} 10115 10116// Information about this specific recommendation, such as the timestamp for 10117// when AWS made a specific recommendation. 10118type ReservationPurchaseRecommendationMetadata struct { 10119 _ struct{} `type:"structure"` 10120 10121 // The timestamp for when AWS made this recommendation. 10122 GenerationTimestamp *string `type:"string"` 10123 10124 // The ID for this specific recommendation. 10125 RecommendationId *string `type:"string"` 10126} 10127 10128// String returns the string representation 10129func (s ReservationPurchaseRecommendationMetadata) String() string { 10130 return awsutil.Prettify(s) 10131} 10132 10133// GoString returns the string representation 10134func (s ReservationPurchaseRecommendationMetadata) GoString() string { 10135 return s.String() 10136} 10137 10138// SetGenerationTimestamp sets the GenerationTimestamp field's value. 10139func (s *ReservationPurchaseRecommendationMetadata) SetGenerationTimestamp(v string) *ReservationPurchaseRecommendationMetadata { 10140 s.GenerationTimestamp = &v 10141 return s 10142} 10143 10144// SetRecommendationId sets the RecommendationId field's value. 10145func (s *ReservationPurchaseRecommendationMetadata) SetRecommendationId(v string) *ReservationPurchaseRecommendationMetadata { 10146 s.RecommendationId = &v 10147 return s 10148} 10149 10150// A summary about this recommendation, such as the currency code, the amount 10151// that AWS estimates that you could save, and the total amount of reservation 10152// to purchase. 10153type ReservationPurchaseRecommendationSummary struct { 10154 _ struct{} `type:"structure"` 10155 10156 // The currency code used for this recommendation. 10157 CurrencyCode *string `type:"string"` 10158 10159 // The total amount that AWS estimates that this recommendation could save you 10160 // in a month. 10161 TotalEstimatedMonthlySavingsAmount *string `type:"string"` 10162 10163 // The total amount that AWS estimates that this recommendation could save you 10164 // in a month, as a percentage of your costs. 10165 TotalEstimatedMonthlySavingsPercentage *string `type:"string"` 10166} 10167 10168// String returns the string representation 10169func (s ReservationPurchaseRecommendationSummary) String() string { 10170 return awsutil.Prettify(s) 10171} 10172 10173// GoString returns the string representation 10174func (s ReservationPurchaseRecommendationSummary) GoString() string { 10175 return s.String() 10176} 10177 10178// SetCurrencyCode sets the CurrencyCode field's value. 10179func (s *ReservationPurchaseRecommendationSummary) SetCurrencyCode(v string) *ReservationPurchaseRecommendationSummary { 10180 s.CurrencyCode = &v 10181 return s 10182} 10183 10184// SetTotalEstimatedMonthlySavingsAmount sets the TotalEstimatedMonthlySavingsAmount field's value. 10185func (s *ReservationPurchaseRecommendationSummary) SetTotalEstimatedMonthlySavingsAmount(v string) *ReservationPurchaseRecommendationSummary { 10186 s.TotalEstimatedMonthlySavingsAmount = &v 10187 return s 10188} 10189 10190// SetTotalEstimatedMonthlySavingsPercentage sets the TotalEstimatedMonthlySavingsPercentage field's value. 10191func (s *ReservationPurchaseRecommendationSummary) SetTotalEstimatedMonthlySavingsPercentage(v string) *ReservationPurchaseRecommendationSummary { 10192 s.TotalEstimatedMonthlySavingsPercentage = &v 10193 return s 10194} 10195 10196// A group of reservations that share a set of attributes. 10197type ReservationUtilizationGroup struct { 10198 _ struct{} `type:"structure"` 10199 10200 // The attributes for this group of reservations. 10201 Attributes map[string]*string `type:"map"` 10202 10203 // The key for a specific reservation attribute. 10204 Key *string `type:"string"` 10205 10206 // How much you used this group of reservations. 10207 Utilization *ReservationAggregates `type:"structure"` 10208 10209 // The value of a specific reservation attribute. 10210 Value *string `type:"string"` 10211} 10212 10213// String returns the string representation 10214func (s ReservationUtilizationGroup) String() string { 10215 return awsutil.Prettify(s) 10216} 10217 10218// GoString returns the string representation 10219func (s ReservationUtilizationGroup) GoString() string { 10220 return s.String() 10221} 10222 10223// SetAttributes sets the Attributes field's value. 10224func (s *ReservationUtilizationGroup) SetAttributes(v map[string]*string) *ReservationUtilizationGroup { 10225 s.Attributes = v 10226 return s 10227} 10228 10229// SetKey sets the Key field's value. 10230func (s *ReservationUtilizationGroup) SetKey(v string) *ReservationUtilizationGroup { 10231 s.Key = &v 10232 return s 10233} 10234 10235// SetUtilization sets the Utilization field's value. 10236func (s *ReservationUtilizationGroup) SetUtilization(v *ReservationAggregates) *ReservationUtilizationGroup { 10237 s.Utilization = v 10238 return s 10239} 10240 10241// SetValue sets the Value field's value. 10242func (s *ReservationUtilizationGroup) SetValue(v string) *ReservationUtilizationGroup { 10243 s.Value = &v 10244 return s 10245} 10246 10247// Details on the resource. 10248type ResourceDetails struct { 10249 _ struct{} `type:"structure"` 10250 10251 // Details on the Amazon EC2 resource. 10252 EC2ResourceDetails *EC2ResourceDetails `type:"structure"` 10253} 10254 10255// String returns the string representation 10256func (s ResourceDetails) String() string { 10257 return awsutil.Prettify(s) 10258} 10259 10260// GoString returns the string representation 10261func (s ResourceDetails) GoString() string { 10262 return s.String() 10263} 10264 10265// SetEC2ResourceDetails sets the EC2ResourceDetails field's value. 10266func (s *ResourceDetails) SetEC2ResourceDetails(v *EC2ResourceDetails) *ResourceDetails { 10267 s.EC2ResourceDetails = v 10268 return s 10269} 10270 10271// The specified ARN in the request doesn't exist. 10272type ResourceNotFoundException struct { 10273 _ struct{} `type:"structure"` 10274 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 10275 10276 Message_ *string `locationName:"Message" type:"string"` 10277} 10278 10279// String returns the string representation 10280func (s ResourceNotFoundException) String() string { 10281 return awsutil.Prettify(s) 10282} 10283 10284// GoString returns the string representation 10285func (s ResourceNotFoundException) GoString() string { 10286 return s.String() 10287} 10288 10289func newErrorResourceNotFoundException(v protocol.ResponseMetadata) error { 10290 return &ResourceNotFoundException{ 10291 RespMetadata: v, 10292 } 10293} 10294 10295// Code returns the exception type name. 10296func (s *ResourceNotFoundException) Code() string { 10297 return "ResourceNotFoundException" 10298} 10299 10300// Message returns the exception's message. 10301func (s *ResourceNotFoundException) Message() string { 10302 if s.Message_ != nil { 10303 return *s.Message_ 10304 } 10305 return "" 10306} 10307 10308// OrigErr always returns nil, satisfies awserr.Error interface. 10309func (s *ResourceNotFoundException) OrigErr() error { 10310 return nil 10311} 10312 10313func (s *ResourceNotFoundException) Error() string { 10314 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 10315} 10316 10317// Status code returns the HTTP status code for the request's response error. 10318func (s *ResourceNotFoundException) StatusCode() int { 10319 return s.RespMetadata.StatusCode 10320} 10321 10322// RequestID returns the service's response RequestID for request. 10323func (s *ResourceNotFoundException) RequestID() string { 10324 return s.RespMetadata.RequestID 10325} 10326 10327// Resource utilization of current resource. 10328type ResourceUtilization struct { 10329 _ struct{} `type:"structure"` 10330 10331 // Utilization of current Amazon EC2 instance. 10332 EC2ResourceUtilization *EC2ResourceUtilization `type:"structure"` 10333} 10334 10335// String returns the string representation 10336func (s ResourceUtilization) String() string { 10337 return awsutil.Prettify(s) 10338} 10339 10340// GoString returns the string representation 10341func (s ResourceUtilization) GoString() string { 10342 return s.String() 10343} 10344 10345// SetEC2ResourceUtilization sets the EC2ResourceUtilization field's value. 10346func (s *ResourceUtilization) SetEC2ResourceUtilization(v *EC2ResourceUtilization) *ResourceUtilization { 10347 s.EC2ResourceUtilization = v 10348 return s 10349} 10350 10351// The result that is associated with a time period. 10352type ResultByTime struct { 10353 _ struct{} `type:"structure"` 10354 10355 // Whether the result is estimated. 10356 Estimated *bool `type:"boolean"` 10357 10358 // The groups that this time period includes. 10359 Groups []*Group `type:"list"` 10360 10361 // The time period that the result covers. 10362 TimePeriod *DateInterval `type:"structure"` 10363 10364 // The total amount of cost or usage accrued during the time period. 10365 Total map[string]*MetricValue `type:"map"` 10366} 10367 10368// String returns the string representation 10369func (s ResultByTime) String() string { 10370 return awsutil.Prettify(s) 10371} 10372 10373// GoString returns the string representation 10374func (s ResultByTime) GoString() string { 10375 return s.String() 10376} 10377 10378// SetEstimated sets the Estimated field's value. 10379func (s *ResultByTime) SetEstimated(v bool) *ResultByTime { 10380 s.Estimated = &v 10381 return s 10382} 10383 10384// SetGroups sets the Groups field's value. 10385func (s *ResultByTime) SetGroups(v []*Group) *ResultByTime { 10386 s.Groups = v 10387 return s 10388} 10389 10390// SetTimePeriod sets the TimePeriod field's value. 10391func (s *ResultByTime) SetTimePeriod(v *DateInterval) *ResultByTime { 10392 s.TimePeriod = v 10393 return s 10394} 10395 10396// SetTotal sets the Total field's value. 10397func (s *ResultByTime) SetTotal(v map[string]*MetricValue) *ResultByTime { 10398 s.Total = v 10399 return s 10400} 10401 10402// Recommendations to rightsize resources. 10403type RightsizingRecommendation struct { 10404 _ struct{} `type:"structure"` 10405 10406 // The account that this recommendation is for. 10407 AccountId *string `type:"string"` 10408 10409 // Context regarding the current instance. 10410 CurrentInstance *CurrentInstance `type:"structure"` 10411 10412 // Details for modification recommendations. 10413 ModifyRecommendationDetail *ModifyRecommendationDetail `type:"structure"` 10414 10415 // Recommendation to either terminate or modify the resource. 10416 RightsizingType *string `type:"string" enum:"RightsizingType"` 10417 10418 // Details for termination recommendations. 10419 TerminateRecommendationDetail *TerminateRecommendationDetail `type:"structure"` 10420} 10421 10422// String returns the string representation 10423func (s RightsizingRecommendation) String() string { 10424 return awsutil.Prettify(s) 10425} 10426 10427// GoString returns the string representation 10428func (s RightsizingRecommendation) GoString() string { 10429 return s.String() 10430} 10431 10432// SetAccountId sets the AccountId field's value. 10433func (s *RightsizingRecommendation) SetAccountId(v string) *RightsizingRecommendation { 10434 s.AccountId = &v 10435 return s 10436} 10437 10438// SetCurrentInstance sets the CurrentInstance field's value. 10439func (s *RightsizingRecommendation) SetCurrentInstance(v *CurrentInstance) *RightsizingRecommendation { 10440 s.CurrentInstance = v 10441 return s 10442} 10443 10444// SetModifyRecommendationDetail sets the ModifyRecommendationDetail field's value. 10445func (s *RightsizingRecommendation) SetModifyRecommendationDetail(v *ModifyRecommendationDetail) *RightsizingRecommendation { 10446 s.ModifyRecommendationDetail = v 10447 return s 10448} 10449 10450// SetRightsizingType sets the RightsizingType field's value. 10451func (s *RightsizingRecommendation) SetRightsizingType(v string) *RightsizingRecommendation { 10452 s.RightsizingType = &v 10453 return s 10454} 10455 10456// SetTerminateRecommendationDetail sets the TerminateRecommendationDetail field's value. 10457func (s *RightsizingRecommendation) SetTerminateRecommendationDetail(v *TerminateRecommendationDetail) *RightsizingRecommendation { 10458 s.TerminateRecommendationDetail = v 10459 return s 10460} 10461 10462// Enables you to customize recommendations across two attributes. You can choose 10463// to view recommendations for instances within the same instance families or 10464// across different instance families. You can also choose to view your estimated 10465// savings associated with recommendations with consideration of existing Savings 10466// Plans or RI benefits, or neither. 10467type RightsizingRecommendationConfiguration struct { 10468 _ struct{} `type:"structure"` 10469 10470 // The option to consider RI or Savings Plans discount benefits in your savings 10471 // calculation. The default value is TRUE. 10472 // 10473 // BenefitsConsidered is a required field 10474 BenefitsConsidered *bool `type:"boolean" required:"true"` 10475 10476 // The option to see recommendations within the same instance family, or recommendations 10477 // for instances across other families. The default value is SAME_INSTANCE_FAMILY. 10478 // 10479 // RecommendationTarget is a required field 10480 RecommendationTarget *string `type:"string" required:"true" enum:"RecommendationTarget"` 10481} 10482 10483// String returns the string representation 10484func (s RightsizingRecommendationConfiguration) String() string { 10485 return awsutil.Prettify(s) 10486} 10487 10488// GoString returns the string representation 10489func (s RightsizingRecommendationConfiguration) GoString() string { 10490 return s.String() 10491} 10492 10493// Validate inspects the fields of the type to determine if they are valid. 10494func (s *RightsizingRecommendationConfiguration) Validate() error { 10495 invalidParams := request.ErrInvalidParams{Context: "RightsizingRecommendationConfiguration"} 10496 if s.BenefitsConsidered == nil { 10497 invalidParams.Add(request.NewErrParamRequired("BenefitsConsidered")) 10498 } 10499 if s.RecommendationTarget == nil { 10500 invalidParams.Add(request.NewErrParamRequired("RecommendationTarget")) 10501 } 10502 10503 if invalidParams.Len() > 0 { 10504 return invalidParams 10505 } 10506 return nil 10507} 10508 10509// SetBenefitsConsidered sets the BenefitsConsidered field's value. 10510func (s *RightsizingRecommendationConfiguration) SetBenefitsConsidered(v bool) *RightsizingRecommendationConfiguration { 10511 s.BenefitsConsidered = &v 10512 return s 10513} 10514 10515// SetRecommendationTarget sets the RecommendationTarget field's value. 10516func (s *RightsizingRecommendationConfiguration) SetRecommendationTarget(v string) *RightsizingRecommendationConfiguration { 10517 s.RecommendationTarget = &v 10518 return s 10519} 10520 10521// Metadata for this recommendation set. 10522type RightsizingRecommendationMetadata struct { 10523 _ struct{} `type:"structure"` 10524 10525 // Additional metadata that may be applicable to the recommendation. 10526 AdditionalMetadata *string `type:"string"` 10527 10528 // The timestamp for when AWS made this recommendation. 10529 GenerationTimestamp *string `type:"string"` 10530 10531 // How many days of previous usage that AWS considers when making this recommendation. 10532 LookbackPeriodInDays *string `type:"string" enum:"LookbackPeriodInDays"` 10533 10534 // The ID for this specific recommendation. 10535 RecommendationId *string `type:"string"` 10536} 10537 10538// String returns the string representation 10539func (s RightsizingRecommendationMetadata) String() string { 10540 return awsutil.Prettify(s) 10541} 10542 10543// GoString returns the string representation 10544func (s RightsizingRecommendationMetadata) GoString() string { 10545 return s.String() 10546} 10547 10548// SetAdditionalMetadata sets the AdditionalMetadata field's value. 10549func (s *RightsizingRecommendationMetadata) SetAdditionalMetadata(v string) *RightsizingRecommendationMetadata { 10550 s.AdditionalMetadata = &v 10551 return s 10552} 10553 10554// SetGenerationTimestamp sets the GenerationTimestamp field's value. 10555func (s *RightsizingRecommendationMetadata) SetGenerationTimestamp(v string) *RightsizingRecommendationMetadata { 10556 s.GenerationTimestamp = &v 10557 return s 10558} 10559 10560// SetLookbackPeriodInDays sets the LookbackPeriodInDays field's value. 10561func (s *RightsizingRecommendationMetadata) SetLookbackPeriodInDays(v string) *RightsizingRecommendationMetadata { 10562 s.LookbackPeriodInDays = &v 10563 return s 10564} 10565 10566// SetRecommendationId sets the RecommendationId field's value. 10567func (s *RightsizingRecommendationMetadata) SetRecommendationId(v string) *RightsizingRecommendationMetadata { 10568 s.RecommendationId = &v 10569 return s 10570} 10571 10572// Summary of rightsizing recommendations 10573type RightsizingRecommendationSummary struct { 10574 _ struct{} `type:"structure"` 10575 10576 // Estimated total savings resulting from modifications, on a monthly basis. 10577 EstimatedTotalMonthlySavingsAmount *string `type:"string"` 10578 10579 // The currency code that AWS used to calculate the savings. 10580 SavingsCurrencyCode *string `type:"string"` 10581 10582 // Savings percentage based on the recommended modifications, relative to the 10583 // total On-Demand costs associated with these instances. 10584 SavingsPercentage *string `type:"string"` 10585 10586 // Total number of instance recommendations. 10587 TotalRecommendationCount *string `type:"string"` 10588} 10589 10590// String returns the string representation 10591func (s RightsizingRecommendationSummary) String() string { 10592 return awsutil.Prettify(s) 10593} 10594 10595// GoString returns the string representation 10596func (s RightsizingRecommendationSummary) GoString() string { 10597 return s.String() 10598} 10599 10600// SetEstimatedTotalMonthlySavingsAmount sets the EstimatedTotalMonthlySavingsAmount field's value. 10601func (s *RightsizingRecommendationSummary) SetEstimatedTotalMonthlySavingsAmount(v string) *RightsizingRecommendationSummary { 10602 s.EstimatedTotalMonthlySavingsAmount = &v 10603 return s 10604} 10605 10606// SetSavingsCurrencyCode sets the SavingsCurrencyCode field's value. 10607func (s *RightsizingRecommendationSummary) SetSavingsCurrencyCode(v string) *RightsizingRecommendationSummary { 10608 s.SavingsCurrencyCode = &v 10609 return s 10610} 10611 10612// SetSavingsPercentage sets the SavingsPercentage field's value. 10613func (s *RightsizingRecommendationSummary) SetSavingsPercentage(v string) *RightsizingRecommendationSummary { 10614 s.SavingsPercentage = &v 10615 return s 10616} 10617 10618// SetTotalRecommendationCount sets the TotalRecommendationCount field's value. 10619func (s *RightsizingRecommendationSummary) SetTotalRecommendationCount(v string) *RightsizingRecommendationSummary { 10620 s.TotalRecommendationCount = &v 10621 return s 10622} 10623 10624// The combination of AWS service, linked account, Region, and usage type where 10625// a cost anomaly is observed. 10626type RootCause struct { 10627 _ struct{} `type:"structure"` 10628 10629 // The linked account value associated with the cost anomaly. 10630 LinkedAccount *string `type:"string"` 10631 10632 // The AWS Region associated with the cost anomaly. 10633 Region *string `type:"string"` 10634 10635 // The AWS service name associated with the cost anomaly. 10636 Service *string `type:"string"` 10637 10638 // The UsageType value associated with the cost anomaly. 10639 UsageType *string `type:"string"` 10640} 10641 10642// String returns the string representation 10643func (s RootCause) String() string { 10644 return awsutil.Prettify(s) 10645} 10646 10647// GoString returns the string representation 10648func (s RootCause) GoString() string { 10649 return s.String() 10650} 10651 10652// SetLinkedAccount sets the LinkedAccount field's value. 10653func (s *RootCause) SetLinkedAccount(v string) *RootCause { 10654 s.LinkedAccount = &v 10655 return s 10656} 10657 10658// SetRegion sets the Region field's value. 10659func (s *RootCause) SetRegion(v string) *RootCause { 10660 s.Region = &v 10661 return s 10662} 10663 10664// SetService sets the Service field's value. 10665func (s *RootCause) SetService(v string) *RootCause { 10666 s.Service = &v 10667 return s 10668} 10669 10670// SetUsageType sets the UsageType field's value. 10671func (s *RootCause) SetUsageType(v string) *RootCause { 10672 s.UsageType = &v 10673 return s 10674} 10675 10676// The amortized amount of Savings Plans purchased in a specific account during 10677// a specific time interval. 10678type SavingsPlansAmortizedCommitment struct { 10679 _ struct{} `type:"structure"` 10680 10681 // The amortized amount of your Savings Plans commitment that was purchased 10682 // with either a Partial or a NoUpfront. 10683 AmortizedRecurringCommitment *string `type:"string"` 10684 10685 // The amortized amount of your Savings Plans commitment that was purchased 10686 // with an Upfront or PartialUpfront Savings Plans. 10687 AmortizedUpfrontCommitment *string `type:"string"` 10688 10689 // The total amortized amount of your Savings Plans commitment, regardless of 10690 // your Savings Plans purchase method. 10691 TotalAmortizedCommitment *string `type:"string"` 10692} 10693 10694// String returns the string representation 10695func (s SavingsPlansAmortizedCommitment) String() string { 10696 return awsutil.Prettify(s) 10697} 10698 10699// GoString returns the string representation 10700func (s SavingsPlansAmortizedCommitment) GoString() string { 10701 return s.String() 10702} 10703 10704// SetAmortizedRecurringCommitment sets the AmortizedRecurringCommitment field's value. 10705func (s *SavingsPlansAmortizedCommitment) SetAmortizedRecurringCommitment(v string) *SavingsPlansAmortizedCommitment { 10706 s.AmortizedRecurringCommitment = &v 10707 return s 10708} 10709 10710// SetAmortizedUpfrontCommitment sets the AmortizedUpfrontCommitment field's value. 10711func (s *SavingsPlansAmortizedCommitment) SetAmortizedUpfrontCommitment(v string) *SavingsPlansAmortizedCommitment { 10712 s.AmortizedUpfrontCommitment = &v 10713 return s 10714} 10715 10716// SetTotalAmortizedCommitment sets the TotalAmortizedCommitment field's value. 10717func (s *SavingsPlansAmortizedCommitment) SetTotalAmortizedCommitment(v string) *SavingsPlansAmortizedCommitment { 10718 s.TotalAmortizedCommitment = &v 10719 return s 10720} 10721 10722// The amount of Savings Plans eligible usage that is covered by Savings Plans. 10723// All calculations consider the On-Demand equivalent of your Savings Plans 10724// usage. 10725type SavingsPlansCoverage struct { 10726 _ struct{} `type:"structure"` 10727 10728 // The attribute that applies to a specific Dimension. 10729 Attributes map[string]*string `type:"map"` 10730 10731 // The amount of Savings Plans eligible usage that the Savings Plans covered. 10732 Coverage *SavingsPlansCoverageData `type:"structure"` 10733 10734 // The time period of the request. 10735 TimePeriod *DateInterval `type:"structure"` 10736} 10737 10738// String returns the string representation 10739func (s SavingsPlansCoverage) String() string { 10740 return awsutil.Prettify(s) 10741} 10742 10743// GoString returns the string representation 10744func (s SavingsPlansCoverage) GoString() string { 10745 return s.String() 10746} 10747 10748// SetAttributes sets the Attributes field's value. 10749func (s *SavingsPlansCoverage) SetAttributes(v map[string]*string) *SavingsPlansCoverage { 10750 s.Attributes = v 10751 return s 10752} 10753 10754// SetCoverage sets the Coverage field's value. 10755func (s *SavingsPlansCoverage) SetCoverage(v *SavingsPlansCoverageData) *SavingsPlansCoverage { 10756 s.Coverage = v 10757 return s 10758} 10759 10760// SetTimePeriod sets the TimePeriod field's value. 10761func (s *SavingsPlansCoverage) SetTimePeriod(v *DateInterval) *SavingsPlansCoverage { 10762 s.TimePeriod = v 10763 return s 10764} 10765 10766// Specific coverage percentage, On-Demand costs, and spend covered by Savings 10767// Plans, and total Savings Plans costs for an account. 10768type SavingsPlansCoverageData struct { 10769 _ struct{} `type:"structure"` 10770 10771 // The percentage of your existing Savings Plans covered usage, divided by all 10772 // of your eligible Savings Plans usage in an account(or set of accounts). 10773 CoveragePercentage *string `type:"string"` 10774 10775 // The cost of your AWS usage at the public On-Demand rate. 10776 OnDemandCost *string `type:"string"` 10777 10778 // The amount of your AWS usage that is covered by a Savings Plans. 10779 SpendCoveredBySavingsPlans *string `type:"string"` 10780 10781 // The total cost of your AWS usage, regardless of your purchase option. 10782 TotalCost *string `type:"string"` 10783} 10784 10785// String returns the string representation 10786func (s SavingsPlansCoverageData) String() string { 10787 return awsutil.Prettify(s) 10788} 10789 10790// GoString returns the string representation 10791func (s SavingsPlansCoverageData) GoString() string { 10792 return s.String() 10793} 10794 10795// SetCoveragePercentage sets the CoveragePercentage field's value. 10796func (s *SavingsPlansCoverageData) SetCoveragePercentage(v string) *SavingsPlansCoverageData { 10797 s.CoveragePercentage = &v 10798 return s 10799} 10800 10801// SetOnDemandCost sets the OnDemandCost field's value. 10802func (s *SavingsPlansCoverageData) SetOnDemandCost(v string) *SavingsPlansCoverageData { 10803 s.OnDemandCost = &v 10804 return s 10805} 10806 10807// SetSpendCoveredBySavingsPlans sets the SpendCoveredBySavingsPlans field's value. 10808func (s *SavingsPlansCoverageData) SetSpendCoveredBySavingsPlans(v string) *SavingsPlansCoverageData { 10809 s.SpendCoveredBySavingsPlans = &v 10810 return s 10811} 10812 10813// SetTotalCost sets the TotalCost field's value. 10814func (s *SavingsPlansCoverageData) SetTotalCost(v string) *SavingsPlansCoverageData { 10815 s.TotalCost = &v 10816 return s 10817} 10818 10819// Attribute details on a specific Savings Plan. 10820type SavingsPlansDetails struct { 10821 _ struct{} `type:"structure"` 10822 10823 // A group of instance types that Savings Plans applies to. 10824 InstanceFamily *string `type:"string"` 10825 10826 // The unique ID used to distinguish Savings Plans from one another. 10827 OfferingId *string `type:"string"` 10828 10829 // A collection of AWS resources in a geographic area. Each AWS Region is isolated 10830 // and independent of the other Regions. 10831 Region *string `type:"string"` 10832} 10833 10834// String returns the string representation 10835func (s SavingsPlansDetails) String() string { 10836 return awsutil.Prettify(s) 10837} 10838 10839// GoString returns the string representation 10840func (s SavingsPlansDetails) GoString() string { 10841 return s.String() 10842} 10843 10844// SetInstanceFamily sets the InstanceFamily field's value. 10845func (s *SavingsPlansDetails) SetInstanceFamily(v string) *SavingsPlansDetails { 10846 s.InstanceFamily = &v 10847 return s 10848} 10849 10850// SetOfferingId sets the OfferingId field's value. 10851func (s *SavingsPlansDetails) SetOfferingId(v string) *SavingsPlansDetails { 10852 s.OfferingId = &v 10853 return s 10854} 10855 10856// SetRegion sets the Region field's value. 10857func (s *SavingsPlansDetails) SetRegion(v string) *SavingsPlansDetails { 10858 s.Region = &v 10859 return s 10860} 10861 10862// Contains your request parameters, Savings Plan Recommendations Summary, and 10863// Details. 10864type SavingsPlansPurchaseRecommendation struct { 10865 _ struct{} `type:"structure"` 10866 10867 // The account scope that you want your recommendations for. Amazon Web Services 10868 // calculates recommendations including the management account and member accounts 10869 // if the value is set to PAYER. If the value is LINKED, recommendations are 10870 // calculated for individual member accounts only. 10871 AccountScope *string `type:"string" enum:"AccountScope"` 10872 10873 // The lookback period in days, used to generate the recommendation. 10874 LookbackPeriodInDays *string `type:"string" enum:"LookbackPeriodInDays"` 10875 10876 // The payment option used to generate the recommendation. 10877 PaymentOption *string `type:"string" enum:"PaymentOption"` 10878 10879 // Details for the Savings Plans we recommend that you purchase to cover existing 10880 // Savings Plans eligible workloads. 10881 SavingsPlansPurchaseRecommendationDetails []*SavingsPlansPurchaseRecommendationDetail `type:"list"` 10882 10883 // Summary metrics for your Savings Plans Recommendations. 10884 SavingsPlansPurchaseRecommendationSummary *SavingsPlansPurchaseRecommendationSummary `type:"structure"` 10885 10886 // The requested Savings Plans recommendation type. 10887 SavingsPlansType *string `type:"string" enum:"SupportedSavingsPlansType"` 10888 10889 // The Savings Plans recommendation term in years, used to generate the recommendation. 10890 TermInYears *string `type:"string" enum:"TermInYears"` 10891} 10892 10893// String returns the string representation 10894func (s SavingsPlansPurchaseRecommendation) String() string { 10895 return awsutil.Prettify(s) 10896} 10897 10898// GoString returns the string representation 10899func (s SavingsPlansPurchaseRecommendation) GoString() string { 10900 return s.String() 10901} 10902 10903// SetAccountScope sets the AccountScope field's value. 10904func (s *SavingsPlansPurchaseRecommendation) SetAccountScope(v string) *SavingsPlansPurchaseRecommendation { 10905 s.AccountScope = &v 10906 return s 10907} 10908 10909// SetLookbackPeriodInDays sets the LookbackPeriodInDays field's value. 10910func (s *SavingsPlansPurchaseRecommendation) SetLookbackPeriodInDays(v string) *SavingsPlansPurchaseRecommendation { 10911 s.LookbackPeriodInDays = &v 10912 return s 10913} 10914 10915// SetPaymentOption sets the PaymentOption field's value. 10916func (s *SavingsPlansPurchaseRecommendation) SetPaymentOption(v string) *SavingsPlansPurchaseRecommendation { 10917 s.PaymentOption = &v 10918 return s 10919} 10920 10921// SetSavingsPlansPurchaseRecommendationDetails sets the SavingsPlansPurchaseRecommendationDetails field's value. 10922func (s *SavingsPlansPurchaseRecommendation) SetSavingsPlansPurchaseRecommendationDetails(v []*SavingsPlansPurchaseRecommendationDetail) *SavingsPlansPurchaseRecommendation { 10923 s.SavingsPlansPurchaseRecommendationDetails = v 10924 return s 10925} 10926 10927// SetSavingsPlansPurchaseRecommendationSummary sets the SavingsPlansPurchaseRecommendationSummary field's value. 10928func (s *SavingsPlansPurchaseRecommendation) SetSavingsPlansPurchaseRecommendationSummary(v *SavingsPlansPurchaseRecommendationSummary) *SavingsPlansPurchaseRecommendation { 10929 s.SavingsPlansPurchaseRecommendationSummary = v 10930 return s 10931} 10932 10933// SetSavingsPlansType sets the SavingsPlansType field's value. 10934func (s *SavingsPlansPurchaseRecommendation) SetSavingsPlansType(v string) *SavingsPlansPurchaseRecommendation { 10935 s.SavingsPlansType = &v 10936 return s 10937} 10938 10939// SetTermInYears sets the TermInYears field's value. 10940func (s *SavingsPlansPurchaseRecommendation) SetTermInYears(v string) *SavingsPlansPurchaseRecommendation { 10941 s.TermInYears = &v 10942 return s 10943} 10944 10945// Details for your recommended Savings Plans. 10946type SavingsPlansPurchaseRecommendationDetail struct { 10947 _ struct{} `type:"structure"` 10948 10949 // The AccountID the recommendation is generated for. 10950 AccountId *string `type:"string"` 10951 10952 // The currency code AWS used to generate the recommendations and present potential 10953 // savings. 10954 CurrencyCode *string `type:"string"` 10955 10956 // The average value of hourly On-Demand spend over the lookback period of the 10957 // applicable usage type. 10958 CurrentAverageHourlyOnDemandSpend *string `type:"string"` 10959 10960 // The highest value of hourly On-Demand spend over the lookback period of the 10961 // applicable usage type. 10962 CurrentMaximumHourlyOnDemandSpend *string `type:"string"` 10963 10964 // The lowest value of hourly On-Demand spend over the lookback period of the 10965 // applicable usage type. 10966 CurrentMinimumHourlyOnDemandSpend *string `type:"string"` 10967 10968 // The estimated utilization of the recommended Savings Plans. 10969 EstimatedAverageUtilization *string `type:"string"` 10970 10971 // The estimated monthly savings amount, based on the recommended Savings Plans. 10972 EstimatedMonthlySavingsAmount *string `type:"string"` 10973 10974 // The remaining On-Demand cost estimated to not be covered by the recommended 10975 // Savings Plans, over the length of the lookback period. 10976 EstimatedOnDemandCost *string `type:"string"` 10977 10978 // The estimated On-Demand costs you would expect with no additional commitment, 10979 // based on your usage of the selected time period and the Savings Plans you 10980 // own. 10981 EstimatedOnDemandCostWithCurrentCommitment *string `type:"string"` 10982 10983 // The estimated return on investment based on the recommended Savings Plans 10984 // purchased. This is calculated as estimatedSavingsAmount/ estimatedSPCost*100. 10985 EstimatedROI *string `type:"string"` 10986 10987 // The cost of the recommended Savings Plans over the length of the lookback 10988 // period. 10989 EstimatedSPCost *string `type:"string"` 10990 10991 // The estimated savings amount based on the recommended Savings Plans over 10992 // the length of the lookback period. 10993 EstimatedSavingsAmount *string `type:"string"` 10994 10995 // The estimated savings percentage relative to the total cost of applicable 10996 // On-Demand usage over the lookback period. 10997 EstimatedSavingsPercentage *string `type:"string"` 10998 10999 // The recommended hourly commitment level for the Savings Plans type, and configuration 11000 // based on the usage during the lookback period. 11001 HourlyCommitmentToPurchase *string `type:"string"` 11002 11003 // Details for your recommended Savings Plans. 11004 SavingsPlansDetails *SavingsPlansDetails `type:"structure"` 11005 11006 // The upfront cost of the recommended Savings Plans, based on the selected 11007 // payment option. 11008 UpfrontCost *string `type:"string"` 11009} 11010 11011// String returns the string representation 11012func (s SavingsPlansPurchaseRecommendationDetail) String() string { 11013 return awsutil.Prettify(s) 11014} 11015 11016// GoString returns the string representation 11017func (s SavingsPlansPurchaseRecommendationDetail) GoString() string { 11018 return s.String() 11019} 11020 11021// SetAccountId sets the AccountId field's value. 11022func (s *SavingsPlansPurchaseRecommendationDetail) SetAccountId(v string) *SavingsPlansPurchaseRecommendationDetail { 11023 s.AccountId = &v 11024 return s 11025} 11026 11027// SetCurrencyCode sets the CurrencyCode field's value. 11028func (s *SavingsPlansPurchaseRecommendationDetail) SetCurrencyCode(v string) *SavingsPlansPurchaseRecommendationDetail { 11029 s.CurrencyCode = &v 11030 return s 11031} 11032 11033// SetCurrentAverageHourlyOnDemandSpend sets the CurrentAverageHourlyOnDemandSpend field's value. 11034func (s *SavingsPlansPurchaseRecommendationDetail) SetCurrentAverageHourlyOnDemandSpend(v string) *SavingsPlansPurchaseRecommendationDetail { 11035 s.CurrentAverageHourlyOnDemandSpend = &v 11036 return s 11037} 11038 11039// SetCurrentMaximumHourlyOnDemandSpend sets the CurrentMaximumHourlyOnDemandSpend field's value. 11040func (s *SavingsPlansPurchaseRecommendationDetail) SetCurrentMaximumHourlyOnDemandSpend(v string) *SavingsPlansPurchaseRecommendationDetail { 11041 s.CurrentMaximumHourlyOnDemandSpend = &v 11042 return s 11043} 11044 11045// SetCurrentMinimumHourlyOnDemandSpend sets the CurrentMinimumHourlyOnDemandSpend field's value. 11046func (s *SavingsPlansPurchaseRecommendationDetail) SetCurrentMinimumHourlyOnDemandSpend(v string) *SavingsPlansPurchaseRecommendationDetail { 11047 s.CurrentMinimumHourlyOnDemandSpend = &v 11048 return s 11049} 11050 11051// SetEstimatedAverageUtilization sets the EstimatedAverageUtilization field's value. 11052func (s *SavingsPlansPurchaseRecommendationDetail) SetEstimatedAverageUtilization(v string) *SavingsPlansPurchaseRecommendationDetail { 11053 s.EstimatedAverageUtilization = &v 11054 return s 11055} 11056 11057// SetEstimatedMonthlySavingsAmount sets the EstimatedMonthlySavingsAmount field's value. 11058func (s *SavingsPlansPurchaseRecommendationDetail) SetEstimatedMonthlySavingsAmount(v string) *SavingsPlansPurchaseRecommendationDetail { 11059 s.EstimatedMonthlySavingsAmount = &v 11060 return s 11061} 11062 11063// SetEstimatedOnDemandCost sets the EstimatedOnDemandCost field's value. 11064func (s *SavingsPlansPurchaseRecommendationDetail) SetEstimatedOnDemandCost(v string) *SavingsPlansPurchaseRecommendationDetail { 11065 s.EstimatedOnDemandCost = &v 11066 return s 11067} 11068 11069// SetEstimatedOnDemandCostWithCurrentCommitment sets the EstimatedOnDemandCostWithCurrentCommitment field's value. 11070func (s *SavingsPlansPurchaseRecommendationDetail) SetEstimatedOnDemandCostWithCurrentCommitment(v string) *SavingsPlansPurchaseRecommendationDetail { 11071 s.EstimatedOnDemandCostWithCurrentCommitment = &v 11072 return s 11073} 11074 11075// SetEstimatedROI sets the EstimatedROI field's value. 11076func (s *SavingsPlansPurchaseRecommendationDetail) SetEstimatedROI(v string) *SavingsPlansPurchaseRecommendationDetail { 11077 s.EstimatedROI = &v 11078 return s 11079} 11080 11081// SetEstimatedSPCost sets the EstimatedSPCost field's value. 11082func (s *SavingsPlansPurchaseRecommendationDetail) SetEstimatedSPCost(v string) *SavingsPlansPurchaseRecommendationDetail { 11083 s.EstimatedSPCost = &v 11084 return s 11085} 11086 11087// SetEstimatedSavingsAmount sets the EstimatedSavingsAmount field's value. 11088func (s *SavingsPlansPurchaseRecommendationDetail) SetEstimatedSavingsAmount(v string) *SavingsPlansPurchaseRecommendationDetail { 11089 s.EstimatedSavingsAmount = &v 11090 return s 11091} 11092 11093// SetEstimatedSavingsPercentage sets the EstimatedSavingsPercentage field's value. 11094func (s *SavingsPlansPurchaseRecommendationDetail) SetEstimatedSavingsPercentage(v string) *SavingsPlansPurchaseRecommendationDetail { 11095 s.EstimatedSavingsPercentage = &v 11096 return s 11097} 11098 11099// SetHourlyCommitmentToPurchase sets the HourlyCommitmentToPurchase field's value. 11100func (s *SavingsPlansPurchaseRecommendationDetail) SetHourlyCommitmentToPurchase(v string) *SavingsPlansPurchaseRecommendationDetail { 11101 s.HourlyCommitmentToPurchase = &v 11102 return s 11103} 11104 11105// SetSavingsPlansDetails sets the SavingsPlansDetails field's value. 11106func (s *SavingsPlansPurchaseRecommendationDetail) SetSavingsPlansDetails(v *SavingsPlansDetails) *SavingsPlansPurchaseRecommendationDetail { 11107 s.SavingsPlansDetails = v 11108 return s 11109} 11110 11111// SetUpfrontCost sets the UpfrontCost field's value. 11112func (s *SavingsPlansPurchaseRecommendationDetail) SetUpfrontCost(v string) *SavingsPlansPurchaseRecommendationDetail { 11113 s.UpfrontCost = &v 11114 return s 11115} 11116 11117// Metadata about your Savings Plans Purchase Recommendations. 11118type SavingsPlansPurchaseRecommendationMetadata struct { 11119 _ struct{} `type:"structure"` 11120 11121 // Additional metadata that may be applicable to the recommendation. 11122 AdditionalMetadata *string `type:"string"` 11123 11124 // The timestamp showing when the recommendations were generated. 11125 GenerationTimestamp *string `type:"string"` 11126 11127 // The unique identifier for the recommendation set. 11128 RecommendationId *string `type:"string"` 11129} 11130 11131// String returns the string representation 11132func (s SavingsPlansPurchaseRecommendationMetadata) String() string { 11133 return awsutil.Prettify(s) 11134} 11135 11136// GoString returns the string representation 11137func (s SavingsPlansPurchaseRecommendationMetadata) GoString() string { 11138 return s.String() 11139} 11140 11141// SetAdditionalMetadata sets the AdditionalMetadata field's value. 11142func (s *SavingsPlansPurchaseRecommendationMetadata) SetAdditionalMetadata(v string) *SavingsPlansPurchaseRecommendationMetadata { 11143 s.AdditionalMetadata = &v 11144 return s 11145} 11146 11147// SetGenerationTimestamp sets the GenerationTimestamp field's value. 11148func (s *SavingsPlansPurchaseRecommendationMetadata) SetGenerationTimestamp(v string) *SavingsPlansPurchaseRecommendationMetadata { 11149 s.GenerationTimestamp = &v 11150 return s 11151} 11152 11153// SetRecommendationId sets the RecommendationId field's value. 11154func (s *SavingsPlansPurchaseRecommendationMetadata) SetRecommendationId(v string) *SavingsPlansPurchaseRecommendationMetadata { 11155 s.RecommendationId = &v 11156 return s 11157} 11158 11159// Summary metrics for your Savings Plans Purchase Recommendations. 11160type SavingsPlansPurchaseRecommendationSummary struct { 11161 _ struct{} `type:"structure"` 11162 11163 // The currency code AWS used to generate the recommendations and present potential 11164 // savings. 11165 CurrencyCode *string `type:"string"` 11166 11167 // The current total on demand spend of the applicable usage types over the 11168 // lookback period. 11169 CurrentOnDemandSpend *string `type:"string"` 11170 11171 // The recommended Savings Plans cost on a daily (24 hourly) basis. 11172 DailyCommitmentToPurchase *string `type:"string"` 11173 11174 // The estimated monthly savings amount, based on the recommended Savings Plans 11175 // purchase. 11176 EstimatedMonthlySavingsAmount *string `type:"string"` 11177 11178 // The estimated On-Demand costs you would expect with no additional commitment, 11179 // based on your usage of the selected time period and the Savings Plans you 11180 // own. 11181 EstimatedOnDemandCostWithCurrentCommitment *string `type:"string"` 11182 11183 // The estimated return on investment based on the recommended Savings Plans 11184 // and estimated savings. 11185 EstimatedROI *string `type:"string"` 11186 11187 // The estimated total savings over the lookback period, based on the purchase 11188 // of the recommended Savings Plans. 11189 EstimatedSavingsAmount *string `type:"string"` 11190 11191 // The estimated savings relative to the total cost of On-Demand usage, over 11192 // the lookback period. This is calculated as estimatedSavingsAmount/ CurrentOnDemandSpend*100. 11193 EstimatedSavingsPercentage *string `type:"string"` 11194 11195 // The estimated total cost of the usage after purchasing the recommended Savings 11196 // Plans. This is a sum of the cost of Savings Plans during this term, and the 11197 // remaining On-Demand usage. 11198 EstimatedTotalCost *string `type:"string"` 11199 11200 // The recommended hourly commitment based on the recommendation parameters. 11201 HourlyCommitmentToPurchase *string `type:"string"` 11202 11203 // The aggregate number of Savings Plans recommendations that exist for your 11204 // account. 11205 TotalRecommendationCount *string `type:"string"` 11206} 11207 11208// String returns the string representation 11209func (s SavingsPlansPurchaseRecommendationSummary) String() string { 11210 return awsutil.Prettify(s) 11211} 11212 11213// GoString returns the string representation 11214func (s SavingsPlansPurchaseRecommendationSummary) GoString() string { 11215 return s.String() 11216} 11217 11218// SetCurrencyCode sets the CurrencyCode field's value. 11219func (s *SavingsPlansPurchaseRecommendationSummary) SetCurrencyCode(v string) *SavingsPlansPurchaseRecommendationSummary { 11220 s.CurrencyCode = &v 11221 return s 11222} 11223 11224// SetCurrentOnDemandSpend sets the CurrentOnDemandSpend field's value. 11225func (s *SavingsPlansPurchaseRecommendationSummary) SetCurrentOnDemandSpend(v string) *SavingsPlansPurchaseRecommendationSummary { 11226 s.CurrentOnDemandSpend = &v 11227 return s 11228} 11229 11230// SetDailyCommitmentToPurchase sets the DailyCommitmentToPurchase field's value. 11231func (s *SavingsPlansPurchaseRecommendationSummary) SetDailyCommitmentToPurchase(v string) *SavingsPlansPurchaseRecommendationSummary { 11232 s.DailyCommitmentToPurchase = &v 11233 return s 11234} 11235 11236// SetEstimatedMonthlySavingsAmount sets the EstimatedMonthlySavingsAmount field's value. 11237func (s *SavingsPlansPurchaseRecommendationSummary) SetEstimatedMonthlySavingsAmount(v string) *SavingsPlansPurchaseRecommendationSummary { 11238 s.EstimatedMonthlySavingsAmount = &v 11239 return s 11240} 11241 11242// SetEstimatedOnDemandCostWithCurrentCommitment sets the EstimatedOnDemandCostWithCurrentCommitment field's value. 11243func (s *SavingsPlansPurchaseRecommendationSummary) SetEstimatedOnDemandCostWithCurrentCommitment(v string) *SavingsPlansPurchaseRecommendationSummary { 11244 s.EstimatedOnDemandCostWithCurrentCommitment = &v 11245 return s 11246} 11247 11248// SetEstimatedROI sets the EstimatedROI field's value. 11249func (s *SavingsPlansPurchaseRecommendationSummary) SetEstimatedROI(v string) *SavingsPlansPurchaseRecommendationSummary { 11250 s.EstimatedROI = &v 11251 return s 11252} 11253 11254// SetEstimatedSavingsAmount sets the EstimatedSavingsAmount field's value. 11255func (s *SavingsPlansPurchaseRecommendationSummary) SetEstimatedSavingsAmount(v string) *SavingsPlansPurchaseRecommendationSummary { 11256 s.EstimatedSavingsAmount = &v 11257 return s 11258} 11259 11260// SetEstimatedSavingsPercentage sets the EstimatedSavingsPercentage field's value. 11261func (s *SavingsPlansPurchaseRecommendationSummary) SetEstimatedSavingsPercentage(v string) *SavingsPlansPurchaseRecommendationSummary { 11262 s.EstimatedSavingsPercentage = &v 11263 return s 11264} 11265 11266// SetEstimatedTotalCost sets the EstimatedTotalCost field's value. 11267func (s *SavingsPlansPurchaseRecommendationSummary) SetEstimatedTotalCost(v string) *SavingsPlansPurchaseRecommendationSummary { 11268 s.EstimatedTotalCost = &v 11269 return s 11270} 11271 11272// SetHourlyCommitmentToPurchase sets the HourlyCommitmentToPurchase field's value. 11273func (s *SavingsPlansPurchaseRecommendationSummary) SetHourlyCommitmentToPurchase(v string) *SavingsPlansPurchaseRecommendationSummary { 11274 s.HourlyCommitmentToPurchase = &v 11275 return s 11276} 11277 11278// SetTotalRecommendationCount sets the TotalRecommendationCount field's value. 11279func (s *SavingsPlansPurchaseRecommendationSummary) SetTotalRecommendationCount(v string) *SavingsPlansPurchaseRecommendationSummary { 11280 s.TotalRecommendationCount = &v 11281 return s 11282} 11283 11284// The amount of savings you're accumulating, against the public On-Demand rate 11285// of the usage accrued in an account. 11286type SavingsPlansSavings struct { 11287 _ struct{} `type:"structure"` 11288 11289 // The savings amount that you are accumulating for the usage that is covered 11290 // by a Savings Plans, when compared to the On-Demand equivalent of the same 11291 // usage. 11292 NetSavings *string `type:"string"` 11293 11294 // How much the amount that the usage would have cost if it was accrued at the 11295 // On-Demand rate. 11296 OnDemandCostEquivalent *string `type:"string"` 11297} 11298 11299// String returns the string representation 11300func (s SavingsPlansSavings) String() string { 11301 return awsutil.Prettify(s) 11302} 11303 11304// GoString returns the string representation 11305func (s SavingsPlansSavings) GoString() string { 11306 return s.String() 11307} 11308 11309// SetNetSavings sets the NetSavings field's value. 11310func (s *SavingsPlansSavings) SetNetSavings(v string) *SavingsPlansSavings { 11311 s.NetSavings = &v 11312 return s 11313} 11314 11315// SetOnDemandCostEquivalent sets the OnDemandCostEquivalent field's value. 11316func (s *SavingsPlansSavings) SetOnDemandCostEquivalent(v string) *SavingsPlansSavings { 11317 s.OnDemandCostEquivalent = &v 11318 return s 11319} 11320 11321// The measurement of how well you are using your existing Savings Plans. 11322type SavingsPlansUtilization struct { 11323 _ struct{} `type:"structure"` 11324 11325 // The total amount of Savings Plans commitment that's been purchased in an 11326 // account (or set of accounts). 11327 TotalCommitment *string `type:"string"` 11328 11329 // The amount of your Savings Plans commitment that was not consumed from Savings 11330 // Plans eligible usage in a specific period. 11331 UnusedCommitment *string `type:"string"` 11332 11333 // The amount of your Savings Plans commitment that was consumed from Savings 11334 // Plans eligible usage in a specific period. 11335 UsedCommitment *string `type:"string"` 11336 11337 // The amount of UsedCommitment divided by the TotalCommitment for your Savings 11338 // Plans. 11339 UtilizationPercentage *string `type:"string"` 11340} 11341 11342// String returns the string representation 11343func (s SavingsPlansUtilization) String() string { 11344 return awsutil.Prettify(s) 11345} 11346 11347// GoString returns the string representation 11348func (s SavingsPlansUtilization) GoString() string { 11349 return s.String() 11350} 11351 11352// SetTotalCommitment sets the TotalCommitment field's value. 11353func (s *SavingsPlansUtilization) SetTotalCommitment(v string) *SavingsPlansUtilization { 11354 s.TotalCommitment = &v 11355 return s 11356} 11357 11358// SetUnusedCommitment sets the UnusedCommitment field's value. 11359func (s *SavingsPlansUtilization) SetUnusedCommitment(v string) *SavingsPlansUtilization { 11360 s.UnusedCommitment = &v 11361 return s 11362} 11363 11364// SetUsedCommitment sets the UsedCommitment field's value. 11365func (s *SavingsPlansUtilization) SetUsedCommitment(v string) *SavingsPlansUtilization { 11366 s.UsedCommitment = &v 11367 return s 11368} 11369 11370// SetUtilizationPercentage sets the UtilizationPercentage field's value. 11371func (s *SavingsPlansUtilization) SetUtilizationPercentage(v string) *SavingsPlansUtilization { 11372 s.UtilizationPercentage = &v 11373 return s 11374} 11375 11376// The aggregated utilization metrics for your Savings Plans usage. 11377type SavingsPlansUtilizationAggregates struct { 11378 _ struct{} `type:"structure"` 11379 11380 // The total amortized commitment for a Savings Plans. This includes the sum 11381 // of the upfront and recurring Savings Plans fees. 11382 AmortizedCommitment *SavingsPlansAmortizedCommitment `type:"structure"` 11383 11384 // The amount saved by using existing Savings Plans. Savings returns both net 11385 // savings from Savings Plans, as well as the onDemandCostEquivalent of the 11386 // Savings Plans when considering the utilization rate. 11387 Savings *SavingsPlansSavings `type:"structure"` 11388 11389 // A ratio of your effectiveness of using existing Savings Plans to apply to 11390 // workloads that are Savings Plans eligible. 11391 // 11392 // Utilization is a required field 11393 Utilization *SavingsPlansUtilization `type:"structure" required:"true"` 11394} 11395 11396// String returns the string representation 11397func (s SavingsPlansUtilizationAggregates) String() string { 11398 return awsutil.Prettify(s) 11399} 11400 11401// GoString returns the string representation 11402func (s SavingsPlansUtilizationAggregates) GoString() string { 11403 return s.String() 11404} 11405 11406// SetAmortizedCommitment sets the AmortizedCommitment field's value. 11407func (s *SavingsPlansUtilizationAggregates) SetAmortizedCommitment(v *SavingsPlansAmortizedCommitment) *SavingsPlansUtilizationAggregates { 11408 s.AmortizedCommitment = v 11409 return s 11410} 11411 11412// SetSavings sets the Savings field's value. 11413func (s *SavingsPlansUtilizationAggregates) SetSavings(v *SavingsPlansSavings) *SavingsPlansUtilizationAggregates { 11414 s.Savings = v 11415 return s 11416} 11417 11418// SetUtilization sets the Utilization field's value. 11419func (s *SavingsPlansUtilizationAggregates) SetUtilization(v *SavingsPlansUtilization) *SavingsPlansUtilizationAggregates { 11420 s.Utilization = v 11421 return s 11422} 11423 11424// The amount of Savings Plans utilization, in hours. 11425type SavingsPlansUtilizationByTime struct { 11426 _ struct{} `type:"structure"` 11427 11428 // The total amortized commitment for a Savings Plans. This includes the sum 11429 // of the upfront and recurring Savings Plans fees. 11430 AmortizedCommitment *SavingsPlansAmortizedCommitment `type:"structure"` 11431 11432 // The amount saved by using existing Savings Plans. Savings returns both net 11433 // savings from Savings Plans as well as the onDemandCostEquivalent of the Savings 11434 // Plans when considering the utilization rate. 11435 Savings *SavingsPlansSavings `type:"structure"` 11436 11437 // The time period of the request. 11438 // 11439 // TimePeriod is a required field 11440 TimePeriod *DateInterval `type:"structure" required:"true"` 11441 11442 // A ratio of your effectiveness of using existing Savings Plans to apply to 11443 // workloads that are Savings Plans eligible. 11444 // 11445 // Utilization is a required field 11446 Utilization *SavingsPlansUtilization `type:"structure" required:"true"` 11447} 11448 11449// String returns the string representation 11450func (s SavingsPlansUtilizationByTime) String() string { 11451 return awsutil.Prettify(s) 11452} 11453 11454// GoString returns the string representation 11455func (s SavingsPlansUtilizationByTime) GoString() string { 11456 return s.String() 11457} 11458 11459// SetAmortizedCommitment sets the AmortizedCommitment field's value. 11460func (s *SavingsPlansUtilizationByTime) SetAmortizedCommitment(v *SavingsPlansAmortizedCommitment) *SavingsPlansUtilizationByTime { 11461 s.AmortizedCommitment = v 11462 return s 11463} 11464 11465// SetSavings sets the Savings field's value. 11466func (s *SavingsPlansUtilizationByTime) SetSavings(v *SavingsPlansSavings) *SavingsPlansUtilizationByTime { 11467 s.Savings = v 11468 return s 11469} 11470 11471// SetTimePeriod sets the TimePeriod field's value. 11472func (s *SavingsPlansUtilizationByTime) SetTimePeriod(v *DateInterval) *SavingsPlansUtilizationByTime { 11473 s.TimePeriod = v 11474 return s 11475} 11476 11477// SetUtilization sets the Utilization field's value. 11478func (s *SavingsPlansUtilizationByTime) SetUtilization(v *SavingsPlansUtilization) *SavingsPlansUtilizationByTime { 11479 s.Utilization = v 11480 return s 11481} 11482 11483// A single daily or monthly Savings Plans utilization rate, and details for 11484// your account. A management account in an organization have access to member 11485// accounts. You can use GetDimensionValues to determine the possible dimension 11486// values. 11487type SavingsPlansUtilizationDetail struct { 11488 _ struct{} `type:"structure"` 11489 11490 // The total amortized commitment for a Savings Plans. Includes the sum of the 11491 // upfront and recurring Savings Plans fees. 11492 AmortizedCommitment *SavingsPlansAmortizedCommitment `type:"structure"` 11493 11494 // The attribute that applies to a specific Dimension. 11495 Attributes map[string]*string `type:"map"` 11496 11497 // The amount saved by using existing Savings Plans. Savings returns both net 11498 // savings from savings plans as well as the onDemandCostEquivalent of the Savings 11499 // Plans when considering the utilization rate. 11500 Savings *SavingsPlansSavings `type:"structure"` 11501 11502 // The unique Amazon Resource Name (ARN) for a particular Savings Plan. 11503 SavingsPlanArn *string `type:"string"` 11504 11505 // A ratio of your effectiveness of using existing Savings Plans to apply to 11506 // workloads that are Savings Plans eligible. 11507 Utilization *SavingsPlansUtilization `type:"structure"` 11508} 11509 11510// String returns the string representation 11511func (s SavingsPlansUtilizationDetail) String() string { 11512 return awsutil.Prettify(s) 11513} 11514 11515// GoString returns the string representation 11516func (s SavingsPlansUtilizationDetail) GoString() string { 11517 return s.String() 11518} 11519 11520// SetAmortizedCommitment sets the AmortizedCommitment field's value. 11521func (s *SavingsPlansUtilizationDetail) SetAmortizedCommitment(v *SavingsPlansAmortizedCommitment) *SavingsPlansUtilizationDetail { 11522 s.AmortizedCommitment = v 11523 return s 11524} 11525 11526// SetAttributes sets the Attributes field's value. 11527func (s *SavingsPlansUtilizationDetail) SetAttributes(v map[string]*string) *SavingsPlansUtilizationDetail { 11528 s.Attributes = v 11529 return s 11530} 11531 11532// SetSavings sets the Savings field's value. 11533func (s *SavingsPlansUtilizationDetail) SetSavings(v *SavingsPlansSavings) *SavingsPlansUtilizationDetail { 11534 s.Savings = v 11535 return s 11536} 11537 11538// SetSavingsPlanArn sets the SavingsPlanArn field's value. 11539func (s *SavingsPlansUtilizationDetail) SetSavingsPlanArn(v string) *SavingsPlansUtilizationDetail { 11540 s.SavingsPlanArn = &v 11541 return s 11542} 11543 11544// SetUtilization sets the Utilization field's value. 11545func (s *SavingsPlansUtilizationDetail) SetUtilization(v *SavingsPlansUtilization) *SavingsPlansUtilizationDetail { 11546 s.Utilization = v 11547 return s 11548} 11549 11550// You've reached the limit on the number of resources you can create, or exceeded 11551// the size of an individual resource. 11552type ServiceQuotaExceededException struct { 11553 _ struct{} `type:"structure"` 11554 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 11555 11556 Message_ *string `locationName:"Message" type:"string"` 11557} 11558 11559// String returns the string representation 11560func (s ServiceQuotaExceededException) String() string { 11561 return awsutil.Prettify(s) 11562} 11563 11564// GoString returns the string representation 11565func (s ServiceQuotaExceededException) GoString() string { 11566 return s.String() 11567} 11568 11569func newErrorServiceQuotaExceededException(v protocol.ResponseMetadata) error { 11570 return &ServiceQuotaExceededException{ 11571 RespMetadata: v, 11572 } 11573} 11574 11575// Code returns the exception type name. 11576func (s *ServiceQuotaExceededException) Code() string { 11577 return "ServiceQuotaExceededException" 11578} 11579 11580// Message returns the exception's message. 11581func (s *ServiceQuotaExceededException) Message() string { 11582 if s.Message_ != nil { 11583 return *s.Message_ 11584 } 11585 return "" 11586} 11587 11588// OrigErr always returns nil, satisfies awserr.Error interface. 11589func (s *ServiceQuotaExceededException) OrigErr() error { 11590 return nil 11591} 11592 11593func (s *ServiceQuotaExceededException) Error() string { 11594 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 11595} 11596 11597// Status code returns the HTTP status code for the request's response error. 11598func (s *ServiceQuotaExceededException) StatusCode() int { 11599 return s.RespMetadata.StatusCode 11600} 11601 11602// RequestID returns the service's response RequestID for request. 11603func (s *ServiceQuotaExceededException) RequestID() string { 11604 return s.RespMetadata.RequestID 11605} 11606 11607// Hardware specifications for the service that you want recommendations for. 11608type ServiceSpecification struct { 11609 _ struct{} `type:"structure"` 11610 11611 // The Amazon EC2 hardware specifications that you want AWS to provide recommendations 11612 // for. 11613 EC2Specification *EC2Specification `type:"structure"` 11614} 11615 11616// String returns the string representation 11617func (s ServiceSpecification) String() string { 11618 return awsutil.Prettify(s) 11619} 11620 11621// GoString returns the string representation 11622func (s ServiceSpecification) GoString() string { 11623 return s.String() 11624} 11625 11626// SetEC2Specification sets the EC2Specification field's value. 11627func (s *ServiceSpecification) SetEC2Specification(v *EC2Specification) *ServiceSpecification { 11628 s.EC2Specification = v 11629 return s 11630} 11631 11632// The details of how to sort the data. 11633type SortDefinition struct { 11634 _ struct{} `type:"structure"` 11635 11636 // The key by which to sort the data. 11637 // 11638 // Key is a required field 11639 Key *string `type:"string" required:"true"` 11640 11641 // The order in which to sort the data. 11642 SortOrder *string `type:"string" enum:"SortOrder"` 11643} 11644 11645// String returns the string representation 11646func (s SortDefinition) String() string { 11647 return awsutil.Prettify(s) 11648} 11649 11650// GoString returns the string representation 11651func (s SortDefinition) GoString() string { 11652 return s.String() 11653} 11654 11655// Validate inspects the fields of the type to determine if they are valid. 11656func (s *SortDefinition) Validate() error { 11657 invalidParams := request.ErrInvalidParams{Context: "SortDefinition"} 11658 if s.Key == nil { 11659 invalidParams.Add(request.NewErrParamRequired("Key")) 11660 } 11661 11662 if invalidParams.Len() > 0 { 11663 return invalidParams 11664 } 11665 return nil 11666} 11667 11668// SetKey sets the Key field's value. 11669func (s *SortDefinition) SetKey(v string) *SortDefinition { 11670 s.Key = &v 11671 return s 11672} 11673 11674// SetSortOrder sets the SortOrder field's value. 11675func (s *SortDefinition) SetSortOrder(v string) *SortDefinition { 11676 s.SortOrder = &v 11677 return s 11678} 11679 11680// The recipient of AnomalySubscription notifications. 11681type Subscriber struct { 11682 _ struct{} `type:"structure"` 11683 11684 // The email address or SNS Amazon Resource Name (ARN), depending on the Type. 11685 Address *string `min:"6" type:"string"` 11686 11687 // Indicates if the subscriber accepts the notifications. 11688 Status *string `type:"string" enum:"SubscriberStatus"` 11689 11690 // The notification delivery channel. 11691 Type *string `type:"string" enum:"SubscriberType"` 11692} 11693 11694// String returns the string representation 11695func (s Subscriber) String() string { 11696 return awsutil.Prettify(s) 11697} 11698 11699// GoString returns the string representation 11700func (s Subscriber) GoString() string { 11701 return s.String() 11702} 11703 11704// Validate inspects the fields of the type to determine if they are valid. 11705func (s *Subscriber) Validate() error { 11706 invalidParams := request.ErrInvalidParams{Context: "Subscriber"} 11707 if s.Address != nil && len(*s.Address) < 6 { 11708 invalidParams.Add(request.NewErrParamMinLen("Address", 6)) 11709 } 11710 11711 if invalidParams.Len() > 0 { 11712 return invalidParams 11713 } 11714 return nil 11715} 11716 11717// SetAddress sets the Address field's value. 11718func (s *Subscriber) SetAddress(v string) *Subscriber { 11719 s.Address = &v 11720 return s 11721} 11722 11723// SetStatus sets the Status field's value. 11724func (s *Subscriber) SetStatus(v string) *Subscriber { 11725 s.Status = &v 11726 return s 11727} 11728 11729// SetType sets the Type field's value. 11730func (s *Subscriber) SetType(v string) *Subscriber { 11731 s.Type = &v 11732 return s 11733} 11734 11735// The values that are available for a tag. 11736// 11737// If Values and Key are not specified, the ABSENT MatchOption is applied to 11738// all tags. That is, filtering on resources with no tags. 11739// 11740// If Values is provided and Key is not specified, the ABSENT MatchOption is 11741// applied to the tag Key only. That is, filtering on resources without the 11742// given tag key. 11743type TagValues struct { 11744 _ struct{} `type:"structure"` 11745 11746 // The key for the tag. 11747 Key *string `type:"string"` 11748 11749 // The match options that you can use to filter your results. MatchOptions is 11750 // only applicable for actions related to Cost Category. The default values 11751 // for MatchOptions are EQUALS and CASE_SENSITIVE. 11752 MatchOptions []*string `type:"list"` 11753 11754 // The specific value of the tag. 11755 Values []*string `type:"list"` 11756} 11757 11758// String returns the string representation 11759func (s TagValues) String() string { 11760 return awsutil.Prettify(s) 11761} 11762 11763// GoString returns the string representation 11764func (s TagValues) GoString() string { 11765 return s.String() 11766} 11767 11768// SetKey sets the Key field's value. 11769func (s *TagValues) SetKey(v string) *TagValues { 11770 s.Key = &v 11771 return s 11772} 11773 11774// SetMatchOptions sets the MatchOptions field's value. 11775func (s *TagValues) SetMatchOptions(v []*string) *TagValues { 11776 s.MatchOptions = v 11777 return s 11778} 11779 11780// SetValues sets the Values field's value. 11781func (s *TagValues) SetValues(v []*string) *TagValues { 11782 s.Values = v 11783 return s 11784} 11785 11786// Details on recommended instance. 11787type TargetInstance struct { 11788 _ struct{} `type:"structure"` 11789 11790 // The currency code that AWS used to calculate the costs for this instance. 11791 CurrencyCode *string `type:"string"` 11792 11793 // Indicates whether this recommendation is the defaulted AWS recommendation. 11794 DefaultTargetInstance *bool `type:"boolean"` 11795 11796 // Expected cost to operate this instance type on a monthly basis. 11797 EstimatedMonthlyCost *string `type:"string"` 11798 11799 // Estimated savings resulting from modification, on a monthly basis. 11800 EstimatedMonthlySavings *string `type:"string"` 11801 11802 // Expected utilization metrics for target instance type. 11803 ExpectedResourceUtilization *ResourceUtilization `type:"structure"` 11804 11805 // Details on the target instance type. 11806 ResourceDetails *ResourceDetails `type:"structure"` 11807} 11808 11809// String returns the string representation 11810func (s TargetInstance) String() string { 11811 return awsutil.Prettify(s) 11812} 11813 11814// GoString returns the string representation 11815func (s TargetInstance) GoString() string { 11816 return s.String() 11817} 11818 11819// SetCurrencyCode sets the CurrencyCode field's value. 11820func (s *TargetInstance) SetCurrencyCode(v string) *TargetInstance { 11821 s.CurrencyCode = &v 11822 return s 11823} 11824 11825// SetDefaultTargetInstance sets the DefaultTargetInstance field's value. 11826func (s *TargetInstance) SetDefaultTargetInstance(v bool) *TargetInstance { 11827 s.DefaultTargetInstance = &v 11828 return s 11829} 11830 11831// SetEstimatedMonthlyCost sets the EstimatedMonthlyCost field's value. 11832func (s *TargetInstance) SetEstimatedMonthlyCost(v string) *TargetInstance { 11833 s.EstimatedMonthlyCost = &v 11834 return s 11835} 11836 11837// SetEstimatedMonthlySavings sets the EstimatedMonthlySavings field's value. 11838func (s *TargetInstance) SetEstimatedMonthlySavings(v string) *TargetInstance { 11839 s.EstimatedMonthlySavings = &v 11840 return s 11841} 11842 11843// SetExpectedResourceUtilization sets the ExpectedResourceUtilization field's value. 11844func (s *TargetInstance) SetExpectedResourceUtilization(v *ResourceUtilization) *TargetInstance { 11845 s.ExpectedResourceUtilization = v 11846 return s 11847} 11848 11849// SetResourceDetails sets the ResourceDetails field's value. 11850func (s *TargetInstance) SetResourceDetails(v *ResourceDetails) *TargetInstance { 11851 s.ResourceDetails = v 11852 return s 11853} 11854 11855// Details on termination recommendation. 11856type TerminateRecommendationDetail struct { 11857 _ struct{} `type:"structure"` 11858 11859 // The currency code that AWS used to calculate the costs for this instance. 11860 CurrencyCode *string `type:"string"` 11861 11862 // Estimated savings resulting from modification, on a monthly basis. 11863 EstimatedMonthlySavings *string `type:"string"` 11864} 11865 11866// String returns the string representation 11867func (s TerminateRecommendationDetail) String() string { 11868 return awsutil.Prettify(s) 11869} 11870 11871// GoString returns the string representation 11872func (s TerminateRecommendationDetail) GoString() string { 11873 return s.String() 11874} 11875 11876// SetCurrencyCode sets the CurrencyCode field's value. 11877func (s *TerminateRecommendationDetail) SetCurrencyCode(v string) *TerminateRecommendationDetail { 11878 s.CurrencyCode = &v 11879 return s 11880} 11881 11882// SetEstimatedMonthlySavings sets the EstimatedMonthlySavings field's value. 11883func (s *TerminateRecommendationDetail) SetEstimatedMonthlySavings(v string) *TerminateRecommendationDetail { 11884 s.EstimatedMonthlySavings = &v 11885 return s 11886} 11887 11888// Filters cost anomalies based on the total impact. 11889type TotalImpactFilter struct { 11890 _ struct{} `type:"structure"` 11891 11892 // The upper bound dollar value used in the filter. 11893 EndValue *float64 `type:"double"` 11894 11895 // The comparing value used in the filter. 11896 // 11897 // NumericOperator is a required field 11898 NumericOperator *string `type:"string" required:"true" enum:"NumericOperator"` 11899 11900 // The lower bound dollar value used in the filter. 11901 // 11902 // StartValue is a required field 11903 StartValue *float64 `type:"double" required:"true"` 11904} 11905 11906// String returns the string representation 11907func (s TotalImpactFilter) String() string { 11908 return awsutil.Prettify(s) 11909} 11910 11911// GoString returns the string representation 11912func (s TotalImpactFilter) GoString() string { 11913 return s.String() 11914} 11915 11916// Validate inspects the fields of the type to determine if they are valid. 11917func (s *TotalImpactFilter) Validate() error { 11918 invalidParams := request.ErrInvalidParams{Context: "TotalImpactFilter"} 11919 if s.NumericOperator == nil { 11920 invalidParams.Add(request.NewErrParamRequired("NumericOperator")) 11921 } 11922 if s.StartValue == nil { 11923 invalidParams.Add(request.NewErrParamRequired("StartValue")) 11924 } 11925 11926 if invalidParams.Len() > 0 { 11927 return invalidParams 11928 } 11929 return nil 11930} 11931 11932// SetEndValue sets the EndValue field's value. 11933func (s *TotalImpactFilter) SetEndValue(v float64) *TotalImpactFilter { 11934 s.EndValue = &v 11935 return s 11936} 11937 11938// SetNumericOperator sets the NumericOperator field's value. 11939func (s *TotalImpactFilter) SetNumericOperator(v string) *TotalImpactFilter { 11940 s.NumericOperator = &v 11941 return s 11942} 11943 11944// SetStartValue sets the StartValue field's value. 11945func (s *TotalImpactFilter) SetStartValue(v float64) *TotalImpactFilter { 11946 s.StartValue = &v 11947 return s 11948} 11949 11950// The cost anomaly monitor does not exist for the account. 11951type UnknownMonitorException struct { 11952 _ struct{} `type:"structure"` 11953 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 11954 11955 Message_ *string `locationName:"Message" type:"string"` 11956} 11957 11958// String returns the string representation 11959func (s UnknownMonitorException) String() string { 11960 return awsutil.Prettify(s) 11961} 11962 11963// GoString returns the string representation 11964func (s UnknownMonitorException) GoString() string { 11965 return s.String() 11966} 11967 11968func newErrorUnknownMonitorException(v protocol.ResponseMetadata) error { 11969 return &UnknownMonitorException{ 11970 RespMetadata: v, 11971 } 11972} 11973 11974// Code returns the exception type name. 11975func (s *UnknownMonitorException) Code() string { 11976 return "UnknownMonitorException" 11977} 11978 11979// Message returns the exception's message. 11980func (s *UnknownMonitorException) Message() string { 11981 if s.Message_ != nil { 11982 return *s.Message_ 11983 } 11984 return "" 11985} 11986 11987// OrigErr always returns nil, satisfies awserr.Error interface. 11988func (s *UnknownMonitorException) OrigErr() error { 11989 return nil 11990} 11991 11992func (s *UnknownMonitorException) Error() string { 11993 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 11994} 11995 11996// Status code returns the HTTP status code for the request's response error. 11997func (s *UnknownMonitorException) StatusCode() int { 11998 return s.RespMetadata.StatusCode 11999} 12000 12001// RequestID returns the service's response RequestID for request. 12002func (s *UnknownMonitorException) RequestID() string { 12003 return s.RespMetadata.RequestID 12004} 12005 12006// The cost anomaly subscription does not exist for the account. 12007type UnknownSubscriptionException struct { 12008 _ struct{} `type:"structure"` 12009 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 12010 12011 Message_ *string `locationName:"Message" type:"string"` 12012} 12013 12014// String returns the string representation 12015func (s UnknownSubscriptionException) String() string { 12016 return awsutil.Prettify(s) 12017} 12018 12019// GoString returns the string representation 12020func (s UnknownSubscriptionException) GoString() string { 12021 return s.String() 12022} 12023 12024func newErrorUnknownSubscriptionException(v protocol.ResponseMetadata) error { 12025 return &UnknownSubscriptionException{ 12026 RespMetadata: v, 12027 } 12028} 12029 12030// Code returns the exception type name. 12031func (s *UnknownSubscriptionException) Code() string { 12032 return "UnknownSubscriptionException" 12033} 12034 12035// Message returns the exception's message. 12036func (s *UnknownSubscriptionException) Message() string { 12037 if s.Message_ != nil { 12038 return *s.Message_ 12039 } 12040 return "" 12041} 12042 12043// OrigErr always returns nil, satisfies awserr.Error interface. 12044func (s *UnknownSubscriptionException) OrigErr() error { 12045 return nil 12046} 12047 12048func (s *UnknownSubscriptionException) Error() string { 12049 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 12050} 12051 12052// Status code returns the HTTP status code for the request's response error. 12053func (s *UnknownSubscriptionException) StatusCode() int { 12054 return s.RespMetadata.StatusCode 12055} 12056 12057// RequestID returns the service's response RequestID for request. 12058func (s *UnknownSubscriptionException) RequestID() string { 12059 return s.RespMetadata.RequestID 12060} 12061 12062// Cost Explorer was unable to identify the usage unit. Provide UsageType/UsageTypeGroup 12063// filter selections that contain matching units, for example: hours. 12064type UnresolvableUsageUnitException struct { 12065 _ struct{} `type:"structure"` 12066 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 12067 12068 Message_ *string `locationName:"Message" type:"string"` 12069} 12070 12071// String returns the string representation 12072func (s UnresolvableUsageUnitException) String() string { 12073 return awsutil.Prettify(s) 12074} 12075 12076// GoString returns the string representation 12077func (s UnresolvableUsageUnitException) GoString() string { 12078 return s.String() 12079} 12080 12081func newErrorUnresolvableUsageUnitException(v protocol.ResponseMetadata) error { 12082 return &UnresolvableUsageUnitException{ 12083 RespMetadata: v, 12084 } 12085} 12086 12087// Code returns the exception type name. 12088func (s *UnresolvableUsageUnitException) Code() string { 12089 return "UnresolvableUsageUnitException" 12090} 12091 12092// Message returns the exception's message. 12093func (s *UnresolvableUsageUnitException) Message() string { 12094 if s.Message_ != nil { 12095 return *s.Message_ 12096 } 12097 return "" 12098} 12099 12100// OrigErr always returns nil, satisfies awserr.Error interface. 12101func (s *UnresolvableUsageUnitException) OrigErr() error { 12102 return nil 12103} 12104 12105func (s *UnresolvableUsageUnitException) Error() string { 12106 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 12107} 12108 12109// Status code returns the HTTP status code for the request's response error. 12110func (s *UnresolvableUsageUnitException) StatusCode() int { 12111 return s.RespMetadata.StatusCode 12112} 12113 12114// RequestID returns the service's response RequestID for request. 12115func (s *UnresolvableUsageUnitException) RequestID() string { 12116 return s.RespMetadata.RequestID 12117} 12118 12119type UpdateAnomalyMonitorInput struct { 12120 _ struct{} `type:"structure"` 12121 12122 // Cost anomaly monitor Amazon Resource Names (ARNs). 12123 // 12124 // MonitorArn is a required field 12125 MonitorArn *string `type:"string" required:"true"` 12126 12127 // The new name for the cost anomaly monitor. 12128 MonitorName *string `type:"string"` 12129} 12130 12131// String returns the string representation 12132func (s UpdateAnomalyMonitorInput) String() string { 12133 return awsutil.Prettify(s) 12134} 12135 12136// GoString returns the string representation 12137func (s UpdateAnomalyMonitorInput) GoString() string { 12138 return s.String() 12139} 12140 12141// Validate inspects the fields of the type to determine if they are valid. 12142func (s *UpdateAnomalyMonitorInput) Validate() error { 12143 invalidParams := request.ErrInvalidParams{Context: "UpdateAnomalyMonitorInput"} 12144 if s.MonitorArn == nil { 12145 invalidParams.Add(request.NewErrParamRequired("MonitorArn")) 12146 } 12147 12148 if invalidParams.Len() > 0 { 12149 return invalidParams 12150 } 12151 return nil 12152} 12153 12154// SetMonitorArn sets the MonitorArn field's value. 12155func (s *UpdateAnomalyMonitorInput) SetMonitorArn(v string) *UpdateAnomalyMonitorInput { 12156 s.MonitorArn = &v 12157 return s 12158} 12159 12160// SetMonitorName sets the MonitorName field's value. 12161func (s *UpdateAnomalyMonitorInput) SetMonitorName(v string) *UpdateAnomalyMonitorInput { 12162 s.MonitorName = &v 12163 return s 12164} 12165 12166type UpdateAnomalyMonitorOutput struct { 12167 _ struct{} `type:"structure"` 12168 12169 // A cost anomaly monitor ARN. 12170 // 12171 // MonitorArn is a required field 12172 MonitorArn *string `type:"string" required:"true"` 12173} 12174 12175// String returns the string representation 12176func (s UpdateAnomalyMonitorOutput) String() string { 12177 return awsutil.Prettify(s) 12178} 12179 12180// GoString returns the string representation 12181func (s UpdateAnomalyMonitorOutput) GoString() string { 12182 return s.String() 12183} 12184 12185// SetMonitorArn sets the MonitorArn field's value. 12186func (s *UpdateAnomalyMonitorOutput) SetMonitorArn(v string) *UpdateAnomalyMonitorOutput { 12187 s.MonitorArn = &v 12188 return s 12189} 12190 12191type UpdateAnomalySubscriptionInput struct { 12192 _ struct{} `type:"structure"` 12193 12194 // The update to the frequency value at which subscribers will receive notifications. 12195 Frequency *string `type:"string" enum:"AnomalySubscriptionFrequency"` 12196 12197 // A list of cost anomaly monitor ARNs. 12198 MonitorArnList []*string `type:"list"` 12199 12200 // The update to the subscriber list. 12201 Subscribers []*Subscriber `type:"list"` 12202 12203 // A cost anomaly subscription Amazon Resource Name (ARN). 12204 // 12205 // SubscriptionArn is a required field 12206 SubscriptionArn *string `type:"string" required:"true"` 12207 12208 // The subscription's new name. 12209 SubscriptionName *string `type:"string"` 12210 12211 // The update to the threshold value for receiving notifications. 12212 Threshold *float64 `type:"double"` 12213} 12214 12215// String returns the string representation 12216func (s UpdateAnomalySubscriptionInput) String() string { 12217 return awsutil.Prettify(s) 12218} 12219 12220// GoString returns the string representation 12221func (s UpdateAnomalySubscriptionInput) GoString() string { 12222 return s.String() 12223} 12224 12225// Validate inspects the fields of the type to determine if they are valid. 12226func (s *UpdateAnomalySubscriptionInput) Validate() error { 12227 invalidParams := request.ErrInvalidParams{Context: "UpdateAnomalySubscriptionInput"} 12228 if s.SubscriptionArn == nil { 12229 invalidParams.Add(request.NewErrParamRequired("SubscriptionArn")) 12230 } 12231 if s.Subscribers != nil { 12232 for i, v := range s.Subscribers { 12233 if v == nil { 12234 continue 12235 } 12236 if err := v.Validate(); err != nil { 12237 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Subscribers", i), err.(request.ErrInvalidParams)) 12238 } 12239 } 12240 } 12241 12242 if invalidParams.Len() > 0 { 12243 return invalidParams 12244 } 12245 return nil 12246} 12247 12248// SetFrequency sets the Frequency field's value. 12249func (s *UpdateAnomalySubscriptionInput) SetFrequency(v string) *UpdateAnomalySubscriptionInput { 12250 s.Frequency = &v 12251 return s 12252} 12253 12254// SetMonitorArnList sets the MonitorArnList field's value. 12255func (s *UpdateAnomalySubscriptionInput) SetMonitorArnList(v []*string) *UpdateAnomalySubscriptionInput { 12256 s.MonitorArnList = v 12257 return s 12258} 12259 12260// SetSubscribers sets the Subscribers field's value. 12261func (s *UpdateAnomalySubscriptionInput) SetSubscribers(v []*Subscriber) *UpdateAnomalySubscriptionInput { 12262 s.Subscribers = v 12263 return s 12264} 12265 12266// SetSubscriptionArn sets the SubscriptionArn field's value. 12267func (s *UpdateAnomalySubscriptionInput) SetSubscriptionArn(v string) *UpdateAnomalySubscriptionInput { 12268 s.SubscriptionArn = &v 12269 return s 12270} 12271 12272// SetSubscriptionName sets the SubscriptionName field's value. 12273func (s *UpdateAnomalySubscriptionInput) SetSubscriptionName(v string) *UpdateAnomalySubscriptionInput { 12274 s.SubscriptionName = &v 12275 return s 12276} 12277 12278// SetThreshold sets the Threshold field's value. 12279func (s *UpdateAnomalySubscriptionInput) SetThreshold(v float64) *UpdateAnomalySubscriptionInput { 12280 s.Threshold = &v 12281 return s 12282} 12283 12284type UpdateAnomalySubscriptionOutput struct { 12285 _ struct{} `type:"structure"` 12286 12287 // A cost anomaly subscription ARN. 12288 // 12289 // SubscriptionArn is a required field 12290 SubscriptionArn *string `type:"string" required:"true"` 12291} 12292 12293// String returns the string representation 12294func (s UpdateAnomalySubscriptionOutput) String() string { 12295 return awsutil.Prettify(s) 12296} 12297 12298// GoString returns the string representation 12299func (s UpdateAnomalySubscriptionOutput) GoString() string { 12300 return s.String() 12301} 12302 12303// SetSubscriptionArn sets the SubscriptionArn field's value. 12304func (s *UpdateAnomalySubscriptionOutput) SetSubscriptionArn(v string) *UpdateAnomalySubscriptionOutput { 12305 s.SubscriptionArn = &v 12306 return s 12307} 12308 12309type UpdateCostCategoryDefinitionInput struct { 12310 _ struct{} `type:"structure"` 12311 12312 // The unique identifier for your Cost Category. 12313 // 12314 // CostCategoryArn is a required field 12315 CostCategoryArn *string `min:"20" type:"string" required:"true"` 12316 12317 // The rule schema version in this particular Cost Category. 12318 // 12319 // RuleVersion is a required field 12320 RuleVersion *string `type:"string" required:"true" enum:"CostCategoryRuleVersion"` 12321 12322 // The Expression object used to categorize costs. For more information, see 12323 // CostCategoryRule (https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_CostCategoryRule.html). 12324 // 12325 // Rules is a required field 12326 Rules []*CostCategoryRule `min:"1" type:"list" required:"true"` 12327} 12328 12329// String returns the string representation 12330func (s UpdateCostCategoryDefinitionInput) String() string { 12331 return awsutil.Prettify(s) 12332} 12333 12334// GoString returns the string representation 12335func (s UpdateCostCategoryDefinitionInput) GoString() string { 12336 return s.String() 12337} 12338 12339// Validate inspects the fields of the type to determine if they are valid. 12340func (s *UpdateCostCategoryDefinitionInput) Validate() error { 12341 invalidParams := request.ErrInvalidParams{Context: "UpdateCostCategoryDefinitionInput"} 12342 if s.CostCategoryArn == nil { 12343 invalidParams.Add(request.NewErrParamRequired("CostCategoryArn")) 12344 } 12345 if s.CostCategoryArn != nil && len(*s.CostCategoryArn) < 20 { 12346 invalidParams.Add(request.NewErrParamMinLen("CostCategoryArn", 20)) 12347 } 12348 if s.RuleVersion == nil { 12349 invalidParams.Add(request.NewErrParamRequired("RuleVersion")) 12350 } 12351 if s.Rules == nil { 12352 invalidParams.Add(request.NewErrParamRequired("Rules")) 12353 } 12354 if s.Rules != nil && len(s.Rules) < 1 { 12355 invalidParams.Add(request.NewErrParamMinLen("Rules", 1)) 12356 } 12357 if s.Rules != nil { 12358 for i, v := range s.Rules { 12359 if v == nil { 12360 continue 12361 } 12362 if err := v.Validate(); err != nil { 12363 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams)) 12364 } 12365 } 12366 } 12367 12368 if invalidParams.Len() > 0 { 12369 return invalidParams 12370 } 12371 return nil 12372} 12373 12374// SetCostCategoryArn sets the CostCategoryArn field's value. 12375func (s *UpdateCostCategoryDefinitionInput) SetCostCategoryArn(v string) *UpdateCostCategoryDefinitionInput { 12376 s.CostCategoryArn = &v 12377 return s 12378} 12379 12380// SetRuleVersion sets the RuleVersion field's value. 12381func (s *UpdateCostCategoryDefinitionInput) SetRuleVersion(v string) *UpdateCostCategoryDefinitionInput { 12382 s.RuleVersion = &v 12383 return s 12384} 12385 12386// SetRules sets the Rules field's value. 12387func (s *UpdateCostCategoryDefinitionInput) SetRules(v []*CostCategoryRule) *UpdateCostCategoryDefinitionInput { 12388 s.Rules = v 12389 return s 12390} 12391 12392type UpdateCostCategoryDefinitionOutput struct { 12393 _ struct{} `type:"structure"` 12394 12395 // The unique identifier for your Cost Category. 12396 CostCategoryArn *string `min:"20" type:"string"` 12397 12398 // The Cost Category's effective start date. 12399 EffectiveStart *string `min:"20" type:"string"` 12400} 12401 12402// String returns the string representation 12403func (s UpdateCostCategoryDefinitionOutput) String() string { 12404 return awsutil.Prettify(s) 12405} 12406 12407// GoString returns the string representation 12408func (s UpdateCostCategoryDefinitionOutput) GoString() string { 12409 return s.String() 12410} 12411 12412// SetCostCategoryArn sets the CostCategoryArn field's value. 12413func (s *UpdateCostCategoryDefinitionOutput) SetCostCategoryArn(v string) *UpdateCostCategoryDefinitionOutput { 12414 s.CostCategoryArn = &v 12415 return s 12416} 12417 12418// SetEffectiveStart sets the EffectiveStart field's value. 12419func (s *UpdateCostCategoryDefinitionOutput) SetEffectiveStart(v string) *UpdateCostCategoryDefinitionOutput { 12420 s.EffectiveStart = &v 12421 return s 12422} 12423 12424// The amount of utilization, in hours. 12425type UtilizationByTime struct { 12426 _ struct{} `type:"structure"` 12427 12428 // The groups that this utilization result uses. 12429 Groups []*ReservationUtilizationGroup `type:"list"` 12430 12431 // The period of time that this utilization was used for. 12432 TimePeriod *DateInterval `type:"structure"` 12433 12434 // The total number of reservation hours that were used. 12435 Total *ReservationAggregates `type:"structure"` 12436} 12437 12438// String returns the string representation 12439func (s UtilizationByTime) String() string { 12440 return awsutil.Prettify(s) 12441} 12442 12443// GoString returns the string representation 12444func (s UtilizationByTime) GoString() string { 12445 return s.String() 12446} 12447 12448// SetGroups sets the Groups field's value. 12449func (s *UtilizationByTime) SetGroups(v []*ReservationUtilizationGroup) *UtilizationByTime { 12450 s.Groups = v 12451 return s 12452} 12453 12454// SetTimePeriod sets the TimePeriod field's value. 12455func (s *UtilizationByTime) SetTimePeriod(v *DateInterval) *UtilizationByTime { 12456 s.TimePeriod = v 12457 return s 12458} 12459 12460// SetTotal sets the Total field's value. 12461func (s *UtilizationByTime) SetTotal(v *ReservationAggregates) *UtilizationByTime { 12462 s.Total = v 12463 return s 12464} 12465 12466const ( 12467 // AccountScopePayer is a AccountScope enum value 12468 AccountScopePayer = "PAYER" 12469 12470 // AccountScopeLinked is a AccountScope enum value 12471 AccountScopeLinked = "LINKED" 12472) 12473 12474// AccountScope_Values returns all elements of the AccountScope enum 12475func AccountScope_Values() []string { 12476 return []string{ 12477 AccountScopePayer, 12478 AccountScopeLinked, 12479 } 12480} 12481 12482const ( 12483 // AnomalyFeedbackTypeYes is a AnomalyFeedbackType enum value 12484 AnomalyFeedbackTypeYes = "YES" 12485 12486 // AnomalyFeedbackTypeNo is a AnomalyFeedbackType enum value 12487 AnomalyFeedbackTypeNo = "NO" 12488 12489 // AnomalyFeedbackTypePlannedActivity is a AnomalyFeedbackType enum value 12490 AnomalyFeedbackTypePlannedActivity = "PLANNED_ACTIVITY" 12491) 12492 12493// AnomalyFeedbackType_Values returns all elements of the AnomalyFeedbackType enum 12494func AnomalyFeedbackType_Values() []string { 12495 return []string{ 12496 AnomalyFeedbackTypeYes, 12497 AnomalyFeedbackTypeNo, 12498 AnomalyFeedbackTypePlannedActivity, 12499 } 12500} 12501 12502const ( 12503 // AnomalySubscriptionFrequencyDaily is a AnomalySubscriptionFrequency enum value 12504 AnomalySubscriptionFrequencyDaily = "DAILY" 12505 12506 // AnomalySubscriptionFrequencyImmediate is a AnomalySubscriptionFrequency enum value 12507 AnomalySubscriptionFrequencyImmediate = "IMMEDIATE" 12508 12509 // AnomalySubscriptionFrequencyWeekly is a AnomalySubscriptionFrequency enum value 12510 AnomalySubscriptionFrequencyWeekly = "WEEKLY" 12511) 12512 12513// AnomalySubscriptionFrequency_Values returns all elements of the AnomalySubscriptionFrequency enum 12514func AnomalySubscriptionFrequency_Values() []string { 12515 return []string{ 12516 AnomalySubscriptionFrequencyDaily, 12517 AnomalySubscriptionFrequencyImmediate, 12518 AnomalySubscriptionFrequencyWeekly, 12519 } 12520} 12521 12522const ( 12523 // ContextCostAndUsage is a Context enum value 12524 ContextCostAndUsage = "COST_AND_USAGE" 12525 12526 // ContextReservations is a Context enum value 12527 ContextReservations = "RESERVATIONS" 12528 12529 // ContextSavingsPlans is a Context enum value 12530 ContextSavingsPlans = "SAVINGS_PLANS" 12531) 12532 12533// Context_Values returns all elements of the Context enum 12534func Context_Values() []string { 12535 return []string{ 12536 ContextCostAndUsage, 12537 ContextReservations, 12538 ContextSavingsPlans, 12539 } 12540} 12541 12542// The rule schema version in this particular Cost Category. 12543const ( 12544 // CostCategoryRuleVersionCostCategoryExpressionV1 is a CostCategoryRuleVersion enum value 12545 CostCategoryRuleVersionCostCategoryExpressionV1 = "CostCategoryExpression.v1" 12546) 12547 12548// CostCategoryRuleVersion_Values returns all elements of the CostCategoryRuleVersion enum 12549func CostCategoryRuleVersion_Values() []string { 12550 return []string{ 12551 CostCategoryRuleVersionCostCategoryExpressionV1, 12552 } 12553} 12554 12555const ( 12556 // CostCategoryStatusProcessing is a CostCategoryStatus enum value 12557 CostCategoryStatusProcessing = "PROCESSING" 12558 12559 // CostCategoryStatusApplied is a CostCategoryStatus enum value 12560 CostCategoryStatusApplied = "APPLIED" 12561) 12562 12563// CostCategoryStatus_Values returns all elements of the CostCategoryStatus enum 12564func CostCategoryStatus_Values() []string { 12565 return []string{ 12566 CostCategoryStatusProcessing, 12567 CostCategoryStatusApplied, 12568 } 12569} 12570 12571const ( 12572 // CostCategoryStatusComponentCostExplorer is a CostCategoryStatusComponent enum value 12573 CostCategoryStatusComponentCostExplorer = "COST_EXPLORER" 12574) 12575 12576// CostCategoryStatusComponent_Values returns all elements of the CostCategoryStatusComponent enum 12577func CostCategoryStatusComponent_Values() []string { 12578 return []string{ 12579 CostCategoryStatusComponentCostExplorer, 12580 } 12581} 12582 12583const ( 12584 // DimensionAz is a Dimension enum value 12585 DimensionAz = "AZ" 12586 12587 // DimensionInstanceType is a Dimension enum value 12588 DimensionInstanceType = "INSTANCE_TYPE" 12589 12590 // DimensionLinkedAccount is a Dimension enum value 12591 DimensionLinkedAccount = "LINKED_ACCOUNT" 12592 12593 // DimensionLinkedAccountName is a Dimension enum value 12594 DimensionLinkedAccountName = "LINKED_ACCOUNT_NAME" 12595 12596 // DimensionOperation is a Dimension enum value 12597 DimensionOperation = "OPERATION" 12598 12599 // DimensionPurchaseType is a Dimension enum value 12600 DimensionPurchaseType = "PURCHASE_TYPE" 12601 12602 // DimensionRegion is a Dimension enum value 12603 DimensionRegion = "REGION" 12604 12605 // DimensionService is a Dimension enum value 12606 DimensionService = "SERVICE" 12607 12608 // DimensionServiceCode is a Dimension enum value 12609 DimensionServiceCode = "SERVICE_CODE" 12610 12611 // DimensionUsageType is a Dimension enum value 12612 DimensionUsageType = "USAGE_TYPE" 12613 12614 // DimensionUsageTypeGroup is a Dimension enum value 12615 DimensionUsageTypeGroup = "USAGE_TYPE_GROUP" 12616 12617 // DimensionRecordType is a Dimension enum value 12618 DimensionRecordType = "RECORD_TYPE" 12619 12620 // DimensionOperatingSystem is a Dimension enum value 12621 DimensionOperatingSystem = "OPERATING_SYSTEM" 12622 12623 // DimensionTenancy is a Dimension enum value 12624 DimensionTenancy = "TENANCY" 12625 12626 // DimensionScope is a Dimension enum value 12627 DimensionScope = "SCOPE" 12628 12629 // DimensionPlatform is a Dimension enum value 12630 DimensionPlatform = "PLATFORM" 12631 12632 // DimensionSubscriptionId is a Dimension enum value 12633 DimensionSubscriptionId = "SUBSCRIPTION_ID" 12634 12635 // DimensionLegalEntityName is a Dimension enum value 12636 DimensionLegalEntityName = "LEGAL_ENTITY_NAME" 12637 12638 // DimensionDeploymentOption is a Dimension enum value 12639 DimensionDeploymentOption = "DEPLOYMENT_OPTION" 12640 12641 // DimensionDatabaseEngine is a Dimension enum value 12642 DimensionDatabaseEngine = "DATABASE_ENGINE" 12643 12644 // DimensionCacheEngine is a Dimension enum value 12645 DimensionCacheEngine = "CACHE_ENGINE" 12646 12647 // DimensionInstanceTypeFamily is a Dimension enum value 12648 DimensionInstanceTypeFamily = "INSTANCE_TYPE_FAMILY" 12649 12650 // DimensionBillingEntity is a Dimension enum value 12651 DimensionBillingEntity = "BILLING_ENTITY" 12652 12653 // DimensionReservationId is a Dimension enum value 12654 DimensionReservationId = "RESERVATION_ID" 12655 12656 // DimensionResourceId is a Dimension enum value 12657 DimensionResourceId = "RESOURCE_ID" 12658 12659 // DimensionRightsizingType is a Dimension enum value 12660 DimensionRightsizingType = "RIGHTSIZING_TYPE" 12661 12662 // DimensionSavingsPlansType is a Dimension enum value 12663 DimensionSavingsPlansType = "SAVINGS_PLANS_TYPE" 12664 12665 // DimensionSavingsPlanArn is a Dimension enum value 12666 DimensionSavingsPlanArn = "SAVINGS_PLAN_ARN" 12667 12668 // DimensionPaymentOption is a Dimension enum value 12669 DimensionPaymentOption = "PAYMENT_OPTION" 12670 12671 // DimensionAgreementEndDateTimeAfter is a Dimension enum value 12672 DimensionAgreementEndDateTimeAfter = "AGREEMENT_END_DATE_TIME_AFTER" 12673 12674 // DimensionAgreementEndDateTimeBefore is a Dimension enum value 12675 DimensionAgreementEndDateTimeBefore = "AGREEMENT_END_DATE_TIME_BEFORE" 12676) 12677 12678// Dimension_Values returns all elements of the Dimension enum 12679func Dimension_Values() []string { 12680 return []string{ 12681 DimensionAz, 12682 DimensionInstanceType, 12683 DimensionLinkedAccount, 12684 DimensionLinkedAccountName, 12685 DimensionOperation, 12686 DimensionPurchaseType, 12687 DimensionRegion, 12688 DimensionService, 12689 DimensionServiceCode, 12690 DimensionUsageType, 12691 DimensionUsageTypeGroup, 12692 DimensionRecordType, 12693 DimensionOperatingSystem, 12694 DimensionTenancy, 12695 DimensionScope, 12696 DimensionPlatform, 12697 DimensionSubscriptionId, 12698 DimensionLegalEntityName, 12699 DimensionDeploymentOption, 12700 DimensionDatabaseEngine, 12701 DimensionCacheEngine, 12702 DimensionInstanceTypeFamily, 12703 DimensionBillingEntity, 12704 DimensionReservationId, 12705 DimensionResourceId, 12706 DimensionRightsizingType, 12707 DimensionSavingsPlansType, 12708 DimensionSavingsPlanArn, 12709 DimensionPaymentOption, 12710 DimensionAgreementEndDateTimeAfter, 12711 DimensionAgreementEndDateTimeBefore, 12712 } 12713} 12714 12715const ( 12716 // GranularityDaily is a Granularity enum value 12717 GranularityDaily = "DAILY" 12718 12719 // GranularityMonthly is a Granularity enum value 12720 GranularityMonthly = "MONTHLY" 12721 12722 // GranularityHourly is a Granularity enum value 12723 GranularityHourly = "HOURLY" 12724) 12725 12726// Granularity_Values returns all elements of the Granularity enum 12727func Granularity_Values() []string { 12728 return []string{ 12729 GranularityDaily, 12730 GranularityMonthly, 12731 GranularityHourly, 12732 } 12733} 12734 12735const ( 12736 // GroupDefinitionTypeDimension is a GroupDefinitionType enum value 12737 GroupDefinitionTypeDimension = "DIMENSION" 12738 12739 // GroupDefinitionTypeTag is a GroupDefinitionType enum value 12740 GroupDefinitionTypeTag = "TAG" 12741 12742 // GroupDefinitionTypeCostCategory is a GroupDefinitionType enum value 12743 GroupDefinitionTypeCostCategory = "COST_CATEGORY" 12744) 12745 12746// GroupDefinitionType_Values returns all elements of the GroupDefinitionType enum 12747func GroupDefinitionType_Values() []string { 12748 return []string{ 12749 GroupDefinitionTypeDimension, 12750 GroupDefinitionTypeTag, 12751 GroupDefinitionTypeCostCategory, 12752 } 12753} 12754 12755const ( 12756 // LookbackPeriodInDaysSevenDays is a LookbackPeriodInDays enum value 12757 LookbackPeriodInDaysSevenDays = "SEVEN_DAYS" 12758 12759 // LookbackPeriodInDaysThirtyDays is a LookbackPeriodInDays enum value 12760 LookbackPeriodInDaysThirtyDays = "THIRTY_DAYS" 12761 12762 // LookbackPeriodInDaysSixtyDays is a LookbackPeriodInDays enum value 12763 LookbackPeriodInDaysSixtyDays = "SIXTY_DAYS" 12764) 12765 12766// LookbackPeriodInDays_Values returns all elements of the LookbackPeriodInDays enum 12767func LookbackPeriodInDays_Values() []string { 12768 return []string{ 12769 LookbackPeriodInDaysSevenDays, 12770 LookbackPeriodInDaysThirtyDays, 12771 LookbackPeriodInDaysSixtyDays, 12772 } 12773} 12774 12775const ( 12776 // MatchOptionEquals is a MatchOption enum value 12777 MatchOptionEquals = "EQUALS" 12778 12779 // MatchOptionAbsent is a MatchOption enum value 12780 MatchOptionAbsent = "ABSENT" 12781 12782 // MatchOptionStartsWith is a MatchOption enum value 12783 MatchOptionStartsWith = "STARTS_WITH" 12784 12785 // MatchOptionEndsWith is a MatchOption enum value 12786 MatchOptionEndsWith = "ENDS_WITH" 12787 12788 // MatchOptionContains is a MatchOption enum value 12789 MatchOptionContains = "CONTAINS" 12790 12791 // MatchOptionCaseSensitive is a MatchOption enum value 12792 MatchOptionCaseSensitive = "CASE_SENSITIVE" 12793 12794 // MatchOptionCaseInsensitive is a MatchOption enum value 12795 MatchOptionCaseInsensitive = "CASE_INSENSITIVE" 12796) 12797 12798// MatchOption_Values returns all elements of the MatchOption enum 12799func MatchOption_Values() []string { 12800 return []string{ 12801 MatchOptionEquals, 12802 MatchOptionAbsent, 12803 MatchOptionStartsWith, 12804 MatchOptionEndsWith, 12805 MatchOptionContains, 12806 MatchOptionCaseSensitive, 12807 MatchOptionCaseInsensitive, 12808 } 12809} 12810 12811const ( 12812 // MetricBlendedCost is a Metric enum value 12813 MetricBlendedCost = "BLENDED_COST" 12814 12815 // MetricUnblendedCost is a Metric enum value 12816 MetricUnblendedCost = "UNBLENDED_COST" 12817 12818 // MetricAmortizedCost is a Metric enum value 12819 MetricAmortizedCost = "AMORTIZED_COST" 12820 12821 // MetricNetUnblendedCost is a Metric enum value 12822 MetricNetUnblendedCost = "NET_UNBLENDED_COST" 12823 12824 // MetricNetAmortizedCost is a Metric enum value 12825 MetricNetAmortizedCost = "NET_AMORTIZED_COST" 12826 12827 // MetricUsageQuantity is a Metric enum value 12828 MetricUsageQuantity = "USAGE_QUANTITY" 12829 12830 // MetricNormalizedUsageAmount is a Metric enum value 12831 MetricNormalizedUsageAmount = "NORMALIZED_USAGE_AMOUNT" 12832) 12833 12834// Metric_Values returns all elements of the Metric enum 12835func Metric_Values() []string { 12836 return []string{ 12837 MetricBlendedCost, 12838 MetricUnblendedCost, 12839 MetricAmortizedCost, 12840 MetricNetUnblendedCost, 12841 MetricNetAmortizedCost, 12842 MetricUsageQuantity, 12843 MetricNormalizedUsageAmount, 12844 } 12845} 12846 12847const ( 12848 // MonitorDimensionService is a MonitorDimension enum value 12849 MonitorDimensionService = "SERVICE" 12850) 12851 12852// MonitorDimension_Values returns all elements of the MonitorDimension enum 12853func MonitorDimension_Values() []string { 12854 return []string{ 12855 MonitorDimensionService, 12856 } 12857} 12858 12859const ( 12860 // MonitorTypeDimensional is a MonitorType enum value 12861 MonitorTypeDimensional = "DIMENSIONAL" 12862 12863 // MonitorTypeCustom is a MonitorType enum value 12864 MonitorTypeCustom = "CUSTOM" 12865) 12866 12867// MonitorType_Values returns all elements of the MonitorType enum 12868func MonitorType_Values() []string { 12869 return []string{ 12870 MonitorTypeDimensional, 12871 MonitorTypeCustom, 12872 } 12873} 12874 12875const ( 12876 // NumericOperatorEqual is a NumericOperator enum value 12877 NumericOperatorEqual = "EQUAL" 12878 12879 // NumericOperatorGreaterThanOrEqual is a NumericOperator enum value 12880 NumericOperatorGreaterThanOrEqual = "GREATER_THAN_OR_EQUAL" 12881 12882 // NumericOperatorLessThanOrEqual is a NumericOperator enum value 12883 NumericOperatorLessThanOrEqual = "LESS_THAN_OR_EQUAL" 12884 12885 // NumericOperatorGreaterThan is a NumericOperator enum value 12886 NumericOperatorGreaterThan = "GREATER_THAN" 12887 12888 // NumericOperatorLessThan is a NumericOperator enum value 12889 NumericOperatorLessThan = "LESS_THAN" 12890 12891 // NumericOperatorBetween is a NumericOperator enum value 12892 NumericOperatorBetween = "BETWEEN" 12893) 12894 12895// NumericOperator_Values returns all elements of the NumericOperator enum 12896func NumericOperator_Values() []string { 12897 return []string{ 12898 NumericOperatorEqual, 12899 NumericOperatorGreaterThanOrEqual, 12900 NumericOperatorLessThanOrEqual, 12901 NumericOperatorGreaterThan, 12902 NumericOperatorLessThan, 12903 NumericOperatorBetween, 12904 } 12905} 12906 12907const ( 12908 // OfferingClassStandard is a OfferingClass enum value 12909 OfferingClassStandard = "STANDARD" 12910 12911 // OfferingClassConvertible is a OfferingClass enum value 12912 OfferingClassConvertible = "CONVERTIBLE" 12913) 12914 12915// OfferingClass_Values returns all elements of the OfferingClass enum 12916func OfferingClass_Values() []string { 12917 return []string{ 12918 OfferingClassStandard, 12919 OfferingClassConvertible, 12920 } 12921} 12922 12923const ( 12924 // PaymentOptionNoUpfront is a PaymentOption enum value 12925 PaymentOptionNoUpfront = "NO_UPFRONT" 12926 12927 // PaymentOptionPartialUpfront is a PaymentOption enum value 12928 PaymentOptionPartialUpfront = "PARTIAL_UPFRONT" 12929 12930 // PaymentOptionAllUpfront is a PaymentOption enum value 12931 PaymentOptionAllUpfront = "ALL_UPFRONT" 12932 12933 // PaymentOptionLightUtilization is a PaymentOption enum value 12934 PaymentOptionLightUtilization = "LIGHT_UTILIZATION" 12935 12936 // PaymentOptionMediumUtilization is a PaymentOption enum value 12937 PaymentOptionMediumUtilization = "MEDIUM_UTILIZATION" 12938 12939 // PaymentOptionHeavyUtilization is a PaymentOption enum value 12940 PaymentOptionHeavyUtilization = "HEAVY_UTILIZATION" 12941) 12942 12943// PaymentOption_Values returns all elements of the PaymentOption enum 12944func PaymentOption_Values() []string { 12945 return []string{ 12946 PaymentOptionNoUpfront, 12947 PaymentOptionPartialUpfront, 12948 PaymentOptionAllUpfront, 12949 PaymentOptionLightUtilization, 12950 PaymentOptionMediumUtilization, 12951 PaymentOptionHeavyUtilization, 12952 } 12953} 12954 12955const ( 12956 // RecommendationTargetSameInstanceFamily is a RecommendationTarget enum value 12957 RecommendationTargetSameInstanceFamily = "SAME_INSTANCE_FAMILY" 12958 12959 // RecommendationTargetCrossInstanceFamily is a RecommendationTarget enum value 12960 RecommendationTargetCrossInstanceFamily = "CROSS_INSTANCE_FAMILY" 12961) 12962 12963// RecommendationTarget_Values returns all elements of the RecommendationTarget enum 12964func RecommendationTarget_Values() []string { 12965 return []string{ 12966 RecommendationTargetSameInstanceFamily, 12967 RecommendationTargetCrossInstanceFamily, 12968 } 12969} 12970 12971const ( 12972 // RightsizingTypeTerminate is a RightsizingType enum value 12973 RightsizingTypeTerminate = "TERMINATE" 12974 12975 // RightsizingTypeModify is a RightsizingType enum value 12976 RightsizingTypeModify = "MODIFY" 12977) 12978 12979// RightsizingType_Values returns all elements of the RightsizingType enum 12980func RightsizingType_Values() []string { 12981 return []string{ 12982 RightsizingTypeTerminate, 12983 RightsizingTypeModify, 12984 } 12985} 12986 12987const ( 12988 // SavingsPlansDataTypeAttributes is a SavingsPlansDataType enum value 12989 SavingsPlansDataTypeAttributes = "ATTRIBUTES" 12990 12991 // SavingsPlansDataTypeUtilization is a SavingsPlansDataType enum value 12992 SavingsPlansDataTypeUtilization = "UTILIZATION" 12993 12994 // SavingsPlansDataTypeAmortizedCommitment is a SavingsPlansDataType enum value 12995 SavingsPlansDataTypeAmortizedCommitment = "AMORTIZED_COMMITMENT" 12996 12997 // SavingsPlansDataTypeSavings is a SavingsPlansDataType enum value 12998 SavingsPlansDataTypeSavings = "SAVINGS" 12999) 13000 13001// SavingsPlansDataType_Values returns all elements of the SavingsPlansDataType enum 13002func SavingsPlansDataType_Values() []string { 13003 return []string{ 13004 SavingsPlansDataTypeAttributes, 13005 SavingsPlansDataTypeUtilization, 13006 SavingsPlansDataTypeAmortizedCommitment, 13007 SavingsPlansDataTypeSavings, 13008 } 13009} 13010 13011const ( 13012 // SortOrderAscending is a SortOrder enum value 13013 SortOrderAscending = "ASCENDING" 13014 13015 // SortOrderDescending is a SortOrder enum value 13016 SortOrderDescending = "DESCENDING" 13017) 13018 13019// SortOrder_Values returns all elements of the SortOrder enum 13020func SortOrder_Values() []string { 13021 return []string{ 13022 SortOrderAscending, 13023 SortOrderDescending, 13024 } 13025} 13026 13027const ( 13028 // SubscriberStatusConfirmed is a SubscriberStatus enum value 13029 SubscriberStatusConfirmed = "CONFIRMED" 13030 13031 // SubscriberStatusDeclined is a SubscriberStatus enum value 13032 SubscriberStatusDeclined = "DECLINED" 13033) 13034 13035// SubscriberStatus_Values returns all elements of the SubscriberStatus enum 13036func SubscriberStatus_Values() []string { 13037 return []string{ 13038 SubscriberStatusConfirmed, 13039 SubscriberStatusDeclined, 13040 } 13041} 13042 13043const ( 13044 // SubscriberTypeEmail is a SubscriberType enum value 13045 SubscriberTypeEmail = "EMAIL" 13046 13047 // SubscriberTypeSns is a SubscriberType enum value 13048 SubscriberTypeSns = "SNS" 13049) 13050 13051// SubscriberType_Values returns all elements of the SubscriberType enum 13052func SubscriberType_Values() []string { 13053 return []string{ 13054 SubscriberTypeEmail, 13055 SubscriberTypeSns, 13056 } 13057} 13058 13059const ( 13060 // SupportedSavingsPlansTypeComputeSp is a SupportedSavingsPlansType enum value 13061 SupportedSavingsPlansTypeComputeSp = "COMPUTE_SP" 13062 13063 // SupportedSavingsPlansTypeEc2InstanceSp is a SupportedSavingsPlansType enum value 13064 SupportedSavingsPlansTypeEc2InstanceSp = "EC2_INSTANCE_SP" 13065) 13066 13067// SupportedSavingsPlansType_Values returns all elements of the SupportedSavingsPlansType enum 13068func SupportedSavingsPlansType_Values() []string { 13069 return []string{ 13070 SupportedSavingsPlansTypeComputeSp, 13071 SupportedSavingsPlansTypeEc2InstanceSp, 13072 } 13073} 13074 13075const ( 13076 // TermInYearsOneYear is a TermInYears enum value 13077 TermInYearsOneYear = "ONE_YEAR" 13078 13079 // TermInYearsThreeYears is a TermInYears enum value 13080 TermInYearsThreeYears = "THREE_YEARS" 13081) 13082 13083// TermInYears_Values returns all elements of the TermInYears enum 13084func TermInYears_Values() []string { 13085 return []string{ 13086 TermInYearsOneYear, 13087 TermInYearsThreeYears, 13088 } 13089} 13090