Skip to content

update_post

Patches an existing post. Only the fields you send are changed — everything omitted keeps its current value. Supplying targetAccounts replaces the target list outright rather than adding to it.

Access
write
Category
Publishing
Endpoint
POST/api/tools/update_post
On this page
  1. Parameters
  2. Example request
  3. Response

Parameters

id
stringrequired
ObjectId of the post to update.
content
string
Replacement text body.
targetAccounts
array<object>
Replacement profile list. The post is re-pointed at exactly these profiles.
platform
enumrequired
linkedin · twitter · facebook · instagram · threads · bluesky · youtube
profileId
string
Id returned by get_connected_accounts.
username
string
Handle, carried through for readability.
platforms
array<enum>
Replacement network list; each network expands to all of its connected profiles.
scheduleDate
string
YYYY-MM-DD.
scheduleTime
string
HH:MM, 24-hour.
timezone
string
IANA zone for the schedule above.default: UTC
mediaUrl
string
Replacement single attachment. Replaces the whole set with this one file.
mediaUrls
array<string>
Replacement attachment set — add, remove or reorder carousel slides. An empty array removes all media.
youtube
object
Replacement upload details for a post going to a YouTube channel: title (≤100), description (≤5000) and privacyStatus (public · unlisted · private). Fields you omit keep their current value.
status
enum
scheduled · draft · failed — use draft to pull a post out of the queue without deleting it.
workspaceId
string
Workspace to act on, from list_workspaces. Omit to use the default workspace on the key.

Example request

curl -X POST "https://api.postmcpai.com/api/tools/update_post" \
  -H "Content-Type: application/json" \
  -H "x-api-key: $POSTMCPAI_API_KEY" \
  -d '{
    "id": "66a50c89e4b019a2b72f",
    "content": "Updated announcement with the launch link included. 🌟",
    "scheduleTime": "11:30",
    "timezone": "Asia/Kolkata"
  }'

Response

The post as it stands after the patch.

200 · application/json
{
  "success": true,
  "message": "Post updated successfully",
  "post": {
    "id": "66a50c89e4b019a2b72f",
    "content": "Updated announcement with the launch link included. 🌟",
    "scheduleDate": "2026-08-02",
    "scheduleTime": "11:30",
    "status": "scheduled"
  }
}