Application wallet transaction history
An application API key reads debit history attributable to that application in its linked wallet. Send x-api-key; the server resolves the wallet, so do not supply a wallet ID. This covers debit history, without granting access to balances, credits, recharges, exports or configuration.
Parent groups
GET /v1/organization/wallet/transaction-groups returns two parent kinds:
standalone: one debit without a session;expandable: false, with itstransactiondetails.session: one conversation session;expandable: true,sessionIdandservicessummarized by service type.
limit counts parent groups, not raw debits or nested service summaries. Use offset as a zero-based parent page number and limit 1–200 (default 10). pagination.total / totalPages count scoped, filtered parent groups. Repeat serviceType to filter multiple services.
startDate and endDate are inclusive calendar dates (YYYY-MM-DD) in timeZone, an IANA timezone (default UTC). Response instants remain ISO UTC. Keep the same dates and timezone when expanding services so displayed totals match.
curl --get 'https://app.chatt2.me/v1/organization/wallet/transaction-groups' \
-H 'x-api-key: YOUR_APPLICATION_API_KEY' \
--data-urlencode 'offset=0' \
--data-urlencode 'limit=10' \
--data-urlencode 'serviceType=AiChat' \
--data-urlencode 'serviceType=AudioTranscription' \
--data-urlencode 'startDate=2026-08-01' \
--data-urlencode 'endDate=2026-08-31' \
--data-urlencode 'timeZone=America/Sao_Paulo'
Expand a session service
Use the session parent's sessionId, not its groupId or a standalone transaction ID. Call GET /v1/organization/wallet/transaction-groups/{sessionId}/items with one required serviceType from that parent's service summary. This page counts raw debit events with limit 1–50 (default 10).
The first request omits cursor:
curl --get 'https://app.chatt2.me/v1/organization/wallet/transaction-groups/SESSION_UUID/items' \
-H 'x-api-key: YOUR_APPLICATION_API_KEY' \
--data-urlencode 'serviceType=AudioTranscription' \
--data-urlencode 'limit=10' \
--data-urlencode 'startDate=2026-08-01' \
--data-urlencode 'endDate=2026-08-31' \
--data-urlencode 'timeZone=America/Sao_Paulo'
For later pages, preserve those filters and send the exact opaque pagination.nextCursor as cursor. Do not manufacture/decode cursors. Stop at hasMore: false, when nextCursor is null. Items are ordered newest first. Standalone rows already contain their transaction and have no session expansion.
Fields and billing units
| Field | Interpretation |
|---|---|
groupId, kind, sessionId | Parent correlation; session ID appears only on session groups |
latestChargeDate, transactionCount, amount | Latest charge time, underlying debit count and aggregate amount |
services[].serviceType, billingUnit, quantity, amount | Service summary and charged units; use returned service types |
Transaction/item quantity, unitPrice, amount | Charged quantity, price per unit and actual debit amount |
Item messageId | Optional message correlation for applicable services |
durationSeconds | Optional source audio duration in seconds |
billedMinutes | Optional billed transcription minutes; can differ from source duration / 60 due to billing rounding |
segments | Optional breakdown of quantities/prices/amounts when pricing uses multiple segments |
billingUnit values are request, conversation, message, minute, number, second, gb. Quantity is a count in that unit, not currency or milliseconds. Amounts and unit prices are decimal monetary values in BRL, not integer cents; use recorded debit/segment totals rather than reconstructing invoices from source durations. A source duration and charged quantity describe different measures.
See the API reference schemas WalletTransactionGroupsOutput, WalletTransactionGroup, SessionTransactionItemsOutput, BillingUnit, and BillingSegment for exact public fields.
Errors and empty results
- 400: invalid pagination, service, session UUID, date/timezone or cursor; malformed cursors return
INVALID_CURSOR. - 401: missing, invalid, revoked/expired key or unavailable application/access.
- 404
WALLET_NOT_FOUND: this application has no linked wallet. - 200 with
data: []: no matching debits after application scope/filters, including an unmatched session/service. It does not imply access to another application's history. Empty item pages end withhasMore: false,nextCursor: null.
Error bodies follow the common error format.