v1

latestOpenAPI 3.1.02026-07-261444991.2 MB
Credit

Fetch customer credit balance by external customer id

Returns a paginated list of unexpired, non-zero credit blocks for a customer.

If include_all_blocks is set to true, all credit blocks (including expired and depleted blocks) will be included in the response.

Note that currency defaults to credits if not specified. To use a real world currency, set currency to an ISO 4217 string.

Results can be filtered by the block's effective_date using the effective_date[gte], effective_date[gt], effective_date[lt], and effective_date[lte] query parameters. This filters on when the credit block becomes effective, which may differ from creation time for backdated credits.

get/customers/external_customer_id/{external_customer_id}/credits

Path parameters

external_customer_idstring nullable required

Query parameters

limitinteger

The number of items to fetch. Defaults to 20.

cursorstring nullable

Cursor for pagination. This can be populated by the next_cursor value returned from the initial request.

currencystring nullable

The ledger currency or custom pricing unit to use.

include_all_blocksboolean

If set to True, all expired and depleted blocks, as well as active block will be returned.

effective_date[gte]string date-time nullable
effective_date[gt]string date-time nullable
effective_date[lt]string date-time nullable
effective_date[lte]string date-time nullable

Response

OK