send_sms
Sends a transactional SMS via the OpenCDP Gateway.
Usage
from cdp_client.models import SmsPayload
await client.send_sms(payload: SmsPayload)
SmsPayload
| Field | Type | Description |
|---|---|---|
to | str | Recipient phone number (E.164 format). |
identifiers | Identifiers | User identifiers for tracking. |
body | str | The SMS message content. |
transactional_message_id | str | Optional: Template reference. |
Example
from cdp_client.models import SmsPayload, Identifiers
payload = SmsPayload(
to="+1234567890",
identifiers=Identifiers(id="u_001"),
body="Your verification code is 123456."
)
await client.send_sms(payload)