API reference

REST API

Manage agents, calls, phone numbers, SMS, contacts, campaigns, automations, knowledge bases, and more programmatically over HTTPS.

Base URL & authentication

All endpoints are relative to https://jagcall.com/v1/ and require an Authorization: Bearer jc_live_… header (an API key, or a jca_… OAuth access token). New to the API? Start with the Getting started guide.

This reference is generated from the OpenAPI spec (v1.0.0). Download the full machine-readable spec to import into Postman, Insomnia, or an SDK generator: openapi.json.

List endpoints are paginated with limit and offset query parameters and return a { items, total, limit, offset } envelope. See each endpoint's parameters for its limit range.

Errors

Every error response has the shape { "error": { code, message, status, request_id, details } }. Codes include bad_request (400), unauthorized (401), insufficient_balance (402), forbidden (403, including a missing scope), not_found (404), conflict (409), validation_error (422), and rate_limit_exceeded (429). The X-Request-ID response header matches request_id; include it when contacting support.

Scopes

An OAuth token or a scoped API key can only call endpoints covered by its scopes (for example contacts:read for contact notes and tasks). API keys created without scopes are unrestricted. See the full scope list.

Rate limits

Limits are per organization per minute, not per key, in separate buckets. Defaults: 200 reads, 30 writes, 30 call creations, 60 SMS sends, 10 searches (phone numbers and knowledge bases), and 5 number or workspace provisioning requests. Every response carries X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset (Unix seconds); a 429 adds Retry-After.

Paused access

JagCall can pause API access for a key, an OAuth app, an organization, or the whole platform. A paused credential gets 403 (api_key_paused, oauth_client_paused, organization_api_paused) or, for a platform pause, 503 api_paused with Retry-After.

Corporate accounts with child organizations (workspaces) must send an X-JagCall-Org header naming the organization a request targets; GET /v1/workspaces lists them.

Agents

GET/v1/agents

List all agents for this organization.

Parameters

agent_typestringoptional
limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "name": "Example",      "status": "active",      "llm_provider": "string",      "llm_model": "string",      "llm_temperature": 0,      "system_prompt": "string",      "tts_provider": "string",      "tts_voice_id": "tts_voice_123",      "tts_model": "string",      "voice_speed": 0,      "stt_provider": "string",      "stt_model": "string",      "stt_language": "string",      "greeting_message": "string",      "end_call_silence_seconds": 0,      "max_call_duration_seconds": 142,      "allow_interruptions": false,      "interruption_min_words": 0,      "vad_confidence": 0,      "vad_start_secs": 0,      "vad_min_volume": 0,      "webhook_url": "https://example.com",      "created_at": "2025-11-01T14:30:00Z",      "updated_at": "2025-11-01T14:30:00Z"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/agents \  -H "Authorization: Bearer jc_live_..."
POST/v1/agents

Create a new AI agent.

Request body

json
{  "name": "Example",  "system_prompt": "string",  "llm_provider": "gemini",  "llm_model": "gemini-2.5-flash-lite",  "llm_temperature": 0.7,  "tts_provider": "cartesia",  "tts_voice_id": "tts_voice_123",  "tts_model": "sonic-2",  "stt_provider": "deepgram",  "stt_model": "nova-3",  "stt_language": "en",  "greeting_message": "string",  "end_call_silence_seconds": 600,  "max_call_duration_seconds": 1800,  "allow_interruptions": true,  "interruption_min_words": 2,  "vad_confidence": 0.7,  "vad_start_secs": 0.4,  "vad_min_volume": 0.6,  "webhook_url": "https://example.com",  "webhook_secret": "string",  "voice_speed": 1}

Response

json
{  "id": "id_123",  "name": "Example",  "status": "active",  "llm_provider": "string",  "llm_model": "string",  "llm_temperature": 0,  "system_prompt": "string",  "tts_provider": "string",  "tts_voice_id": "tts_voice_123",  "tts_model": "string",  "voice_speed": 0,  "stt_provider": "string",  "stt_model": "string",  "stt_language": "string",  "greeting_message": "string",  "end_call_silence_seconds": 0,  "max_call_duration_seconds": 142,  "allow_interruptions": false,  "interruption_min_words": 0,  "vad_confidence": 0,  "vad_start_secs": 0,  "vad_min_volume": 0,  "webhook_url": "https://example.com",  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/agents \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"name":"Example","system_prompt":"string","llm_provider":"gemini","llm_model":"gemini-2.5-flash-lite","llm_temperature":0.7,"tts_provider":"cartesia","tts_voice_id":"tts_voice_123","tts_model":"sonic-2","stt_provider":"deepgram","stt_model":"nova-3","stt_language":"en","greeting_message":"string","end_call_silence_seconds":600,"max_call_duration_seconds":1800,"allow_interruptions":true,"interruption_min_words":2,"vad_confidence":0.7,"vad_start_secs":0.4,"vad_min_volume":0.6,"webhook_url":"https://example.com","webhook_secret":"string","voice_speed":1}'
GET/v1/agents/{agent_id}

Get details of a specific agent.

Parameters

agent_idstringrequired

Response

json
{  "id": "id_123",  "name": "Example",  "status": "active",  "llm_provider": "string",  "llm_model": "string",  "llm_temperature": 0,  "system_prompt": "string",  "tts_provider": "string",  "tts_voice_id": "tts_voice_123",  "tts_model": "string",  "voice_speed": 0,  "stt_provider": "string",  "stt_model": "string",  "stt_language": "string",  "greeting_message": "string",  "end_call_silence_seconds": 0,  "max_call_duration_seconds": 142,  "allow_interruptions": false,  "interruption_min_words": 0,  "vad_confidence": 0,  "vad_start_secs": 0,  "vad_min_volume": 0,  "webhook_url": "https://example.com",  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl https://jagcall.com/v1/agents/agent_123 \  -H "Authorization: Bearer jc_live_..."
PUT/v1/agents/{agent_id}

Update an existing agent. Only provided fields are changed. Auto-publishes the draft so changes take effect immediately.

Parameters

agent_idstringrequired

Request body

json
{  "name": "Example",  "status": "active",  "system_prompt": "string",  "llm_provider": "gemini",  "llm_model": "string",  "llm_temperature": 0,  "tts_provider": "cartesia",  "tts_voice_id": "tts_voice_123",  "tts_model": "string",  "stt_provider": "deepgram",  "stt_model": "string",  "stt_language": "string",  "timezone": "string",  "greeting_message": "string",  "end_call_silence_seconds": 0,  "max_call_duration_seconds": 142,  "allow_interruptions": false,  "interruption_min_words": 0,  "vad_confidence": 0,  "vad_start_secs": 0,  "vad_min_volume": 0,  "webhook_url": "https://example.com",  "webhook_secret": "string",  "voice_speed": 0}

Response

json
{  "id": "id_123",  "name": "Example",  "status": "active",  "llm_provider": "string",  "llm_model": "string",  "llm_temperature": 0,  "system_prompt": "string",  "tts_provider": "string",  "tts_voice_id": "tts_voice_123",  "tts_model": "string",  "voice_speed": 0,  "stt_provider": "string",  "stt_model": "string",  "stt_language": "string",  "greeting_message": "string",  "end_call_silence_seconds": 0,  "max_call_duration_seconds": 142,  "allow_interruptions": false,  "interruption_min_words": 0,  "vad_confidence": 0,  "vad_start_secs": 0,  "vad_min_volume": 0,  "webhook_url": "https://example.com",  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X PUT https://jagcall.com/v1/agents/agent_123 \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"name":"Example","status":"active","system_prompt":"string","llm_provider":"gemini","llm_model":"string","llm_temperature":0,"tts_provider":"cartesia","tts_voice_id":"tts_voice_123","tts_model":"string","stt_provider":"deepgram","stt_model":"string","stt_language":"string","timezone":"string","greeting_message":"string","end_call_silence_seconds":0,"max_call_duration_seconds":142,"allow_interruptions":false,"interruption_min_words":0,"vad_confidence":0,"vad_start_secs":0,"vad_min_volume":0,"webhook_url":"https://example.com","webhook_secret":"string","voice_speed":0}'
DELETE/v1/agents/{agent_id}

Delete an agent. This cannot be undone.

Parameters

agent_idstringrequired

Example

curl
curl -X DELETE https://jagcall.com/v1/agents/agent_123 \  -H "Authorization: Bearer jc_live_..."
PUT/v1/agents/{agent_id}/knowledge

Replace this agent's knowledge base, entire. **PUT, not PATCH.** Your database is the source of truth for a timetable that changes weekly, so send the whole thing every time: the sync is then idempotent, and a partial failure cannot leave half of last term's schedule being read aloud to a parent. An empty ``sections`` list clears it. Only the knowledge base this endpoint owns is replaced. Anything a human attached to the agent in the dashboard is left alone.

Parameters

agent_idstringrequired

Request body

json
{  "sections": [    {      "title": "string",      "content": "string"    }  ]}

Example

curl
curl -X PUT https://jagcall.com/v1/agents/agent_123/knowledge \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"sections":[{"title":"string","content":"string"}]}'

Calls

GET/v1/calls

List all calls for this organization, newest first (ties broken by id, so paging is stable). Supports filtering and pagination. Timestamps are UTC.

Parameters

agent_idstringoptional
directionstringoptional

inbound or outbound

statusstringoptional
created_afterstringoptional

Only calls created at or after this time (ISO 8601; no offset means UTC).

created_beforestringoptional

Only calls created before this time (ISO 8601; no offset means UTC).

limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "agent_id": "agent_123",      "direction": "outbound",      "status": "active",      "from_number": "+14155551234",      "to_number": "+14155551234",      "duration_seconds": 142,      "cost_total": 0.0231,      "recording_url": "https://example.com",      "call_summary": "string",      "call_successful": false,      "user_sentiment": "string",      "extracted_data": {},      "error_message": "string",      "phone_number_id": "phone_number_123",      "answered_by_identity": "string",      "started_at": "2025-11-01T14:30:00Z",      "ended_at": "2025-11-01T14:30:00Z",      "created_at": "2025-11-01T14:30:00Z"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/calls \  -H "Authorization: Bearer jc_live_..."
POST/v1/calls

Initiate an outbound call via an AI agent. Fair-use refusals are named, with ``details.reason`` saying which: - **402 ``plan_limit_reached``** — the plan's monthly fair-use call minutes are used up (``fair_use_minutes_reached``) and the account has not turned on pay-per-minute calling. Upgrade, add team members, or wait for the period to renew. - **402 ``insufficient_balance``** — pay-per-minute calling is on and the minutes are used up, but the prepaid balance no longer funds another minute (``fair_use_minutes_balance_low``). Top up the balance.

Request body

json
{  "agent_id": "agent_123",  "to_number": "+14155551234",  "from_number_id": "from_number_123",  "metadata": {}}

Response

json
{  "id": "id_123",  "agent_id": "agent_123",  "direction": "outbound",  "status": "active",  "from_number": "+14155551234",  "to_number": "+14155551234",  "duration_seconds": 142,  "cost_total": 0.0231,  "recording_url": "https://example.com",  "call_summary": "string",  "call_successful": false,  "user_sentiment": "string",  "extracted_data": {},  "error_message": "string",  "phone_number_id": "phone_number_123",  "answered_by_identity": "string",  "started_at": "2025-11-01T14:30:00Z",  "ended_at": "2025-11-01T14:30:00Z",  "created_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/calls \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"agent_id":"agent_123","to_number":"+14155551234","from_number_id":"from_number_123","metadata":{}}'
GET/v1/calls/{call_id}

Get details of a specific call.

Parameters

call_idstringrequired

Response

json
{  "id": "id_123",  "agent_id": "agent_123",  "direction": "outbound",  "status": "active",  "from_number": "+14155551234",  "to_number": "+14155551234",  "duration_seconds": 142,  "cost_total": 0.0231,  "recording_url": "https://example.com",  "call_summary": "string",  "call_successful": false,  "user_sentiment": "string",  "extracted_data": {},  "error_message": "string",  "phone_number_id": "phone_number_123",  "answered_by_identity": "string",  "started_at": "2025-11-01T14:30:00Z",  "ended_at": "2025-11-01T14:30:00Z",  "created_at": "2025-11-01T14:30:00Z"}

Example

curl
curl https://jagcall.com/v1/calls/call_123 \  -H "Authorization: Bearer jc_live_..."
DELETE/v1/calls/{call_id}

Delete a call with its recording, transcript and any voicemail left on it. The recording is removed from JagCall's storage and from Twilio. A call that is still live (queued, ringing or in progress) cannot be deleted: 409. Afterwards ``GET /v1/calls/{id}`` answers 404.

Parameters

call_idstringrequired

Example

curl
curl -X DELETE https://jagcall.com/v1/calls/call_123 \  -H "Authorization: Bearer jc_live_..."
GET/v1/calls/{call_id}/recording

Stream the call recording audio, proxying Twilio auth.

Parameters

call_idstringrequired

Example

curl
curl https://jagcall.com/v1/calls/call_123/recording \  -H "Authorization: Bearer jc_live_..."
GET/v1/calls/{call_id}/transcript

Get the transcript of a call.

Parameters

call_idstringrequired

Response

json
[  {    "role": "string",    "content": "string",    "timestamp_ms": 0  }]

Example

curl
curl https://jagcall.com/v1/calls/call_123/transcript \  -H "Authorization: Bearer jc_live_..."

Phone Numbers

GET/v1/phone-numbers

List all active phone numbers for this organization.

Parameters

limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "phone_number": "+14155551234",      "friendly_name": "Example",      "inbound_agent_id": "inbound_agent_123",      "sms_agent_id": "sms_agent_123",      "status": "active",      "schedule": {},      "sms_schedule": {},      "forward_number": "+14155551234",      "forward_webhook_url": "https://example.com",      "sms_active": false,      "messaging_registration_status": "unregistered",      "recording_notice": "string",      "recording_notice_enabled": false,      "recording_mode": "enforced",      "routing_mode": "default",      "routing_url": "https://example.com",      "routing_fallback": "voicemail",      "fallback_ai_supported": true,      "created_at": "2025-11-01T14:30:00Z",      "inbound_notice": false    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/phone-numbers \  -H "Authorization: Bearer jc_live_..."
POST/v1/phone-numbers

Purchase and provision a phone number from Twilio.

Request body

json
{  "phone_number": "+14155551234",  "friendly_name": "Example",  "inbound_agent_id": "inbound_agent_123"}

Response

json
{  "id": "id_123",  "phone_number": "+14155551234",  "friendly_name": "Example",  "inbound_agent_id": "inbound_agent_123",  "sms_agent_id": "sms_agent_123",  "status": "active",  "schedule": {},  "sms_schedule": {},  "forward_number": "+14155551234",  "forward_webhook_url": "https://example.com",  "sms_active": false,  "messaging_registration_status": "unregistered",  "recording_notice": "string",  "recording_notice_enabled": false,  "recording_mode": "enforced",  "routing_mode": "default",  "routing_url": "https://example.com",  "routing_fallback": "voicemail",  "fallback_ai_supported": true,  "created_at": "2025-11-01T14:30:00Z",  "inbound_notice": false}

Example

curl
curl -X POST https://jagcall.com/v1/phone-numbers \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"phone_number":"+14155551234","friendly_name":"Example","inbound_agent_id":"inbound_agent_123"}'
PUT/v1/phone-numbers/{number_id}

Update a phone number (friendly name, inbound agent assignment, schedules, forwarding, recording notice, partner routing). Fields that are not sent stay as they are. ``recording_notice`` takes up to 500 characters (trimmed; an empty string clears it) and ``recording_notice_enabled`` can only be true while a notice is set.

Parameters

number_idstringrequired

Request body

json
{  "friendly_name": "Example",  "inbound_agent_id": "inbound_agent_123",  "schedule": {},  "sms_schedule": {},  "forward_number": "+14155551234",  "forward_webhook_url": "https://example.com",  "recording_notice": "string",  "recording_notice_enabled": true,  "routing_mode": "default",  "routing_url": "https://example.com",  "routing_fallback": "voicemail"}

Response

json
{  "id": "id_123",  "phone_number": "+14155551234",  "friendly_name": "Example",  "inbound_agent_id": "inbound_agent_123",  "sms_agent_id": "sms_agent_123",  "status": "active",  "schedule": {},  "sms_schedule": {},  "forward_number": "+14155551234",  "forward_webhook_url": "https://example.com",  "sms_active": false,  "messaging_registration_status": "unregistered",  "recording_notice": "string",  "recording_notice_enabled": false,  "recording_mode": "enforced",  "routing_mode": "default",  "routing_url": "https://example.com",  "routing_fallback": "voicemail",  "fallback_ai_supported": true,  "created_at": "2025-11-01T14:30:00Z",  "inbound_notice": false}

Example

curl
curl -X PUT https://jagcall.com/v1/phone-numbers/number_123 \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"friendly_name":"Example","inbound_agent_id":"inbound_agent_123","schedule":{},"sms_schedule":{},"forward_number":"+14155551234","forward_webhook_url":"https://example.com","recording_notice":"string","recording_notice_enabled":true,"routing_mode":"default","routing_url":"https://example.com","routing_fallback":"voicemail"}'
DELETE/v1/phone-numbers/{number_id}

Schedule a phone number for release at the end of the billing period.

Parameters

number_idstringrequired

Example

curl
curl -X DELETE https://jagcall.com/v1/phone-numbers/number_123 \  -H "Authorization: Bearer jc_live_..."
POST/v1/phone-numbers/{number_id}/route

Point a number at an agent — the last step of provisioning a tenant. Voice and messaging route independently: a studio may want the AI answering the phone while a human handles texts. Naming an agent that belongs to another organization is a 404, not a silent no-op — a number quietly pointed at nothing answers with dead air.

Parameters

number_idstringrequired

Request body

json
{  "inbound_agent_id": "inbound_agent_123",  "sms_agent_id": "sms_agent_123",  "sms_auto_reply": false}

Response

json
{  "id": "id_123",  "phone_number": "+14155551234",  "friendly_name": "Example",  "inbound_agent_id": "inbound_agent_123",  "sms_agent_id": "sms_agent_123",  "status": "active",  "schedule": {},  "sms_schedule": {},  "forward_number": "+14155551234",  "forward_webhook_url": "https://example.com",  "sms_active": false,  "messaging_registration_status": "unregistered",  "recording_notice": "string",  "recording_notice_enabled": false,  "recording_mode": "enforced",  "routing_mode": "default",  "routing_url": "https://example.com",  "routing_fallback": "voicemail",  "fallback_ai_supported": true,  "created_at": "2025-11-01T14:30:00Z",  "inbound_notice": false}

Example

curl
curl -X POST https://jagcall.com/v1/phone-numbers/number_123/route \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"inbound_agent_id":"inbound_agent_123","sms_agent_id":"sms_agent_123","sms_auto_reply":false}'
GET/v1/phone-numbers/available

Search for numbers available to buy into the targeted organization. The GET form of ``POST /v1/phone-numbers/search`` — a search is a read, so it is safe to retry and cacheable at the caller's end. Both remain.

Parameters

countrystringoptional

ISO-2 country code.

area_codestringoptional

Example

curl
curl https://jagcall.com/v1/phone-numbers/available \  -H "Authorization: Bearer jc_live_..."
POST/v1/phone-numbers/search

Search for available phone numbers to purchase.

Request body

json
{  "country": "US",  "area_code": "string"}

Example

curl
curl -X POST https://jagcall.com/v1/phone-numbers/search \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"country":"US","area_code":"string"}'

SMS

POST/v1/sms

Send an outbound SMS from a number this organization holds. The response carries the message id. Write it against your own delivery row — one you created *before* calling here — so "it did not arrive" and "nothing was attempted" stay two different facts. The ``sms.delivered`` / ``sms.failed`` webhooks close that row and carry the same id. Refusals are named rather than lumped together: - **402 ``insufficient_balance``** — no funds. On a Corporate account the details name the child org and the parent account that ran dry. - **402 ``plan_limit_reached``** — the plan's monthly fair-use texting cap is used up (``details.reason`` = ``fair_use_sms_reached``). Upgrade the plan or add team members, or wait for the period to renew. - **409 ``recipient_opted_out``** — this handset texted STOP. The opt-out binds every number on the billing account and the details carry its date. This is the system working, not a failure to send.

Request body

json
{  "to_number": "+14155551234",  "from_number_id": "from_number_123",  "body": "string"}

Response

json
{  "id": "id_123",  "conversation_id": "conversation_123",  "direction": "outbound",  "from_number": "+14155551234",  "to_number": "+14155551234",  "body": "string",  "status": "active",  "segments": 0,  "error_code": "string",  "error_message": "string",  "created_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/sms \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"to_number":"+14155551234","from_number_id":"from_number_123","body":"string"}'
GET/v1/sms/{message_id}

Get one text message by id.

Parameters

message_idstringrequired

Response

json
{  "id": "id_123",  "conversation_id": "conversation_123",  "direction": "outbound",  "from_number": "+14155551234",  "to_number": "+14155551234",  "body": "string",  "status": "active",  "segments": 0,  "error_code": "string",  "error_message": "string",  "created_at": "2025-11-01T14:30:00Z"}

Example

curl
curl https://jagcall.com/v1/sms/message_123 \  -H "Authorization: Bearer jc_live_..."
DELETE/v1/sms/{message_id}

Delete one text message, here and at Twilio. Its conversation stays. Afterwards ``GET /v1/sms/{id}`` answers 404.

Parameters

message_idstringrequired

Example

curl
curl -X DELETE https://jagcall.com/v1/sms/message_123 \  -H "Authorization: Bearer jc_live_..."
GET/v1/sms/conversations

List SMS conversations.

Parameters

limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "phone_number_id": "phone_number_123",      "contact_number": "+14155551234",      "status": "active",      "last_message_at": "2025-11-01T14:30:00Z",      "created_at": "2025-11-01T14:30:00Z"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/sms/conversations \  -H "Authorization: Bearer jc_live_..."
GET/v1/sms/conversations/{conversation_id}/messages

Get messages in an SMS conversation.

Parameters

conversation_idstringrequired
limitintegeroptional

Defaults to 100. Range 1–500.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "conversation_id": "conversation_123",      "direction": "outbound",      "from_number": "+14155551234",      "to_number": "+14155551234",      "body": "string",      "status": "active",      "segments": 0,      "error_code": "string",      "error_message": "string",      "created_at": "2025-11-01T14:30:00Z"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/sms/conversations/conversation_123/messages \  -H "Authorization: Bearer jc_live_..."

Contacts

GET/v1/contacts

List contacts. Filter by free-text search or exact phone number.

Parameters

searchstringoptional
phonestringoptional
limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "phone_number": "+14155551234",      "name": "Example",      "email": "user@example.com",      "company": "string",      "notes": "string",      "tags": "string",      "address": "string",      "role": "string",      "is_favorite": false,      "created_at": "2025-11-01T14:30:00Z",      "updated_at": "2025-11-01T14:30:00Z"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/contacts \  -H "Authorization: Bearer jc_live_..."
POST/v1/contacts

Create a contact. Returns 409 if the phone number already exists. A contact deleted in the last 30 days with the same phone is brought back (same id, with its notes and tasks) holding the fields sent here.

Request body

json
{  "phone_number": "+14155551234",  "name": "Example",  "email": "user@example.com",  "company": "string",  "notes": "string",  "tags": "string",  "address": "string",  "role": "string",  "is_favorite": false}

Response

json
{  "id": "id_123",  "phone_number": "+14155551234",  "name": "Example",  "email": "user@example.com",  "company": "string",  "notes": "string",  "tags": "string",  "address": "string",  "role": "string",  "is_favorite": false,  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/contacts \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"phone_number":"+14155551234","name":"Example","email":"user@example.com","company":"string","notes":"string","tags":"string","address":"string","role":"string","is_favorite":false}'
GET/v1/contacts/{contact_id}

Get Contact Public

Parameters

contact_idstringrequired

Response

json
{  "id": "id_123",  "phone_number": "+14155551234",  "name": "Example",  "email": "user@example.com",  "company": "string",  "notes": "string",  "tags": "string",  "address": "string",  "role": "string",  "is_favorite": false,  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl https://jagcall.com/v1/contacts/contact_123 \  -H "Authorization: Bearer jc_live_..."
PATCH/v1/contacts/{contact_id}

Update Contact Public

Parameters

contact_idstringrequired

Request body

json
{  "phone_number": "+14155551234",  "name": "Example",  "email": "user@example.com",  "company": "string",  "notes": "string",  "tags": "string",  "address": "string",  "role": "string",  "is_favorite": false}

Response

json
{  "id": "id_123",  "phone_number": "+14155551234",  "name": "Example",  "email": "user@example.com",  "company": "string",  "notes": "string",  "tags": "string",  "address": "string",  "role": "string",  "is_favorite": false,  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X PATCH https://jagcall.com/v1/contacts/contact_123 \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"phone_number":"+14155551234","name":"Example","email":"user@example.com","company":"string","notes":"string","tags":"string","address":"string","role":"string","is_favorite":false}'
DELETE/v1/contacts/{contact_id}

Delete a contact. Its notes and tasks are kept for 30 days and come back if a contact with the same phone is created again. Calls and texts are not touched (see DELETE /v1/calls/{id} and DELETE /v1/sms/{id}).

Parameters

contact_idstringrequired

Example

curl
curl -X DELETE https://jagcall.com/v1/contacts/contact_123 \  -H "Authorization: Bearer jc_live_..."
GET/v1/contacts/{contact_id}/notes

List a contact's notes, newest first.

Parameters

contact_idstringrequired
limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "contact_id": "contact_123",      "body": "string",      "created_by_user_id": "created_by_user_123",      "created_by_name": "Example",      "created_at": "2025-11-01T14:30:00Z",      "updated_at": "2025-11-01T14:30:00Z"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/contacts/contact_123/notes \  -H "Authorization: Bearer jc_live_..."
POST/v1/contacts/{contact_id}/notes

Add a note to a contact. The author fields are null for API-key writes.

Parameters

contact_idstringrequired

Request body

json
{  "body": "string"}

Response

json
{  "id": "id_123",  "contact_id": "contact_123",  "body": "string",  "created_by_user_id": "created_by_user_123",  "created_by_name": "Example",  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/contacts/contact_123/notes \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"body":"string"}'
PUT/v1/contacts/{contact_id}/notes/{note_id}

Replace a note's body.

Parameters

contact_idstringrequired
note_idstringrequired

Request body

json
{  "body": "string"}

Response

json
{  "id": "id_123",  "contact_id": "contact_123",  "body": "string",  "created_by_user_id": "created_by_user_123",  "created_by_name": "Example",  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X PUT https://jagcall.com/v1/contacts/contact_123/notes/note_123 \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"body":"string"}'
DELETE/v1/contacts/{contact_id}/notes/{note_id}

Delete Contact Note Public

Parameters

contact_idstringrequired
note_idstringrequired

Example

curl
curl -X DELETE https://jagcall.com/v1/contacts/contact_123/notes/note_123 \  -H "Authorization: Bearer jc_live_..."
GET/v1/contacts/{contact_id}/tasks

List a contact's tasks. `status` is `open` (default), `done` or `all`.

Parameters

contact_idstringrequired
statusstringoptional

One of: open, done, all. Defaults to "open".

limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "contact_id": "contact_123",      "title": "string",      "due_at": "2025-11-01T14:30:00Z",      "is_done": false,      "completed_at": "2025-11-01T14:30:00Z",      "assignee_user_id": "assignee_user_123",      "created_by_user_id": "created_by_user_123",      "created_by_name": "Example",      "created_at": "2025-11-01T14:30:00Z",      "updated_at": "2025-11-01T14:30:00Z"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/contacts/contact_123/tasks \  -H "Authorization: Bearer jc_live_..."
POST/v1/contacts/{contact_id}/tasks

Create a task on a contact. `assignee_user_id` must be a member of the organization.

Parameters

contact_idstringrequired

Request body

json
{  "title": "string",  "due_at": "2025-11-01T14:30:00Z",  "assignee_user_id": "assignee_user_123"}

Response

json
{  "id": "id_123",  "contact_id": "contact_123",  "title": "string",  "due_at": "2025-11-01T14:30:00Z",  "is_done": false,  "completed_at": "2025-11-01T14:30:00Z",  "assignee_user_id": "assignee_user_123",  "created_by_user_id": "created_by_user_123",  "created_by_name": "Example",  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/contacts/contact_123/tasks \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"title":"string","due_at":"2025-11-01T14:30:00Z","assignee_user_id":"assignee_user_123"}'
PUT/v1/contacts/{contact_id}/tasks/{task_id}

Partial update: only fields present are changed. `due_at: null` clears the date, `is_done` completes or reopens the task.

Parameters

contact_idstringrequired
task_idstringrequired

Request body

json
{  "title": "string",  "due_at": "2025-11-01T14:30:00Z",  "assignee_user_id": "assignee_user_123",  "is_done": false}

Response

json
{  "id": "id_123",  "contact_id": "contact_123",  "title": "string",  "due_at": "2025-11-01T14:30:00Z",  "is_done": false,  "completed_at": "2025-11-01T14:30:00Z",  "assignee_user_id": "assignee_user_123",  "created_by_user_id": "created_by_user_123",  "created_by_name": "Example",  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X PUT https://jagcall.com/v1/contacts/contact_123/tasks/task_123 \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"title":"string","due_at":"2025-11-01T14:30:00Z","assignee_user_id":"assignee_user_123","is_done":false}'
DELETE/v1/contacts/{contact_id}/tasks/{task_id}

Delete Contact Task Public

Parameters

contact_idstringrequired
task_idstringrequired

Example

curl
curl -X DELETE https://jagcall.com/v1/contacts/contact_123/tasks/task_123 \  -H "Authorization: Bearer jc_live_..."
GET/v1/tasks

Every task in the organization with its contact's name and phone.

Parameters

statusstringoptional

One of: open, done, all. Defaults to "open".

assigneestringoptional

'unassigned' or a member's user id. Omit for everyone's tasks. 'me' and 'me_or_unassigned' are not available to API credentials (400).

due_beforestringoptional

Only tasks with a due date at or before this instant (overdue + due soon).

contact_idstringoptional
qstringoptional

Matches task title, contact name or phone.

limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "contact_id": "contact_123",      "title": "string",      "due_at": "2025-11-01T14:30:00Z",      "is_done": false,      "completed_at": "2025-11-01T14:30:00Z",      "assignee_user_id": "assignee_user_123",      "created_by_user_id": "created_by_user_123",      "created_by_name": "Example",      "created_at": "2025-11-01T14:30:00Z",      "updated_at": "2025-11-01T14:30:00Z",      "contact_name": "Example",      "contact_phone": "string"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/tasks \  -H "Authorization: Bearer jc_live_..."

Campaigns

GET/v1/campaigns

List Campaigns Public

Parameters

limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "name": "Example",      "agent_id": "agent_123",      "phone_number_id": "phone_number_123",      "status": "active",      "scheduled_at": "2025-11-01T14:30:00Z",      "max_concurrent": 0,      "total_contacts": 3,      "called": 0,      "completed": 0,      "failed": 0,      "created_at": "2025-11-01T14:30:00Z",      "updated_at": "2025-11-01T14:30:00Z"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/campaigns \  -H "Authorization: Bearer jc_live_..."
POST/v1/campaigns

Create a draft campaign with its contact list (JSON, not CSV upload).

Request body

json
{  "name": "Example",  "agent_id": "agent_123",  "phone_number_id": "phone_number_123",  "scheduled_at": "2025-11-01T14:30:00Z",  "max_concurrent": 2,  "contacts": [    {      "phone_number": "+14155551234",      "name": "Example"    }  ]}

Response

json
{  "id": "id_123",  "name": "Example",  "agent_id": "agent_123",  "phone_number_id": "phone_number_123",  "status": "active",  "scheduled_at": "2025-11-01T14:30:00Z",  "max_concurrent": 0,  "total_contacts": 3,  "called": 0,  "completed": 0,  "failed": 0,  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/campaigns \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"name":"Example","agent_id":"agent_123","phone_number_id":"phone_number_123","scheduled_at":"2025-11-01T14:30:00Z","max_concurrent":2,"contacts":[{"phone_number":"+14155551234","name":"Example"}]}'
GET/v1/campaigns/{campaign_id}

Get Campaign Public

Parameters

campaign_idstringrequired

Response

json
{  "id": "id_123",  "name": "Example",  "agent_id": "agent_123",  "phone_number_id": "phone_number_123",  "status": "active",  "scheduled_at": "2025-11-01T14:30:00Z",  "max_concurrent": 0,  "total_contacts": 3,  "called": 0,  "completed": 0,  "failed": 0,  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl https://jagcall.com/v1/campaigns/campaign_123 \  -H "Authorization: Bearer jc_live_..."
DELETE/v1/campaigns/{campaign_id}

Delete Campaign Public

Parameters

campaign_idstringrequired

Example

curl
curl -X DELETE https://jagcall.com/v1/campaigns/campaign_123 \  -H "Authorization: Bearer jc_live_..."
POST/v1/campaigns/{campaign_id}/cancel

Cancel Campaign Public

Parameters

campaign_idstringrequired

Response

json
{  "id": "id_123",  "name": "Example",  "agent_id": "agent_123",  "phone_number_id": "phone_number_123",  "status": "active",  "scheduled_at": "2025-11-01T14:30:00Z",  "max_concurrent": 0,  "total_contacts": 3,  "called": 0,  "completed": 0,  "failed": 0,  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/campaigns/campaign_123/cancel \  -H "Authorization: Bearer jc_live_..."
GET/v1/campaigns/{campaign_id}/contacts

List Campaign Contacts Public

Parameters

campaign_idstringrequired
statusstringoptional
limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "campaign_id": "campaign_123",      "phone_number": "+14155551234",      "name": "Example",      "status": "active",      "outcome": "string",      "call_id": "call_123",      "error": "string",      "called_at": "2025-11-01T14:30:00Z",      "created_at": "2025-11-01T14:30:00Z"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/campaigns/campaign_123/contacts \  -H "Authorization: Bearer jc_live_..."
POST/v1/campaigns/{campaign_id}/pause

Pause Campaign Public

Parameters

campaign_idstringrequired

Response

json
{  "id": "id_123",  "name": "Example",  "agent_id": "agent_123",  "phone_number_id": "phone_number_123",  "status": "active",  "scheduled_at": "2025-11-01T14:30:00Z",  "max_concurrent": 0,  "total_contacts": 3,  "called": 0,  "completed": 0,  "failed": 0,  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/campaigns/campaign_123/pause \  -H "Authorization: Bearer jc_live_..."
POST/v1/campaigns/{campaign_id}/resume

Resume Campaign Public

Parameters

campaign_idstringrequired

Response

json
{  "id": "id_123",  "name": "Example",  "agent_id": "agent_123",  "phone_number_id": "phone_number_123",  "status": "active",  "scheduled_at": "2025-11-01T14:30:00Z",  "max_concurrent": 0,  "total_contacts": 3,  "called": 0,  "completed": 0,  "failed": 0,  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/campaigns/campaign_123/resume \  -H "Authorization: Bearer jc_live_..."
POST/v1/campaigns/{campaign_id}/start

Start Campaign Public

Parameters

campaign_idstringrequired

Response

json
{  "id": "id_123",  "name": "Example",  "agent_id": "agent_123",  "phone_number_id": "phone_number_123",  "status": "active",  "scheduled_at": "2025-11-01T14:30:00Z",  "max_concurrent": 0,  "total_contacts": 3,  "called": 0,  "completed": 0,  "failed": 0,  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/campaigns/campaign_123/start \  -H "Authorization: Bearer jc_live_..."

Automations

GET/v1/automations

List Automations Public

Parameters

limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "name": "Example",      "description": "string",      "enabled": true,      "trigger_type": "string",      "trigger_filters": {},      "conditions": [],      "actions": [],      "run_count": 3,      "last_run_at": "2025-11-01T14:30:00Z",      "created_at": "2025-11-01T14:30:00Z"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/automations \  -H "Authorization: Bearer jc_live_..."
POST/v1/automations

Create Automation Public

Request body

json
{  "name": "Example",  "trigger_type": "call.no_answer",  "description": "string",  "trigger_filters": {},  "conditions": [],  "actions": [],  "enabled": true}

Response

json
{  "id": "id_123",  "name": "Example",  "description": "string",  "enabled": true,  "trigger_type": "string",  "trigger_filters": {},  "conditions": [],  "actions": [],  "run_count": 3,  "last_run_at": "2025-11-01T14:30:00Z",  "created_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/automations \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"name":"Example","trigger_type":"call.no_answer","description":"string","trigger_filters":{},"conditions":[],"actions":[],"enabled":true}'
GET/v1/automations/{automation_id}

Get Automation Public

Parameters

automation_idstringrequired

Response

json
{  "id": "id_123",  "name": "Example",  "description": "string",  "enabled": true,  "trigger_type": "string",  "trigger_filters": {},  "conditions": [],  "actions": [],  "run_count": 3,  "last_run_at": "2025-11-01T14:30:00Z",  "created_at": "2025-11-01T14:30:00Z"}

Example

curl
curl https://jagcall.com/v1/automations/automation_123 \  -H "Authorization: Bearer jc_live_..."
PATCH/v1/automations/{automation_id}

Update Automation Public

Parameters

automation_idstringrequired

Request body

json
{  "name": "Example",  "description": "string",  "trigger_type": "string",  "trigger_filters": {},  "conditions": [],  "actions": [],  "enabled": true}

Response

json
{  "id": "id_123",  "name": "Example",  "description": "string",  "enabled": true,  "trigger_type": "string",  "trigger_filters": {},  "conditions": [],  "actions": [],  "run_count": 3,  "last_run_at": "2025-11-01T14:30:00Z",  "created_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X PATCH https://jagcall.com/v1/automations/automation_123 \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"name":"Example","description":"string","trigger_type":"string","trigger_filters":{},"conditions":[],"actions":[],"enabled":true}'
DELETE/v1/automations/{automation_id}

Delete Automation Public

Parameters

automation_idstringrequired

Example

curl
curl -X DELETE https://jagcall.com/v1/automations/automation_123 \  -H "Authorization: Bearer jc_live_..."
GET/v1/automations/{automation_id}/runs

List Automation Runs Public

Parameters

automation_idstringrequired
limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "automation_id": "automation_123",      "trigger_event": "string",      "status": "active",      "started_at": "2025-11-01T14:30:00Z",      "completed_at": "2025-11-01T14:30:00Z"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/automations/automation_123/runs \  -H "Authorization: Bearer jc_live_..."

Knowledge Bases

GET/v1/documents/{doc_id}

Get Document Public

Parameters

doc_idstringrequired

Response

json
{  "id": "id_123",  "knowledge_base_id": "knowledge_base_123",  "filename": "Example",  "content_type": "string",  "file_size": 0,  "chunk_count": 3,  "status": "active",  "error_message": "string",  "created_at": "2025-11-01T14:30:00Z"}

Example

curl
curl https://jagcall.com/v1/documents/doc_123 \  -H "Authorization: Bearer jc_live_..."
DELETE/v1/documents/{doc_id}

Delete Document Public

Parameters

doc_idstringrequired

Example

curl
curl -X DELETE https://jagcall.com/v1/documents/doc_123 \  -H "Authorization: Bearer jc_live_..."
GET/v1/knowledge-bases

List Knowledge Bases Public

Parameters

limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "name": "Example",      "description": "string",      "created_at": "2025-11-01T14:30:00Z",      "updated_at": "2025-11-01T14:30:00Z"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/knowledge-bases \  -H "Authorization: Bearer jc_live_..."
POST/v1/knowledge-bases

Create Knowledge Base Public

Request body

json
{  "name": "Example",  "description": "string"}

Response

json
{  "id": "id_123",  "name": "Example",  "description": "string",  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/knowledge-bases \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"name":"Example","description":"string"}'
GET/v1/knowledge-bases/{kb_id}

Get Knowledge Base Public

Parameters

kb_idstringrequired

Response

json
{  "id": "id_123",  "name": "Example",  "description": "string",  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl https://jagcall.com/v1/knowledge-bases/kb_123 \  -H "Authorization: Bearer jc_live_..."
DELETE/v1/knowledge-bases/{kb_id}

Delete Knowledge Base Public

Parameters

kb_idstringrequired

Example

curl
curl -X DELETE https://jagcall.com/v1/knowledge-bases/kb_123 \  -H "Authorization: Bearer jc_live_..."
GET/v1/knowledge-bases/{kb_id}/documents

List Documents Public

Parameters

kb_idstringrequired
limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "knowledge_base_id": "knowledge_base_123",      "filename": "Example",      "content_type": "string",      "file_size": 0,      "chunk_count": 3,      "status": "active",      "error_message": "string",      "created_at": "2025-11-01T14:30:00Z"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/knowledge-bases/kb_123/documents \  -H "Authorization: Bearer jc_live_..."
POST/v1/knowledge-bases/{kb_id}/documents

Add a text document. Chunking + embedding happen synchronously, so the response may take a few seconds for large documents.

Parameters

kb_idstringrequired

Request body

json
{  "filename": "Example",  "content": "string",  "content_type": "text/plain"}

Response

json
{  "id": "id_123",  "knowledge_base_id": "knowledge_base_123",  "filename": "Example",  "content_type": "string",  "file_size": 0,  "chunk_count": 3,  "status": "active",  "error_message": "string",  "created_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/knowledge-bases/kb_123/documents \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"filename":"Example","content":"string","content_type":"text/plain"}'
POST/v1/knowledge-bases/search

Semantic search across the org's knowledge bases. Restricts to the given knowledge_base_ids (validated for ownership) or all org KBs.

Request body

json
{  "query": "string",  "knowledge_base_ids": [    "string"  ],  "top_k": 5}

Example

curl
curl -X POST https://jagcall.com/v1/knowledge-bases/search \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"query":"string","knowledge_base_ids":["string"],"top_k":5}'

Analytics

GET/v1/analytics/calls-over-time

Daily call counts and outcomes over the period.

Parameters

daysintegeroptional

Defaults to 30. Range 1–90.

Example

curl
curl https://jagcall.com/v1/analytics/calls-over-time \  -H "Authorization: Bearer jc_live_..."
GET/v1/analytics/overview

Aggregate call/cost/sentiment metrics for the period.

Parameters

daysintegeroptional

Defaults to 30. Range 1–90.

Example

curl
curl https://jagcall.com/v1/analytics/overview \  -H "Authorization: Bearer jc_live_..."

Usage

GET/v1/usage

Current-month usage totals (minutes, SMS, cost).

Example

curl
curl https://jagcall.com/v1/usage \  -H "Authorization: Bearer jc_live_..."
GET/v1/usage/history

Per-month usage totals for the last N months.

Parameters

monthsintegeroptional

Defaults to 6. Range 1–12.

Example

curl
curl https://jagcall.com/v1/usage/history \  -H "Authorization: Bearer jc_live_..."

Webhooks

POST/v1/webhook-deliveries/{delivery_id}/replay

Replay Delivery Public

Parameters

delivery_idstringrequired

Response

json
{  "id": "id_123",  "endpoint_id": "endpoint_123",  "target_kind": "string",  "event_type": "string",  "status": "active",  "attempts": 0,  "next_attempt_at": "2025-11-01T14:30:00Z",  "last_status_code": 0,  "last_error": "string",  "replayed_from_id": "replayed_from_123",  "payload": {},  "created_at": "2025-11-01T14:30:00Z",  "delivered_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X POST https://jagcall.com/v1/webhook-deliveries/delivery_123/replay \  -H "Authorization: Bearer jc_live_..."
GET/v1/webhook-endpoints

List Endpoints Public

Response

json
[  {    "id": "id_123",    "url": "https://example.com",    "description": "string",    "events": [      "string"    ],    "enabled": true,    "has_secret": false,    "consecutive_failures": 0,    "previous_secret_expires_at": "2025-11-01T14:30:00Z",    "created_at": "2025-11-01T14:30:00Z",    "updated_at": "2025-11-01T14:30:00Z"  }]

Example

curl
curl https://jagcall.com/v1/webhook-endpoints \  -H "Authorization: Bearer jc_live_..."
POST/v1/webhook-endpoints

Create Endpoint Public

Request body

json
{  "url": "https://example.com",  "description": "string",  "events": [    "string"  ]}

Example

curl
curl -X POST https://jagcall.com/v1/webhook-endpoints \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"url":"https://example.com","description":"string","events":["string"]}'
GET/v1/webhook-endpoints/{endpoint_id}

Get Endpoint Public

Parameters

endpoint_idstringrequired

Response

json
{  "id": "id_123",  "url": "https://example.com",  "description": "string",  "events": [    "string"  ],  "enabled": true,  "has_secret": false,  "consecutive_failures": 0,  "previous_secret_expires_at": "2025-11-01T14:30:00Z",  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl https://jagcall.com/v1/webhook-endpoints/endpoint_123 \  -H "Authorization: Bearer jc_live_..."
PATCH/v1/webhook-endpoints/{endpoint_id}

Update Endpoint Public

Parameters

endpoint_idstringrequired

Request body

json
{  "url": "https://example.com",  "description": "string",  "events": [    "string"  ],  "enabled": true}

Response

json
{  "id": "id_123",  "url": "https://example.com",  "description": "string",  "events": [    "string"  ],  "enabled": true,  "has_secret": false,  "consecutive_failures": 0,  "previous_secret_expires_at": "2025-11-01T14:30:00Z",  "created_at": "2025-11-01T14:30:00Z",  "updated_at": "2025-11-01T14:30:00Z"}

Example

curl
curl -X PATCH https://jagcall.com/v1/webhook-endpoints/endpoint_123 \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"url":"https://example.com","description":"string","events":["string"],"enabled":true}'
DELETE/v1/webhook-endpoints/{endpoint_id}

Delete Endpoint Public

Parameters

endpoint_idstringrequired

Example

curl
curl -X DELETE https://jagcall.com/v1/webhook-endpoints/endpoint_123 \  -H "Authorization: Bearer jc_live_..."
GET/v1/webhook-endpoints/{endpoint_id}/deliveries

List Endpoint Deliveries Public

Parameters

endpoint_idstringrequired
statusstringoptional
limitintegeroptional

Defaults to 50. Range 1–100.

offsetintegeroptional

Defaults to 0. Min 0.

Response

json
{  "items": [    {      "id": "id_123",      "endpoint_id": "endpoint_123",      "target_kind": "string",      "event_type": "string",      "status": "active",      "attempts": 0,      "next_attempt_at": "2025-11-01T14:30:00Z",      "last_status_code": 0,      "last_error": "string",      "replayed_from_id": "replayed_from_123",      "payload": {},      "created_at": "2025-11-01T14:30:00Z",      "delivered_at": "2025-11-01T14:30:00Z"    }  ],  "total": 3,  "limit": 50,  "offset": 0}

Example

curl
curl https://jagcall.com/v1/webhook-endpoints/endpoint_123/deliveries \  -H "Authorization: Bearer jc_live_..."
POST/v1/webhook-endpoints/{endpoint_id}/replay-failed

Bulk-redeliver failed deliveries since ``since`` (max 100 per call; repeat while ``remaining`` > 0). Delivered/already-replayed rows are skipped.

Parameters

endpoint_idstringrequired
sincestringrequired

Replay failed deliveries created at or after this ISO-8601 time

limitintegeroptional

Defaults to 100. Range 1–100.

Example

curl
curl -X POST https://jagcall.com/v1/webhook-endpoints/endpoint_123/replay-failed \  -H "Authorization: Bearer jc_live_..."
POST/v1/webhook-endpoints/{endpoint_id}/rotate-secret

Rotate Secret Public

Parameters

endpoint_idstringrequired
gracebooleanoptional

Defaults to true.

Example

curl
curl -X POST https://jagcall.com/v1/webhook-endpoints/endpoint_123/rotate-secret \  -H "Authorization: Bearer jc_live_..."
GET/v1/webhook-events

Webhook Events Public

Example

curl
curl https://jagcall.com/v1/webhook-events \  -H "Authorization: Bearer jc_live_..."

Browser Calling

GET/v1/browser-call/phone-numbers

List phone numbers available as caller IDs for browser calling.

Example

curl
curl https://jagcall.com/v1/browser-call/phone-numbers \  -H "Authorization: Bearer jc_live_..."
POST/v1/browser-call/token

Generate a Twilio access token for browser-based WebRTC calling. Without a body the identity is the org-wide ``api_org_<org_id>``. With ``client_identity`` it is ``p_<org_id>_<client_identity>``: a browser that partner routing can ring by itself.

Parameters

platformstringoptional

One of: web, ios, android. Defaults to "web".

Request body

json
{  "client_identity": "string"}

Example

curl
curl -X POST https://jagcall.com/v1/browser-call/token \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"client_identity":"string"}'
POST/v1/browser-call/transfer

Blind-transfer a live browser call to an outside number. The other party hears a hold message, then the target rings (30 s); the softphone's own leg drops once the redirect lands. Only a call that this org's partner browser identity (``api_org_<org_id>``) is on can be transferred. The destination goes through the same toll-fraud and international rules as an outbound call. A plan at its fair-use minute cap is refused ``403 fair_use_limit_reached``, unless the account pays per minute: then the transfer goes through with the new leg capped (``timeLimit``) at what the balance funds, and a balance that no longer funds a minute is ``402 insufficient_balance`` (``details.reason`` = ``fair_use_minutes_balance_low``).

Request body

json
{  "call_sid": "string",  "target_number": "+14155551234"}

Example

curl
curl -X POST https://jagcall.com/v1/browser-call/transfer \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"call_sid":"string","target_number":"+14155551234"}'

Billing

GET/v1/billing/balance

Get current balance for the organization.

Example

curl
curl https://jagcall.com/v1/billing/balance \  -H "Authorization: Bearer jc_live_..."

Integrations

PUT/v1/integrations

Set integration credentials (e.g. Frubix API key, webhook URL) for the org.

Request body

json
{  "frubix_api_key": "string",  "webhook_url": "https://example.com",  "webhook_secret": "string"}

Example

curl
curl -X PUT https://jagcall.com/v1/integrations \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"frubix_api_key":"string","webhook_url":"https://example.com","webhook_secret":"string"}'

Other

GET/v1/oauth/grant

The state of the grant this credential came from. ``refreshTokenExpiresInSeconds`` is the number to alarm on: at zero the grant is gone for good and a human has to reconnect. It is null for an API key, which does not expire that way.

Example

curl
curl https://jagcall.com/v1/oauth/grant \  -H "Authorization: Bearer jc_live_..."
GET/v1/voicemails/{voicemail_id}

One voicemail: who left it, on which number and call, how long, and its transcript.

Parameters

voicemail_idstringrequired

Response

json
{  "id": "id_123",  "call_id": "call_123",  "phone_number_id": "phone_number_123",  "from_number": "+14155551234",  "to_number": "+14155551234",  "duration_seconds": 142,  "transcript": "string",  "transcription_status": "active",  "is_read": false,  "created_at": "2025-11-01T14:30:00Z",  "audio_url": "https://example.com"}

Example

curl
curl https://jagcall.com/v1/voicemails/voicemail_123 \  -H "Authorization: Bearer jc_live_..."
GET/v1/voicemails/{voicemail_id}/audio

Stream the voicemail audio (WAV). Supports ``Range`` requests (206).

Parameters

voicemail_idstringrequired

Example

curl
curl https://jagcall.com/v1/voicemails/voicemail_123/audio \  -H "Authorization: Bearer jc_live_..."
GET/v1/workspaces

List every organization on this billing account, with the allowance. ``isBillingParent`` marks the corporate account itself — pin that id at your end and compare, so a grant established from the wrong JagCall login is caught before any tenant is provisioned into it. ``limit`` is 1 on every plan but Corporate.

Example

curl
curl https://jagcall.com/v1/workspaces \  -H "Authorization: Bearer jc_live_..."
POST/v1/workspaces

Create a child organization, keyed on ``externalId``. Returns 201 for a new organization and **200** when ``externalId`` already named one — the body is identical, so a caller that never distinguishes them is correct either way.

Request body

json
{  "name": "Example",  "externalId": "string"}

Response

json
{  "id": "id_123",  "name": "Example",  "slug": "string",  "externalId": "string"}

Example

curl
curl -X POST https://jagcall.com/v1/workspaces \  -H "Authorization: Bearer jc_live_..." \  -H "Content-Type: application/json" \  -d '{"name":"Example","externalId":"string"}'
DELETE/v1/workspaces/{workspace_id}

Release a workspace when its tenant is deleted. Refuses (400) any organization holding call recordings, transcripts or SMS history, and refuses the billing parent. Treat 400 as "leave it alone" and 404 as "already gone".

Parameters

workspace_idstringrequired

Example

curl
curl -X DELETE https://jagcall.com/v1/workspaces/workspace_123 \  -H "Authorization: Bearer jc_live_..."

Still need help?

Can't find what you're looking for? Send us a message and our team will get back to you.

Contact support