Talos docs

POST /input

Since 0.6
Plain text

Request

Request body: InputRequest

POST /input request: synthetic input for the playtester.

FieldTypeRequiredDescription
actionsInputEvent[]yesThe actions and axes to inject, applied in order.

Request body: InputEvent

One synthetic input, tagged by type.

ValueMeaning
actionA named action, as ctx.input.pressed("jump") reads it.
axisA two-axis input, as ctx.input.axis("move") reads it.
steerWorld-frame steering for a harness walking a route.
mouseMouse motion, as a person's mouse gives it: delta pixels every tick, for frames ticks.
keyOne key going down or up, as the window's keyboard sends it.

Response

Response: InputResponse

POST /input response.

FieldTypePresentDescription
acceptedintegeralwaysHow many of the submitted inputs were applied.
frameintegeralwaysThe frame they take effect on: the next tick the sim runs.
unboundstring[]sometimesNames that no entity in the scene consumes, so the caller learns about a typo instead of watching nothing happen.

Example

curl -X POST "http://127.0.0.1:7700/input" --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.