List ledger entries

gethttps://api.mentio.dev/v1/billing/ledger

List every movement of the balance, newest first, cursor paged.

Rows are the welcome credit, top-ups, refunds, the daily keyword-day and mention debits, and adjustments. A debit row carries the UTC day it settled and the cumulative units behind it.

Authentication

AuthorizationBearer <token>Required

An API key (mk_live_...) from the dashboard or an OAuth access token. See Authentication.

Query parameters

cursorstringOptional

Opaque cursor from a previous page (nextCursor).

limitintegerOptional

Page size, 1 to 100 (default 50).

Default501 to 100

Response

200Ledger entries, newest first
dataarray<object>Required

Ledger entries, newest first.

+Show 8 properties
idstringRequired

Ledger entry id (led_...).

kindstringRequired

signup_credit, topup, refund, debit_keyword_days, debit_mentions, debit_comments or adjustment.

+Show 7 enum values
signup_credittopuprefunddebit_keyword_daysdebit_mentionsdebit_commentsadjustment
amountCentsintegerRequired

Integer USD cents; credits positive, debits negative.

daystringnullableRequired

Debit rows: the last UTC day the row settled (YYYY-MM-DD).

unitsintegernullableRequired

Debit rows: cumulative units (mentions or keyword-days) settled up to this row.

notestringnullableRequired

Free text on credits and adjustments.

polarOrderIdstringnullableRequired

Top-ups and refunds: the Polar order.

createdAtstringRequired

ISO 8601 timestamp, UTC.

nextCursorstringnullableRequired

Pass it back as cursor for the next page; null on the last.

400Invalid cursor
+Show 1 property
errorobjectRequired

The error.

+Show 4 properties
codestringRequired

Stable machine-readable code; branch on this, never on the message. Codes are additive: a client should treat one it does not know as a generic failure of the same status.

+Show 46 enum values
unauthorizedforbiddenread_only_keyvalidation_errornot_foundinvalid_cursorpayload_too_largeidempotency_key_in_useidempotency_key_reusedrate_limitedduplicate_keywordinsufficient_balancekeyword_limit_reachedbilling_not_configuredorder_not_creditedschedule_requiredunknown_channelnot_a_digesthourly_email_unsupportedslack_not_connectedslack_not_configuredtelegram_not_configuredfeed_unreadablefeed_login_requiredfeed_login_expiredfeed_limit_reachedfeed_auth_not_configuredemail_not_configuredinvalid_assigneeclassification_pendinginvalid_memberalready_memberlast_ownerduplicate_segmentfilter_too_complexduplicate_viewduplicate_groupdefault_groupdefault_group_contextgroup_changedinvalid_signaturewebhook_not_configuredinvalid_tokenprotected_userupstream_unavailableinternal_error
messagestringRequired

Human-readable detail; may change between releases.

requestIdstringOptional

The id of this request (also the X-Request-Id response header); quote it to support.

retryAfterSecondsintegerOptional

For rate_limited and other retryable errors: how long to wait before retrying (mirrors the Retry-After header).

401Missing or invalid credentials
+Show 1 property
errorobjectRequired

The error.

+Show 4 properties
codestringRequired

Stable machine-readable code; branch on this, never on the message. Codes are additive: a client should treat one it does not know as a generic failure of the same status.

+Show 46 enum values
unauthorizedforbiddenread_only_keyvalidation_errornot_foundinvalid_cursorpayload_too_largeidempotency_key_in_useidempotency_key_reusedrate_limitedduplicate_keywordinsufficient_balancekeyword_limit_reachedbilling_not_configuredorder_not_creditedschedule_requiredunknown_channelnot_a_digesthourly_email_unsupportedslack_not_connectedslack_not_configuredtelegram_not_configuredfeed_unreadablefeed_login_requiredfeed_login_expiredfeed_limit_reachedfeed_auth_not_configuredemail_not_configuredinvalid_assigneeclassification_pendinginvalid_memberalready_memberlast_ownerduplicate_segmentfilter_too_complexduplicate_viewduplicate_groupdefault_groupdefault_group_contextgroup_changedinvalid_signaturewebhook_not_configuredinvalid_tokenprotected_userupstream_unavailableinternal_error
messagestringRequired

Human-readable detail; may change between releases.

requestIdstringOptional

The id of this request (also the X-Request-Id response header); quote it to support.

retryAfterSecondsintegerOptional

For rate_limited and other retryable errors: how long to wait before retrying (mirrors the Retry-After header).