---
title: "Resolve a file"
method: GET
path: "/datasets/{namespace}/{repo}/resolve/{rev}/{path}"
tags: ["datasets"]
---

# Resolve a file

`GET /datasets/{namespace}/{repo}/resolve/{rev}/{path}`

This endpoint requires to follow redirection

## Path parameters

- `namespace` string, required
- `repo` string, required
- `rev` string, required
- `path` string, required — Wildcard path parameter

## Headers

- `Range` string — The range in bytes of the file to download
- `Accept` 'application/vnd.xet-fileinfo+json' — Returns json information about the XET file info - if the file is a xet file

## Response `200`

The XET file info only available if the accept header is set to application/vnd.xet-fileinfo+json

- object
  - `hash` string, required — The XET hash of the file
  - `refreshUrl` string, required — The XET auth URL for the file
  - `reconstructionUrl` string, required — The XET reconstruction URL for the file
  - `etag` string, required — The ETag of the file
  - `size` number, required — The size of the file

## Other responses

- `302` — Redirection to file
- `304` — Not modified
- `307` — Redirection to Xet endpoint

---

[API](https://skmtc.net/huggingface/apis/hub-api-endpoints.md) · [All operations](https://skmtc.net/huggingface/apis/hub-api-endpoints/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/huggingface/hub-api-endpoints/versions/dae0cc3790f0/schema)
