List evaluator scenarios
Returns a paginated list of evaluator scenarios in your organization, optionally filtered by test agent or tags.
GET
/
ai
/
tests
/
test_framework
/
v1
/
scenarios
JavaScript
import Telnyx from 'telnyx';
const client = new Telnyx({
apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
});
// Automatically fetches more pages as needed.
for await (const response of client.ai.tests.testFramework.v1.scenarios.list()) {
console.log(response);
}import os
from telnyx import Telnyx
client = Telnyx(
api_key=os.environ.get("TELNYX_API_KEY"), # This is the default and can be omitted
)
page = client.ai.tests.test_framework.v1.scenarios.list()
print(page)
package main
import (
"context"
"fmt"
"github.com/team-telnyx/telnyx-go"
"github.com/team-telnyx/telnyx-go/option"
)
func main() {
client := telnyx.NewClient(
option.WithAPIKey("My API Key"),
)
scenarios, err := client.AI.Tests.TestFramework.V1.Scenarios.List(context.TODO())
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", scenarios.Data)
}
package com.telnyx.sdk.example;
import com.telnyx.sdk.client.TelnyxClient;
import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;
public final class Main {
private Main() {}
public static void main(String[] args) {
TelnyxClient client = TelnyxOkHttpClient.fromEnv();
var page = client.ai().tests().testFramework().v1().scenarios().list();
}
}require "telnyx"
telnyx = Telnyx::Client.new(api_key: "My API Key")
page = telnyx.ai.tests.test_framework.v1.scenarios.list
puts(page)<?php
require_once dirname(__DIR__) . '/vendor/autoload.php';
use Telnyx\Client;
use Telnyx\Core\Exceptions\APIException;
$client = new Client(apiKey: getenv('TELNYX_API_KEY') ?: 'My API Key');
try {
$page = $client->ai->tests->testFramework->v1->scenarios->list();
var_dump($page);
} catch (APIException $e) {
echo $e->getMessage();
}telnyx ai:tests:test-framework:v1:scenarios list \
--api-key 'My API Key'curl --request GET \
--url https://api.telnyx.com/v2/ai/tests/test_framework/v1/scenarios \
--header 'Authorization: Bearer <token>'{
"count": 1,
"next": null,
"previous": null,
"results": [
{
"id": 9512,
"name": "Refund escalation flow",
"personality": 4643,
"personality_name": "Interruptive (High)",
"phone_number": "+13125550188",
"expected_outcome_prompt": "The assistant explains the refund policy and offers escalation.",
"instructions": "Call the support line and demand a refund for a damaged product.",
"scenario_language": "en",
"scenario_type": "workflow",
"tags": [
"support",
"regression"
],
"agent": 1259,
"inbound_phone_number": null,
"inbound_phone_number_data": null,
"metrics": [
266881,
266882
],
"metric_names": [
"Greeting quality",
"Escalation quality"
],
"first_message": "Hi, I want a refund.",
"tool_ids": [],
"test_profile": null,
"test_profile_data": null,
"dynamic_variable_values": null,
"created_at": "2026-10-13T18:04:05.123456Z",
"updated_at": "2026-10-13T18:04:05.123456Z",
"last_updated_by": 1,
"folder_path": null
}
]
}{
"errors": [
{
"code": "10015",
"title": "Bad Request",
"detail": "The AI Tests service rejected the request."
}
]
}{
"errors": [
{
"code": "10003",
"title": "Unauthorized",
"detail": "The API key is missing or invalid."
}
]
}{
"errors": [
{
"code": "10005",
"title": "Not Found",
"detail": "The requested resource or URL could not be found."
}
]
}{
"errors": [
{
"code": "10018",
"title": "Unprocessable Entity",
"detail": "Validation failed for the request payload."
}
]
}{
"errors": [
{
"code": "10029",
"title": "Too Many Requests",
"detail": "Too many requests; retry later."
}
]
}{
"errors": [
{
"code": "10063",
"title": "Service Unavailable",
"detail": "The test framework service is temporarily unavailable."
}
]
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Query Parameters
Page number (1-based).
Required range:
x >= 1Number of results per page.
Required range:
1 <= x <= 250Filter scenarios belonging to the specified test agent.
Filter scenarios belonging to the specified Telnyx assistant.
Filter scenarios by a comma-separated list of tags.
Was this page helpful?
JavaScript
import Telnyx from 'telnyx';
const client = new Telnyx({
apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
});
// Automatically fetches more pages as needed.
for await (const response of client.ai.tests.testFramework.v1.scenarios.list()) {
console.log(response);
}import os
from telnyx import Telnyx
client = Telnyx(
api_key=os.environ.get("TELNYX_API_KEY"), # This is the default and can be omitted
)
page = client.ai.tests.test_framework.v1.scenarios.list()
print(page)
package main
import (
"context"
"fmt"
"github.com/team-telnyx/telnyx-go"
"github.com/team-telnyx/telnyx-go/option"
)
func main() {
client := telnyx.NewClient(
option.WithAPIKey("My API Key"),
)
scenarios, err := client.AI.Tests.TestFramework.V1.Scenarios.List(context.TODO())
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", scenarios.Data)
}
package com.telnyx.sdk.example;
import com.telnyx.sdk.client.TelnyxClient;
import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;
public final class Main {
private Main() {}
public static void main(String[] args) {
TelnyxClient client = TelnyxOkHttpClient.fromEnv();
var page = client.ai().tests().testFramework().v1().scenarios().list();
}
}require "telnyx"
telnyx = Telnyx::Client.new(api_key: "My API Key")
page = telnyx.ai.tests.test_framework.v1.scenarios.list
puts(page)<?php
require_once dirname(__DIR__) . '/vendor/autoload.php';
use Telnyx\Client;
use Telnyx\Core\Exceptions\APIException;
$client = new Client(apiKey: getenv('TELNYX_API_KEY') ?: 'My API Key');
try {
$page = $client->ai->tests->testFramework->v1->scenarios->list();
var_dump($page);
} catch (APIException $e) {
echo $e->getMessage();
}telnyx ai:tests:test-framework:v1:scenarios list \
--api-key 'My API Key'curl --request GET \
--url https://api.telnyx.com/v2/ai/tests/test_framework/v1/scenarios \
--header 'Authorization: Bearer <token>'{
"count": 1,
"next": null,
"previous": null,
"results": [
{
"id": 9512,
"name": "Refund escalation flow",
"personality": 4643,
"personality_name": "Interruptive (High)",
"phone_number": "+13125550188",
"expected_outcome_prompt": "The assistant explains the refund policy and offers escalation.",
"instructions": "Call the support line and demand a refund for a damaged product.",
"scenario_language": "en",
"scenario_type": "workflow",
"tags": [
"support",
"regression"
],
"agent": 1259,
"inbound_phone_number": null,
"inbound_phone_number_data": null,
"metrics": [
266881,
266882
],
"metric_names": [
"Greeting quality",
"Escalation quality"
],
"first_message": "Hi, I want a refund.",
"tool_ids": [],
"test_profile": null,
"test_profile_data": null,
"dynamic_variable_values": null,
"created_at": "2026-10-13T18:04:05.123456Z",
"updated_at": "2026-10-13T18:04:05.123456Z",
"last_updated_by": 1,
"folder_path": null
}
]
}{
"errors": [
{
"code": "10015",
"title": "Bad Request",
"detail": "The AI Tests service rejected the request."
}
]
}{
"errors": [
{
"code": "10003",
"title": "Unauthorized",
"detail": "The API key is missing or invalid."
}
]
}{
"errors": [
{
"code": "10005",
"title": "Not Found",
"detail": "The requested resource or URL could not be found."
}
]
}{
"errors": [
{
"code": "10018",
"title": "Unprocessable Entity",
"detail": "Validation failed for the request payload."
}
]
}{
"errors": [
{
"code": "10029",
"title": "Too Many Requests",
"detail": "Too many requests; retry later."
}
]
}{
"errors": [
{
"code": "10063",
"title": "Service Unavailable",
"detail": "The test framework service is temporarily unavailable."
}
]
}