Talos docs

POST /scene

Since 0.6

Switch the running world to another scene of the project.

Plain text

Request

Request body: SceneRequest

POST /scene request: switch the running world to another scene of the project.

FieldTypeRequiredDescription
scenestringyesThe scene, project-relative with / separators: what ctx.session.loadScene takes. It is resolved inside the session's content root and may not leave it.

Response

Response: SceneResponse

POST /scene response.

FieldTypePresentDescription
scenestringalwaysThe scene now running, as ctx.session.scene() answers it.
frameintegeralwaysThe frame the new world starts on.
entitiesintegeralwaysHow many entities it holds.

Example

curl -X POST "http://127.0.0.1:7700/scene" --json @body.json

Start a server with argus run --serve; the port is --port (7700 by default). The request and response fields are in the query API guide.