API reference

API reference · API

A project's plans

GET/v1/studio/projects/{id}/plansAPI key

Newest first. A 404 while video and sound jobs are switched off. An API key with the read scope. Rate limited per key at the key's own requests a minute, in a window of its own. An agent's key is refused (403 policy_violation). Every /v1/studio door is a 404 while video and sound jobs are switched off.

Parameters

Path and query parameters
FieldTypeWhat it is
id (path)requiredstringThe project's id, stp_ followed by hex.
limit (query)integer
after (query)stringThe last_id of the previous page.

Answer 200

The plans.

Fields of the 200 answer
FieldTypeWhat it is
objectstringOne of "list".
dataarray of object
data[].idstring
data[].objectstringOne of "studio.plan".
data[].project_idstring
data[].statusstringOne of "running", "completed", "cancelled".
data[].quote_microsintegerThe total the balance was checked against.
data[].microsintegerSettled shots' charges plus running shots' holds.
data[].countsobject
data[].shotsarray of object
data[].shots[].idstring
data[].shots[].objectstringOne of "studio.shot".
data[].shots[].indexinteger
data[].shots[].titlestring or null
data[].shots[].modelstring
data[].shots[].statusstringOne of "waiting", "starting", "running", "completed", "failed", "cancelled".
data[].shots[].microsintegerThe quote while it waits, the job's hold while it runs, the charge once done.
data[].shots[].job_idstring or null
data[].shots[].jobobject or nullThe shot's job, as /api/studio/jobs answers it.
data[].shots[].errorobject or null
data[].shots[].error.codestring
data[].shots[].error.messagestring
data[].shots[].created_atinteger
data[].shots[].started_atinteger or null
data[].shots[].finished_atinteger or null
data[].created_atinteger
data[].finished_atinteger or null
has_moreboolean
last_idstring or null

Errors

  • 401OpenAI shaped error.
  • 403OpenAI shaped error.
  • 404OpenAI shaped error.
  • 429OpenAI shaped error.

Every error answers in one shape, with its type, code and the field it names. The whole list is in the docs' Errors section.

Antimatter