---
title: "Get file"
method: GET
path: "/v1/files/{id}"
tags: ["Files"]
---

# Get file

`GET /v1/files/{id}`

Retrieves the data for a specific file by its ID.

## Path parameters

- `id` string, required

## Response `200`

Successfully retrieved file data.

- union — The response for a file. Properties depend on the file type.
  - ImageResponse — The response for an image file
    - `id` string, required — The id of the file
    - `name` string, required — The name of the file
    - `task_id` string, nullable, required — The id of the task that generated this file, if any
    - `created_at` string, required — The creation date of the file in ISO format
    - `type` 'image/png' | 'image/jpeg' | 'image/webp', required — The MIME type of the file
    - `properties` object, required
      - `size` number, required — The size of the image in bytes
      - `width` number, required — The width of the image in pixels
      - `height` number, required — The height of the image in pixels
  - DocumentResponse — The response for a document file
    - `id` string, required — The id of the file
    - `name` string, required — The name of the file
    - `task_id` string, nullable, required — The id of the task that generated this file, if any
    - `created_at` string, required — The creation date of the file in ISO format
    - `type` 'application/pdf', required — The MIME type of the file
    - `properties` object, required
      - `size` number, required — The size of the document in bytes
      - `page_count` number, required — The number of pages in the document

## Other responses

- `404` — Not Found. The file with the specified ID does not exist or does not belong to the user.
- `422` — Validation Error. The file ID format is invalid.
- `429` — Rate Limit Exceeded.
- `5XX` — Internal Server Error.

---

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