API reference
Posts API
One request can post to many channels. Each channel gets its own copy, so you can change the text per network.
https://app.brokenpost.com/api/public/v1Create or schedule a post
/postsSchedule, publish now or save a draft.
Request body
{
"type": "schedule",
"date": "2026-12-01T09:00:00.000Z",
"shortLink": false,
"tags": [],
"posts": [
{
"integration": { "id": "cm4a1b2c3d4e5f6g7h8i9j0k" },
"value": [
{
"content": "Our winter menu is here ☕",
"image": [
{ "id": "f0e1d2c3", "path": "https://media.brokenpost.com/winter.jpg" }
]
}
],
"settings": { "__type": "instagram", "post_type": "post" }
}
]
}Response
[ { "postId": "cm4post0001", "integration": "cm4a1b2c3d4e5f6g7h8i9j0k" } ]The request body
| Field | Type | What it does |
|---|---|---|
type | "schedule" | "now" | "draft" | "update" | Schedule for date, publish right away, keep as a draft, or update a post you created before (see Update a post). |
date | ISO 8601 | When it goes out. Used for every channel in the request. |
shortLink | boolean | Shorten links in the text. |
tags | { value, label }[] | Labels you see in the calendar. Send [] for none. |
inter | number, optional | Repeat the post every N days (1 to 365). |
needsApproval | boolean, optional | With type "draft": wait for a teammate or client to approve it. |
republish | boolean, optional | Publish a post that already went out again. Without it, scheduling a published post is refused. |
posts[].integration.id | string | The channel id from /integrations. |
posts[].value | array | The post and its thread or comments, in order. Each item has content (HTML or plain text), image (media from /upload) and, when updating, the id of the post it replaces. |
posts[].settings | object | Network options. __type is the network identifier; the rest comes from /integration-settings/:id. |
posts[].group | string, optional | Posts with the same group are edited and deleted together. |
Threads and first comments
Add more items to value. On X and Threads they become a thread; on Instagram, LinkedIn and Facebook they become comments under your post. delay (minutes) waits before each one.
"value": [
{ "content": "Thread time 🧵", "image": [] },
{ "content": "Part two", "image": [], "delay": 1 }
]Update a post
Send the same body with type: "update", the post’s group, and the id of each post in its value item. Get both from GET /posts.
Without an id, the item is saved as a new post next to the old one.
Each save gives the post a new group. To delete it afterwards, use DELETE /posts/:id, or read the new group from GET /posts.
"type": "update",
"posts": [
{
"integration": { "id": "cm4a1b2c3d4e5f6g7h8i9j0k" },
"group": "d1fecfeb-33e4-4e09-b580-04ac945b4b0b",
"value": [{ "id": "cm4post0001", "content": "Our winter menu is here (updated)", "image": [] }],
"settings": { "__type": "instagram", "post_type": "post" }
}
]Read and change posts
/postsPosts between two dates.
startDatequery, ISO 8601 | Start of the range. |
|---|---|
endDatequery, ISO 8601 | End of the range. |
customerquery, optional | Only the posts of one brand. |
/posts/:id/statusMove a post between draft and scheduled.
Request body
{ "status": "schedule" }/posts/:id/settingsChange a post’s network settings.
Request body
{ "settings": { "__type": "youtube", "title": "Winter menu", "type": "public" } }/posts/:id/missingWhat a post still needs before it can go out, for example a missing video for TikTok.
/posts/:id/release-idGive a published post the id it got on the network, when we could not read it. Only works on posts with releaseId: "missing"; others get a 400.
Request body
{ "releaseId": "17912345678901234" }/posts/:idDelete a post and every copy in its group.
/posts/group/:groupDelete a whole group at once.
Validation
Posts are checked with the same rules as the app. When something is wrong you get a 400 that names the channel and the problem, for example a post that is too long for X or an Instagram post with no image.
{
"statusCode": 400,
"provider": "x",
"name": "Mango Café",
"error": "post is too long, please fix it"
}