Developers

Sauti API

Programmatic access to calls, messages, agents, and campaigns. RESTful endpoints, webhook events, full control.

Base URL: https://sauti.shylock.ai/apiGet your API key →

Authentication

All requests require an API key passed in the Authorization header. Generate keys in your Shylock dashboard under Settings.

Authorization: Bearer sk_live_your_api_key

Endpoints

POST/v1/calls

Initiate an outbound call

Request body

{
  "assistantId": "asst_jane_collections",
  "phoneNumberId": "pn_jakarta_01",
  "customer": {
    "number": "+62812345678",
    "name": "Rina Wijaya"
  }
}

Response

{
  "id": "call_8f3k2j",
  "status": "ringing",
  "assistant": "asst_jane_collections",
  "from": "+62215551234",
  "to": "+62812345678",
  "created_at": "2026-04-02T10:30:00Z"
}
POST/v1/messages

Send a message via WhatsApp, SMS, or email

Request body

{
  "channel": "whatsapp",
  "to": "+62812345678",
  "content": {
    "text": "Hi Rina, this is a reminder about your upcoming payment on the 5th."
  },
  "assistantId": "asst_jane_collections"
}

Response

{
  "id": "msg_a9x2kp",
  "channel": "whatsapp",
  "status": "sent",
  "to": "+62812345678",
  "created_at": "2026-04-02T10:31:00Z"
}
POST/v1/assistants

Create a new AI assistant

Request body

{
  "name": "Jane",
  "language": "id",
  "personality": {
    "system_prompt": "You are Jane, a collections agent for Juniper Bank. You speak Indonesian. You are professional, empathetic, and solution-oriented."
  },
  "voice": {
    "provider": "elevenlabs",
    "voice_id": "sari_indonesian"
  },
  "model": {
    "provider": "openai",
    "model": "gpt-4o"
  }
}

Response

{
  "id": "asst_jane_collections",
  "name": "Jane",
  "status": "active",
  "language": "id",
  "created_at": "2026-04-02T10:00:00Z"
}
GET/v1/calls/:id

Get call details including transcript and recording

Response

{
  "id": "call_8f3k2j",
  "status": "completed",
  "duration": 142,
  "outcome": "promise_to_pay",
  "transcript": [
    { "role": "agent", "text": "Hi Rina, this is Jane from Juniper Bank..." },
    { "role": "customer", "text": "Yes, I can pay on the 5th." }
  ],
  "recording_url": "https://sauti.shylock.ai/recordings/call_8f3k2j.mp3",
  "created_at": "2026-04-02T10:30:00Z",
  "ended_at": "2026-04-02T10:32:22Z"
}

Real-time events

Webhooks

Register a webhook URL in your dashboard. We'll POST events to your endpoint as they happen.

call.completed

Fired when a call ends. Includes transcript, duration, outcome.

call.failed

Fired when a call fails to connect. Includes error reason.

message.delivered

Fired when a WhatsApp/SMS/email is delivered.

message.replied

Fired when the customer replies to a message.

payment.promised

Fired when a customer promises to pay during a call.

Ready to integrate?

Sign up, grab your API key, and start building.

Get started →