> ## Documentation Index
> Fetch the complete documentation index at: https://docs.trypost.it/llms.txt
> Use this file to discover all available pages before exploring further.

# Upload to signed URL

> Receives a file at a one-time signed URL issued by the MCP `request-media-upload-tool`. No API key: the signature authorizes the request. Send the file as `multipart/form-data` in the `media` field, for example `curl -F media=@launch.jpg "<upload_url>"`. The URL works once, until it expires (15 minutes by default); a second upload to it returns `409`. The returned `upload_token` is then used as a media item, like a token from `POST /uploads`. Accepted files: JPEG, PNG, GIF and WebP images (HEIC and HEIF too when the server can convert them, stored as JPEG), MP4 and MOV videos, and PDF documents. Size caps: 10 MB per image (and at most about 67 megapixels, 8192 × 8192 pixels in total), 1 GB per video, 100 MB per PDF. Each network enforces its own, usually smaller, caps when the post is scheduled or published (`GET /content-types`). A file the server cannot read returns `422` with only `message`: `Unable to read uploaded file.`



## OpenAPI

````yaml /openapi.json post /uploads/{token}
openapi: 3.1.0
info:
  title: TryPost API
  version: 2.0.0
  description: >-
    REST API for TryPost. Authenticate with a workspace API key as a Bearer
    token.
servers:
  - url: https://app.trypost.it/api
    description: TryPost Cloud
security:
  - bearerAuth: []
tags:
  - name: Posts
    description: Create, read, update, delete and preview posts.
  - name: Post notes
    description: Internal notes on a post, visible to workspace members.
  - name: Approvals
    description: Approve or reject posts waiting for approval.
  - name: Recurrence
    description: Make a post repeat on a schedule.
  - name: Media and uploads
    description: Upload files and attach media to posts.
  - name: Social accounts
    description: Connected social accounts and their network-specific options.
  - name: Channels
    description: A channel's posting schedule and queue.
  - name: Ideas
    description: Ideas on the Create board.
  - name: Idea stages
    description: The groups (columns) of the ideas board.
  - name: Analytics
    description: Workspace and channel insights.
  - name: Labels
    description: Labels to organize posts and ideas.
  - name: Signatures
    description: Reusable text to append to posts.
  - name: Workspace
    description: The workspace the API key belongs to.
  - name: API keys
    description: Personal API keys for this workspace.
  - name: Webhooks
    description: Outgoing webhooks and their delivery logs.
  - name: Repurposes
    description: Automations that republish videos posted outside TryPost.
  - name: Platform
    description: Platform capabilities and content types.
paths:
  /uploads/{token}:
    post:
      tags:
        - Media and uploads
      summary: Upload to signed URL
      description: >-
        Receives a file at a one-time signed URL issued by the MCP
        `request-media-upload-tool`. No API key: the signature authorizes the
        request. Send the file as `multipart/form-data` in the `media` field,
        for example `curl -F media=@launch.jpg "<upload_url>"`. The URL works
        once, until it expires (15 minutes by default); a second upload to it
        returns `409`. The returned `upload_token` is then used as a media item,
        like a token from `POST /uploads`. Accepted files: JPEG, PNG, GIF and
        WebP images (HEIC and HEIF too when the server can convert them, stored
        as JPEG), MP4 and MOV videos, and PDF documents. Size caps: 10 MB per
        image (and at most about 67 megapixels, 8192 × 8192 pixels in total), 1
        GB per video, 100 MB per PDF. Each network enforces its own, usually
        smaller, caps when the post is scheduled or published (`GET
        /content-types`). A file the server cannot read returns `422` with only
        `message`: `Unable to read uploaded file.`
      operationId: uploadToSignedUrl
      parameters:
        - name: token
          in: path
          required: true
          description: Upload token from the signed URL.
          schema:
            type: string
            format: uuid
          example: 4f6c2b1e-8d3a-4e5f-9a7b-1c2d3e4f5a6b
        - name: workspace_id
          in: query
          required: true
          description: Part of the signed URL.
          schema:
            type: string
            format: uuid
        - name: expires
          in: query
          required: true
          description: Part of the signed URL (Unix timestamp).
          schema:
            type: integer
        - name: signature
          in: query
          required: true
          description: Part of the signed URL.
          schema:
            type: string
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
                - media
              properties:
                media:
                  type: string
                  format: binary
                  description: The file.
      responses:
        '201':
          description: The stored file.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SignedUpload'
              example:
                upload_token: 4f6c2b1e-8d3a-4e5f-9a7b-1c2d3e4f5a6b
                media_id: 9d3c1f30-8a9b-4c0d-9e1f-2a3b4c5d6e7f
                type: image
                mime_type: image/jpeg
                original_filename: launch.jpg
        '403':
          description: The signature is invalid or the URL expired.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
              example:
                message: Invalid signature.
        '404':
          description: The workspace of this URL no longer exists.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '409':
          description: This URL was already used. The body has an empty `message`.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
              example:
                message: ''
        '422':
          $ref: '#/components/responses/ValidationError'
        '429':
          description: >-
            Too many uploads. Limits: 60 per minute per workspace and 1200 per
            minute per IP address.
          headers:
            Retry-After:
              description: Seconds to wait before retrying.
              schema:
                type: integer
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RateLimitErrorBody'
      security: []
components:
  schemas:
    SignedUpload:
      type: object
      properties:
        upload_token:
          type: string
          format: uuid
        media_id:
          type: string
          format: uuid
        type:
          type: string
          enum:
            - image
            - video
            - document
        mime_type:
          type: string
        original_filename:
          type: string
    ErrorBody:
      type: object
      properties:
        message:
          type: string
    RateLimitErrorBody:
      type: object
      properties:
        name:
          type: string
          const: rate_limit_exceeded
        message:
          type: string
          examples:
            - Rate limit exceeded. Please retry after 30 seconds.
    ValidationErrorBody:
      type: object
      properties:
        message:
          type: string
        errors:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
  responses:
    ValidationError:
      description: Validation failed.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ValidationErrorBody'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Workspace API key from Settings → API Keys.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.