---
title: "Create a short-lived document upload grant"
method: POST
path: "/v1/telephony/compliance-cases/{id}/uploads:grant"
tags: ["Telephony"]
---

# Create a short-lived document upload grant

`POST /v1/telephony/compliance-cases/{id}/uploads:grant`

## Request

- Base URL: `https://api.pyai.com`
- URL: `https://api.pyai.com/v1/telephony/compliance-cases/{id}/uploads:grant`
- Auth: one of:
  - HTTP bearer
  - API key in header `x-api-key`

Returns an opaque object reference and a five-minute, single-object V4 upload URL. The client must send every returned required header. The declared MIME type, size, and SHA-256 are pinned into object metadata; no URL or document bytes are persisted in the control-plane database.

## Path parameters

- `id` string, required

## Request body

- NumberComplianceUploadGrantCreate
  - `document_request_id` string, required
  - `mime_type` string, required
  - `size_bytes` integer, required
  - `sha256` string, required

## Response `200`

Short-lived scoped upload grant

- NumberComplianceSignedGrant
  - `object_ref` string
  - `signed_url` string, uri, required: Ephemeral transport credential. Never persist or log it.
  - `required_headers` object
  - `expires_at` integer, required

## Other responses

- `400`: Invalid request (bad field, unsupported value)
- `409`: Secure document storage is not configured.

---

[API](https://skmtc.dev/pyai/apis/pyai-api.md) · [All operations](https://skmtc.dev/pyai/apis/pyai-api/llms.txt) · [OpenAPI document](https://skmtc.dev/pyai/apis/pyai-api/revisions/271a1539185b?raw)
