---
title: "List one directory of the chat's sandbox: folders first, then files."
method: GET
path: "/ai/conversations/{public_id}/sandbox/files"
tags: ["AI Chat"]
---

# List one directory of the chat's sandbox: folders first, then files.

`GET /ai/conversations/{public_id}/sandbox/files`

## Request

- Base URL: `/api` (relative, and the document was published on a file host, not at the API’s origin)
- URL: `/api/ai/conversations/{public_id}/sandbox/files`
- Auth: HTTP bearer

## Path parameters

- `public_id` string, required

## Query parameters

- `path` string, nullable

## Response `200`

Directory listing

- SandboxDirectory: One directory of the chat's sandbox: folders first, then files, by name.
  - `entries` SandboxEntry[], required
    - `kind` 'file' | 'directory' | 'symlink' | 'other', required: What a directory entry is.
    - `name` string, required
    - `path` string, required: Absolute path inside the sandbox.
    - `size` integer, required: Size in bytes as the filesystem reports it.
  - `path` string, required: Absolute path of the directory listed.
  - `truncated` boolean, required: True when the directory has more than the entries returned.
  - `work_dir` string, required: The sandbox work directory, where the assistant's relative paths start.

## Other responses

- `400`: Invalid path
- `401`: Unauthorized
- `403`: Insufficient permissions
- `404`: Conversation, sandbox or directory not found
- `409`: No sandbox is linked, or it could not be started
- `500`: The listing command failed
- `503`: This server has no sandbox backend
- `504`: The sandbox did not answer in time

## Changes

> 81 revisions in range; 1 not diffed.

- **2026-10-20** `79089e9f49ee`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/gotempsh/apis/temps/changes/ai/conversations/:public_id/sandbox/files/get.md)

---

[API](https://skmtc.dev/gotempsh/apis/temps.md) · [All operations](https://skmtc.dev/gotempsh/apis/temps/llms.txt) · [OpenAPI document](https://skmtc.dev/gotempsh/apis/temps/revisions/ab6d5d19e930?raw)
