Skip to main content
GET
Get a task, with its result once completed

Authorizations

Authorization
string
header
required

An API key from the dashboard: afg_live_… or afg_test_….

Path Parameters

taskId
string
required

Response

OK

id
string
required
status
enum<string>
required
Available options:
queued,
processing,
completed,
failed
mode
enum<string>
required
Available options:
live,
test
prompt
string
required
model
string
required
country
string
required
language
string
required
enrichments
string[]
required
metadata
object
required
webhookUrl
string | null
required
costMicros
integer
required

What the task was charged, in micro-dollars: 13000 is $0.013. 0 for a test key.

refunded
boolean
required
apiKeyId
string | null
required
createdAt
string
required
startedAt
string | null
required
completedAt
string | null
required
failedAt
string | null
required
error
object | null
required
resultExpiresAt
string | null
required

When the result stops being readable: 7 days after completion. Null until the task completes.

result
object | null
required

Once completed, on GET /v1/tasks/{taskId} only, for 7 days (resultExpiresAt). Null after that; the task stays.