Make an API key
In the console, under Settings, API keys. Give it only the scopes it needs, such as agents:write and web_calls:create. It is shown whole only once.
[ Developers ]
A REST API with keys and scopes, a small web SDK, signed webhooks, and three ways for an agent to reach your own systems in the middle of a call.
[ Quickstart ]
In the console, under Settings, API keys. Give it only the scopes it needs, such as agents:write and web_calls:create. It is shown whole only once.
POST /v1/agents with a name and a prompt in your own words. The agent is live at once, and shows in the dashboard with an API tag.
Your server asks POST /v1/web-calls for a single-use token. Your page passes it to startCall(), and the visitor is talking.
curl https://api.your-jeevan-domain.in/v1/agents \
-H "Authorization: Bearer $JEEVAN_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: admissions-helpline-1" \
-d '{
"name": "Admissions helpline",
"prompt": "You answer parents' questions about batches and fees.",
"signature": "hindi-standard",
"voice": "Riya",
"start_language": "hi"
}'
import { startCall } from "@jeevan-ai/web-call";
// Your server mints a single-use token with POST /v1/web-calls
const token = await fetch("/token", { method: "POST" }).then((r) => r.json());
const call = await startCall({
accessToken: token.access_token,
signalingUrl: token.signaling_url,
iceServersUrl: token.ice_servers_url,
onStatus: (state) => console.log(state), // "connecting", "connected", "ended"
});
// later
call.end();
// POST to your endpoint, signed with the Standard Webhooks headers
{
"id": "evt_8f3aXk2LmQ",
"type": "call.billed",
"created_at": "2026-10-20T11:42:07Z",
"data": {
"call_id": "call_K7q2xN4vLp",
"agent_name": "Admissions helpline",
"billed_seconds": 61,
"amount_paise": 153,
"currency": "INR"
}
}
Single-use web-call tokens, bound to your website. Your API key never reaches the page.
[ REST ]
JSON over HTTPS. Send your key on every request as Authorization: Bearer sk_live_… The machine-readable description is at /v1/openapi.json.
| Method | Path | Scope | What it does |
|---|---|---|---|
| GET | /v1/signatures | agents:read | The signatures you can use, and their price a minute |
| GET | /v1/voices | agents:read | The voices of those signatures |
| POST | /v1/agents | agents:write | Create an agent, live at once |
| GET | /v1/agents | agents:read | List the agents made through the API |
| PATCH | /v1/agents/{id} | agents:write | Change an agent. New calls get the change, live calls keep theirs |
| DELETE | /v1/agents/{id} | agents:write | Archive an agent |
| POST | /v1/web-calls | web_calls:create | A single-use token for one browser call |
| GET | /v1/calls | calls:read | Every call, newest first: web, test and phone |
| GET | /v1/calls/{id} | calls:read | One call with its transcript, analysis and bill |
| GET | /v1/calls/{id}/recording | calls:read | A private link to the recording, good for 5 minutes |
| POST | /v1/calls/{id}/end | calls:control | End a live call within a few seconds |
| GET | /v1/wallet | billing:read | Balance, held, available and days left |
| POST | /v1/webhook-endpoints | webhooks:write | Register a webhook endpoint |
| POST | /v1/keys | keys:write | Create an API key |
Send an Idempotency-Key header when you create something. A retry within 24 hours gets the first answer back, never a second agent.
Lists come 20 at a time, up to 100, with has_more and a next_cursor for the next page.
Every error has a code you can act on and a request id to quote to support.
{ "error": { "type": "…", "code": "plan_limit_reached",
"message": "…", "request_id": "req_…" } }
10 requests a second for each key, with short bursts to 20. Every answer carries X-Request-Id and the X-RateLimit-* headers, so you know how many are left.
[ SDK ]
@jeevan-ai/web-call starts a voice call with your agent in the browser, inside your own design.
A token starts a single call and then stops working.
An unused token expires two minutes after it is made.
It works only from the origin your server named.
Pass what you know, such as the signed-in customer's name, and the prompt can use it.
Errors come with a clear code
server.js · mint a token
// The key stays on your server and never reaches the page
const API = "https://api.your-jeevan-domain.in";
const answer = await fetch(`${API}/v1/web-calls`, {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.JEEVAN_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
agent: "agent_K7q2xN4vLp",
origin: "https://www.yourclinic.in",
variables: { customer_name: "Rohit" },
}),
});
const token = await answer.json();
// { access_token, signaling_url, ice_servers_url }
No code at all? The website widget
// The "Talk to us" widget is one snippet copied from the console.
// Tell the agent what the visitor is looking at:
window.VoiceWidget.setContext({ product: "Kurta set" });
[ Events ]
Register an https endpoint and your server hears the moment something happens. Each event is signed with your endpoint's secret, using the Standard Webhooks headers.
call.startedA call was allowed to start
call.endedA call finished, with its length
call.analyzedThe analysis is ready. Fetch the call for its transcript and details
call.billedThe call was charged: seconds and amount
wallet.low_balanceThe wallet went below its threshold
wallet.topup_succeededA recharge reached the wallet
A 2xx answer counts as delivered. A timeout or a 5xx is tried again after 30 s, 2 min, 10 min, 1 h, 6 h and 24 h. Every delivery is logged in the console, with a Resend button.
call.analyzed → fetch the details
// The event carries ids only. The details come from the API, with your key.
GET /v1/calls/call_K7q2xN4vLp
{
"analysis": {
"disposition": "appointment_booked",
"extracted": { "patient_name": "Rohit", "appointment_time": "10:30" }
}
}
verify.js · check the signature first
import crypto from "node:crypto";
function isFromJeevan(headers, rawBody, secret) {
const signed = `${headers["webhook-id"]}.${headers["webhook-timestamp"]}.${rawBody}`;
const key = Buffer.from(secret.replace("whsec_", ""), "base64");
const expected = crypto.createHmac("sha256", key).update(signed).digest("base64");
return headers["webhook-signature"].split(" ").some((s) => s === `v1,${expected}`);
}
[ Inside a call ]
Set up in the agent editor, on the step that needs them. Each one is a plain HTTPS request to an address you control.
Before hello. Your server has 10 seconds to say who is calling. If it is slow, the call goes on without the extra details.
During the call. The model fills the parameters from the conversation. Fixed values, such as a shared secret or {{caller_number}}, are sent without the model seeing them.
After the call. You write the payload, with the details collected and the outcome. It is tried up to 5 times.
Only public addresses are accepted. Private and office-network addresses are refused, so a tool can never reach an internal network.
// Jeevan AI asks your server about the caller
POST https://your-crm.in/caller
{
"event": "call_inbound",
"call_inbound": {
"agent_id": 17,
"from_number": "+919820012345",
"to_number": "+912248912033"
}
}
// You answer, and the prompt can use {{customer_name}}
{
"initial_context": {
"customer_name": "Rohit",
"last_order": "Kurta set, shipped on 18 Oct"
}
}
// The agent decides to call check_slots and fills in the parameters
POST https://your-clinic.in/api/slots
{
"date": "2026-10-21",
"part": "morning"
}
// Your answer goes straight back to the agent,
// which says it in its own words. Keep it short.
{
"free": ["10:30", "11:15"]
}
// The payload template you write in the Webhook step
{
"call_id": "{{workflow_run_id}}",
"agent": "{{workflow_name}}",
"caller": "{{initial_context.caller_number}}",
"patient_name": "{{gathered_context.patient_name}}",
"date": "{{gathered_context.appointment_date}}",
"time": "{{gathered_context.appointment_time}}",
"seconds": "{{cost_info.call_duration_seconds}}"
}
// The outcome (call_disposition) is added on its own
Not yet
Placing a phone call by API: POST /v1/calls answers outbound_not_enabled while calling out is off. Also still to come: phone numbers, tools and knowledge bases by API, a usage report, live call events and a test mode. An agent made by API is a single prompt for now.
Bring one call your product should handle, and we will walk through the API on a working agent.