---
title: "Get automation run logs"
method: GET
path: "/automations/{automationId}/runs/{runId}/logs"
tags: ["Automations"]
---

# Get automation run logs

`GET /automations/{automationId}/runs/{runId}/logs`

## Request

- Base URL: `https://api.sazabi.com/v1`
- URL: `https://api.sazabi.com/v1/automations/{automationId}/runs/{runId}/logs`
- Auth: none declared

Get the captured stdout/stderr for a single automation run, reading the full output from durable storage when the inline preview was truncated.

## Path parameters

- `automationId` string, uuid, required: Automation ID.
- `runId` string, uuid, required: Automation run ID.

## Query parameters

- `projectId` string, uuid: Project that owns the automation. Auto-filled from CLI and SDK context when omitted.

## Response `200`

OK

- object
  - `logs` object, required
    - `stdout` string, required: Captured standard output for the run.
    - `stderr` string, required: Captured standard error for the run.
    - `exitCode` integer, nullable, required: Process exit code of the run's command, if it finished.
    - `status` 'queued' | 'running' | 'succeeded' | 'failed' | 'timed_out', required: Execution status of the run's captured command.
    - `truncated` boolean, required: Whether the captured output exceeded the inline preview limit. The full output is returned when it could be read from durable storage; otherwise the truncated preview is returned with this flag set.
    - `startedAt` string, date-time, nullable, required: When the command started executing, if known.
    - `completedAt` string, date-time, nullable, required: When the command finished executing, if known.
    - `durationMs` integer, nullable, required: Command execution duration in milliseconds, if known.

---

[API](https://skmtc.dev/sazabi/apis/sazabi-public-api.md) - [All operations](https://skmtc.dev/sazabi/apis/sazabi-public-api/llms.txt) - [OpenAPI document](https://skmtc.dev/sazabi/apis/sazabi-public-api/revisions/965b6230cf45?raw)
