Billing ledger
billing.ledger.v1.LedgerService/RefundAccountCredit (36-credits-ledger.md, API Surface; Account credit; 38-payments-and-tax.md, Refunds). Pays refundable account credit back to the provider payment it came from, never more than what is left of that payment, as refunds with reason account_credit_refund and no credit note (billing-svc docs/questions.md, P96). Credit added by hand, an invoice's surplus or an external overpayment can only be spent. More than the balance is balance_would_be_negative; more than the refundable part (the balances read's refundable) is refund_exceeds_payment.
BearerAuthAuthorization<token>Access token as "Bearer "
customer_id*stringThe Customer id
X-Idempotency-Key?stringIdempotency key
The credit_refunded LedgerEntry object
application/json- response
curl -X POST 'https://api.us.pontive.com/v1/billing/customers/string/account-credit/refund'{}billing.ledger.v1.LedgerService/ListBalances (36-credits-ledger.md, API Surface).
BearerAuthAuthorization<token>Access token as "Bearer "
customer_id*stringid
unit?stringunit
at?stringRFC 3339 time
page?integerPage number, from 1
limit?integerItems per page, 1 to 100, default 25
A list of Balance objects with pagination
application/json- response
data?array<>object?stringpagination?Pagination is the page answered (api-route-review D9).
curl -X GET 'https://api.us.pontive.com/v1/billing/customers/string/balances'{ "data": [ { "id": "string", "object": "string" } ], "object": "string", "pagination": { "limit": 0, "page": 0, "total": 0, "total_pages": 0 }}billing.ledger.v1.LedgerService/CreateLedgerAdjustment (36-credits-ledger.md, API Surface).
BearerAuthAuthorization<token>Access token as "Bearer "
customer_id*stringid
X-Idempotency-Key?stringIdempotency key
A LedgerEntry object
application/json- response
id?stringID is its prefixed id.
object?stringObject names the kind: customer, invoice, contract, …
curl -X POST 'https://api.us.pontive.com/v1/billing/customers/string/ledger-adjustments'{ "id": "string", "object": "string"}billing.ledger.v1.LedgerService/CreateTopUp (36-credits-ledger.md, API Surface).
BearerAuthAuthorization<token>Access token as "Bearer "
customer_id*stringid
X-Idempotency-Key?stringIdempotency key
The CreateTopUpResponse fields
application/json- response
curl -X POST 'https://api.us.pontive.com/v1/billing/customers/string/top-ups'{}billing.ledger.v1.LedgerService/GetWallet (36-credits-ledger.md, API Surface).
BearerAuthAuthorization<token>Access token as "Bearer "
customer_id*stringid
unit*stringunit
A Wallet object
application/json- response
id?stringID is its prefixed id.
object?stringObject names the kind: customer, invoice, contract, …
curl -X GET 'https://api.us.pontive.com/v1/billing/customers/string/wallets/string'{ "id": "string", "object": "string"}billing.ledger.v1.LedgerService/UpdateWalletSettings (36-credits-ledger.md, API Surface).
BearerAuthAuthorization<token>Access token as "Bearer "
customer_id*stringid
unit*stringunit
X-Idempotency-Key?stringIdempotency key
A WalletSettings object
application/json- response
id?stringID is its prefixed id.
object?stringObject names the kind: customer, invoice, contract, …
curl -X PUT 'https://api.us.pontive.com/v1/billing/customers/string/wallets/string'{ "id": "string", "object": "string"}billing.ledger.v1.LedgerService/ListLedgerEntries (36-credits-ledger.md, API Surface).
BearerAuthAuthorization<token>Access token as "Bearer "
limit?integerItems per page, 1 to 100, default 25
after?stringCursor: a next_cursor, to continue forward
before?stringCursor: a next_cursor, to read the page just before it
customer_id?stringA cust_ id
grant_id?stringA grant id
account?stringaccount
type?stringtype
invoice_id?stringA binv_ id
from?stringRFC 3339 time
to?stringRFC 3339 time
A list of LedgerEntry objects, walked by cursor (api-route-review D41)
application/json- response
data?array<>next_cursor?stringobject?stringcurl -X GET 'https://api.us.pontive.com/v1/billing/ledger-entries'{ "data": [ { "id": "string", "object": "string" } ], "next_cursor": "string", "object": "string"}