Soto icon

Soto

Budgets

Service object for interacting with AWS Budgets service.

public struct Budgets: AWSService

The AWS Budgets API enables you to use AWS Budgets to plan your service usage, service costs, and instance reservations. The API reference provides descriptions, syntax, and usage examples for each of the actions and data types for AWS Budgets.

Budgets provide you with a way to see the following information:

  • How close your plan is to your budgeted amount or to the free tier limits

  • Your usage-to-date, including how much you've used of your Reserved Instances (RIs)

  • Your current estimated charges from AWS, and how much your predicted usage will accrue in charges by the end of the month

  • How much of your budget has been used

AWS updates your budget status several times a day. Budgets track your unblended costs, subscriptions, refunds, and RIs. You can create the following types of budgets:

  • Cost budgets - Plan how much you want to spend on a service.

  • Usage budgets - Plan how much you want to use one or more services.

  • RI utilization budgets - Define a utilization threshold, and receive alerts when your RI usage falls below that threshold. This lets you see if your RIs are unused or under-utilized.

  • RI coverage budgets - Define a coverage threshold, and receive alerts when the number of your instance hours that are covered by RIs fall below that threshold. This lets you see how much of your instance usage is covered by a reservation.

Service Endpoint

The AWS Budgets API provides the following endpoint:

  • https://budgets.amazonaws.com

For information about costs that are associated with the AWS Budgets API, see AWS Cost Management Pricing.

Inheritance

AWSService

Initializers

init(client:partition:endpoint:timeout:byteBufferAllocator:options:)

Initialize the Budgets client

public init(client: AWSClient, partition: AWSPartition = .aws, endpoint: String? = nil, timeout: TimeAmount? = nil, byteBufferAllocator: ByteBufferAllocator = ByteBufferAllocator(), options: AWSServiceConfig.Options = [])

Parameters

  • client: AWSClient used to process requests
  • partition: AWS partition where service resides, standard (.aws), china (.awscn), government (.awsusgov).
  • endpoint: Custom endpoint URL to use instead of standard AWS servers
  • timeout: Timeout value for HTTP requests

init(from:patch:)

Initializer required by AWSService.with(middlewares:​timeout:​byteBufferAllocator:​options). You are not able to use this initializer directly as there are no public initializers for AWSServiceConfig.Patch. Please use AWSService.with(middlewares:​timeout:​byteBufferAllocator:​options) instead.

public init(from: Budgets, patch: AWSServiceConfig.Patch)

Properties

client

Client used for communication with AWS

let client: AWSClient

config

Service configuration

let config: AWSServiceConfig

Methods

createBudget(_:logger:on:)

public func createBudget(_ input: CreateBudgetRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<CreateBudgetResponse>

Creates a budget and, if included, notifications and subscribers.

Only one of BudgetLimit or PlannedBudgetLimits can be present in the syntax at one time. Use the syntax that matches your case. The Request Syntax section shows the BudgetLimit syntax. For PlannedBudgetLimits, see the Examples section.

createBudgetAction(_:logger:on:)

public func createBudgetAction(_ input: CreateBudgetActionRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<CreateBudgetActionResponse>

Creates a budget action.

createNotification(_:logger:on:)

public func createNotification(_ input: CreateNotificationRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<CreateNotificationResponse>

Creates a notification. You must create the budget before you create the associated notification.

createSubscriber(_:logger:on:)

public func createSubscriber(_ input: CreateSubscriberRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<CreateSubscriberResponse>

Creates a subscriber. You must create the associated budget and notification before you create the subscriber.

deleteBudget(_:logger:on:)

public func deleteBudget(_ input: DeleteBudgetRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DeleteBudgetResponse>

Deletes a budget. You can delete your budget at any time.

Deleting a budget also deletes the notifications and subscribers that are associated with that budget.

deleteBudgetAction(_:logger:on:)

public func deleteBudgetAction(_ input: DeleteBudgetActionRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DeleteBudgetActionResponse>

Deletes a budget action.

deleteNotification(_:logger:on:)

public func deleteNotification(_ input: DeleteNotificationRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DeleteNotificationResponse>

Deletes a notification.

Deleting a notification also deletes the subscribers that are associated with the notification.

deleteSubscriber(_:logger:on:)

public func deleteSubscriber(_ input: DeleteSubscriberRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DeleteSubscriberResponse>

Deletes a subscriber.

Deleting the last subscriber to a notification also deletes the notification.

describeBudget(_:logger:on:)

public func describeBudget(_ input: DescribeBudgetRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DescribeBudgetResponse>

Describes a budget.

The Request Syntax section shows the BudgetLimit syntax. For PlannedBudgetLimits, see the Examples section.

describeBudgetAction(_:logger:on:)

public func describeBudgetAction(_ input: DescribeBudgetActionRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DescribeBudgetActionResponse>

Describes a budget action detail.

describeBudgetActionHistories(_:logger:on:)

public func describeBudgetActionHistories(_ input: DescribeBudgetActionHistoriesRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DescribeBudgetActionHistoriesResponse>

Describes a budget action history detail.

describeBudgetActionsForAccount(_:logger:on:)

public func describeBudgetActionsForAccount(_ input: DescribeBudgetActionsForAccountRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DescribeBudgetActionsForAccountResponse>

Describes all of the budget actions for an account.

describeBudgetActionsForBudget(_:logger:on:)

public func describeBudgetActionsForBudget(_ input: DescribeBudgetActionsForBudgetRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DescribeBudgetActionsForBudgetResponse>

Describes all of the budget actions for a budget.

describeBudgetPerformanceHistory(_:logger:on:)

public func describeBudgetPerformanceHistory(_ input: DescribeBudgetPerformanceHistoryRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DescribeBudgetPerformanceHistoryResponse>

Describes the history for DAILY, MONTHLY, and QUARTERLY budgets. Budget history isn't available for ANNUAL budgets.

describeBudgets(_:logger:on:)

public func describeBudgets(_ input: DescribeBudgetsRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DescribeBudgetsResponse>

Lists the budgets that are associated with an account.

The Request Syntax section shows the BudgetLimit syntax. For PlannedBudgetLimits, see the Examples section.

describeNotificationsForBudget(_:logger:on:)

public func describeNotificationsForBudget(_ input: DescribeNotificationsForBudgetRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DescribeNotificationsForBudgetResponse>

Lists the notifications that are associated with a budget.

describeSubscribersForNotification(_:logger:on:)

public func describeSubscribersForNotification(_ input: DescribeSubscribersForNotificationRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DescribeSubscribersForNotificationResponse>

Lists the subscribers that are associated with a notification.

executeBudgetAction(_:logger:on:)

public func executeBudgetAction(_ input: ExecuteBudgetActionRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<ExecuteBudgetActionResponse>

Executes a budget action.

updateBudget(_:logger:on:)

public func updateBudget(_ input: UpdateBudgetRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<UpdateBudgetResponse>

Updates a budget. You can change every part of a budget except for the budgetName and the calculatedSpend. When you modify a budget, the calculatedSpend drops to zero until AWS has new usage data to use for forecasting.

Only one of BudgetLimit or PlannedBudgetLimits can be present in the syntax at one time. Use the syntax that matches your case. The Request Syntax section shows the BudgetLimit syntax. For PlannedBudgetLimits, see the Examples section.

updateBudgetAction(_:logger:on:)

public func updateBudgetAction(_ input: UpdateBudgetActionRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<UpdateBudgetActionResponse>

Updates a budget action.

updateNotification(_:logger:on:)

public func updateNotification(_ input: UpdateNotificationRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<UpdateNotificationResponse>

Updates a notification.

updateSubscriber(_:logger:on:)

public func updateSubscriber(_ input: UpdateSubscriberRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<UpdateSubscriberResponse>

Updates a subscriber.

describeBudgetActionHistoriesPaginator(_:_:logger:on:onPage:)

public func describeBudgetActionHistoriesPaginator<Result>(_ input: DescribeBudgetActionHistoriesRequest, _ initialValue: Result, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil, onPage: @escaping (Result, DescribeBudgetActionHistoriesResponse, EventLoop) -> EventLoopFuture<(Bool, Result)>) -> EventLoopFuture<Result>

Describes a budget action history detail.

Provide paginated results to closure onPage for it to combine them into one result. This works in a similar manner to Array.reduce<Result>(_:_:) -> Result.

Parameters:

  • input: Input for request
  • initialValue: The value to use as the initial accumulating value. initialValue is passed to onPage the first time it is called.
  • logger: Logger used flot logging
  • eventLoop: EventLoop to run this process on
  • onPage: closure called with each paginated response. It combines an accumulating result with the contents of response. This combined result is then returned along with a boolean indicating if the paginate operation should continue.

describeBudgetActionHistoriesPaginator(_:logger:on:onPage:)

Provide paginated results to closure onPage.

public func describeBudgetActionHistoriesPaginator(_ input: DescribeBudgetActionHistoriesRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil, onPage: @escaping (DescribeBudgetActionHistoriesResponse, EventLoop) -> EventLoopFuture<Bool>) -> EventLoopFuture<Void>

Parameters

  • input: Input for request
  • logger: Logger used flot logging
  • eventLoop: EventLoop to run this process on
  • onPage: closure called with each block of entries. Returns boolean indicating whether we should continue.

describeBudgetActionsForAccountPaginator(_:_:logger:on:onPage:)

public func describeBudgetActionsForAccountPaginator<Result>(_ input: DescribeBudgetActionsForAccountRequest, _ initialValue: Result, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil, onPage: @escaping (Result, DescribeBudgetActionsForAccountResponse, EventLoop) -> EventLoopFuture<(Bool, Result)>) -> EventLoopFuture<Result>

Describes all of the budget actions for an account.

Provide paginated results to closure onPage for it to combine them into one result. This works in a similar manner to Array.reduce<Result>(_:_:) -> Result.

Parameters:

  • input: Input for request
  • initialValue: The value to use as the initial accumulating value. initialValue is passed to onPage the first time it is called.
  • logger: Logger used flot logging
  • eventLoop: EventLoop to run this process on
  • onPage: closure called with each paginated response. It combines an accumulating result with the contents of response. This combined result is then returned along with a boolean indicating if the paginate operation should continue.

describeBudgetActionsForAccountPaginator(_:logger:on:onPage:)

Provide paginated results to closure onPage.

public func describeBudgetActionsForAccountPaginator(_ input: DescribeBudgetActionsForAccountRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil, onPage: @escaping (DescribeBudgetActionsForAccountResponse, EventLoop) -> EventLoopFuture<Bool>) -> EventLoopFuture<Void>

Parameters

  • input: Input for request
  • logger: Logger used flot logging
  • eventLoop: EventLoop to run this process on
  • onPage: closure called with each block of entries. Returns boolean indicating whether we should continue.

describeBudgetActionsForBudgetPaginator(_:_:logger:on:onPage:)

public func describeBudgetActionsForBudgetPaginator<Result>(_ input: DescribeBudgetActionsForBudgetRequest, _ initialValue: Result, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil, onPage: @escaping (Result, DescribeBudgetActionsForBudgetResponse, EventLoop) -> EventLoopFuture<(Bool, Result)>) -> EventLoopFuture<Result>

Describes all of the budget actions for a budget.

Provide paginated results to closure onPage for it to combine them into one result. This works in a similar manner to Array.reduce<Result>(_:_:) -> Result.

Parameters:

  • input: Input for request
  • initialValue: The value to use as the initial accumulating value. initialValue is passed to onPage the first time it is called.
  • logger: Logger used flot logging
  • eventLoop: EventLoop to run this process on
  • onPage: closure called with each paginated response. It combines an accumulating result with the contents of response. This combined result is then returned along with a boolean indicating if the paginate operation should continue.

describeBudgetActionsForBudgetPaginator(_:logger:on:onPage:)

Provide paginated results to closure onPage.

public func describeBudgetActionsForBudgetPaginator(_ input: DescribeBudgetActionsForBudgetRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil, onPage: @escaping (DescribeBudgetActionsForBudgetResponse, EventLoop) -> EventLoopFuture<Bool>) -> EventLoopFuture<Void>

Parameters

  • input: Input for request
  • logger: Logger used flot logging
  • eventLoop: EventLoop to run this process on
  • onPage: closure called with each block of entries. Returns boolean indicating whether we should continue.

describeBudgetPerformanceHistoryPaginator(_:_:logger:on:onPage:)

public func describeBudgetPerformanceHistoryPaginator<Result>(_ input: DescribeBudgetPerformanceHistoryRequest, _ initialValue: Result, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil, onPage: @escaping (Result, DescribeBudgetPerformanceHistoryResponse, EventLoop) -> EventLoopFuture<(Bool, Result)>) -> EventLoopFuture<Result>

Describes the history for DAILY, MONTHLY, and QUARTERLY budgets. Budget history isn't available for ANNUAL budgets.

Provide paginated results to closure onPage for it to combine them into one result. This works in a similar manner to Array.reduce<Result>(_:_:) -> Result.

Parameters:

  • input: Input for request
  • initialValue: The value to use as the initial accumulating value. initialValue is passed to onPage the first time it is called.
  • logger: Logger used flot logging
  • eventLoop: EventLoop to run this process on
  • onPage: closure called with each paginated response. It combines an accumulating result with the contents of response. This combined result is then returned along with a boolean indicating if the paginate operation should continue.

describeBudgetPerformanceHistoryPaginator(_:logger:on:onPage:)

Provide paginated results to closure onPage.

public func describeBudgetPerformanceHistoryPaginator(_ input: DescribeBudgetPerformanceHistoryRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil, onPage: @escaping (DescribeBudgetPerformanceHistoryResponse, EventLoop) -> EventLoopFuture<Bool>) -> EventLoopFuture<Void>

Parameters

  • input: Input for request
  • logger: Logger used flot logging
  • eventLoop: EventLoop to run this process on
  • onPage: closure called with each block of entries. Returns boolean indicating whether we should continue.

describeBudgetsPaginator(_:_:logger:on:onPage:)

public func describeBudgetsPaginator<Result>(_ input: DescribeBudgetsRequest, _ initialValue: Result, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil, onPage: @escaping (Result, DescribeBudgetsResponse, EventLoop) -> EventLoopFuture<(Bool, Result)>) -> EventLoopFuture<Result>

Lists the budgets that are associated with an account.

The Request Syntax section shows the BudgetLimit syntax. For PlannedBudgetLimits, see the Examples section.

Provide paginated results to closure onPage for it to combine them into one result. This works in a similar manner to Array.reduce<Result>(_:_:) -> Result.

Parameters:

  • input: Input for request
  • initialValue: The value to use as the initial accumulating value. initialValue is passed to onPage the first time it is called.
  • logger: Logger used flot logging
  • eventLoop: EventLoop to run this process on
  • onPage: closure called with each paginated response. It combines an accumulating result with the contents of response. This combined result is then returned along with a boolean indicating if the paginate operation should continue.

describeBudgetsPaginator(_:logger:on:onPage:)

Provide paginated results to closure onPage.

public func describeBudgetsPaginator(_ input: DescribeBudgetsRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil, onPage: @escaping (DescribeBudgetsResponse, EventLoop) -> EventLoopFuture<Bool>) -> EventLoopFuture<Void>

Parameters

  • input: Input for request
  • logger: Logger used flot logging
  • eventLoop: EventLoop to run this process on
  • onPage: closure called with each block of entries. Returns boolean indicating whether we should continue.

describeNotificationsForBudgetPaginator(_:_:logger:on:onPage:)

public func describeNotificationsForBudgetPaginator<Result>(_ input: DescribeNotificationsForBudgetRequest, _ initialValue: Result, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil, onPage: @escaping (Result, DescribeNotificationsForBudgetResponse, EventLoop) -> EventLoopFuture<(Bool, Result)>) -> EventLoopFuture<Result>

Lists the notifications that are associated with a budget.

Provide paginated results to closure onPage for it to combine them into one result. This works in a similar manner to Array.reduce<Result>(_:_:) -> Result.

Parameters:

  • input: Input for request
  • initialValue: The value to use as the initial accumulating value. initialValue is passed to onPage the first time it is called.
  • logger: Logger used flot logging
  • eventLoop: EventLoop to run this process on
  • onPage: closure called with each paginated response. It combines an accumulating result with the contents of response. This combined result is then returned along with a boolean indicating if the paginate operation should continue.

describeNotificationsForBudgetPaginator(_:logger:on:onPage:)

Provide paginated results to closure onPage.

public func describeNotificationsForBudgetPaginator(_ input: DescribeNotificationsForBudgetRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil, onPage: @escaping (DescribeNotificationsForBudgetResponse, EventLoop) -> EventLoopFuture<Bool>) -> EventLoopFuture<Void>

Parameters

  • input: Input for request
  • logger: Logger used flot logging
  • eventLoop: EventLoop to run this process on
  • onPage: closure called with each block of entries. Returns boolean indicating whether we should continue.

describeSubscribersForNotificationPaginator(_:_:logger:on:onPage:)

public func describeSubscribersForNotificationPaginator<Result>(_ input: DescribeSubscribersForNotificationRequest, _ initialValue: Result, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil, onPage: @escaping (Result, DescribeSubscribersForNotificationResponse, EventLoop) -> EventLoopFuture<(Bool, Result)>) -> EventLoopFuture<Result>

Lists the subscribers that are associated with a notification.

Provide paginated results to closure onPage for it to combine them into one result. This works in a similar manner to Array.reduce<Result>(_:_:) -> Result.

Parameters:

  • input: Input for request
  • initialValue: The value to use as the initial accumulating value. initialValue is passed to onPage the first time it is called.
  • logger: Logger used flot logging
  • eventLoop: EventLoop to run this process on
  • onPage: closure called with each paginated response. It combines an accumulating result with the contents of response. This combined result is then returned along with a boolean indicating if the paginate operation should continue.

describeSubscribersForNotificationPaginator(_:logger:on:onPage:)

Provide paginated results to closure onPage.

public func describeSubscribersForNotificationPaginator(_ input: DescribeSubscribersForNotificationRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil, onPage: @escaping (DescribeSubscribersForNotificationResponse, EventLoop) -> EventLoopFuture<Bool>) -> EventLoopFuture<Void>

Parameters

  • input: Input for request
  • logger: Logger used flot logging
  • eventLoop: EventLoop to run this process on
  • onPage: closure called with each block of entries. Returns boolean indicating whether we should continue.