---
title: "Get stack logs"
method: GET
path: "/v1/stacks/{id}/logs"
tags: ["Stacks"]
---

# Get stack logs

`GET /v1/stacks/{id}/logs`

Retrieve logs from all services in the stack

## Path parameters

- `id` string, required — Stack identifier

## Query parameters

- `tail` string — Number of log lines to return per service

## Response `200`

Structured logs from all services

- object — Structured logs response from stack
  - `id` string, required — Stack ID
  - `services` object[], required — Logs organized by service
    - `id` string, required — Service ID
    - `name` string, required — Service name
    - `role` 'frontend' | 'backend' | 'fullstack' | 'worker' | 'database' | 'unknown', required — Service roles in a stack
    - `logs` string, required — Logs for this service
    - `lineCount` number, required — Number of log lines
  - `combinedLogs` string — Combined logs from all services (legacy support)
  - `totalLineCount` number, required — Total log lines across all services

## Other responses

- `404` — Stack not found

## Changes

- **2025-10-29** `17a1ccb59fba` — 1 info
  - api operation id `get_stack_logs` was added
- **2025-10-29** `1a4801fc49a1` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/benchify/apis/benchify-api/changes/v1/stacks/:id/logs/get.md)

---

[API](https://skmtc.dev/benchify/apis/benchify-api.md) · [All operations](https://skmtc.dev/benchify/apis/benchify-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/benchify/benchify-api/revisions/1a65aea8dd7d/schema)
