---
title: "show logs"
method: PUT
path: "/api/v0/instances/request_logs/{id}"
tags: ["Instances"]
---

# show logs

`PUT /api/v0/instances/request_logs/{id}`

Request logs from a specific instance. The logs will be uploaded to S3 and can be retrieved from a generated URL. Supports both container logs and daemon system logs.

CLI Usage: `vastai show logs <instance_id> [--tail <lines>] [--filter <grep>] [--daemon-logs]`

## Path parameters

- `id` integer, required

## Request body

- object
  - `tail` string — Number of lines to show from end of logs
  - `filter` string — Grep filter to apply to log entries
  - `daemon_logs` 'true' — If "true", fetch daemon system logs instead of container logs

## Response `200`

Success response with S3 URL for log retrieval

- object
  - `success` boolean
  - `result_url` string — S3 URL where logs can be downloaded
  - `msg` string — Status message

## Other responses

- `403` — Not authorized
- `404` — Instance not found

---

[API](https://skmtc.net/vast/apis/vast-ai-api.md) · [All operations](https://skmtc.net/vast/apis/vast-ai-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/vast/vast-ai-api/revisions/4ed14f79f796/schema)
