Try It In The Dashboard
Automations are already live in the bundle.social dashboard under Automations (bundle.social/dashboard/general/automations), so you can see how everything works before writing a line of code.- Use it as a flow builder. Click a flow together, and the API definition panel next to it shows the exact
definitionJSON this API expects, with the real IDs from your team. Copy it into yourPOST /api/v1/automationsorPATCHcall and you’re done. - Watch it run. The execution logs show every run and what each step did, the same data as Testing & Execution Logs.
- Ice breakers and the persistent menu can be set up there too.
- It’s the same data either way: flows created through the API show up in the dashboard, and the other way around.
In This Section
Building Flows
Triggers, keywords, delays, conditions and message formats.
Managing Flows
Create, publish, pause, archive, delete and copy flows.
How Flows Behave
What happens in practice, and the built-in safety limits. Read before you build.
Testing & Execution Logs
Test a flow and see why every run did what it did.
Ice Breakers & Persistent Menu
Instagram ice breakers, Messenger menu and Get Started button.
Automation Webhooks
comment.received and the other events your webhook starts getting.Recipes
Copy-paste flows for the most common use cases.
Direct Messages
The inbox API automations are built on.
All Endpoints
All endpoints use your API key in thex-api-key header, same as the rest of the API.
Which Tool Do I Need?
Not everything is an automation. Pick the right tool first:
All of them work on the same comments and conversations. A comment your flow answered can still be moderated by hand, and a conversation started by an automation shows up in the DM inbox.
Supported Platforms
TikTok has no DM automations. TikTok flows work on comments and nothing else.
Plans And Limits
Automations are a paid-plan feature. Each connected account has a monthly budget of automation runs:- One run = one flow reacting to one comment or message, no matter how many steps it has.
- Runs that stop at a condition, get skipped by a safety limit (see Safety Limits), or get canceled don’t count.
- Runs that fail do count, and so do test runs, since they really send messages.
- DMs sent by automations also count toward the account’s monthly message quota.
- When the budget runs out, new runs are recorded as
SKIPPEDwith the codeAUTOMATION_MONTHLY_LIMIT_REACHED. Quotas reset on the 1st of every month (UTC).
Before You Start
Once your organization is on the allowlist:- Reconnect your Facebook and Instagram accounts with
withMessagingScope: true. This covers accounts that were already connected before the switch. Until they are reconnected they have no messaging permissions, and we don’t receive their new comments either, so no flow on them can ever fire. - Subscribe each account to messages with
POST /api/v1/social-account/messaging/enable. This registers it for Meta’s message webhooks. It’s needed for any flow that reacts to DMs or button taps, or sends DMs or private replies. A flow that only replies publicly or likes comments works without it. Both steps are two API calls, see Direct Messages → Setup. - TikTok accounts need comment management permissions. A regular TikTok connection has them. If publishing a flow complains about permissions, reconnect the account. Also give every TikTok flow a 5-10 second delay.
- Comment flows only work on posts published through bundle.social on that account. You point the flow at one with
postId. - Your webhook endpoint accepts the new events (see Webhooks).
Instagram account must be reconnected with messaging permissions.
Where The IDs Come From
How It Works
A flow is one trigger plus up to 100 steps:- Trigger. An event arrives: a new comment, a new DM, or a tap on a button or quick reply. We look for published, active flows whose trigger matches it.
- Run. Each matching flow gets its own execution (a run). If the trigger has a delay, the run waits for it.
- Steps. Steps run top to bottom. A
CONDITIONstep that doesn’t match stops the run right there. - Log. Every run and every step is recorded, with inputs, outputs and errors. That’s your debugging tool, see Executions.
Drafts And Publishing
Flows are versioned, so you can edit safely while the old version keeps running. Changes are saved as a draft, and nothing you edit goes live until you publish it. Details in Managing Flows.Capabilities By Platform
Triggers
Steps
Which Steps Fit Which Trigger
Some combinations make no sense (or Meta forbids them), so publishing rejects them:SEND_PRIVATE_REPLY,SEND_PUBLIC_COMMENT_REPLYandLIKE_COMMENTneed aCOMMENT_CREATEDtrigger. There’s no comment to reply to otherwise.SEND_MESSAGEneeds aDM_RECEIVED,QUICK_REPLY_CLICKEDorBUTTON_CLICKEDtrigger. To DM a commenter, useSEND_PRIVATE_REPLY. Meta doesn’t allow any other message until they answer it.ARCHIVE_CONVERSATION/OPEN_CONVERSATIONneed a DM or click trigger, or aSEND_PRIVATE_REPLYearlier in the flow (that’s what creates the conversation).- Every flow needs at least one step that actually does something (not only conditions).
Quick FAQ
”My flow is ACTIVE but nothing happens.”
Check in this order:- Was the account reconnected after your organization was allowlisted? Accounts connected earlier don’t send us comments or DMs. See Before You Start.
- Is it a comment flow? The post in
postIdmust be published through bundle.social on the same account. - Did you edit it after publishing? Edits are drafts until you publish again.
- Do the keywords really match? They match whole words:
"link"won’t match “links”. - Look at the executions. If runs are there as
SKIPPED,error.codetells you why. No error means a condition stopped the run,output.skippedAtStepIdsays which one. - No executions at all for a DM flow? Make sure the account is subscribed with
messaging/enable(Direct Messages → Setup). - Still no executions? While automations are paused on our side (for example during a platform incident), incoming events don’t create runs at all, so nothing shows up in the logs.
”Can one comment or message trigger several flows?”
Yes, every matching flow runs (up to 25), and each one sends its own reply. If that’s not what you want, make the keywords not overlap.”Why did someone get two replies to one message?”
Two flows matched the same message, usually a catch-all flow plus a keyword flow. See DM Flows.”Why did my automation ignore someone’s second message?”
The loop brake: in DMs, one automated answer per person per 60 seconds, 6 per hour. The skipped run is in the executions withAUTOMATION_CONVERSATION_COOLDOWN. Use quick replies or buttons for back-and-forth conversations, since taps skip this brake.
”My TikTok flow sometimes fails on the reply or like step.”
Most likely TikTok wasn’t ready for the comment yet when the step ran. SetactionDelaySeconds to 5-10 on the flow and publish again. See Delays.
”Can one flow cover all my posts?”
No. A comment flow always points at one post. Create one per post, ideally when you schedule it.”Can I stop automations for one conversation when a human takes over?”
Not per conversation. Pausing a flow stops it for everyone. Build your flows around keywords and buttons so they only answer what they’re meant to.”How do I reply to a comment by hand?”
With the Comments API, or with a private reply if you want to answer in DMs. See Which Tool Do I Need?.”Can I DM everyone who commented, not just reply?”
That’s exactly whatSEND_PRIVATE_REPLY is. One private reply per comment, text only, within 7 days of the comment. Those are Meta’s rules, not ours.