Skip to main content
POST
/
api
/
v1
/
agents
/
test
/
messages
Typescript (SDK)
import { SyllableSDK } from "syllable-sdk";

const syllableSDK = new SyllableSDK({
  apiKeyHeader: process.env["SYLLABLESDK_API_KEY_HEADER"] ?? "",
});

async function run() {
  const result = await syllableSDK.agents.test.sendTestMessage({
    serviceName: "<value>",
    source: "[email protected]",
    text: "Hello",
    testId: "<id>",
    agentId: "<id>",
  });

  console.log(result);
}

run();
{
  "test_id": "<string>",
  "agent_id": "<string>",
  "response": "<unknown>",
  "text": "<string>",
  "response_text": "<string>"
}

Authorizations

Syllable-API-Key
string
header
required

Body

application/json

Message sent in a test chat with an agent.

service_name
string
required

Name of the service producing the message

source
string
required

Name of the source of the message - identifies the user, like an email or username.

test_id
string
required

Channel-manager-side ID of the session (see Session.channel_manager_sid)

agent_id
string
required

ID of the agent with which the chat is taking place

text
string | null

The text of the message

Example:

"Hello"

org_name
string | null
deprecated

Unused: Name of the organization associated with the agent

override_timestamp
string | null

Override for the timestamp of the message

session_start
boolean
default:false

Whether this message is the start of a new session

Response

Successful Response

Response from an agent in a test chat.

test_id
string
required

Channel-manager-side ID of the session (see Session.channel_manager_sid)

agent_id
string
required

ID of the agent with which the chat is taking place

response
any | null
required

The response from the agent

text
string

The text of the message that elicited the response

response_text
string

The text of the response