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/webhooks" \ -H "Content-Type: application/json" \ -d '{ "target_url": "string", "event_types": [ "email.received" ] }'{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "organization_id": "7c60d51f-b44e-4682-87d6-449835ea4de6", "target_url": "string", "event_types": [ "string" ], "status": "active", "consecutive_failures": 0, "last_success_at": "2019-08-24T14:15:22Z", "last_failure_at": "2019-08-24T14:15:22Z", "created_at": "2019-08-24T14:15:22Z", "updated_at": "2019-08-24T14:15:22Z", "secret": "string"}Create Sms
Send an outbound SMS. Sends synchronously — the response reports the final status (sent or failed), not a queued placeholder, though delivery confirmation from the carrier can still arrive later as a webhook or GET /v1/sms/{sms_id} update. An explicit from resolves a dedicated number; otherwise Hail picks an alphanumeric sender ID where the destination corridor allows it, or requires a dedicated SMS-capable number otherwise. Requires recipient_consent=true on the request body; Hail does not verify lawful basis to contact the recipient, the caller warrants it.
Create Verification
Submit your details and documents (multipart/form-data). Parts: `purpose` (`number`, the default, or `sms` to register to send SMS in the US; `sms` takes `country_code=US` and `number_type=local` and charges the filing fee), `country_code`, `number_type`, `subject_type`, `provider` (optional; for `sms` it defaults to the carrier of your US numbers), `fields` (JSON object), `address` (JSON object, when required), `documents` (JSON object: slot name to `{"option": ..., "fields": {...}}`), and one file part per slot named `file.<slot>`. Get the slot and field names from `GET /verifications/requirements`. The carrier checks the details right away. Problems come back as 422 with the field named, and nothing is kept. When it passes, the verification is submitted to the carrier for its review; read it back to follow the state.