Skip to main content
Glama

Upload image or video

upload_asset

Upload an image or video to PinBridge and get an asset_id for create_pin.

    Use when the media was generated in this session or Pinterest cannot
    fetch it from a public URL; otherwise pass image_url to create_pin
    directly. Provide exactly one of content_base64 or source_url. Videos
    must be uploaded assets.

    Returns id (use as asset_id), public_url, asset_type, content_type,
    size_bytes, created_at. Files are capped at 200 MB (plans cap lower).
    Fails with payment_required on plans without uploaded_media_assets
    (see get_billing_status), validation_error for unsupported media, and
    invalid_image when the file is truncated or corrupted (re-encode the
    exact original bytes; never retype base64 by hand).
    

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filenameYesFile name with extension, e.g. "hero.png".
asset_typeNoKind of media being uploaded.image
source_urlNoPublic http(s) URL the server downloads instead of content_base64; no redirects, private hosts are refused.
content_typeNoMIME type, e.g. "image/png"; inferred when omitted.
content_base64NoBase64-encoded file bytes (data: prefix allowed).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changed
    • addedInput schema / properties / asset_type / description
      Added value: +"Kind of media being uploaded."
    • addedInput schema / properties / content_base64 / description
      Added value: +"Base64-encoded file bytes (data: prefix allowed)."
    • addedInput schema / properties / content_type / description
      Added value: +"MIME type, e.g. \"image/png\"; inferred when omitted."
    • addedInput schema / properties / filename / description
      Added value: +"File name with extension, e.g. \"hero.png\"."
    • addedInput schema / properties / source_url / description
      Added value: +"Public http(s) URL the server downloads instead of content_base64; no redirects, private hosts are refused."
  2. Added

TDQS

A5/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations only signal that this is a non-read, non-destructive, non-idempotent action. The description adds substantial behavior: the 200 MB cap, plan-gated payment_required failure, validation_error for unsupported media, invalid_image for corrupted files, and the exact recovery instruction to re-encode the original bytes.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is dense but efficiently organized: purpose first, then usage routing, then exclusivity constraint, return fields, and failure modes. Every sentence conveys actionable information without redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a tool with no output schema, five parameters, and failure-prone upload behavior, the description covers invocation conditions, parameter exclusivity, return format, file size limits, plan gating, and error recovery. Nothing essential is missing for correct use.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so parameters are already documented, but the description adds meaning beyond the schema: exclusivity of content_base64 versus source_url, the requirement that videos be uploaded assets, practical MIME inference context, and the server behavior for source_url (no redirects, private hosts refused). It also documents the return fields no output schema provides.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource: 'Upload an image or video to PinBridge and get an asset_id for create_pin.' The purpose is unmistakable and distinguishes this upload step from descendant pin-creation tools.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit when-to-use conditions ('generated in this session or Pinterest cannot fetch it from a public URL'), an explicit alternative ('otherwise pass image_url to create_pin directly'), and a hard constraint ('Provide exactly one of content_base64 or source_url'). This fully routes an agent to the correct tool.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources