Documentation menu

Documentation

SautiPBX API

SautiPBX turns phone calls into something you control with code. Acquire numbers, place and receive calls, and drive them with simple XML verbs — over one REST API, billed per second in Kenyan Shillings.

How it works

Two ideas run through the whole platform:

  • The REST API is how you talk to us — place a call, buy a number, read call records, check your balance. You authenticate with a secret API key.
  • Voice webhooks are how we talk to you. When a call needs instructions, we POST the call's details to your URL and you reply with a <Response> document of verbs telling us what to do.

Everything a call does — ring, answer, complete — is also pushed to you live over a WebSocket, and stored on a call record you can query later.

Base URL

All REST endpoints live under a single base URL:

https://sauti-pbx.services.co.ke/api

Requests and responses are JSON. Send your API key as a bearer token on every request — see Authentication.

Start here

Conventions

  • Every resource has a stable uuid. Calls also carry a human-friendly sid (e.g. call_...).
  • Money is in KES as a decimal string, never cents.
  • Timestamps are ISO-8601 in UTC.
  • Write requests that place calls or spend money accept an Idempotency-Key header so retries are safe.