Schedule mailing
cyberimpact_create_mailingWRITE, SENDS EMAIL TO CUSTOMERS: create a mailing scheduled to be sent at send_at to every member of the chosen groups. It goes out for real unless it is cancelled in the Cyberimpact app before send_at. Only call it after the user has approved the subject, body, sender and groups, and set confirm_send to true. mail_from must be a validated sender address of the account. A mailing cannot be deleted through this server. POST /mailings.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| send_at | Yes | When to start sending, 'yyyy-mm-dd HH:mm:ss'. Cyberimpact reports dates in Eastern time (EST/EDT). | |
| subject | Yes | Email subject. | |
| bodyHtml | No | HTML body. At least one of bodyHtml or bodyText is required. | |
| bodyText | No | Plain-text body. At least one of bodyHtml or bodyText is required. | |
| language | Yes | en_ca or fr_ca. | |
| reply_to | No | Reply-to address. | |
| from_name | No | From name. | |
| group_ids | Yes | Groups whose members receive the mailing (see cyberimpact_list_groups; check member counts first). | |
| mail_from | No | From address; must be a validated sender in the account. | |
| statistics | No | detailed (default) or anonymized open/click statistics. | |
| confirm_send | Yes | Must be true: the user explicitly approved sending this mailing to these groups. |