Chat
Get generation
Retrieve the record of one request — its outcome, delivery, usage and final cost — by its generation ID.
https://api.numes.ai/api/v1/generationUse the id from a response or the X-Generation-Id header. This is the authoritative record of what was delivered and charged, including after a disconnect or a mid-stream error. Generations belong to your account: another account's ID returns 404. The record never contains prompts, outputs or keys. Guide: Usage accounting.
outcome is in_progress until the request finishes, then a final value such as success, cancelled or failed. Treat any final value other than success as unsuccessful, and read delivered_output and total_cost for what was delivered and charged. attempts lists each endpoint that was tried; while an attempt's financial_status is pending, its cost fields are omitted. A pending charge isn't a zero charge.
Authorization
AuthorizationheaderRequired
Bearer inference key. Charges settle in the key's billing currency. Authorization: Bearer $NUMES_API_KEY
Headers
X-Request-IdstringCorrelation ID, not an idempotency key. Inference request IDs recorded with a generation are unique per account. A traffic-admitted request reusing a recorded ID returns 400 invalid_request. Traffic admission rejection takes precedence over this conflict, including for reused IDs; it performs no generation lookup and writes no generation, result or attempt. Rate-limit rejection returns 429 rate_limited with Retry-After; an inference limiter outage retains 500 server.
Length1–128
Query parameters
Responses
200Generation metadata visible to the owning accountapplication/json
BodyGenerationResponseapplication/json
dataobjectRequiredShowHide18 child attributes
usageobjectRequiredShowHide16 child attributes
costnumberRequiredSettled cost in the inference key's immutable billing currency. For BTC keys, 1 is one satoshi and precision is one micro-satoshi.
Range≥ 0usage_meterstringOpaque identifier of the billing basis this request was charged under. Treat it as a label; the charged amounts are in the cost fields.
gateway_billing_unitsobjectHistorical gateway billing quantities; absent for current native-meter inference.
native_tokensobjectValidated upstream native-token usage. Current native meters price these counts; reasoning partitions completion and cache partitions prompt.
attemptsarray<object>RequiredShowHide14 child attributes
ErrorCompatible error envelopeapplication/json
Headers