---
title: "Public Upload Document"
method: POST
path: "/api/share-links/public/{token}/upload"
tags: ["Share Links"]
---

# Public Upload Document

`POST /api/share-links/public/{token}/upload`

## Request

- Base URL: `https://api.flagpost.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.flagpost.ai/api/share-links/public/{token}/upload`
- Auth: HTTP bearer

Upload a document via share link.

Validates the token and uploads the document to the business's data room.
Uses atomic increment to prevent race conditions with max_uses quota.

## Path parameters

- `token` string, required

## Request body `multipart/form-data`

- BodyPublicUploadDocumentApiShareLinksPublicTokenUploadPost
  - `file` string, binary, required

## Response `200`

Successful Response

- object

## Other responses

- `422`: Validation Error

---

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