---
title: "Prepare test set upload"
method: POST
path: "/tabpfn/prepare_test_set_upload"
tags: ["Prediction"]
---

# Prepare test set upload

`POST /tabpfn/prepare_test_set_upload`

**Recommended:** Use [tabpfn-client](https://github.com/PriorLabs/tabpfn-client) (`TabPFNClassifier` / `TabPFNRegressor`). It calls these routes for you.

After fit: pass `fitted_train_set_id` and `x_test_info`; receive `test_set_upload_id` and signed URLs for test features.

## Request body

- PrepareTestSetUploadRequest
  - `fitted_train_set_id` string, uuid, required
  - `x_test_info` FileInfo, required
    - `format` 'csv' | 'parquet', required
    - `hash` string, nullable — The crc32c hash of the file, used to deduplicate the file.
    - `size_bytes` integer, nullable — The size of the file in bytes, used to compute the optimal number of chunks when chunking is enabled.
    - `use_chunks` boolean — Whether to split the the file into chunks and upload them in parallel.
  - `force_reupload` boolean — Whether to force the upload of the file even if a file with the same hash already exists.

## Response `200`

Test upload id and signed URLs

- PrepareTestSetUploadResponse
  - `test_set_upload_id` string, uuid, required
  - `x_test_info` FileUploadInfo, required
    - `signed_urls` string[], required
    - `expires_at` number, required
    - `required_headers` object, required

---

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