number.provisioned
Sent when a phone number is claimed and added to the workspace.
Sent when a phone number is claimed and added to the workspace.
number.provisioned is sent when a number is claimed into your workspace, from the console or with POST /v1/numbers/{id}/claim. The number can take calls from this point.
Subscribe by adding number.provisioned to the events of a webhook created with POST /v1/webhooks.
The body is flat JSON. The event name is in the X-Sautikit-Event-Kind header, not in the body.
{
"workspace_id": "01900000-0000-7000-8000-000000000002",
"number_id": "01900000-0000-7000-8000-000000000004",
"e164": "+254720000000",
"monthly_minor": 50000,
"currency": "KES",
"claimed_at": "2026-06-27T10:00:00.123456789Z"
}| Field | Type | Description |
|---|---|---|
workspace_id | string (UUID) | The workspace that claimed the number. |
number_id | string (UUID) | The number's id. Use it with /v1/numbers/{id}. |
e164 | string | The number in E.164 form. |
monthly_minor | integer | Monthly rental in minor units (KES cents). 50000 is KES 500.00. |
currency | string | Wallet currency, for example KES. |
claimed_at | string (RFC 3339) | When the number was claimed. |
Other fields may be present.
| Header | Description |
|---|---|
X-Sautikit-Event-Kind | number.provisioned. Route on this. |
X-Sautikit-Event-Id | UUID of the event. Deduplicate on this. |
X-Sautikit-Delivery-Id | UUID of this delivery. |
X-Sautikit-Attempt | Attempt number, starting at 1. |
X-Sautikit-Timestamp | Unix time (seconds) when the delivery was signed. |
X-Sautikit-Signature | t=<timestamp>,v1=<hex HMAC-SHA256>. See Verify webhook signatures. |
X-Sautikit-Event-Id header.// verifyWebhook is the function from the "Verify webhook signatures" guide.
import { verifyWebhook } from "./verify-webhook.js";
export async function POST(req) {
const body = await req.text();
try {
verifyWebhook(body, req.headers.get("x-sautikit-signature") ?? "", process.env.WEBHOOK_SECRET);
} catch {
return new Response("Forbidden", { status: 403 });
}
if (req.headers.get("x-sautikit-event-kind") === "number.provisioned") {
const { number_id, e164 } = JSON.parse(body);
console.log(`Number ${e164} is live (${number_id})`);
// set its routing, add it to your own records
}
return new Response("OK", { status: 200 });
}PUT /v1/numbers/{id}/routing.number.released