Calls
Create Web Call
API Reference
Built-in Tools
Custom Tools
Calls
Post-call Analysis
Phone Numbers
- GETRetrieve a paginated list of all phone numbers configured in your PIA Platform account
- POSTCreate a new phone number
- GETRetrieve detailed information about a specific phone number configuration
- DELRemove a phone number configuration from the PIA Platform
- PATCHUpdate the configuration of an existing phone number
Knowledge Bases
Knowledge Bases v2
Prompt Generation
Public Sharing
Calls
Create Web Call
Create a new web-based call session with an AI agent.
This endpoint initializes a new web call session that allows direct browser-based communication between a user and an AI agent. Use this for implementing click-to-call or embedded chat interfaces in web applications.
POST
/
v1
/
calls
/
create-web-call
{
"_id": "<string>",
"ai_agent_id": "<string>",
"ai_agent_name": "<string>",
"call_status": "registered",
"override_ai_agent_id": "<string>",
"metadata": {},
"pia_llm_dynamic_data": {},
"call_start_time": "2023-11-07T05:31:56Z",
"call_end_time": "2023-11-07T05:31:56Z",
"messages": [
{
"role": "agent",
"content": "<string>"
}
],
"recorded_call_audio_url": "<string>",
"access_token": "<string>",
"call_duration_seconds": 123,
"call_type": "web_call",
"call_finish_reason": "user_ended_call"
}
Body
application/json
Response
201
application/json
Successful Response
The response is of type object
.
{
"_id": "<string>",
"ai_agent_id": "<string>",
"ai_agent_name": "<string>",
"call_status": "registered",
"override_ai_agent_id": "<string>",
"metadata": {},
"pia_llm_dynamic_data": {},
"call_start_time": "2023-11-07T05:31:56Z",
"call_end_time": "2023-11-07T05:31:56Z",
"messages": [
{
"role": "agent",
"content": "<string>"
}
],
"recorded_call_audio_url": "<string>",
"access_token": "<string>",
"call_duration_seconds": 123,
"call_type": "web_call",
"call_finish_reason": "user_ended_call"
}