Module: Dnsimple::Client::Billing
- Included in:
- BillingService
- Defined in:
- lib/dnsimple/client/billing.rb
Instance Method Summary collapse
-
#charges(account_id, options = {}) ⇒ Dnsimple::PaginatedResponse<Dnsimple::Struct::Charge>
(also: #list_charges)
List the billing charges for the account.
Instance Method Details
#charges(account_id, options = {}) ⇒ Dnsimple::PaginatedResponse<Dnsimple::Struct::Charge> Also known as: list_charges
List the billing charges for the account.
27 28 29 30 31 |
# File 'lib/dnsimple/client/billing.rb', line 27 def charges(account_id, = {}) response = client.get(Client.versioned("/%s/billing/charges" % [account_id]), Options::ListOptions.new()) Dnsimple::PaginatedResponse.new(response, response["data"].map { |r| Struct::Charge.new(r) }) end |