---
title: "Get presigned URL for template upload"
method: POST
path: "/api/v1/templates/upload-url"
tags: ["Templates"]
---

# Get presigned URL for template upload

`POST /api/v1/templates/upload-url`

## Request

- Base URL: `https://api.korala.ai`
- URL: `https://api.korala.ai/api/v1/templates/upload-url`
- Auth: one of:
  - API key in header `X-API-Key`
  - `bearer` (a scheme the document does not define)

## Request body

- CreateTemplateUploadUrlDto
  - `sandbox` boolean: Dashboard mode. API keys always use their authenticated mode.
  - `collectionIds` string[]: Explicit destination collections. Omission or [] leaves the resource unassigned.
  - `filename` string, required
  - `contentType` string, required: MIME type of the file. Supported: application/pdf, application/vnd.openxmlformats-officedocument.wordprocessingml.document

## Response `201`

- TemplateUploadUrlResponseDto
  - `templateId` string, required
  - `uploadUrl` string, required
  - `key` string, required
  - `maxUploadBytes` number, required: Largest file this organization's plan accepts, in bytes. Uploading a bigger file is rejected when the upload is confirmed, so check it before transferring.

---

[API](https://skmtc.dev/korala/apis/korala-public-api.md) · [All operations](https://skmtc.dev/korala/apis/korala-public-api/llms.txt) · [OpenAPI document](https://skmtc.dev/korala/apis/korala-public-api/revisions/5c4d7810c507?raw)
