Postato Docs
MCP ToolsTools

Delete Media

Delete an uploaded media file from storage. Removes the file from CDN and marks it as expired. Cannot delete media that is attached to a published post.

delete_media

Delete an uploaded media file from storage. Removes the file from CDN and marks it as expired. Cannot delete media that is attached to a published post.

Parameters

ParameterTypeRequiredDescription
mediaIdstringyesThe media ID to delete.
workspaceIdstringnoWorkspace ID. Required if your API key accesses multiple workspaces.

When to use

Remove a media asset from a workspace. Soft-deletes the record and prevents future posts from attaching it. Already-published posts referencing the media are unaffected — the live content on the target network keeps its own copy.

Example

{
  "workspaceId": "wks_01H...",
  "mediaId": "med_01H..."
}

Response: { "success": true } or 404 if not found.

Gotchas

  • Deleted media cannot be reattached to new posts. If you need the asset back, re-upload.
  • Scheduled or draft posts that reference the deleted media will fail at delivery time with a media_not_found error. If you're sweeping unused media, cross-check against pending posts first via list_posts + a filter on status.
  • Deletion does not free the idempotencyKey of posts that used it.

On this page