Get usage and balance
The prepaid balance (ledger, pending mention charges, and the effective balance the stop rule reads), the daily burn and the days it buys, the keywords the wallet runs and pauses, the matches recorded today and over 30 days, and whether tracking is stopped or the balance is low. Every matched mention bills ($0.008), relevant or not; every active keyword bills $5 a month, charged daily.
API key minted via POST /v1/api-keys (format mk_live_...)
In: header
Response Body
application/json
application/json
curl -X GET "https://api.mentio.dev/v1/usage"{
"balance": {
"cents": 0,
"pendingCents": 0,
"effectiveCents": 0,
"currency": "USD"
},
"burn": {
"perDayCents": 0,
"daysLeft": 0
},
"keywords": {
"active": 0,
"paused": 0,
"capped": 0,
"limit": 0,
"dayCents": 0
},
"mentions": {
"today": 0,
"last30d": 0
},
"stopped": true,
"lowBalance": true,
"lastTopUpAt": "string"
}{
"error": {
"code": "unauthorized",
"message": "string",
"requestId": "string",
"retryAfterSeconds": 0
}
}Get the usage breakdown GET
What the workspace consumed and was charged over a window, grouped by one dimension per call (`by`: day, platform or keyword), in USD cents at list price, with the window's totals on every call. `range` reads a trailing window of UTC days ending today (default 30d); `month` reads one calendar month (YYYY-MM), the shape a bill or a per-customer margin is reconciled against. Keyword-days come from the daily tick and mention charges from the matches that billed, so a deleted keyword keeps its charges in the keyword rows (`keyword.removed`) while its mention counts read 0; the same numbers ride on each keyword as `stats.cost` for the running month. `totals.ledgerDebitCents` is what the wallet has debited so far for the window's days: mentions settle the morning after their day, so a window ending today lags `totals.totalCents` by the unsettled ones, and a closed month differs from it only by cumulative rounding. Rows are paged (`limit`, `offset`, `total`); a workspace may read this at most 30 times a minute through its keys and tokens together.
Save a view POST
Save a named filter over mentions. The filter takes the same fields as GET /v1/mentions (lists are any-of, `not` lists none-of, every condition ANDed), plus `anyOf`, groups of those conditions of which at least one must hold; an empty filter is every mention. Nothing is materialized: the view selects whatever matches when it is read.