OnCallClerk Logo

I  ·  Developer platform

Launch a live AI phone agent in sixty seconds.

Get a phone number, answer calls, and handle customers, all via API or SDK. Type the code, hit launch, then call the agent below.

create-agent.ts
Writing
1 
0 / 404 chars

II  ·  Quick start

Up and running in under five minutes.

Install, authenticate, create, provision, call.

01

Install

Install the SDK

Add the OnCallClerk SDK via your package manager.

npm install @oncallclerk/sdk
02

Authenticate

Authenticate

Grab an API key from your dashboard and initialise the client.

import OnCallClerk from '@oncallclerk/sdk'

const client = new OnCallClerk({
  apiKey: process.env.OCC_API_KEY,
})
03

Create

Create a voice agent

Configure and deploy an agent with a single call.

const agent = await client.agents.create({
  business_name: 'Acme Corp',
  voice_id: 'f5HLTX707KIM4SzJYzSz',
  greeting: 'Hello, thanks for calling Acme Corp!',
  system_prompt: 'You are a helpful receptionist for Acme Corp...',
})
04

Provision

Assign a phone number

Provision a number and attach it to the agent.

const number = await client.phoneNumbers.create({
  agent_id: agent.id,
  country: 'US',
})

console.log(number.phone_number)  // '+14155550123'
05

Live

Call the agent

Dial the assigned number, or test it from the dashboard. That's it. Your agent is live.

III  ·  Authentication

Bearer token, on every request.

All API requests require authentication via a bearer token in the Authorization header. Generate keys from your dashboard.

curl https://api.oncallclerk.com/agents \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json"

Keep your key secret

Never expose your API key in client-side code or public repositories. Use environment variables.

IV  ·  Explore the docs

Everything you need to build.

REST

API reference

Complete REST documentation with endpoints, request and response schemas, and authentication. Covers agents, phone numbers, transcripts, and voices.

Read the API reference

TypeScript

SDK reference

Typed methods for every API operation. Install via npm, initialise with your key, and build with full IntelliSense support.

Read the SDK reference

Examples

Code examples

Ready-to-use templates for common patterns: IVR flows, lead capture bots, appointment schedulers, and multi-agent setups.

Coming soon

Webhooks

Real-time events

Receive notifications for call events, transcript completions, and agent status changes via webhooks you configure.

Coming soon

V  ·  Reference

Endpoints and rate limits.

Base URL

All API requests are made to:

https://api.oncallclerk.com

Rate limits

Starter60 requests / min
Professional300 requests / min
EnterpriseCustom

VI  ·  Pricing

Pay for what works.

All plans include a 14-day free trial. You only pay for calls we actually answer.

Calculate your savings

Start building now.

Create your free account, grab an API key, and deploy your first voice agent in under five minutes.