---
title: "Get a file"
method: GET
path: "/v1/workspaces/{workspace_id}/files/{file_id}"
tags: ["Files"]
---

# Get a file

`GET /v1/workspaces/{workspace_id}/files/{file_id}`

## Request

- Base URL: `https://api.stacksync.com`
- URL: `https://api.stacksync.com/v1/workspaces/{workspace_id}/files/{file_id}`
- Auth: HTTP bearer

A file's details. Its content is downloaded through the file proxy.

## Path parameters

- `workspace_id` integer, required
- `file_id` string, uuid, required

## Query parameters

- `region` 'besg' | 'usnv', required

## Response `200`

OK

- WorkspaceFile: A file stored in the workspace (a knowledge base document, a genie attachment, an upload)
  - `file_id` string, required
  - `name` string, required
  - `mime_type` string, nullable, required
  - `size_bytes` integer, nullable, required
  - `tags` string[], required
  - `source` string, nullable, required
  - `source_ref` string, nullable, required: Id of the resource the file belongs to, null when it belongs to none
  - `created_at` string, nullable, required
  - `region` string, required

## Other responses

- `400`: Bad Request
- `403`: Forbidden
- `404`: Not Found

---

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