Class: Aws::Billing::Client
- Inherits:
-
Seahorse::Client::Base
- Object
- Seahorse::Client::Base
- Aws::Billing::Client
- Includes:
- ClientStubs
- Defined in:
- 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](/sdk-for-ruby/v3/developer-guide/setup-config.html).
See #initialize for a full list of supported configuration options.
Class Attribute Summary collapse
- .identifier ⇒ Object readonly private
API Operations collapse
-
#create_billing_view(params = {}) ⇒ Types::CreateBillingViewResponse
Creates a billing view with the specified billing view attributes.
-
#delete_billing_view(params = {}) ⇒ Types::DeleteBillingViewResponse
Deletes the specified billing view.
-
#get_billing_view(params = {}) ⇒ Types::GetBillingViewResponse
Returns the metadata associated to the specified billing view ARN.
-
#get_resource_policy(params = {}) ⇒ Types::GetResourcePolicyResponse
Returns the resource-based policy document attached to the resource in ‘JSON` format.
-
#list_billing_views(params = {}) ⇒ Types::ListBillingViewsResponse
Lists the billing views available for a given time period.
-
#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.
-
#tag_resource(params = {}) ⇒ Struct
An API operation for adding one or more tags (key-value pairs) to a resource.
-
#untag_resource(params = {}) ⇒ Struct
Removes one or more tags from a resource.
-
#update_billing_view(params = {}) ⇒ Types::UpdateBillingViewResponse
An API to update the attributes of the billing view.
Class Method Summary collapse
- .errors_module ⇒ Object private
Instance Method Summary collapse
- #build_request(operation_name, params = {}) ⇒ Object private
-
#initialize(options) ⇒ Client
constructor
A new instance of Client.
- #waiter_names ⇒ Object deprecated private Deprecated.
Constructor Details
#initialize(options) ⇒ Client
Returns a new instance of Client.
451 452 453 |
# File 'lib/aws-sdk-billing/client.rb', line 451 def initialize(*args) super end |
Class Attribute Details
.identifier ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
1121 1122 1123 |
# File 'lib/aws-sdk-billing/client.rb', line 1121 def identifier @identifier end |
Class Method Details
.errors_module ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
1124 1125 1126 |
# File 'lib/aws-sdk-billing/client.rb', line 1124 def errors_module Errors end |
Instance Method Details
#build_request(operation_name, params = {}) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 |
# File 'lib/aws-sdk-billing/client.rb', line 1094 def build_request(operation_name, params = {}) handlers = @handlers.for(operation_name) tracer = config.telemetry_provider.tracer_provider.tracer( Aws::Telemetry.module_to_tracer_name('Aws::Billing') ) context = Seahorse::Client::RequestContext.new( operation_name: operation_name, operation: config.api.operation(operation_name), client: self, params: params, config: config, tracer: tracer ) context[:gem_name] = 'aws-sdk-billing' context[:gem_version] = '1.1.0' Seahorse::Client::Request.new(handlers, context) end |
#create_billing_view(params = {}) ⇒ Types::CreateBillingViewResponse
Creates a billing view with the specified billing view attributes.
555 556 557 558 |
# File 'lib/aws-sdk-billing/client.rb', line 555 def create_billing_view(params = {}, = {}) req = build_request(:create_billing_view, params) req.send_request() end |
#delete_billing_view(params = {}) ⇒ Types::DeleteBillingViewResponse
Deletes the specified billing view.
596 597 598 599 |
# File 'lib/aws-sdk-billing/client.rb', line 596 def delete_billing_view(params = {}, = {}) req = build_request(:delete_billing_view, params) req.send_request() end |
#get_billing_view(params = {}) ⇒ Types::GetBillingViewResponse
Returns the metadata associated to the specified billing view ARN.
663 664 665 666 |
# File 'lib/aws-sdk-billing/client.rb', line 663 def get_billing_view(params = {}, = {}) req = build_request(:get_billing_view, params) req.send_request() end |
#get_resource_policy(params = {}) ⇒ Types::GetResourcePolicyResponse
Returns the resource-based policy document attached to the resource in ‘JSON` format.
708 709 710 711 |
# File 'lib/aws-sdk-billing/client.rb', line 708 def get_resource_policy(params = {}, = {}) req = build_request(:get_resource_policy, 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.
810 811 812 813 |
# File 'lib/aws-sdk-billing/client.rb', line 810 def list_billing_views(params = {}, = {}) req = build_request(:list_billing_views, 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.
868 869 870 871 |
# File 'lib/aws-sdk-billing/client.rb', line 868 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.
915 916 917 918 |
# File 'lib/aws-sdk-billing/client.rb', line 915 def (params = {}, = {}) req = build_request(:list_tags_for_resource, params) req.send_request() end |
#tag_resource(params = {}) ⇒ Struct
An API operation for adding one or more tags (key-value pairs) to a resource.
964 965 966 967 |
# File 'lib/aws-sdk-billing/client.rb', line 964 def tag_resource(params = {}, = {}) req = build_request(:tag_resource, 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.
1005 1006 1007 1008 |
# File 'lib/aws-sdk-billing/client.rb', line 1005 def untag_resource(params = {}, = {}) req = build_request(:untag_resource, params) req.send_request() end |
#update_billing_view(params = {}) ⇒ Types::UpdateBillingViewResponse
An API to update the attributes of the billing view.
1085 1086 1087 1088 |
# File 'lib/aws-sdk-billing/client.rb', line 1085 def update_billing_view(params = {}, = {}) req = build_request(:update_billing_view, params) req.send_request() end |
#waiter_names ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
1114 1115 1116 |
# File 'lib/aws-sdk-billing/client.rb', line 1114 def waiter_names [] end |