Generate World
Changed onStart world generation.
Creates a new world generation job and returns a long-running operation. Poll the /operations/{operation_id} endpoint to check generation status and retrieve the generated world when complete.
Args: request: The world generation request containing world_prompt, display_name, tags, model, seed, and permission settings.
Returns: GenerateWorldResponse with operation_id and timestamps. Use the operation_id to poll for completion.
Raises: HTTPException: 400 if invalid request or content violates policies HTTPException: 402 if insufficient credits HTTPException: 500 if generation could not be started
Request
- Base URLhttps://api.worldlabs.ai
- AuthAPI key in header WLT-Api-Key
Request body
Example request
{
"display_name": "Coastal Castle",
"model": "marble-1.0",
"permission": {
"public": false
},
"seed": 42,
"tags": [
"fantasy",
"coastal"
],
"world_prompt": {
"text_prompt": "A grand, ivy-covered castle rises from the shoreline at sunset, its reflection shimmering in the tranquil ocean waves.",
"type": "text"
}
}Response
Successful Response
Changes
- info
added
data_base64media_asseturidiscriminator mapping keys to the//request property - info
added
data_base64media_asseturidiscriminator mapping keys to the////request property - info
added
data_base64media_asseturidiscriminator mapping keys to the//request property - info
added
imagemulti-imagetextvideodiscriminator mapping keys to therequest property
- info