Class: Aws::Billing::Client
- Inherits:
-
Seahorse::Client::Base
- Object
- Seahorse::Client::Base
- Aws::Billing::Client
- Includes:
- ClientStubs
- Defined in:
- gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb
Overview
An API client for Billing. To construct a client, you need to configure a :region and :credentials.
client = Aws::Billing::Client.new(
region: region_name,
credentials: credentials,
# ...
)
For details on configuring region and credentials see the developer guide.
See #initialize for a full list of supported configuration options.
Instance Attribute Summary
Attributes inherited from Seahorse::Client::Base
API Operations collapse
-
#associate_contract(params = {}) ⇒ Struct
Private Pricing contracts let eligible payer accounts manage private pricing agreements with Amazon Web Services.
-
#associate_source_views(params = {}) ⇒ Types::AssociateSourceViewsResponse
Associates one or more source billing views with an existing billing view.
-
#cancel_contractual_investment_attestation(params = {}) ⇒ Struct
Cancels a contractual investment attestation.
-
#create_billing_view(params = {}) ⇒ Types::CreateBillingViewResponse
Creates a billing view with the specified billing view attributes.
-
#create_contractual_investment_attestation(params = {}) ⇒ Types::CreateContractualInvestmentAttestationResponse
Creates an attestation that claims an investment award for a completed milestone or outcome within a private pricing contract.
-
#delete_billing_view(params = {}) ⇒ Types::DeleteBillingViewResponse
Deletes the specified billing view.
-
#disassociate_contract(params = {}) ⇒ Struct
Removes the association between a private pricing contract and your Amazon Web Services account.
-
#disassociate_source_views(params = {}) ⇒ Types::DisassociateSourceViewsResponse
Removes the association between one or more source billing views and an existing billing view.
-
#get_billing_preferences(params = {}) ⇒ Types::GetBillingPreferencesResponse
Retrieves billing preferences for the specified feature.
-
#get_billing_view(params = {}) ⇒ Types::GetBillingViewResponse
Returns the metadata associated to the specified billing view ARN.
-
#get_contract_information(params = {}) ⇒ Types::GetContractInformationResponse
Returns information about a specific private pricing contract, including its term (duration), eligible payer accounts, investment accounts, and legal entities.
-
#get_credit_allocation_history(params = {}) ⇒ Types::GetCreditAllocationHistoryResponse
Returns the per-billing-month allocation history for credits applied to an Amazon Web Services account's bills.
-
#get_credits(params = {}) ⇒ Types::GetCreditsResponse
Returns the list of Amazon Web Services account credits for the specified account.
-
#get_enterprise_support_charge_summary(params = {}) ⇒ Types::GetEnterpriseSupportChargeSummaryResponse
Returns a summary of Enterprise Support data aggregated across all accounts in the Enterprise Support profile.
-
#get_enterprise_support_contract_details(params = {}) ⇒ Types::GetEnterpriseSupportContractDetailsResponse
Returns Enterprise Support contract details.
-
#get_resource_policy(params = {}) ⇒ Types::GetResourcePolicyResponse
Returns the resource-based policy document attached to the resource in
JSONformat. -
#list_billing_view_segments(params = {}) ⇒ Types::ListBillingViewSegmentsResponse
Lists the segments of a billing view over a given time period.
-
#list_billing_views(params = {}) ⇒ Types::ListBillingViewsResponse
Lists the billing views available for a given time period.
-
#list_business_support_account_charges(params = {}) ⇒ Types::ListBusinessSupportAccountChargesResponse
Returns Business Support charges broken down at the linked account level for a given billing month.
-
#list_business_support_subscription_history(params = {}) ⇒ Types::ListBusinessSupportSubscriptionHistoryResponse
Returns the history of Business Support subscription contracts across accounts.
-
#list_contracts(params = {}) ⇒ Types::ListContractsResponse
Lists the private pricing contracts that your Amazon Web Services account is an eligible payer account of.
-
#list_contractual_investment_attestations(params = {}) ⇒ Types::ListContractualInvestmentAttestationsResponse
Lists the investment attestations submitted under a specific private pricing contract.
-
#list_contractual_investment_summaries(params = {}) ⇒ Types::ListContractualInvestmentSummariesResponse
Lists the investment summaries within a specific private pricing contract.
-
#list_contractual_investments(params = {}) ⇒ Types::ListContractualInvestmentsResponse
Lists the investments within a specific investment summary.
-
#list_enterprise_support_linked_account_charges(params = {}) ⇒ Types::ListEnterpriseSupportLinkedAccountChargesResponse
Returns Support-eligible spend broken down at linked account level.
-
#list_source_views_for_billing_view(params = {}) ⇒ Types::ListSourceViewsForBillingViewResponse
Lists the source views (managed Amazon Web Services billing views) associated with the billing view.
-
#list_tags_for_resource(params = {}) ⇒ Types::ListTagsForResourceResponse
Lists tags associated with the billing view resource.
-
#redeem_credits(params = {}) ⇒ Struct
Redeems an Amazon Web Services promotional credit code on behalf of the calling account.
-
#split_credit(params = {}) ⇒ Types::SplitCreditResponse
Splits the available balance of a credit into 2 to 99 new credits in the same account, and cancels the original credit.
-
#tag_resource(params = {}) ⇒ Struct
An API operation for adding one or more tags (key-value pairs) to a resource.
-
#transfer_credit(params = {}) ⇒ Types::TransferCreditResponse
Moves a credit to another account in the same consolidated billing family.
-
#untag_resource(params = {}) ⇒ Struct
Removes one or more tags from a resource.
-
#update_billing_preferences(params = {}) ⇒ Struct
Updates billing preferences for the specified feature.
-
#update_billing_view(params = {}) ⇒ Types::UpdateBillingViewResponse
An API to update the attributes of the billing view.
Instance Method Summary collapse
-
#initialize(options) ⇒ Client
constructor
A new instance of Client.
Methods included from ClientStubs
#api_requests, #stub_data, #stub_responses
Methods inherited from Seahorse::Client::Base
add_plugin, api, clear_plugins, define, new, #operation_names, plugins, remove_plugin, set_api, set_plugins
Methods included from Seahorse::Client::HandlerBuilder
#handle, #handle_request, #handle_response
Constructor Details
#initialize(options) ⇒ Client
Returns a new instance of Client.
486 487 488 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 486 def initialize(*args) super end |
Instance Method Details
#associate_contract(params = {}) ⇒ Struct
Private Pricing contracts let eligible payer accounts manage private pricing agreements with Amazon Web Services. This operation associates a private pricing contract with the caller's Amazon Web Services account. The caller must be a payer (management) account listed on the contract. This operation is idempotent, so retrying a request that already succeeded is safe.
533 534 535 536 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 533 def associate_contract(params = {}, = {}) req = build_request(:associate_contract, params) req.send_request() end |
#associate_source_views(params = {}) ⇒ Types::AssociateSourceViewsResponse
Associates one or more source billing views with an existing billing view. This allows creating aggregate billing views that combine data from multiple sources.
600 601 602 603 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 600 def associate_source_views(params = {}, = {}) req = build_request(:associate_source_views, params) req.send_request() end |
#cancel_contractual_investment_attestation(params = {}) ⇒ Struct
Cancels a contractual investment attestation. This operation is
idempotent, so retrying is safe. You can cancel an attestation only
while it is still pending (its isCancellable value is true).
646 647 648 649 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 646 def cancel_contractual_investment_attestation(params = {}, = {}) req = build_request(:cancel_contractual_investment_attestation, params) req.send_request() end |
#create_billing_view(params = {}) ⇒ Types::CreateBillingViewResponse
Creates a billing view with the specified billing view attributes.
772 773 774 775 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 772 def create_billing_view(params = {}, = {}) req = build_request(:create_billing_view, params) req.send_request() end |
#create_contractual_investment_attestation(params = {}) ⇒ Types::CreateContractualInvestmentAttestationResponse
Creates an attestation that claims an investment award for a completed
milestone or outcome within a private pricing contract. Supply a
clientToken to make the request idempotent so a safe retry does not
create a duplicate attestation. This operation starts an asynchronous
review and returns an attestationId while the attestation is
pending.
1007 1008 1009 1010 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 1007 def create_contractual_investment_attestation(params = {}, = {}) req = build_request(:create_contractual_investment_attestation, params) req.send_request() end |
#delete_billing_view(params = {}) ⇒ Types::DeleteBillingViewResponse
Deletes the specified billing view.
1054 1055 1056 1057 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 1054 def delete_billing_view(params = {}, = {}) req = build_request(:delete_billing_view, params) req.send_request() end |
#disassociate_contract(params = {}) ⇒ Struct
Removes the association between a private pricing contract and your Amazon Web Services account. The account must have been associated with the contract previously. This operation is idempotent, so retrying is safe.
1091 1092 1093 1094 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 1091 def disassociate_contract(params = {}, = {}) req = build_request(:disassociate_contract, params) req.send_request() end |
#disassociate_source_views(params = {}) ⇒ Types::DisassociateSourceViewsResponse
Removes the association between one or more source billing views and an existing billing view. This allows modifying the composition of aggregate billing views.
1142 1143 1144 1145 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 1142 def disassociate_source_views(params = {}, = {}) req = build_request(:disassociate_source_views, params) req.send_request() end |
#get_billing_preferences(params = {}) ⇒ Types::GetBillingPreferencesResponse
Retrieves billing preferences for the specified feature. Each feature controls a distinct billing capability: which accounts can share Reserved Instances or credits, whether billing alerts are enabled, the historical record of sharing changes, per-credit options, and which accounts an individual Reserved Instance or Savings Plan is shared with.
1212 1213 1214 1215 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 1212 def get_billing_preferences(params = {}, = {}) req = build_request(:get_billing_preferences, params) req.send_request() end |
#get_billing_view(params = {}) ⇒ Types::GetBillingViewResponse
Returns the metadata associated to the specified billing view ARN.
1291 1292 1293 1294 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 1291 def get_billing_view(params = {}, = {}) req = build_request(:get_billing_view, params) req.send_request() end |
#get_contract_information(params = {}) ⇒ Types::GetContractInformationResponse
Returns information about a specific private pricing contract, including its term (duration), eligible payer accounts, investment accounts, and legal entities. This operation is read-only.
1364 1365 1366 1367 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 1364 def get_contract_information(params = {}, = {}) req = build_request(:get_contract_information, params) req.send_request() end |
#get_credit_allocation_history(params = {}) ⇒ Types::GetCreditAllocationHistoryResponse
Returns the per-billing-month allocation history for credits applied to an Amazon Web Services account's bills. Traverses the consolidated billing family to capture cross-account credit applications. Supports pagination and optional filtering to a single credit.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
1443 1444 1445 1446 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 1443 def get_credit_allocation_history(params = {}, = {}) req = build_request(:get_credit_allocation_history, params) req.send_request() end |
#get_credits(params = {}) ⇒ Types::GetCreditsResponse
Returns the list of Amazon Web Services account credits for the specified account. Each credit includes its identifier, type, monetary amounts, applicable products, expiration, sharing configuration, and current enabled status.
When the caller is the management account of a consolidated billing
family and payerAccountFlag is true, the response aggregates
credits across the entire family. Otherwise, the response includes
only credits owned by the account specified in accountId.
1523 1524 1525 1526 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 1523 def get_credits(params = {}, = {}) req = build_request(:get_credits, params) req.send_request() end |
#get_enterprise_support_charge_summary(params = {}) ⇒ Types::GetEnterpriseSupportChargeSummaryResponse
Returns a summary of Enterprise Support data aggregated across all accounts in the Enterprise Support profile.
1597 1598 1599 1600 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 1597 def get_enterprise_support_charge_summary(params = {}, = {}) req = build_request(:get_enterprise_support_charge_summary, params) req.send_request() end |
#get_enterprise_support_contract_details(params = {}) ⇒ Types::GetEnterpriseSupportContractDetailsResponse
Returns Enterprise Support contract details.
1675 1676 1677 1678 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 1675 def get_enterprise_support_contract_details(params = {}, = {}) req = build_request(:get_enterprise_support_contract_details, params) req.send_request() end |
#get_resource_policy(params = {}) ⇒ Types::GetResourcePolicyResponse
Returns the resource-based policy document attached to the resource in
JSON format.
1720 1721 1722 1723 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 1720 def get_resource_policy(params = {}, = {}) req = build_request(:get_resource_policy, params) req.send_request() end |
#list_billing_view_segments(params = {}) ⇒ Types::ListBillingViewSegmentsResponse
Lists the segments of a billing view over a given time period. Each
segment identifies the billing domain (PRO_FORMA or BILLABLE) and
the account relationships that apply during its time range.
If you don't provide an arn, the response includes segments for the
caller's PRIMARY billing view.
If a mid-period change occurs, the response includes multiple segments, each with its own time range. The response omits hidden segments, so the segments it returns might not cover the entire requested time period.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
1824 1825 1826 1827 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 1824 def list_billing_view_segments(params = {}, = {}) req = build_request(:list_billing_view_segments, params) req.send_request() end |
#list_billing_views(params = {}) ⇒ Types::ListBillingViewsResponse
Lists the billing views available for a given time period.
Every Amazon Web Services account has a unique PRIMARY billing view
that represents the billing data available by default. Accounts that
use Billing Conductor also have BILLING_GROUP billing views
representing pro forma costs associated with each created billing
group.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
1946 1947 1948 1949 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 1946 def list_billing_views(params = {}, = {}) req = build_request(:list_billing_views, params) req.send_request() end |
#list_business_support_account_charges(params = {}) ⇒ Types::ListBusinessSupportAccountChargesResponse
Returns Business Support charges broken down at the linked account level for a given billing month.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
2026 2027 2028 2029 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2026 def list_business_support_account_charges(params = {}, = {}) req = build_request(:list_business_support_account_charges, params) req.send_request() end |
#list_business_support_subscription_history(params = {}) ⇒ Types::ListBusinessSupportSubscriptionHistoryResponse
Returns the history of Business Support subscription contracts across accounts.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
2086 2087 2088 2089 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2086 def list_business_support_subscription_history(params = {}, = {}) req = build_request(:list_business_support_subscription_history, params) req.send_request() end |
#list_contracts(params = {}) ⇒ Types::ListContractsResponse
Lists the private pricing contracts that your Amazon Web Services account is an eligible payer account of. This operation is read-only and paginated.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
2154 2155 2156 2157 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2154 def list_contracts(params = {}, = {}) req = build_request(:list_contracts, params) req.send_request() end |
#list_contractual_investment_attestations(params = {}) ⇒ Types::ListContractualInvestmentAttestationsResponse
Lists the investment attestations submitted under a specific private
pricing contract. Use this operation to track attestation status,
including the terminal statuses DISBURSED, REJECTED, and
CANCELLED. This operation is read-only and paginated.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
2266 2267 2268 2269 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2266 def list_contractual_investment_attestations(params = {}, = {}) req = build_request(:list_contractual_investment_attestations, params) req.send_request() end |
#list_contractual_investment_summaries(params = {}) ⇒ Types::ListContractualInvestmentSummariesResponse
Lists the investment summaries within a specific private pricing contract. This operation is read-only and paginated.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
2338 2339 2340 2341 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2338 def list_contractual_investment_summaries(params = {}, = {}) req = build_request(:list_contractual_investment_summaries, params) req.send_request() end |
#list_contractual_investments(params = {}) ⇒ Types::ListContractualInvestmentsResponse
Lists the investments within a specific investment summary. This operation is read-only and paginated.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
2441 2442 2443 2444 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2441 def list_contractual_investments(params = {}, = {}) req = build_request(:list_contractual_investments, params) req.send_request() end |
#list_enterprise_support_linked_account_charges(params = {}) ⇒ Types::ListEnterpriseSupportLinkedAccountChargesResponse
Returns Support-eligible spend broken down at linked account level.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
2505 2506 2507 2508 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2505 def list_enterprise_support_linked_account_charges(params = {}, = {}) req = build_request(:list_enterprise_support_linked_account_charges, params) req.send_request() end |
#list_source_views_for_billing_view(params = {}) ⇒ Types::ListSourceViewsForBillingViewResponse
Lists the source views (managed Amazon Web Services billing views) associated with the billing view.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
2563 2564 2565 2566 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2563 def list_source_views_for_billing_view(params = {}, = {}) req = build_request(:list_source_views_for_billing_view, params) req.send_request() end |
#list_tags_for_resource(params = {}) ⇒ Types::ListTagsForResourceResponse
Lists tags associated with the billing view resource.
2610 2611 2612 2613 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2610 def (params = {}, = {}) req = build_request(:list_tags_for_resource, params) req.send_request() end |
#redeem_credits(params = {}) ⇒ Struct
Redeems an Amazon Web Services promotional credit code on behalf of the calling account. On success, a new credit is added to the account's credit ledger with the amount, validity period, and applicable products defined by the promotion. The credit is then automatically applied to subsequent bills according to the standard credit application order.
2637 2638 2639 2640 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2637 def redeem_credits(params = {}, = {}) req = build_request(:redeem_credits, params) req.send_request() end |
#split_credit(params = {}) ⇒ Types::SplitCreditResponse
Splits the available balance of a credit into 2 to 99 new credits in the same account, and cancels the original credit. The new credits keep the original credit's end date and applicable products.
The available balance is the remaining balance minus any amount reserved for a bill that isn't finalized. The portions must add up to exactly the available balance. Each portion must be at least 100.00 in the currency of the credit. For example, if the credit is in USD, each portion must be at least USD $100.00. A reserved amount stays on the original credit and still applies to that bill.
A credit and every credit split from it count toward a limit of 100 credits. After a split, you can't split or transfer the original credit. You can split or transfer its new credits, and you can split a credit after you transfer it.
You must own the credit or be the payer of the account that owns it. You can't undo a split. This operation is idempotent and supports a dry run.
2715 2716 2717 2718 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2715 def split_credit(params = {}, = {}) req = build_request(:split_credit, params) req.send_request() end |
#tag_resource(params = {}) ⇒ Struct
An API operation for adding one or more tags (key-value pairs) to a resource.
2764 2765 2766 2767 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2764 def tag_resource(params = {}, = {}) req = build_request(:tag_resource, params) req.send_request() end |
#transfer_credit(params = {}) ⇒ Types::TransferCreditResponse
Moves a credit to another account in the same consolidated billing family. The credit keeps its ID, balance, end date, and applicable products. Only the account that owns the credit changes.
The transfer removes the credit's sharing settings. The new owner or the payer can set them again. Any amount reserved for a bill that isn't finalized moves with the credit and still applies to that bill.
You must be the payer of both accounts. You can't transfer a credit that has ended, has no available balance, or is the original credit of a split. A transfer creates no credit, so it doesn't count toward the split limit, and the payer can transfer the credit back. This operation is idempotent and supports a dry run.
2835 2836 2837 2838 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2835 def transfer_credit(params = {}, = {}) req = build_request(:transfer_credit, params) req.send_request() end |
#untag_resource(params = {}) ⇒ Struct
Removes one or more tags from a resource. Specify only tag keys in your request. Don't specify the value.
2876 2877 2878 2879 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2876 def untag_resource(params = {}, = {}) req = build_request(:untag_resource, params) req.send_request() end |
#update_billing_preferences(params = {}) ⇒ Struct
Updates billing preferences for the specified feature. Each feature targets a distinct billing capability and has its own set of supported keys. The action sets the value for each provided key; keys not present in the request are unchanged.
To set sharing keys (RI_SHARING, CREDIT_SHARING,
CREDIT_LEVEL_SHARING, BENEFIT_LEVEL_SHARING, and sharing keys
under CREDIT_PREFERENCE_OPTIONS), you must use the management
account of a consolidated billing family. To set the
credit/{creditId}/status key, you must own the credit or use the
management account of its family.
2962 2963 2964 2965 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 2962 def update_billing_preferences(params = {}, = {}) req = build_request(:update_billing_preferences, params) req.send_request() end |
#update_billing_view(params = {}) ⇒ Types::UpdateBillingViewResponse
An API to update the attributes of the billing view.
3050 3051 3052 3053 |
# File 'gems/aws-sdk-billing/lib/aws-sdk-billing/client.rb', line 3050 def update_billing_view(params = {}, = {}) req = build_request(:update_billing_view, params) req.send_request() end |