Get Call Session Detail
curl --request GET \
--url https://api.ravan.ai/api/v1/calling/call-sessions-detail/{id} \
--header 'X-Api-Key: <api-key>'import requests
url = "https://api.ravan.ai/api/v1/calling/call-sessions-detail/{id}"
headers = {"X-Api-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-Api-Key': '<api-key>'}};
fetch('https://api.ravan.ai/api/v1/calling/call-sessions-detail/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.ravan.ai/api/v1/calling/call-sessions-detail/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Api-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.ravan.ai/api/v1/calling/call-sessions-detail/{id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Api-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.ravan.ai/api/v1/calling/call-sessions-detail/{id}")
.header("X-Api-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ravan.ai/api/v1/calling/call-sessions-detail/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Api-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"success": <boolean>,
"message": "<string>",
"data": {
"id": "<string>",
"agent_id": "<string>",
"agent_name": "<string>",
"organization_id": "<string>",
"caller_number": "<string>",
"callee_number": "<string>",
"channel": "<string>",
"status": "<string>",
"recording_url": "<string>",
"duration_sec": <integer>,
"cost_total": "<string>",
"credit_breakdown": {
"channel": "<string>",
"duration_sec": <integer>,
"model_credits": <number>,
"provider_credits": <number>,
"provider_managed": <boolean>,
"telephony_type": "<string>",
"total_credits": <number>
},
"disconnect_reason": "<string>",
"metadata": {},
"post_call_analysis_result": {},
"started_at": "<string>",
"ended_at": "<string>",
"created_at": "<string>",
"transcripts": []
}
}
Calling API
Get Call Session Detail
Get Call Session Detail with Transcripts.
GET
/
api
/
v1
/
calling
/
call-sessions-detail
/
{id}
Get Call Session Detail
curl --request GET \
--url https://api.ravan.ai/api/v1/calling/call-sessions-detail/{id} \
--header 'X-Api-Key: <api-key>'import requests
url = "https://api.ravan.ai/api/v1/calling/call-sessions-detail/{id}"
headers = {"X-Api-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-Api-Key': '<api-key>'}};
fetch('https://api.ravan.ai/api/v1/calling/call-sessions-detail/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.ravan.ai/api/v1/calling/call-sessions-detail/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Api-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.ravan.ai/api/v1/calling/call-sessions-detail/{id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Api-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.ravan.ai/api/v1/calling/call-sessions-detail/{id}")
.header("X-Api-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ravan.ai/api/v1/calling/call-sessions-detail/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Api-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"success": <boolean>,
"message": "<string>",
"data": {
"id": "<string>",
"agent_id": "<string>",
"agent_name": "<string>",
"organization_id": "<string>",
"caller_number": "<string>",
"callee_number": "<string>",
"channel": "<string>",
"status": "<string>",
"recording_url": "<string>",
"duration_sec": <integer>,
"cost_total": "<string>",
"credit_breakdown": {
"channel": "<string>",
"duration_sec": <integer>,
"model_credits": <number>,
"provider_credits": <number>,
"provider_managed": <boolean>,
"telephony_type": "<string>",
"total_credits": <number>
},
"disconnect_reason": "<string>",
"metadata": {},
"post_call_analysis_result": {},
"started_at": "<string>",
"ended_at": "<string>",
"created_at": "<string>",
"transcripts": []
}
}
Authorizations
string
required
Your Agni API key used to authenticate the request. Pass it in the
X-Api-Key header. Find or rotate it from your Ravan AI account settings.Path Parameters
string
required
The unique ID of the resource in the path. Use the ID returned by the related create or list endpoint.
Response
boolean
Whether the request succeeded.
string
Human-readable status message.
object
Full call session with embedded transcripts.
Show data
Show data
string
Session ID
string
Agent ID
string
Agent name
string
Organization ID
string
Caller phone number
string
Callee phone number
string
Call channel
string
Call status
string
Pre-signed recording URL
integer
Duration in seconds
string
Total call cost
object
Credit usage breakdown for the call
string
Reason for disconnect
object
Custom metadata
object
Post-call analysis result
string
Start timestamp
string
End timestamp
string
Creation timestamp
array
Array of transcript entries
{
"success": <boolean>,
"message": "<string>",
"data": {
"id": "<string>",
"agent_id": "<string>",
"agent_name": "<string>",
"organization_id": "<string>",
"caller_number": "<string>",
"callee_number": "<string>",
"channel": "<string>",
"status": "<string>",
"recording_url": "<string>",
"duration_sec": <integer>,
"cost_total": "<string>",
"credit_breakdown": {
"channel": "<string>",
"duration_sec": <integer>,
"model_credits": <number>,
"provider_credits": <number>,
"provider_managed": <boolean>,
"telephony_type": "<string>",
"total_credits": <number>
},
"disconnect_reason": "<string>",
"metadata": {},
"post_call_analysis_result": {},
"started_at": "<string>",
"ended_at": "<string>",
"created_at": "<string>",
"transcripts": []
}
}
Authorizations
Path Parameters
Call session ID
Response
200 - application/json
Successful response
Show child attributes
Show child attributes
Example:
{
"id": "<string>",
"agent_id": "<string>",
"agent_name": "<string>",
"organization_id": "<string>",
"caller_number": "<string>",
"callee_number": "<string>",
"channel": "<string>",
"status": "<string>",
"recording_url": "<string>",
"duration_sec": 0,
"cost_total": "<string>",
"credit_breakdown": {
"channel": "<string>",
"duration_sec": 0,
"model_credits": 0,
"provider_credits": 0,
"provider_managed": true,
"telephony_type": "<string>",
"total_credits": 0
},
"disconnect_reason": "<string>",
"metadata": {},
"post_call_analysis_result": {},
"started_at": "<string>",
"ended_at": "<string>",
"created_at": "<string>",
"transcripts": []
}
⌘I

