Billing Events
Returns paginated individual billing event records with filters for endpoint and date range. Each record includes the request ID, timestamp, endpoint, output units billed, and a cost breakdown in USD (cost_subtotal, cost_discount, cost_total; cost_estimate_nano_usd carries cost_total in nano USD).
Key Features:
- Individual billing event records for each API request
- Per-request cost breakdown before and after discounts
- Flexible date range filtering
- Optional endpoint filtering
- Cursor-based pagination for efficient large dataset queries
- Limited to 10000 records per page for performance
- Date range capped at 90 days per request
Tagged billing events: pass source=tagged-billed to read the tagged
billing-event pivot instead of the default feed. Each row then carries a tags
object built from the X-Fal-Tags tags set on that request, and
tag=key=value filters narrow the results — repeating the parameter with
different keys ANDs them, repeating one key matches any of its values. Requires
tagged reporting to be enabled for the account; recent events are delayed
relative to the default source.
Common Use Cases:
- Audit individual billing events
- Track request patterns and volumes
- Debug specific requests by ID
- Monitor billing unit consumption per request
See fal.ai docs for more details.
Required permissions: billing:usage:read, auth:keys:read, account:users:read. Key presets that include them: BILLING, FULL. See key permissions.
Authorizations
Key on the BILLING preset, or any key whose permissions include the ones this API lists. Prefix it with "Key ", e.g. Authorization: Key YOUR_API_KEY
Query Parameters
Maximum number of items to return. Actual maximum depends on query type and expansion parameters.
x >= 150
Pagination cursor from previous response. Encodes the page number.
"Mg=="
Start date in ISO8601 format (e.g., '2025-01-01T00:00:00Z' or '2025-01-01'). Defaults to 24 hours ago.
"2025-01-01T00:00:00Z"
End date in ISO8601 format, exclusive (e.g., '2025-02-01T00:00:00Z' or '2025-02-01'). Data up to but not including this timestamp is returned. Defaults to current time.
"2025-02-01T00:00:00Z"
Data source. 'billed' is the default billed-event feed. 'tagged-billed' reads the tagged billing-event pivot instead, populating each row's 'tags' and enabling the 'tag' filter; it requires tagged reporting to be enabled for the account, and recent events are delayed relative to 'billed'.
billed, tagged-billed "billed"
Filter by specific endpoint ID(s). Accepts 1-50 endpoint IDs. Supports comma-separated values: ?endpoint_id=model1,model2 or array syntax: ?endpoint_id=model1&endpoint_id=model2
Filter by specific request ID(s). Accepts 1-50 request IDs. Supports comma-separated values: ?request_id=req1,req2 or array syntax: ?request_id=req1&request_id=req2
Filter by X-Fal-Tags 'key=value' pairs. Accepts 1-10 filters: different keys are AND-combined (?tag=env=prod&tag=team=design), and repeating a key matches any of its values. Use the value '(untagged)' to match requests that did not set the key.
Filter by specific API key ID(s). Accepts 1-50 key IDs. Supports comma-separated values: ?api_key_id=key1,key2 or array syntax: ?api_key_id=key1&api_key_id=key2
Filter by team member login username(s) (nickname). Accepts 1-50 usernames. Supports comma-separated values: ?login_username=alice,bob or array syntax: ?login_username=alice&login_username=bob
Data to include in the response. Use 'auth_method' for a formatted authentication method label, and 'auth_method_structured' for a machine-readable auth method object (detail, api_key_id, login_username).
"auth_method"
Response
Billing event data retrieved successfully
Response containing billing event data with pagination support