Skip to main content
Glama

Replace post media

replace_post_media
Destructive

Replaces the video or image behind a not-yet-published post (draft, ready, scheduled or failed) with another upload from the same workspace, like the dashboard's "Replace media". The post keeps its schedule, captions, first comments and platform settings; only the media file changes. Set apply_to_batch: true to also swap every other post in the same batch (same media, same status and, for scheduled posts, the same scheduled time), which is what you want when one upload was scheduled to several platforms at once. Upload the new file first with create_video_upload_from_url or create_video_upload + finalize_video_upload, then pass its id here. Refuses text posts, carousels, and posts that are queued, processing or published. Platform compatibility of the new file is not re-checked, so pick media that suits every platform in the batch.

Input Schema

NameRequiredDescriptionDefault
video_post_idYesThe video_posts.id whose media you want to replace. Get it from list_scheduled_posts or create_post_draft.
apply_to_batchNoAlso swap the other posts in this post's batch (same media, same status, same scheduled time). Default false: only this post is changed.
idempotency_keyNoOptional client-generated key (e.g., a UUID) to make retries safe. Identical calls with the same key within 10 minutes return the original result instead of running the write twice.
new_video_upload_idYesThe video_uploads.id of the replacement video or image (from list_video_uploads or finalize_video_upload). Must be in the same workspace as the post; text posts and carousels can't be swapped in.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A5/5.0
Behavior5/5

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

Annotations already flag destructiveHint=true, but the description adds the crucial nuance of what is preserved (schedule, captions, first comments, platform settings) versus what actually changes (only the media file), which tempers the destructive flag. It also discloses the meaningful risk that platform compatibility of the new file is not re-checked.

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?

Four sentences, front-loaded with what changes and what is preserved, then prerequisites, then the batch flag, then the compatibility caveat. No sentence is redundant; the density is justified by genuinely distinct information.

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 destructive mutation with no output schema, the description covers permitted states, refusal cases, preserved fields, prerequisite tooling, batch scope, idempotency (via schema), and the compatibility caveat. Nothing an agent needs to invoke it safely is missing.

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 a baseline of 3 applies, but the description goes further by explaining the batch semantics that the schema only summarizes: batch means same media, same status, and for scheduled posts the same scheduled time. It also reinforces where each id comes from and the same-workspace constraint.

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 ("Replaces the video or image behind a not-yet-published post") and scopes it to four statuses, immediately separating it from update_post or delete-style siblings. The dashboard analogue ("Replace media") gives an agent a precise mental model.

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?

Names the required prerequisite chain (create_video_upload_from_url or create_video_upload + finalize_video_upload) before calling, and enumerates the exclusions: text posts, carousels, and queued/processing/published posts. It also gives a decision rule for apply_to_batch ("what you want when one upload was scheduled to several platforms at once").

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.