> ## Documentation Index
> Fetch the complete documentation index at: https://monitor-docs.solobiz.academy/llms.txt
> Use this file to discover all available pages before exploring further.

# Publishing workflow

> Create, schedule, track and cancel posts safely as an agent.

Requires an `editor` key. Tools: `create_post`, `get_post_status`, `get_post`, `cancel_post` (HTTP: `POST /posts`, `GET /posts/:id/status`, `GET /posts/:id`, `DELETE /posts/:id`).

## Steps

1. `list_channels` (or `list_groups`). Use the `id` values as `channel_ids`. Only `active` channels accept posts.
2. Build a unique `id_thirdparty` for this intended post, for example `campaign-2026-12-01-launch`. It must not start with `retry:`.
3. `create_post` with `channel_ids`, `content`, `id_thirdparty`, optional `media`, `scheduled_at`.
4. Read `data.duplicate`: `false` means created, `true` means this `id_thirdparty` already existed (nothing new was created).
5. Track with `get_post_status` every 20 seconds, at most 15 minutes, until no target is `pending` or `publishing`.

## Rules

| Rule | Why |
| - | - |
| `scheduled_at` is unix **seconds**, not milliseconds | Milliseconds fail with `invalid_scheduled_at` |
| `scheduled_at` at most 30 days ahead | Farther fails with `invalid_scheduled_at`. Omit, `null` or past time means publish now |
| `id_thirdparty` is required and stable | Retry after a timeout with the **same** value: the Hub returns `duplicate: true`, never a second post |
| Media: public `https` URLs only | The API takes no file uploads. Private or internal URLs fail with `invalid_media_url` |
| Max 10 images (Facebook, Instagram), 20 (Threads); Instagram images `.jpg`/`.jpeg` | Per-channel limits fail with `invalid_post_type` |
| Content limits: Threads 500, Instagram 2200 characters | `invalid_content` |
| Re-read `get_post` before relying on a `pending` post | Humans can edit content or time on the web up to 2 minutes before publish. Check `updated_by` |

## Target statuses

`pending`, `publishing`, `published`, `failed`, `unverified`, `cancelled`.

| Status | Do |
| - | - |
| `published` | Done. `permalink` has the link |
| `failed` | Read `error` (`kind`, `code`, `message`). Tell the human. Do not blindly create a new post: that would use a new `id_thirdparty` and may double-post |
| `unverified` | Outcome unknown. Do not resend. Ask a human to check the platform |
| `cancelled` | Cancelled before publish |

## Cancel

`cancel_post` with the post `id`. Only `pending` targets change to `cancelled`. Targets already `published`, `failed` or `unverified` are untouched. A `publishing` target is flagged and may still finish.

## Confirm before

* Publishing to many channels at once.
* Scheduling more than a handful of posts in one run.
* Any post a human did not approve.

Field details and every error code: [API reference](https://monitor-docs.solobiz.academy/api-reference/introduction.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.