其他

sent-two-way-messaging

sentdm/sent-plugin

Designs inbound and conversational Sent flows — opt-out and opt-in keyword handling, consent state on contacts, auto-replies inside the WhatsApp 24-hour window, RCS STOP chips, conversation history retrieval, and per-channel inbound capability. Use when handling message.received events, implementing STOP or HELP behavior, restoring consent after an opt-out, building a support inbox or chatbot on Sent, or paginating conversation history.

  • 2736 次安装
  • 48 星标
  • 收录于

安装命令

npx skills add https://github.com/sentdm/sent-plugin --skill sent-two-way-messaging

SKILL.md

Sent Two-Way Messaging

Inbound messaging on Sent has one governing rule: consent is enforced by the platform before the application sees the event. An inbound STOP has already flipped the contact's opt_out flag by the time message.received arrives. The application's job is to record it, reflect it in its own UI, and never attempt to send around it.

Keyword handling

Ten keywords ship as defaults:

Action Keywords
Opt out STOP, CANCEL, UNSUBSCRIBE, QUIT, END
Opt in START, UNSTOP, SUBSCRIBE
Help auto-reply HELP, INFO

Matching requires the entire trimmed message body to equal a keyword, case-insensitively. "Please stop messaging me" does not match; "stop" does. Custom keywords are configured in the Sent Dashboard under Compliance, Opt Keywords, with an action of Opt Out, Opt In, or Help, and each must be a single exact token.

Do not claim keywords that are not in the documented set. In application code, mirror the same exact-match rule only to update local subscriber state and audit evidence; never use that matcher to apply consent to Sent a second time. Keep custom dashboard keywords synchronized with the local mirror, and reconcile against the contact's opt_out field when uncertain.

Consent state