---
title: "Read job output."
method: GET
path: "/v1/machines/{id}/jobs/{job_id}/output"
tags: ["machines"]
---

# Read job output.

`GET /v1/machines/{id}/jobs/{job_id}/output`

## Request

- Base URL: `https://api.smolmachines.com`
- URL: `https://api.smolmachines.com/v1/machines/{id}/jobs/{job_id}/output`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/smolmachines/apis/smolfleet-api/docs/v1/machines/:id/jobs/:job_id/output/get.ts> (a function with typed inputs; its response is checked against the schema)

A slice of the job's stdout or stderr from `offset`. Ask again from `nextOffset` until `eof`. Wakes a stopped machine, where the output is kept. Requires the `machine:exec` scope.

## Path parameters

- `id` string, required
- `job_id` string, required

## Query parameters

- `stream` string
- `offset` integer
- `limit` integer

## Response `200`

Output slice

- MachineJobOutput: A slice of a job's stdout or stderr.
  - `data` string, required: The slice as lossy UTF-8.
  - `dataB64` string, byte: The slice, byte-exact (base64).
  - `eof` boolean, required: True once the job has finished and this slice reaches the end of the stream: nothing more will be written.
  - `nextOffset` integer, required: Byte offset to ask for next.
  - `offset` integer, required: Byte offset this slice starts at.
  - `stream` string, required: `stdout` or `stderr`.

## Other responses

- `400`: Unknown stream
- `401`: Missing or invalid API key
- `403`: Key lacks the required scope
- `404`: Not found, or the output is gone from the machine
- `429`: Rate limited; retry after the Retry-After header
- `500`: Internal error
- `503`: Retryable: the machine was unavailable

## Changes

- **2026-10-16** `bc31fc04a568`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/smolmachines/apis/smolfleet-api/changes/v1/machines/:id/jobs/:job_id/output/get.md)

---

[API](https://skmtc.dev/smolmachines/apis/smolfleet-api.md) - [All operations](https://skmtc.dev/smolmachines/apis/smolfleet-api/llms.txt) - [OpenAPI document](https://skmtc.dev/smolmachines/apis/smolfleet-api/revisions/bc31fc04a568?raw)
