curl --request GET \
--url https://api.galtea.ai/testCases/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.galtea.ai/testCases/{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.galtea.ai/testCases/{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.galtea.ai/testCases/{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.galtea.ai/testCases/{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.galtea.ai/testCases/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.galtea.ai/testCases/{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": "tc_123",
"testId": "test_123",
"userId": "user_123",
"input": {
"user_message": "Summarize this contract",
"content": [
{
"type": "file",
"uri": "https://files.galtea.ai/files/org_123/2f6c….pdf",
"filename": "contrato-arrendamiento.pdf",
"mimeType": "application/pdf",
"sizeBytes": 1468006
}
]
},
"expectedOutput": "Paris",
"expectedTools": [
"search",
"calculator"
],
"context": {
"value": "Geography question"
},
"source": "manual",
"sourceFile": "<string>",
"confidence": 0.95,
"confidenceReason": "High quality data",
"variant": "VARIANT_1",
"strategy": "STRATEGY_1",
"languageCode": "es-MX",
"gender": "FEMALE",
"backgroundNoiseProfile": "street",
"backgroundNoiseLevel": "medium",
"userPersona": "Student",
"scenario": "Educational quiz",
"goal": "Test geographical knowledge",
"archetype": "data_grounded",
"specRelevance": "direct",
"stoppingCriterias": [
"MAX_ITERATIONS",
"GOAL_ACHIEVED"
],
"maxIterations": 10,
"isAugmented": false,
"reviewedById": "user_456",
"userScore": 5,
"userScoreReason": "Accurate and complete",
"creditsUsed": 1,
"sourceTestCaseId": "<string>",
"testCaseGroupId": "testCaseGroup_123",
"parentTestCaseId": "<string>",
"legacyAt": "2023-11-07T05:31:56Z",
"seedSessionId": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"deletedAt": "2023-11-07T05:31:56Z"
}{
"error": "Error type",
"message": "Error message description"
}{
"error": "Error type",
"message": "Error message description"
}Get test case by ID
Get a specific test case by ID. See Datasets.
curl --request GET \
--url https://api.galtea.ai/testCases/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.galtea.ai/testCases/{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.galtea.ai/testCases/{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.galtea.ai/testCases/{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.galtea.ai/testCases/{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.galtea.ai/testCases/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.galtea.ai/testCases/{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": "tc_123",
"testId": "test_123",
"userId": "user_123",
"input": {
"user_message": "Summarize this contract",
"content": [
{
"type": "file",
"uri": "https://files.galtea.ai/files/org_123/2f6c….pdf",
"filename": "contrato-arrendamiento.pdf",
"mimeType": "application/pdf",
"sizeBytes": 1468006
}
]
},
"expectedOutput": "Paris",
"expectedTools": [
"search",
"calculator"
],
"context": {
"value": "Geography question"
},
"source": "manual",
"sourceFile": "<string>",
"confidence": 0.95,
"confidenceReason": "High quality data",
"variant": "VARIANT_1",
"strategy": "STRATEGY_1",
"languageCode": "es-MX",
"gender": "FEMALE",
"backgroundNoiseProfile": "street",
"backgroundNoiseLevel": "medium",
"userPersona": "Student",
"scenario": "Educational quiz",
"goal": "Test geographical knowledge",
"archetype": "data_grounded",
"specRelevance": "direct",
"stoppingCriterias": [
"MAX_ITERATIONS",
"GOAL_ACHIEVED"
],
"maxIterations": 10,
"isAugmented": false,
"reviewedById": "user_456",
"userScore": 5,
"userScoreReason": "Accurate and complete",
"creditsUsed": 1,
"sourceTestCaseId": "<string>",
"testCaseGroupId": "testCaseGroup_123",
"parentTestCaseId": "<string>",
"legacyAt": "2023-11-07T05:31:56Z",
"seedSessionId": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"deletedAt": "2023-11-07T05:31:56Z"
}{
"error": "Error type",
"message": "Error message description"
}{
"error": "Error type",
"message": "Error message description"
}Authorizations
Response
Test case retrieved successfully
Structured input data. For plain text input, format is { user_message: "..." }. Uploaded files ride a content array of parts, each { type: "file", uri, filename, mimeType }, beside an optional user_message. mimeType is filled from the stored object when omitted. filename is filled only where the storage records it: AWS does, Azure Blob does not, so send filename on an Azure deployment. Every file part is returned with a server-measured sizeBytes; a value sent for it is ignored.
{
"user_message": "Summarize this contract",
"content": [
{
"type": "file",
"uri": "https://files.galtea.ai/files/org_123/2f6c….pdf",
"filename": "contrato-arrendamiento.pdf",
"mimeType": "application/pdf",
"sizeBytes": 1468006
}
]
}
BCP-47 language tag (e.g. en, es-MX). The region subtag selects the regional variety in simulated user messages and voice synthesis; generated test text keeps the base language. The value is stored as the full tag. A bare code for ca, de, es, eu, fr, gl, it, nl or pt defaults to the European variety of that language, in simulated user messages only (pt -> pt-PT); an explicit region always overrides it, and neither voice synthesis nor the stored value is affected.
"es-MX"
Background noise mixed into the simulated caller audio during a voice test. Clip-backed (office, street, car) or synthetic (white, pink). Null means off; set together with backgroundNoiseLevel.
office, street, car, white, pink "street"
Read and write mean different things here, and the two ids are never the same session. On a response it is the seed session holding this test case predefined conversation, or null when it has none. On a request it is the SOURCE session to copy, which must be a session of this test product. The API answers with the id of the copy it made, never with the id you sent. Omit it, send null, or send back the id the response gave you, and the predefined conversation stays as it is. There is no way to remove a predefined conversation. Cannot be sent together with conversationHistory, the other way to give this test case a conversation.