API reference
Recover an image task by request key
/v1/image-task-requests/{idempotency_key}Recover with the original request key and same API key. Query unknown submissions first; do not resend with a different request key.
Authentication and permissions
Use your current GloopAPI key. Available models, capabilities and permissions depend on its catalog and the endpoint documentation.
Authorization: Bearer $GLOOP_API_KEYAuthentication schemes: BearerAuth
Request
Path parameters
idempotency_keystringRequiredOriginal image request key, encoded as a single path segment; do not replace it with a new key.
Responses and errors
HTTP 200
Image task recovered by request key successfully
application/json
- Type
- object
- Required fields
modelpromptsizenreferencesidstatuscreated_atupdated_atreserved_quotafinal_quotabilling_statusresults
modelstringRequiredPublic model ID from the current key's catalog.
promptstringRequiredGeneration prompt.
sizestringRequiredSize value returned by the selected image-models entry; capabilities and sizes are validated per model.
nintegerRequiredRequested output image count, still constrained by the selected model's maximum.
referencesarrayRequiredList of reference images for generation.
references child fields (1)
[]objectOptional[] child fields (3)
oneOf branch 1
Required in this branch: file_id
oneOf branch 2
Required in this branch: asset_id
oneOf branch 3
Required in this branch: url
source_task_idstringOptionalPublic source task ID, for provenance only.
quote_idstringOptionalPublic quote ID; must satisfy price and request binding on creation.
idstringRequiredPublic identifier of this object, used for its corresponding detail path.
statusstringRequiredunknown is not automatically resubmitted; reserved billing may still be pending.
- Enum
["queued","dispatching","running","succeeded","partial_succeeded","failed","unknown","deleted"]
created_atintegerRequiredCreation time in Unix seconds.
updated_atintegerRequiredLast update time in Unix seconds.
reserved_quotaintegerRequiredReserved quota in platform quota units, not a USD amount.
final_quotaintegerRequiredFinal charge in platform quota units; null means not yet determined.
billing_statusstringRequiredReservation/settlement/refund status; check separately from task and archival status.
error_codestringOptionalPublic error code usable for branching logic.
error_messagestringOptionalUser-facing description processed through public error classification.
resultsarrayRequiredGenerated output items; each item's archival status is independent.
results child fields (1)
[]objectOptional[] child fields (7)
file_idstringOptionalPublic ID of a managed file for the same account and key.
storage_statusstringOptionalFile archival status; managed downloads are only guaranteed after ready.
storage_errorstringOptionalPublic category for file archival failure.
expires_atintegerOptionalExpiration in Unix seconds; 0 means no fixed expiration.
urlstringOptionalAccess URL for a result or reference; signed URLs are only valid briefly.
b64_jsonstringOptionalImage Base64 string; do not request it as a URL.
revised_promptstringOptionalRevised prompt returned by the service, if any.
HTTP 400
Invalid request fields or parameters.
application/json
- Type
- object
- Required fields
error
errorobjectRequirederror child fields (4)
codestringOptionalmessagestringOptionaltypestringOptionalrequest_idstringOptional
HTTP 401
The key is missing, invalid, expired, or revoked.
application/json
- Type
- object
- Required fields
error
errorobjectRequirederror child fields (4)
codestringOptionalmessagestringOptionaltypestringOptionalrequest_idstringOptional
HTTP 403
Insufficient IP, account, model, or tool permissions.
application/json
- Type
- object
- Required fields
error
errorobjectRequirederror child fields (4)
codestringOptionalmessagestringOptionaltypestringOptionalrequest_idstringOptional
HTTP 404
Object/capability unavailable, or feature switch disabled.
application/json
- Type
- object
- Required fields
error
errorobjectRequirederror child fields (4)
codestringOptionalmessagestringOptionaltypestringOptionalrequest_idstringOptional
HTTP 409
Idempotency/quote conflict, object not ready, or still referenced.
application/json
- Type
- object
- Required fields
error
errorobjectRequirederror child fields (4)
codestringOptionalmessagestringOptionaltypestringOptionalrequest_idstringOptional
HTTP 429
Request/queue rate limit.
application/json
- Type
- object
- Required fields
error
errorobjectRequirederror child fields (4)
codestringOptionalmessagestringOptionaltypestringOptionalrequest_idstringOptional
HTTP 500
Internal authentication or data storage failure.
application/json
- Type
- object
- Required fields
error
errorobjectRequirederror child fields (4)
codestringOptionalmessagestringOptionaltypestringOptionalrequest_idstringOptional
HTTP 503
Service, pricing, or storage unavailable.
application/json
- Type
- object
- Required fields
error
errorobjectRequirederror child fields (4)
codestringOptionalmessagestringOptionaltypestringOptionalrequest_idstringOptional