create_automation
Automatically send an approved template to every NEW contact with a tag, e.g. a welcome message whenever a lead tagged "new-lead" is added (by add_or_update_contact, import_contacts, the REST API, or a Zapier/Make integration calling it). Only contacts created AFTER the automation qualify, each at most once: re-importing or tagging existing contacts never triggers it. To message existing contacts, use a broadcast; the response's existing_tagged_contacts says how many already have the tag. Only add contacts who agreed to receive WhatsApp messages. The template must be APPROVED with every {{n}} placeholder mapped (set_template_variables). One automation per tag. delay_minutes (0 to 10080) waits before sending. Returns the automation with live stats and any warnings (e.g. no WhatsApp number connected) that would make sends fail.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Defaults to "Welcome: <tag>" | |
| template_id | Yes | APPROVED template to send | |
| trigger_tag | Yes | Contacts gaining this tag get the message | |
| delay_minutes | No | Minutes to wait before sending, default 0 |