curl --request GET \
--url https://api.openmic.ai/v1/call/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.openmic.ai/v1/call/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.openmic.ai/v1/call/{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.openmic.ai/v1/call/{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 => [
"Authorization: Bearer <token>"
],
]);
$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.openmic.ai/v1/call/{id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.openmic.ai/v1/call/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.openmic.ai/v1/call/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"call_type": "phonecall",
"from_number": "+1234567890",
"to_number": "+0987654321",
"direction": "outbound",
"call_id": "cmbbvrg8wzi487w02m2bc7dji",
"agent_id": "bvrg8wzi487w02m2bc7dh0ev",
"call_status": "ended",
"customer_id": "customer_001",
"start_timestamp": 1678886400000,
"end_timestamp": 1678886700000,
"duration_ms": 300000,
"transcript": [
[
"assistant",
"Hello! How can I help you today?"
],
[
"user",
"I'd like to schedule an appointment."
],
[
"assistant",
"I'd be happy to help you schedule an appointment. What type of service are you looking for?"
]
],
"recording_url": "https://recordings.openmic.ai/call_98765.mp3",
"latency": {
"e2e_min_latency": 0.5,
"e2e_median_latency": 1.2,
"e2e_p90_latency": 2.1,
"llm_min_latency": 0.3,
"llm_median_latency": 0.8,
"llm_p90_latency": 1.5,
"tts_min_latency": 0.2,
"tts_median_latency": 0.4,
"tts_p90_latency": 0.6
},
"call_analysis": {
"summary": "Customer called to schedule an appointment and was successfully assisted.",
"is_successful": true,
"success_evaluation": "excellent",
"extracted_data": null
},
"call_cost": {
"total_cost": 0.0822,
"llm_cost": 0.0052548,
"tts_cost": 0.0242269,
"stt_cost": 0.0527183
},
"dynamic_variables": {
"name": "John"
}
}{
"error": "Missing or invalid organization information"
}{
"error": "Unauthorized",
"message": "Invalid or expired API key"
}{
"error": "Call with the specified ID was not found."
}{
"error": "An unexpected error occurred. Please try again later."
}Get Call
Retrieve details of a specific call by its ID.
curl --request GET \
--url https://api.openmic.ai/v1/call/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.openmic.ai/v1/call/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.openmic.ai/v1/call/{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.openmic.ai/v1/call/{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 => [
"Authorization: Bearer <token>"
],
]);
$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.openmic.ai/v1/call/{id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.openmic.ai/v1/call/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.openmic.ai/v1/call/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"call_type": "phonecall",
"from_number": "+1234567890",
"to_number": "+0987654321",
"direction": "outbound",
"call_id": "cmbbvrg8wzi487w02m2bc7dji",
"agent_id": "bvrg8wzi487w02m2bc7dh0ev",
"call_status": "ended",
"customer_id": "customer_001",
"start_timestamp": 1678886400000,
"end_timestamp": 1678886700000,
"duration_ms": 300000,
"transcript": [
[
"assistant",
"Hello! How can I help you today?"
],
[
"user",
"I'd like to schedule an appointment."
],
[
"assistant",
"I'd be happy to help you schedule an appointment. What type of service are you looking for?"
]
],
"recording_url": "https://recordings.openmic.ai/call_98765.mp3",
"latency": {
"e2e_min_latency": 0.5,
"e2e_median_latency": 1.2,
"e2e_p90_latency": 2.1,
"llm_min_latency": 0.3,
"llm_median_latency": 0.8,
"llm_p90_latency": 1.5,
"tts_min_latency": 0.2,
"tts_median_latency": 0.4,
"tts_p90_latency": 0.6
},
"call_analysis": {
"summary": "Customer called to schedule an appointment and was successfully assisted.",
"is_successful": true,
"success_evaluation": "excellent",
"extracted_data": null
},
"call_cost": {
"total_cost": 0.0822,
"llm_cost": 0.0052548,
"tts_cost": 0.0242269,
"stt_cost": 0.0527183
},
"dynamic_variables": {
"name": "John"
}
}{
"error": "Missing or invalid organization information"
}{
"error": "Unauthorized",
"message": "Invalid or expired API key"
}{
"error": "Call with the specified ID was not found."
}{
"error": "An unexpected error occurred. Please try again later."
}Authorizations
API key authentication. Include your API key in the Authorization header as: Authorization: Bearer <your-api-key>
Path Parameters
The unique identifier of the call
Response
Call details retrieved successfully
Type of call
phonecall, webcall Originating phone number
Destination phone number
Call direction
inbound, outbound Unique call identifier
Bot/agent identifier
Current call status
registered, ongoing, ended, error Customer identifier
Telephony system identifiers
Call start time (Unix timestamp in milliseconds)
Call end time (Unix timestamp in milliseconds)
Call duration in milliseconds
Call transcript as array of [speaker, message] pairs
Transcript entry with [speaker, message] format
2 elementsURL to call recording
Latency metrics for different components
Show child attributes
Show child attributes
Post-call analysis results including summary and success metrics
Show child attributes
Show child attributes
Detailed cost breakdown for the call
Show child attributes
Show child attributes
Send dynamic variables in key value pairs to replace in the prompt.
{ "name": "John" }
Was this page helpful?