Get trace details
curl --request GET \
--url https://control-plane.kubiya.ai/api/v1/traces/{trace_id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://control-plane.kubiya.ai/api/v1/traces/{trace_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://control-plane.kubiya.ai/api/v1/traces/{trace_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://control-plane.kubiya.ai/api/v1/traces/{trace_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://control-plane.kubiya.ai/api/v1/traces/{trace_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://control-plane.kubiya.ai/api/v1/traces/{trace_id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://control-plane.kubiya.ai/api/v1/traces/{trace_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{
"id": "<string>",
"trace_id": "<string>",
"organization_id": "<string>",
"name": "<string>",
"started_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"service_name": "<string>",
"execution_id": "<string>",
"execution_type": "<string>",
"user_id": "<string>",
"user_email": "<string>",
"user_name": "<string>",
"user_avatar": "<string>",
"ended_at": "2023-11-07T05:31:56Z",
"duration_ms": 123,
"span_count": 0,
"error_count": 0,
"updated_at": "2023-11-07T05:31:56Z",
"spans": [
{
"id": "<string>",
"trace_id": "<string>",
"span_id": "<string>",
"organization_id": "<string>",
"name": "<string>",
"start_time_unix_nano": 123,
"created_at": "2023-11-07T05:31:56Z",
"parent_span_id": "<string>",
"status_message": "<string>",
"end_time_unix_nano": 123,
"duration_ns": 123,
"duration_ms": 123,
"attributes": {},
"resource_attributes": {},
"events": [
{}
],
"links": [
{}
],
"children": "<array>"
}
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}API Reference
Get trace details
Get detailed trace information with all spans in tree structure
GET
/
api
/
v1
/
traces
/
{trace_id}
Get trace details
curl --request GET \
--url https://control-plane.kubiya.ai/api/v1/traces/{trace_id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://control-plane.kubiya.ai/api/v1/traces/{trace_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://control-plane.kubiya.ai/api/v1/traces/{trace_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://control-plane.kubiya.ai/api/v1/traces/{trace_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://control-plane.kubiya.ai/api/v1/traces/{trace_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://control-plane.kubiya.ai/api/v1/traces/{trace_id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://control-plane.kubiya.ai/api/v1/traces/{trace_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{
"id": "<string>",
"trace_id": "<string>",
"organization_id": "<string>",
"name": "<string>",
"started_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"service_name": "<string>",
"execution_id": "<string>",
"execution_type": "<string>",
"user_id": "<string>",
"user_email": "<string>",
"user_name": "<string>",
"user_avatar": "<string>",
"ended_at": "2023-11-07T05:31:56Z",
"duration_ms": 123,
"span_count": 0,
"error_count": 0,
"updated_at": "2023-11-07T05:31:56Z",
"spans": [
{
"id": "<string>",
"trace_id": "<string>",
"span_id": "<string>",
"organization_id": "<string>",
"name": "<string>",
"start_time_unix_nano": 123,
"created_at": "2023-11-07T05:31:56Z",
"parent_span_id": "<string>",
"status_message": "<string>",
"end_time_unix_nano": 123,
"duration_ns": 123,
"duration_ms": 123,
"attributes": {},
"resource_attributes": {},
"events": [
{}
],
"links": [
{}
],
"children": "<array>"
}
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Authorizations
Enter your Kubiya API token (format: Bearer )
Path Parameters
Query Parameters
Return spans as flat list instead of tree
Response
Successful Response
Detailed trace response with spans
Trace status enum
Available options:
success, error, running Show child attributes
Show child attributes
Was this page helpful?
⌘I