API reference · Events
Events
Every event on your account, kept so you can catch up on anything your server missed.
GET https://api.framera.ai/v1/events
GET https://api.framera.ai/v1/events/:id
Resend a delivery from the console.
The event object
The event object is also the body of every webhook delivery.
idstring
evt_…. Use it to skip an event you have already handled.objectstring
Always
event.typestring
What happened. See the types below.
createdAtstring
When it happened.
dataobject
What it is about: the job for job events (a webhook carries it with fresh output links), or the balance or top-up for balance events.
Event types
| Type | Sent when | data |
|---|---|---|
job.succeeded | A job finished and its outputs are ready. Its price has been charged. | The job |
job.failed | A job failed. Nothing was charged; the hold went back to your balance. | The job, with its error |
job.cancelled | A queued job was cancelled. Nothing was charged. | The job |
balance.low | Your balance fell below $10 with auto-recharge off (once, until your next top-up). | { object: "balance", available, held, currency } |
balance.topped_up | A top-up or an auto-recharge was added to your balance. | { object: "topup", paymentIntentId, amount, currency, flow, balance } |
balance.recharge_failed | An auto-recharge could not charge your card. | { object: "balance", amount, currency, message } |
List events
GET /v1/events returns your events, newest first, as { object: "list", data, hasMore }.
limitinteger
1 to 100. Default 20.
starting_afterstring
An event id: returns the events after it.
typestring
Only events of one type, such as
job.failed.Retrieve an event
GET /v1/events/:id returns one event with the data it was stored with.
Errors
| Status | Code | When |
|---|---|---|
| 400 | invalid_request | A field is missing, wrong or out of range. The message says which; details.issues lists the fields. |
| 401 | unauthorized | The key is missing, wrong or revoked. |
| 404 | not_found | No such object on your account. |
| 429 | rate_limited | Too many requests. Retry after Retry-After seconds. |