Create an auto-reply
create_auto_replyAdds a rule that answers comments or direct messages automatically, on the person's behalf, from now on (never older comments). trigger COMMENT: when someone comments (optionally only with one of keywords, whole words, any case; only on post_ids; only on channel_ids), post one of public_replies (picked at random) under the comment and/or send message (+ link_url as a tracked short link) privately to the commenter, once per comment within 7 days. trigger MESSAGE: when someone sends a direct message (optionally with a keyword), answer with message within 24 hours. once_per_person (default true) answers each person once per rule per 30 days. At most 120 replies per account per hour. followers_only (COMMENT, Instagram): "comment a word, follow, get the link": the private reply asks them to follow and tap follow_button; the tap lets Shager check with Instagram, and only followers get message + link_url. attachment_media_id (Instagram, Facebook): also send a file privately (a guide, a price list, a coupon image); on comments it goes out after they tap follow_button, since the first private reply can only be text. It is saved paused (enabled=false) unless you pass enabled=true. An enabled rule answers real people with no one checking each answer, so enabled=true first needs your human's OK: the call answers needs_confirmation with confirm_url, where they read every text; after they approve, make the same call again. (Not available in an unclaimed sandbox.)
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>",
"name": "<name>",
"trigger": "<trigger>"
},
"name": "create_auto_reply"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | A short name the person will recognize, e.g. "Link in DM" | |
| enabled | No | false (the default): the rule is saved paused. true: it starts answering real people, so it first needs your human's OK in Shager (needs_confirmation with confirm_url, then the same call again) | |
| message | No | The private message (to the commenter, or the answer to a direct message) | |
| trigger | Yes | COMMENT: someone comments on a post. MESSAGE: someone sends a direct message | |
| keywords | No | Whole words or phrases, any case; empty = every comment or message | |
| link_url | No | Added at the end of the private message as a tracked short link | |
| post_ids | No | COMMENT only: only comments on these Shager posts; empty = every post | |
| channel_ids | No | Only these accounts; empty = every account that supports the trigger | |
| workspace_id | Yes | Workspace id from list_workspaces | |
| follow_button | No | followers_only: the button's text, up to 20 characters, e.g. "I'm following" (required with followers_only) | |
| follow_prompt | No | followers_only: the private reply asking them to follow and tap the button (required with followers_only) | |
| followers_only | No | COMMENT only, Instagram only: the private reply is `follow_prompt` with a `follow_button`; when the person taps it, Shager asks Instagram whether they follow and sends `message` + `link_url` only to followers (others get `follow_reminder` with the button, up to 5 times). Accounts without follower_check in list_auto_replies skip these comments | |
| public_replies | No | COMMENT only: public answers under the comment, one picked at random | |
| follow_reminder | No | followers_only: sent with the button again when they tap it without following yet; empty = follow_prompt again | |
| idempotency_key | No | Any unique string you choose (REST: the Idempotency-Key header works too). Retrying with the same key and body returns the first result instead of creating a second one. Kept 24 hours. | |
| once_per_person | No | Answer each person once per rule (30 days) | |
| confirmation_token | No | The confirmation_token from needs_confirmation. The call goes through only after your human approved this exact action at confirm_url. | |
| attachment_media_id | No | Instagram and Facebook: a file sent privately after `message`: an image (up to 8 MB), a video or a PDF (up to 25 MB) from this workspace's media (create_media_upload or upload_media_from_url first). On COMMENT rules the networks allow only text in the first private reply, so the private reply is `follow_prompt` with a `follow_button` and the file goes out when they tap it (with followers_only, only to followers). Accounts without `files` in list_auto_replies send the message without it |