Send a text

send_site_message

Sends one text from a site to one phone number with one of its templates.

In test mode Sent only checks the text: nothing goes out and nothing is charged. Otherwise it is a real text that reaches a real person, it is charged in credits to the workspace, and its template must be approved. It is refused while texting is off, to a country the site may not text, to a number that is blocked or replied STOP, and past 30 texts a minute, 5 texts to one number a day or 20 credits a day on a paid plan. Pass an idempotencyKey so that sending again sends nothing new. The tool tells the client to send only a text you asked for, to a number you gave, and to check both with you first. See Send a text.

Inputs

Input Type Required Description
projectId string Yes The site id.
template string Yes The template key, from list_site_message_templates.
to string Yes The phone number in international format, such as +14155551234.
variables object No The value of each placeholder, keyed by its name. site is filled with the site's name on its own.
channel string No sms, the default, whatsapp, or sent to let Sent choose.
idempotencyKey string No Any unique string for this text. Sending again with the same key sends nothing new.