Overview
The activity endpoints provide visibility into your account’s API usage and x402 payment transactions. Use these to monitor costs, debug payment flows, and track API key usage.List Transactions
Retrieve recent x402 payment transactions.This endpoint requires session authentication (dashboard login).
Response
List of x402 transaction objects (up to 100 most recent)
Transaction Lifecycle
- pending - Transaction created when endpoint returns 402
- settled - User called
/v1/x402/settleand payment was deducted - completed - User retried request with payment proof and received data
Get Usage Events
Retrieve detailed usage events showing API consumption and costs.This endpoint requires session authentication (dashboard login).
Response
List of usage event objects (up to 100 most recent)
Usage vs Transactions
Understand the difference between these two endpoints:Transactions Endpoint
Shows the x402 payment lifecycle:- All payment requests (even unpaid ones)
- Payment status (pending → settled → completed)
- Which API key initiated each transaction
- Whether payment was consumed
Usage Endpoint
Shows actual consumption and billing:- Only completed/consumed requests
- Exact costs per request
- Usage patterns and history
Usage events are only created when a transaction reaches the
completed status (after payment and consumption).Common Use Cases
Track Spending by API Key
- Call
/v1/usageto get all usage events - Group by
apiKeyIdand sumcostCents - Join with API key names from
/v1/api-keys
Monitor Abandoned Payments
- Call
/v1/transactionsto get all transactions - Filter for
status: "pending"older than 10 minutes - These represent initiated but unpaid requests
Debug Payment Issues
- Call
/v1/transactionswith relevantapiKeyId - Check transaction status and timestamps
- Verify
receiptIdmatches what client sent - Check if transaction was consumed (
consumedAt)
Error Codes
| Status | Error | Description |
|---|---|---|
| 401 | unauthorized | Not logged in or session expired |