> This is the Markdown version of the page. For the complete Lattice Developers documentation index, fetch https://developer.anduril.com/llms.txt. Append .md to any page URL for its clean Markdown.

# Stream manual control frames

POST https://example.developer.anduril.com/api/v1/tasks/{taskId}/manual-control/stream
Content-Type: application/json

Establishes a server streaming connection that delivers manual control frames to agents
using server-sent events (SSE).

This endpoint streams manual control frames, for example, for joystick movements, for a specific task
to the executing agent. The agent should open this stream before reporting `STATUS_EXECUTING`
to ensure it is ready to receive control input when the operator begins sending frames.

Each frame includes epoch and sequence metadata for handling concurrent control sessions
and detecting stale or out-of-order frames. Heartbeat messages are sent periodically to
maintain the connection.

The stream terminates automatically when the task reaches a terminal state
(`STATUS_DONE_OK` or `STATUS_DONE_NOT_OK`).

Reference: https://developer.anduril.com/reference/rest/tasks/stream-manual-control-frames

## Authentication

- `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer <token>`, where token is your auth token.

## Request

### Path parameters

- `taskId` (string, required) — The ID of the manual control task to receive frames for.

### Body (application/json)

This endpoint expects a ManualControlStreamRequest.

- `heartbeatIntervalMs` (integer, optional) — The time interval, in milliseconds, that determines the frequency at which to send heartbeat events. Defaults to 30000 (30 seconds).

## Response

### 200

Returns a stream of manual control frames as they are sent by the operator.

- Streaming response of `Tasks_streamManualControlFrames_Response_200`.
- `event`: `heartbeat` (heartbeat)
  - `timestamp` (string, optional) — The timestamp at which the heartbeat message was sent.
- `event`: `manual_control_frame` (manual_control_frame)
  - `creationTime` (datetime, optional) — The time at which this frame was created. Agents can use this to detect stale frame data.
  - `epochMicros` (string, optional) — Unix timestamp in microseconds identifying the control session. Increments each time a client opens a new stream for this task. Agents should ignore frames with a lower epoch to handle stale streams or operator handoffs.
  - `sequence` (string, optional) — The sequence number for a stream, incremented for each frame. Agents can use this to detect out-of-order delivery within the same epoch.
  - `specification` (GoogleProtobufAny, optional) — The control instructions for this frame, passed through from the client. The format of each task is specific to the task, and not visible to Lattice.
  - `taskId` (string, optional) — The ID of the manual control task this frame belongs to.

## Errors

### 400 Bad Request Error

Bad request

- `code` (string, required)
- `message` (string, required)

### 401 Unauthorized Error

Unauthorized to access resource

- `code` (string, required)
- `message` (string, required)

## Types

### GoogleProtobufAny

Contains an arbitrary serialized message along with a @type that describes the type of the serialized message.

- `@type` (string, optional) — The type of the serialized message.

## Examples

**Request**

```json
{}
```