Dispatch a background-generator workflow
POST
/v1/background-generator
const url = 'https://example.com/v1/background-generator';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"image_model":"example","eval_enabled":true,"resolution":"example","aspect_ratio":"example","seed":1,"on_technical_failure":"example","display_name":"","authoring":{"display_name":"example","setting":"studio_set","photographic_register":"real_photo","topology":{"preset":"seamless_sweep","custom_text":"example"},"subject_zone":{"preset":"near_rear_plane","custom_text":"example"},"supported_crops":["full"],"ground":{"preset":"seamless","custom_text":"example"},"light":{"preset":"soft_frontal","custom_text":"example"},"palette":["example"],"scene_anchors":["example"],"surface_character":"example"},"background_public_id":"example","scene_type":"example","mood":"example","dominant_colors":["example"],"metadata":{},"pilot_brand":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/v1/background-generator \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "image_model": "example", "eval_enabled": true, "resolution": "example", "aspect_ratio": "example", "seed": 1, "on_technical_failure": "example", "display_name": "", "authoring": { "display_name": "example", "setting": "studio_set", "photographic_register": "real_photo", "topology": { "preset": "seamless_sweep", "custom_text": "example" }, "subject_zone": { "preset": "near_rear_plane", "custom_text": "example" }, "supported_crops": [ "full" ], "ground": { "preset": "seamless", "custom_text": "example" }, "light": { "preset": "soft_frontal", "custom_text": "example" }, "palette": [ "example" ], "scene_anchors": [ "example" ], "surface_character": "example" }, "background_public_id": "example", "scene_type": "example", "mood": "example", "dominant_colors": [ "example" ], "metadata": {}, "pilot_brand": "example" }'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Header Parameters
Section titled “Header Parameters”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
BackgroundGeneratorRequest
POST /v1/background-generator — canonical v1 or legacy background generation.
object
display_name
Display Name
string
authoring
Any of:
BackgroundAuthoringInput
The high-leverage public brief for a reusable physical Background.
object
display_name
required
Display Name
string
setting
required
Setting
string
photographic_register
required
Photographic Register
string
topology
required
subject_zone
required
supported_crops
required
Supported Crops
Array<string>
ground
required
light
required
palette
required
Palette
Array<string>
scene_anchors
required
Scene Anchors
Array<string>
null
dominant_colors
Dominant Colors
Array<string>
metadata
Metadata
object
key
additional properties
any
Responses
Section titled “Responses”Successful Response
Media typeapplication/json
WorkflowAcceptedResponse
Returned synchronously from any POST /v1/{name} (202).
object
request_id
required
Request Id
26-char ULID — correlates with the row in credit_operations.
string
status
JobStatus
Studio’s job status at submit time. Almost always NOT_STARTED in this 202.
string
credits_cost
required
Credits Cost
Credits deducted from the calling client. Refunded automatically on any failure path.
integer
Example
{ "status": "NOT_STARTED"}Validation Error
Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationErrorobject
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
Examplegenerated
{ "detail": [ { "loc": [ "example" ], "msg": "example", "type": "example" } ]}