preview_automation
Dry-run: which automations would fire if someone sent this comment or DM, and what they would send. Nothing is sent and nothing is recorded.
source is "comment" (a comment on a post — pass media_id, the Instagram
media id of that post, from get_reel_analytics/list_scheduled_posts's
ig_media_id or resolve_reel_by_link), "dm" (a direct message), or
"story_reply" (a reply to a story — pass media_id as the story's id, from
list_live_stories). text is what the person wrote.
Use it to check a keyword before telling the user "that will work", to see
why a particular comment got no DM (each automation that would not fire is
listed with the reason), and to catch two automations that would both try to
DM the same comment — Instagram allows ONE private reply per comment, so
warnings says so.
It applies the same keyword rule the live engine does. It does not check the
plan's limits, the commenter's 24-hour messaging window, or an ai_dm
automation's inquiry filter and monthly allowance, so "would fire" means
"matches", not "is guaranteed to deliver". Without media_id, an automation
scoped to specific posts is listed as post_not_given rather than guessed.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"workspace_id": "<workspace_id>",
"ig_account_id": "<ig_account_id>",
"source": "<source>",
"text": "<text>"
},
"name": "preview_automation"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | Yes | ||
| source | Yes | ||
| media_id | No | ||
| workspace_id | Yes | ||
| ig_account_id | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | Yes | ||
| source | Yes | ||
| media_id | No | ||
| warnings | No | ||
| would_fire | Yes | ||
| would_not_fire | Yes |