Switch on a background agent
POST/:workspaceUuid/agents
Creates an agent (one per type per workspace). It first runs within five minutes, then on its
schedule. Pre-publish checker looks at posts scheduled in the next horizon_hours and
proposes holding (back to draft) posts that would fail: disconnected accounts, network
requirements, daily caps, the X allowance and links that answer an error. It proposes caption
edits that drop banned_phrases. With ai_review: true it also asks AI to review up to
max_ai_reviews_per_run posts per run (one AI credit each). Failed-post fixer looks at
posts that failed on an account in the last lookback_hours and proposes, per post and
account, reconnect_account (the account's token expired), or retry_account, with a
caption trimmed to the network limit when the text is over it. One open proposal per post
and account. It uses no AI. Admins and members only.
Request
Responses
- 201
- 401
- 403
- 422
Agent created
Missing or invalid API token.
Access denied. Returned when the caller is not a member of the workspace, lacks the role
the endpoint needs, or the workspace's plan does not include API access (capability api).
Validation failed.