---
title: "Get File"
method: GET
path: "/storage/files"
---

# Get File

`GET /storage/files`

## Request

- Base URL: `https://api.traversal.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.traversal.com/storage/files`
- Auth: none declared

Retrieve file contents from S3 storage.

Requires platform admin role.

Args:
    s3_key: S3 key path to retrieve (relative to bucket and storage prefix)

Returns:
    GetFileResponse with file content and path

Raises:
    HTTPException: 400 if s3_key is empty, 403 if not platform admin, 404 if file not found, 500 for other errors

## Query parameters

- `s3_key` string, required

## Response `200`

Successful Response

- GetFileResponse: Response containing file content and metadata. Attributes: content: File content as a UTF-8 decoded string path: The S3 key path that was retrieved
  - `content` string, required
  - `path` string, required

## Other responses

- `422`: Validation Error

---

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