curl --request POST \
--url https://beta.getsales.io/unibox/v1/api/agent-tests \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Team-SID: <api-key>' \
--data '
{
"conversation_sid": "<string>",
"from_message_sid": "<string>"
}
'import requests
url = "https://beta.getsales.io/unibox/v1/api/agent-tests"
payload = {
"conversation_sid": "<string>",
"from_message_sid": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Team-SID": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
Authorization: 'Bearer <token>',
'Team-SID': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({conversation_sid: '<string>', from_message_sid: '<string>'})
};
fetch('https://beta.getsales.io/unibox/v1/api/agent-tests', 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://beta.getsales.io/unibox/v1/api/agent-tests",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'conversation_sid' => '<string>',
'from_message_sid' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"Team-SID: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://beta.getsales.io/unibox/v1/api/agent-tests"
payload := strings.NewReader("{\n \"conversation_sid\": \"<string>\",\n \"from_message_sid\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Team-SID", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://beta.getsales.io/unibox/v1/api/agent-tests")
.header("Authorization", "Bearer <token>")
.header("Team-SID", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"conversation_sid\": \"<string>\",\n \"from_message_sid\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://beta.getsales.io/unibox/v1/api/agent-tests")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Team-SID"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"conversation_sid\": \"<string>\",\n \"from_message_sid\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"operation": "create",
"item": {
"sid": "<string>",
"team_sid": "<string>",
"agent_sid": "<string>",
"conversation_sid": "<string>",
"from_message_sid": "<string>",
"state": "running",
"created_by": {
"actor_type": "user",
"actor_sid": "<string>",
"team_sid": "<string>",
"permissions": {},
"actor_name": "<string>",
"oauth_client_sid": "<string>",
"reason": "<string>",
"cluster_id": 123,
"trace_id": "<string>"
},
"classify_run_sid": "<string>",
"reply_run_sid": "<string>",
"read": {
"scenario_key": "<string>",
"confidence": 123,
"summary": "<string>",
"reason": "<string>",
"custom_scenario_sid": "<string>",
"questions": [
"<string>"
],
"knowledge_miss": "<string>",
"level": {
"scenario_key": "<string>",
"setting": "<string>",
"level": "<string>",
"condition": "<string>",
"condition_kind": "<string>"
},
"hand_off": {
"trigger": "<string>",
"custom_trigger": "<string>",
"note": "<string>"
}
},
"reply": {
"kind": "plan",
"none_reason": "level_off",
"text": "<string>",
"files": [
{
"name": "<string>"
}
],
"checks": [
{
"check": "<string>",
"passed": true
}
],
"dialog": {
"stage": "<string>",
"move": "<string>",
"no_reply": true
},
"note": "<string>"
},
"person": {
"message_sid": "<string>",
"text": "<string>",
"author": "<string>",
"at": "<string>",
"minutes_after": 123
},
"error_code": "<string>",
"cost_usd": 123,
"created_at": "<string>",
"updated_at": "<string>"
},
"already_exists": true,
"meta": {
"trace_id": "<string>",
"span_id": "<string>",
"timestamp": "<string>",
"duration_ms": 1,
"team_sid": "<string>",
"actor_type": "<string>"
}
}{
"success": false,
"error": {
"code": "validation_failed",
"message": "<string>",
"recoverable": true,
"suggestion": "<string>",
"field_errors": {},
"blockers": [
{
"type": "<string>",
"severity": "hard",
"description": "<string>",
"entity_sid": "<string>",
"resolution": "<string>",
"resolution_hint": "<string>",
"count": 123
}
],
"context": {}
},
"meta": {
"trace_id": "<string>",
"span_id": "<string>",
"timestamp": "<string>",
"duration_ms": 1,
"team_sid": "<string>",
"actor_type": "<string>"
}
}{
"success": false,
"error": {
"code": "validation_failed",
"message": "<string>",
"recoverable": true,
"suggestion": "<string>",
"field_errors": {},
"blockers": [
{
"type": "<string>",
"severity": "hard",
"description": "<string>",
"entity_sid": "<string>",
"resolution": "<string>",
"resolution_hint": "<string>",
"count": 123
}
],
"context": {}
},
"meta": {
"trace_id": "<string>",
"span_id": "<string>",
"timestamp": "<string>",
"duration_ms": 1,
"team_sid": "<string>",
"actor_type": "<string>"
}
}Test the AI SDR on a reply
Test the AI SDR on a real reply: the thread, and the lead’s message to answer (its newest when omitted). It reads the thread up to that message and nothing after it, classifies it and writes the reply it would send, as a test: every check runs, nothing is sent, booked, written to the thread or learned. Comes back running: read it with get_agent_test until done, then compare reply.text with person.text, what a person answered. 422 no_lead_message, 503 runtime_unavailable.
Contract:
- MCP tool
start_agent_test, registry packagemcp.unibox/agent_tests, mountunibox.agent-memory. - Operation
create, response envelopecreate. - Flags: none.
curl --request POST \
--url https://beta.getsales.io/unibox/v1/api/agent-tests \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Team-SID: <api-key>' \
--data '
{
"conversation_sid": "<string>",
"from_message_sid": "<string>"
}
'import requests
url = "https://beta.getsales.io/unibox/v1/api/agent-tests"
payload = {
"conversation_sid": "<string>",
"from_message_sid": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Team-SID": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
Authorization: 'Bearer <token>',
'Team-SID': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({conversation_sid: '<string>', from_message_sid: '<string>'})
};
fetch('https://beta.getsales.io/unibox/v1/api/agent-tests', 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://beta.getsales.io/unibox/v1/api/agent-tests",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'conversation_sid' => '<string>',
'from_message_sid' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"Team-SID: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://beta.getsales.io/unibox/v1/api/agent-tests"
payload := strings.NewReader("{\n \"conversation_sid\": \"<string>\",\n \"from_message_sid\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Team-SID", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://beta.getsales.io/unibox/v1/api/agent-tests")
.header("Authorization", "Bearer <token>")
.header("Team-SID", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"conversation_sid\": \"<string>\",\n \"from_message_sid\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://beta.getsales.io/unibox/v1/api/agent-tests")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Team-SID"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"conversation_sid\": \"<string>\",\n \"from_message_sid\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"operation": "create",
"item": {
"sid": "<string>",
"team_sid": "<string>",
"agent_sid": "<string>",
"conversation_sid": "<string>",
"from_message_sid": "<string>",
"state": "running",
"created_by": {
"actor_type": "user",
"actor_sid": "<string>",
"team_sid": "<string>",
"permissions": {},
"actor_name": "<string>",
"oauth_client_sid": "<string>",
"reason": "<string>",
"cluster_id": 123,
"trace_id": "<string>"
},
"classify_run_sid": "<string>",
"reply_run_sid": "<string>",
"read": {
"scenario_key": "<string>",
"confidence": 123,
"summary": "<string>",
"reason": "<string>",
"custom_scenario_sid": "<string>",
"questions": [
"<string>"
],
"knowledge_miss": "<string>",
"level": {
"scenario_key": "<string>",
"setting": "<string>",
"level": "<string>",
"condition": "<string>",
"condition_kind": "<string>"
},
"hand_off": {
"trigger": "<string>",
"custom_trigger": "<string>",
"note": "<string>"
}
},
"reply": {
"kind": "plan",
"none_reason": "level_off",
"text": "<string>",
"files": [
{
"name": "<string>"
}
],
"checks": [
{
"check": "<string>",
"passed": true
}
],
"dialog": {
"stage": "<string>",
"move": "<string>",
"no_reply": true
},
"note": "<string>"
},
"person": {
"message_sid": "<string>",
"text": "<string>",
"author": "<string>",
"at": "<string>",
"minutes_after": 123
},
"error_code": "<string>",
"cost_usd": 123,
"created_at": "<string>",
"updated_at": "<string>"
},
"already_exists": true,
"meta": {
"trace_id": "<string>",
"span_id": "<string>",
"timestamp": "<string>",
"duration_ms": 1,
"team_sid": "<string>",
"actor_type": "<string>"
}
}{
"success": false,
"error": {
"code": "validation_failed",
"message": "<string>",
"recoverable": true,
"suggestion": "<string>",
"field_errors": {},
"blockers": [
{
"type": "<string>",
"severity": "hard",
"description": "<string>",
"entity_sid": "<string>",
"resolution": "<string>",
"resolution_hint": "<string>",
"count": 123
}
],
"context": {}
},
"meta": {
"trace_id": "<string>",
"span_id": "<string>",
"timestamp": "<string>",
"duration_ms": 1,
"team_sid": "<string>",
"actor_type": "<string>"
}
}{
"success": false,
"error": {
"code": "validation_failed",
"message": "<string>",
"recoverable": true,
"suggestion": "<string>",
"field_errors": {},
"blockers": [
{
"type": "<string>",
"severity": "hard",
"description": "<string>",
"entity_sid": "<string>",
"resolution": "<string>",
"resolution_hint": "<string>",
"count": 123
}
],
"context": {}
},
"meta": {
"trace_id": "<string>",
"span_id": "<string>",
"timestamp": "<string>",
"duration_ms": 1,
"team_sid": "<string>",
"actor_type": "<string>"
}
}Authorizations
Access token issued by gs.service.id. Its access_identity claim carries team_sid, actor_sid and actor_type, and that team scope is authoritative.
Team scope for tokens that do not carry one. Ignored when the token already names a team.
Body
Request body of start_agent_test.
The thread to test on (ub_cv_…).
18^ub_cv_The lead's message to answer (ub_ms_…); the thread's newest message of the lead's when omitted. The thread is read up to it and nothing after it.
18^ub_ms_