curl --request GET \
--url https://api.wave.sa/v1/calls \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.wave.sa/v1/calls"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.wave.sa/v1/calls', 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.wave.sa/v1/calls",
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.wave.sa/v1/calls"
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.wave.sa/v1/calls")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.wave.sa/v1/calls")
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{
"data": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"type": "callback",
"status": "initiated",
"from": "<string>",
"to_masked": "+966 50 XXX 0000",
"duration_seconds": 123,
"sandbox_variant": "<string>",
"environment": "sandbox",
"queue_id": "<string>",
"disposition": "<string>",
"campaign_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"machine_detection_result": "human",
"price_sar": "0.37",
"beta_feature": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"answered_at": "2023-11-07T05:31:56Z",
"ended_at": "2023-11-07T05:31:56Z"
}
],
"next_cursor": "<string>",
"limit": 123
}{
"error_code": "INVALID_API_KEY",
"message": "<string>",
"message_ar": "<string>",
"request_id": "<string>",
"docs_url": "<string>"
}{
"error_code": "INVALID_API_KEY",
"message": "<string>",
"message_ar": "<string>",
"request_id": "<string>",
"docs_url": "<string>"
}{
"error_code": "INVALID_API_KEY",
"message": "<string>",
"message_ar": "<string>",
"request_id": "<string>",
"docs_url": "<string>"
}List call logs
Returns the project’s call logs (CDR), newest first, with masked customer numbers. Requires the calls:read scope.
Two ways to page. Cursor mode (the default): send cursor and limit; the answer has next_cursor (pass it back as cursor; null on the last page). Page mode: send page and/or page_size; the answer has total_count, page and page_size. Send one mode, not both: cursor together with page or page_size is a 400. Existing clients that send only cursor and limit are not affected.
Filters work in both modes and can be combined. from and to are inclusive and filter on the time the call was created; with neither, all calls are returned (there is no default range). from must not be later than to. status takes one raw call status. queue_id matches calls that carry a queue id; only callback calls carry one, so web-calling and inbound calls never match.
Environments. A sandbox key (sk_sandbox_) lists, reads and acts on sandbox rows only; a production key (sk_live_) on production rows only. A row of the other environment returns 404, as if it did not exist. This also holds for the in-call control, transfer, conference and recording routes of a call.
curl --request GET \
--url https://api.wave.sa/v1/calls \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.wave.sa/v1/calls"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.wave.sa/v1/calls', 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.wave.sa/v1/calls",
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.wave.sa/v1/calls"
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.wave.sa/v1/calls")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.wave.sa/v1/calls")
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{
"data": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"type": "callback",
"status": "initiated",
"from": "<string>",
"to_masked": "+966 50 XXX 0000",
"duration_seconds": 123,
"sandbox_variant": "<string>",
"environment": "sandbox",
"queue_id": "<string>",
"disposition": "<string>",
"campaign_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"machine_detection_result": "human",
"price_sar": "0.37",
"beta_feature": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"answered_at": "2023-11-07T05:31:56Z",
"ended_at": "2023-11-07T05:31:56Z"
}
],
"next_cursor": "<string>",
"limit": 123
}{
"error_code": "INVALID_API_KEY",
"message": "<string>",
"message_ar": "<string>",
"request_id": "<string>",
"docs_url": "<string>"
}{
"error_code": "INVALID_API_KEY",
"message": "<string>",
"message_ar": "<string>",
"request_id": "<string>",
"docs_url": "<string>"
}{
"error_code": "INVALID_API_KEY",
"message": "<string>",
"message_ar": "<string>",
"request_id": "<string>",
"docs_url": "<string>"
}Authorizations
Your API key from the Wave dashboard. Sandbox keys start sk_sandbox_; production keys start sk_live_. Send as Authorization: Bearer <key>. Some endpoints require a production key and specific scopes.
Query Parameters
Cursor mode: the next_cursor of the previous page. Cannot be sent with page or page_size.
Cursor mode: page size.
1 <= x <= 100Page mode: the page number, starting at 1. Cannot be sent with cursor.
x >= 1Page mode: calls per page (default 20). Cannot be sent with cursor.
1 <= x <= 100Only calls with this status (one raw value).
initiated, ringing, answered, ended, missed, failed, cancelled, timeout Only calls created at or after this time (ISO 8601 date-time).
Only calls created at or before this time (ISO 8601 date-time).
Only calls from this queue. Only callback calls carry a queue id.
Only calls that this API key placed (a UUID). A revoked key of the project works too.
sandbox or production. An API key reads only its own key environment: leave this out, or send the key's own value. Another value returns 400 VALIDATION_ERROR.
sandbox, production 
