FleetDeckDocs

Action payload · devices:control

key

Send one key: return, backspace, space, tab, up, down, left or right. Focus and OS behavior determine its effect.

Payload

json
{
  "type": "key",
  "key": "return"
}

Payload fields

typestringrequired

Discriminator that selects the action or content shape.

Allowed:"key"
keystringrequired

Keyboard key to send to the currently focused control.

Allowed:"return""backspace""space""tab""up""down""left""right"

Unknown fields are rejected.

View JSON Schema
json
{
  "type": "object",
  "properties": {
    "type": {
      "type": "string",
      "enum": [
        "key"
      ],
      "description": "Discriminator that selects the action or content shape."
    },
    "key": {
      "type": "string",
      "enum": [
        "return",
        "backspace",
        "space",
        "tab",
        "up",
        "down",
        "left",
        "right"
      ],
      "description": "Keyboard key to send to the currently focused control."
    }
  },
  "required": [
    "type",
    "key"
  ],
  "additionalProperties": false,
  "description": "Send one key: return, backspace, space, tab, up, down, left or right. Focus and OS behavior determine its effect.",
  "example": {
    "type": "key",
    "key": "return"
  }
}

REST wraps this payload inside {requestId, command}. The matching MCP tool takes sessionId and requestId plus these fields, without the type discriminator.

Contract

Submit this as command to POST /sessions/{sessionId}/actions, pass it as the CLI action JSON, or use the matching MCP convenience tool. Command objects are strict and reject unknown fields.

Execution

Send one key: return, backspace, space, tab, up, down, left or right. Focus and OS behavior determine its effect.

Action status and driver result remain separate. A completed result can still require a fresh screenshot or hierarchy check to prove the intended visible effect.