Send verification
send_verificationSend a one-time verification code (OTP) to a phone number by text, or to an email address with channel "email". TextKit generates the code, handles expiry (10 min) and attempt limits (5), and blocks SMS-pumping and email-bombing abuse.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| from | No | Optional, channel `sms` only: send from a number you own instead of the TextKit pool | |
| No | The address to email the code to (channel `email`). Disposable addresses are refused. | ||
| phone | No | The number to text the code to (channel `sms`). `to` works too. | |
| channel | No | How the code goes out. `sms` needs `phone`; `email` needs `email`. | sms |
| user_ip | No | Optional. Your end user's IP address, as your server saw it. With it, one person requesting codes for many numbers or addresses is limited (20 an hour per IP on your account, texts and emails together); without it there is no per-IP limit, since requests come from your server. | |
| app_name | No | Your product name, shown in the message | |
| customer_id | No | Optional: attribute the verification to one of your customers | |
| idempotency_key | No | Optional. Retries are already safe: the same call with the same inputs within 10 minutes is done once and answers with the first result. Pass your own key to dedupe across a longer gap, or a new one to repeat an identical call on purpose. |