Skip to main content
PUT
/
ai
/
assistants
/
tests
/
{test_id}
JavaScript
import Telnyx from 'telnyx';

const client = new Telnyx({
  apiKey: 'My API Key',
});

const assistantTest = await client.ai.assistants.tests.update('test_id');

console.log(assistantTest.test_id);
{
  "test_id": "123e4567-e89b-12d3-a456-426614174000",
  "name": "Customer Support Bot Test",
  "description": "<string>",
  "telnyx_conversation_channel": "web_chat",
  "destination": "<string>",
  "max_duration_seconds": 123,
  "test_suite": "<string>",
  "instructions": "<string>",
  "rubric": [
    {
      "criteria": "Responds within 30 seconds",
      "name": "Response Time"
    }
  ],
  "created_at": "2024-01-15T09:00:00Z"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

test_id
string
required

Body

application/json

Request model for updating an existing assistant test.

All fields are optional, allowing partial updates of test configuration. Only provided fields will be updated, others remain unchanged.

name
string

Updated name for the assistant test. Must be unique and descriptive.

Required string length: 1 - 255
description
string

Updated description of the test's purpose and evaluation criteria.

Maximum length: 1000
telnyx_conversation_channel
enum<string>

Updated communication channel for the test execution.

Available options:
phone_call,
web_call,
sms_chat,
web_chat
destination
string

Updated target destination for test conversations.

Minimum length: 1
max_duration_seconds
integer

Updated maximum test duration in seconds.

Required range: 1 <= x <= 3600
test_suite
string

Updated test suite assignment for better organization.

Maximum length: 100
instructions
string

Updated test scenario instructions and objectives.

Required string length: 1 - 5000
rubric
Rubric · object[]

Updated evaluation criteria for assessing assistant performance.

Minimum length: 1

Response

Returns the updated test configuration with all changes applied

Response model containing complete assistant test information.

Returns all test configuration details including evaluation criteria, scheduling, and metadata. Used when retrieving individual tests or after creating/updating tests.

test_id
string<uuid>
required

Unique identifier for the assistant test.

Example:

"123e4567-e89b-12d3-a456-426614174000"

name
string
required

Human-readable name of the test.

Example:

"Customer Support Bot Test"

telnyx_conversation_channel
enum<string>
required

Communication channel used for test execution.

Available options:
phone_call,
web_call,
sms_chat,
web_chat
Example:

"web_chat"

rubric
Rubric · object[]
required

Evaluation criteria used to assess test performance.

Example:
[
{
"criteria": "Responds within 30 seconds",
"name": "Response Time"
}
]
created_at
string<date-time>
required

Timestamp when the test was created.

Example:

"2024-01-15T09:00:00Z"

description
string

Detailed description of the test's purpose and scope.

destination
string

Target destination for test conversations.

max_duration_seconds
integer

Maximum allowed duration for test execution in seconds.

test_suite
string

Test suite grouping for organizational purposes.

instructions
string

Detailed test scenario instructions and objectives.