Header Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X POST "https://example.com/v1/sms" \ -H "Content-Type: application/json" \ -d '{ "recipient_consent": true, "to": "string", "body": "string" }'{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "organization_id": "7c60d51f-b44e-4682-87d6-449835ea4de6", "from_e164": "string", "to_e164": "string", "direction": "outbound", "status": "queued", "body": "string", "provider_message_sid": "string", "segment_count": 0, "error_code": "string", "requested_at": "2019-08-24T14:15:22Z", "sent_at": "2019-08-24T14:15:22Z"}Create Email
Send an outbound email through SES. Sends synchronously — the response reports the final status (sent or failed), not a queued placeholder; no separate poll is needed for the happy path, though a bounce or complaint can still arrive later as a webhook or GET /v1/emails/{email_id}/events entry. Requires recipient_consent=true on the request body; Hail does not verify lawful basis to contact the recipient, the caller warrants it.
Create Subscription
Create a webhook subscription for one or more event types. The response includes the plaintext signing secret — this is the only time it is ever returned; store it now. Every later GET omits it. Use POST /v1/webhooks/{sub_id}/rotate-secret to get a new plaintext secret if it is lost or compromised.