/logs/api
curl --request GET \
--url https://api.daily.co/v1/logs/api \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.daily.co/v1/logs/api"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.daily.co/v1/logs/api', 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.daily.co/v1/logs/api",
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.daily.co/v1/logs/api"
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.daily.co/v1/logs/api")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.daily.co/v1/logs/api")
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[
{
"id": "aaaaaaaa-0000-0000-0000-000000000001",
"userId": "bbbbbbbb-0000-0000-0000-000000000001",
"domainId": "cccccccc-0000-0000-0000-000000000001",
"source": "api",
"ip": "203.0.113.10",
"method": "GET",
"url": "/v1/rooms",
"status": 200,
"createdAt": "2024-03-15T18:42:00.000Z",
"request": null,
"response": "{\"total_count\":3,\"data\":[{\"id\":\"room-1\",\"name\":\"hello\"},{\"id\":\"room-2\",\"name\":\"world\"},{\"id\":\"room-3\",\"name\":\"test\"}]}"
},
{
"id": "aaaaaaaa-0000-0000-0000-000000000002",
"userId": "bbbbbbbb-0000-0000-0000-000000000001",
"domainId": "cccccccc-0000-0000-0000-000000000001",
"source": "api",
"ip": "203.0.113.10",
"method": "POST",
"url": "/v1/rooms",
"status": 200,
"createdAt": "2024-03-15T18:41:30.000Z",
"request": "{\"name\":\"my-room\",\"properties\":{\"exp\":1710527690}}",
"response": "{\"id\":\"aaaaaaaa-0000-0000-0000-000000000099\",\"name\":\"my-room\",\"api_created\":true}"
},
{
"id": "aaaaaaaa-0000-0000-0000-000000000003",
"userId": "bbbbbbbb-0000-0000-0000-000000000001",
"domainId": "cccccccc-0000-0000-0000-000000000001",
"source": "api",
"ip": "203.0.113.10",
"method": "POST",
"url": "/v1/meeting-tokens",
"status": 400,
"createdAt": "2024-03-15T18:41:00.000Z",
"request": "{\"properties\":{\"room_name\":\"nonexistent-room\"}}",
"response": "{\"error\":\"invalid-request-error\",\"info\":\"room not found\"}"
}
]{
"info": "\"source\" must be one of [webhook, api] [Received source=\"api\"]\n",
"error": "invalid-request-error"
}Logs
List API Logs
GET
/
logs
/
api
/logs/api
curl --request GET \
--url https://api.daily.co/v1/logs/api \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.daily.co/v1/logs/api"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.daily.co/v1/logs/api', 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.daily.co/v1/logs/api",
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.daily.co/v1/logs/api"
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.daily.co/v1/logs/api")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.daily.co/v1/logs/api")
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[
{
"id": "aaaaaaaa-0000-0000-0000-000000000001",
"userId": "bbbbbbbb-0000-0000-0000-000000000001",
"domainId": "cccccccc-0000-0000-0000-000000000001",
"source": "api",
"ip": "203.0.113.10",
"method": "GET",
"url": "/v1/rooms",
"status": 200,
"createdAt": "2024-03-15T18:42:00.000Z",
"request": null,
"response": "{\"total_count\":3,\"data\":[{\"id\":\"room-1\",\"name\":\"hello\"},{\"id\":\"room-2\",\"name\":\"world\"},{\"id\":\"room-3\",\"name\":\"test\"}]}"
},
{
"id": "aaaaaaaa-0000-0000-0000-000000000002",
"userId": "bbbbbbbb-0000-0000-0000-000000000001",
"domainId": "cccccccc-0000-0000-0000-000000000001",
"source": "api",
"ip": "203.0.113.10",
"method": "POST",
"url": "/v1/rooms",
"status": 200,
"createdAt": "2024-03-15T18:41:30.000Z",
"request": "{\"name\":\"my-room\",\"properties\":{\"exp\":1710527690}}",
"response": "{\"id\":\"aaaaaaaa-0000-0000-0000-000000000099\",\"name\":\"my-room\",\"api_created\":true}"
},
{
"id": "aaaaaaaa-0000-0000-0000-000000000003",
"userId": "bbbbbbbb-0000-0000-0000-000000000001",
"domainId": "cccccccc-0000-0000-0000-000000000001",
"source": "api",
"ip": "203.0.113.10",
"method": "POST",
"url": "/v1/meeting-tokens",
"status": 400,
"createdAt": "2024-03-15T18:41:00.000Z",
"request": "{\"properties\":{\"room_name\":\"nonexistent-room\"}}",
"response": "{\"error\":\"invalid-request-error\",\"info\":\"room not found\"}"
}
]{
"info": "\"source\" must be one of [webhook, api] [Received source=\"api\"]\n",
"error": "invalid-request-error"
}Authorizations
Query Parameters
Given the log ID, will return all records after that ID. See pagination docs
Given the log ID, will return all records before that ID. See pagination docs
Response
200