> Discover all available Postdom documentation from the machine-readable index: https://postdom.com/llms.txt

Configured tool · write

# `upload_media`

Create a short-lived direct-upload contract for finished video or image bytes.

write · non-destructive · closed-world

Human and agent roles

## Configured boundary

### Configured workspace

The returned URL is PUT-only and targets one server-generated key inside this workspace. Video bytes go directly to Postdom-owned storage, never through MCP or the API process; the signed URL is temporary and must not be exposed.

This reference describes the hosted server at https://api.postdom.com/mcp, which runs current source, with a workspace-scoped key created under Connected apps → For developers. The published `@postdom/mcp@0.4.0` package has 14 of these tools: it lacks list_posts, create_slideshow, account_music and the media array.

Callable schema

## Input fields

Field names match the configured tool schema. Runtime-only constraints are labeled separately from schema validation.

| Field | Type | Contract |
| --- | --- | --- |
| content_type Required | video/mp4 \| video/quicktime | Core platformLimits Exact Content-Type the caller will send on the PUT. |
| size_bytes Required | positive integer | At most 524 MB Exact byte length the caller will send on the PUT. |
| platforms Optional | platform[] | Optional; up to nine unique supported destinations Target platforms, when already known, for core media validation before URL issuance; each destination's limits are checked again at publish. |

**For AI agents:** Send only fields exposed by the current tool schema.

**Known failure:** Do not invent platform settings, account IDs, media fields, or setup steps.

Synthetic values

## Example call

Identifiers and values are examples. They do not represent a connected workspace or accepted media source.

_EXAMPLE CALL · CONFIGURED TOOL SCHEMA_

```
upload_media({
  content_type: "video/mp4",
  size_bytes: 2319,
  platforms: ["instagram", "youtube"]
})
```

Observed API record

## Return shape

Returns one five-minute PUT contract and an opaque workspace media handle.

**`media_handle` (pd_media_…)** — Opaque handle used by get_media and publish_video.

**`upload_url` (signed URL)** — Temporary single-key destination. Treat it as sensitive and do not log or share it.

**`method` (PUT)** — The only allowed upload method.

**`headers` (Content-Type · Content-Length)** — Exact headers the direct PUT must preserve.

**`expires_at` (datetime)** — When the short-lived upload URL stops accepting the PUT.

Stop conditions

## Agent handoff

`contract returned`

### PUT the exact bytes

Use the returned URL, method, and headers without modifying the object key or declared byte length.

`PUT complete`

### Verify the handle

Call get_media until it returns stored, pending, or failed.

`expired or rejected`

### Create a new upload

Never reuse or extend an expired signed URL.

 VERIFIED · 26 AUGUST 2026  **POST /v1/media/uploads · packages/core mediaOperations.createUpload**

Examples are synthetic. Human workspace-key creation and revocation remain in Postdom under Connected apps → For developers.
