For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Connect
BlogHelp CenterAPI PricingSign up
OverviewElevenCreativeElevenAgentsElevenAPIAPI referenceChangelog
OverviewElevenCreativeElevenAgentsElevenAPIAPI referenceChangelog
  • API reference
    • Introduction
    • Authentication
    • Streaming
  • ElevenAgents
      • GETList tests
      • GETGet test
      • POSTCreate test
      • PUTUpdate test
      • DELDelete test
      • POSTGet test summaries
      • POSTRun tests on agent
  • ElevenAPI
  • ElevenCreative
  • Core Resources
  • Workspace
  • Legacy
  • Conversational AI
LogoLogo
Login
Login
Connect
BlogHelp CenterAPI PricingSign up
ElevenAgentsTests

Update test

PUT
/v1/convai/agent-testing/:test_id
PUT
/v1/convai/agent-testing/:test_id
$curl -X PUT https://api.elevenlabs.io/v1/convai/agent-testing/test_id \
> -H "Content-Type: application/json" \
> -d '{
> "name": "string"
>}'
1{
2 "type": "llm",
3 "id": "string",
4 "name": "string",
5 "chat_history": [
6 {
7 "role": "user",
8 "time_in_call_secs": 1,
9 "agent_metadata": {
10 "agent_id": "string",
11 "branch_id": "string",
12 "workflow_node_id": "string",
13 "version_id": "string"
14 },
15 "message": "string",
16 "multivoice_message": {
17 "parts": [
18 {
19 "text": "string",
20 "voice_label": "string",
21 "time_in_call_secs": 1
22 }
23 ]
24 },
25 "tool_calls": [
26 {
27 "request_id": "string",
28 "tool_name": "string",
29 "params_as_json": "string",
30 "tool_has_been_called": true,
31 "type": "system",
32 "tool_details": {
33 "type": "webhook",
34 "method": "string",
35 "url": "string",
36 "body": "string",
37 "headers": {},
38 "path_params": {},
39 "query_params": {}
40 }
41 }
42 ],
43 "tool_results": [
44 {
45 "request_id": "string",
46 "tool_name": "string",
47 "result_value": "string",
48 "is_error": true,
49 "is_blocked": false,
50 "tool_has_been_called": true,
51 "tool_latency_secs": 0,
52 "error_type": "",
53 "raw_error_message": "",
54 "dynamic_variable_updates": [
55 {
56 "variable_name": "string",
57 "old_value": "string",
58 "new_value": "string",
59 "updated_at": 1.1,
60 "tool_name": "string",
61 "tool_request_id": "string"
62 }
63 ],
64 "type": "client"
65 }
66 ],
67 "feedback": {
68 "score": "like",
69 "time_in_call_secs": 1
70 },
71 "llm_override": "string",
72 "conversation_turn_metrics": {
73 "metrics": {},
74 "convai_asr_provider": "string",
75 "convai_tts_model": "string",
76 "convai_tts_cascade": "string"
77 },
78 "rag_retrieval_info": {
79 "chunks": [
80 {
81 "document_id": "string",
82 "chunk_id": "string",
83 "vector_distance": 1.1
84 }
85 ],
86 "embedding_model": "e5_mistral_7b_instruct",
87 "retrieval_query": "string",
88 "rag_latency_secs": 1.1,
89 "used_chunk_ids": [
90 "string"
91 ]
92 },
93 "llm_usage": {
94 "model_usage": {}
95 },
96 "interrupted": false,
97 "original_message": "string",
98 "source_medium": "audio",
99 "source_event_id": 1,
100 "used_static_kb_document_ids": [
101 "string"
102 ]
103 }
104 ],
105 "conversation_initiation_source": "unknown",
106 "dynamic_variables": {},
107 "failure_examples": [
108 {
109 "response": "string",
110 "type": "string"
111 }
112 ],
113 "from_conversation_metadata": {
114 "conversation_id": "string",
115 "agent_id": "string",
116 "branch_id": "string",
117 "workflow_node_id": "string",
118 "original_agent_reply": [
119 {
120 "role": "user",
121 "time_in_call_secs": 1,
122 "agent_metadata": {
123 "agent_id": "string",
124 "branch_id": "string",
125 "workflow_node_id": "string",
126 "version_id": "string"
127 },
128 "message": "string",
129 "multivoice_message": {
130 "parts": [
131 {
132 "text": "string",
133 "voice_label": "string",
134 "time_in_call_secs": 1
135 }
136 ]
137 },
138 "tool_calls": [
139 {
140 "request_id": "string",
141 "tool_name": "string",
142 "params_as_json": "string",
143 "tool_has_been_called": true,
144 "type": "system",
145 "tool_details": {
146 "type": "webhook",
147 "method": "string",
148 "url": "string",
149 "body": "string",
150 "headers": {},
151 "path_params": {},
152 "query_params": {}
153 }
154 }
155 ],
156 "tool_results": [
157 {
158 "request_id": "string",
159 "tool_name": "string",
160 "result_value": "string",
161 "is_error": true,
162 "is_blocked": false,
163 "tool_has_been_called": true,
164 "tool_latency_secs": 0,
165 "error_type": "",
166 "raw_error_message": "",
167 "dynamic_variable_updates": [
168 {
169 "variable_name": "string",
170 "old_value": "string",
171 "new_value": "string",
172 "updated_at": 1.1,
173 "tool_name": "string",
174 "tool_request_id": "string"
175 }
176 ],
177 "type": "client"
178 }
179 ],
180 "feedback": {
181 "score": "like",
182 "time_in_call_secs": 1
183 },
184 "llm_override": "string",
185 "conversation_turn_metrics": {
186 "metrics": {},
187 "convai_asr_provider": "string",
188 "convai_tts_model": "string",
189 "convai_tts_cascade": "string"
190 },
191 "rag_retrieval_info": {
192 "chunks": [
193 {
194 "document_id": "string",
195 "chunk_id": "string",
196 "vector_distance": 1.1
197 }
198 ],
199 "embedding_model": "e5_mistral_7b_instruct",
200 "retrieval_query": "string",
201 "rag_latency_secs": 1.1,
202 "used_chunk_ids": [
203 "string"
204 ]
205 },
206 "llm_usage": {
207 "model_usage": {}
208 },
209 "interrupted": false,
210 "original_message": "string",
211 "source_medium": "audio",
212 "source_event_id": 1,
213 "used_static_kb_document_ids": [
214 "string"
215 ]
216 }
217 ]
218 },
219 "success_condition": "",
220 "success_examples": [
221 {
222 "response": "string",
223 "type": "string"
224 }
225 ]
226}
Updates an agent response test by ID.
Was this page helpful?
Previous

Delete test

Next
Built with

Path parameters

test_idstringRequired
The id of a chat response test. This is returned on test creation.

Headers

xi-api-keystringOptional

Request

This endpoint expects an object.
UpdateResponseUnitTestRequestobjectRequired
OR
UpdateToolCallUnitTestRequestobjectRequired
OR
UpdateSimulationTestRequestobjectRequired

Response

Successful Response
llmobject
OR
toolobject
OR
simulationobject

Errors

422
Unprocessable Entity Error