ReferenceAPI

Get a stream URL

Get a signed, reusable URL that speaks the Exec protocol, so a client can run commands or open a session on the computer without going through the API.

POST https://api.nevia.cloud/v1/computers/{cmp}/stream
curl -X POST "https://api.nevia.cloud/v1/computers/01d4cnjk3xg90y576w8y6t4gdwm/stream" \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "ttl_seconds": 3600,
    "env": {
      "LANG": "C"
    }
  }'
{
  "url": "https://exec.example.com/v1/vms/m_0001/exec?v=2&k=1&i=1757592000&e=1757595600&m=m_0001&n=n0002&c=&s=Zm9v",
  "expires_at": "2026-09-10T12:34:56Z",
  "protocol": "connect",
  "max_message_bytes": 1048576,
  "env_vars": [
    {
      "name": "OPENAI_KEY",
      "parts": [
        {
          "literal": "string"
        }
      ]
    }
  ],
  "namespace": "01d4cnjjq40hnnh0nwmkg35nv2h",
  "computer": {
    "id": "01d4cnjk3xg90y576w8y6t4gdwm",
    "workspace": "01d4cnjjq40hnnh0nwmkg35nv2h",
    "name": "api-staging",
    "state": "ready",
    "pending": null,
    "image": "docker.io/library/python:3.13-slim",
    "image_digest": "sha256:9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08",
    "ports": [
      {
        "published": 8080,
        "target": 8080,
        "protocol": "http1",
        "url": "https://01d4cnjk3xg90y576w8y6t4gdwm.machines.example:8080"
      }
    ],
    "url": "https://01d4cnjk3xg90y576w8y6t4gdwm.machines.example",
    "env_keys": [
      "LOG_LEVEL",
      "OPENAI_KEY"
    ],
    "env_vars": [
      {
        "name": "LOG_LEVEL",
        "source": "literal",
        "missing": false
      },
      {
        "name": "OPENAI_KEY",
        "source": "secret",
        "missing": false
      }
    ],
    "generation": 1,
    "protected": false,
    "parent": null,
    "from_checkpoint": null,
    "error": null,
    "created_at": "2026-09-10T12:34:56Z",
    "last_started_at": "2026-09-10T12:35:12Z",
    "last_active_at": "2026-09-10T12:40:03Z",
    "deleted_at": null
  },
  "workspace": "01d4cnjjq40hnnh0nwmkg35nv2h",
  "operations": [
    "01d4cnjm89yk0r3xtv80dy0x7by"
  ]
}

Authorization

bearerAuth
Authorization Bearer <token>

Send the token in the Authorization: Bearer <token> header. See Authenticate.

In: header

Path Parameters

cmp* string

Computer id: 27 lowercase letters and digits.

Match ^[A-Za-z0-9_-]{1,64}$

Header Parameters

Idempotency-Key? string

Optional retry key, kept 24 hours

Length 1 <= length <= 255

Request Body

application/json

Lifetime and env of an exec session URL

Behavior

The URL can't be revoked. Treat it as a credential and keep it out of logs.

Every call returns a new URL. Idempotency-Key is accepted but not replayed.

Response

application/json

The address of the Exec protocol and the computer it belongs to.

Where to reach the computer's exec protocol