Trillet AI logo

Update Call Agent

Update an existing agent

PUThttps://api.trillet.ai/v1/api/agents/{agentId}

Send only the fields you want to change. Objects such as ttsModel and settings are merged into what is stored; arrays such as gapBetweenEachAttemptForSmartCallback and phoneNumberIds replace the stored array.

Headers

x-workspace-idstringrequired

Workspace identifier for the API.

Path Parameters

agentIdstringrequired

The unique identifier of the agent to update.

Request Body

namestring

New name for the agent.

llmModelstring

New language model for the agent. Omit it to leave the current one unchanged.

Pass platform-llm for the managed platform model, or a specific model id such as gpt-4.1 or gemini-2.5-flash. The models on offer change over time, so call List Available Models for the current set rather than hardcoding one.

ttsModelobject

Text-to-Speech configuration updates.

smartCallbackbooleandefault: false

Enable smart callback functionality for the agent.

maxAttemptsForSmartCallbacknumberdefault: 5

Maximum number of callback attempts when smart callback is enabled.

gapBetweenEachAttemptForSmartCallbackarray

Array of time intervals between each callback attempt. Each item contains days and hours.

phoneNumberIdsarray

Replaces the agent's list of phone number IDs. Every new ID must be a number in this workspace, otherwise the request fails with 400. This only edits the list: it doesn't route calls or set up the number. To put a number on the agent, use Assign Phone Number to Agent and Unassign Phone Number from Agent instead.

settingsobject

Additional settings for the agent.

variablesobject

Custom variables to store for the agent.

Response Fields

_idstring

The unique identifier of the agent.

workspaceIdstring

The workspace identifier to which the agent belongs.

userIdstring

The user identifier associated with the agent, if applicable.

namestring

The name assigned to the agent.

ttsModelobject

The configuration of the text-to-speech model used by the agent.

providerstring

The provider of the TTS service.

voiceIdstring

The specific voice ID used in the TTS model.

namestring

The name of the TTS model configuration.

languagestring

The language set for the TTS model.

elevenLabsApiKeystring

Encrypted ElevenLabs API key (only present if provider is "11labs_byo").

llmModelstring

The large language model used by the agent.

smartCallbackboolean

Whether smart callback functionality is enabled.

phoneNumberIdsarray

Array of phone number IDs associated with the agent.

activeSessionsarray

A list of active sessions associated with the agent.

roomNamestring

The name of the room for the session.

participantIdstring

The participant identifier in the session.

startTimedate

The start time of the session.

statusstring

The status of the session.

settingsobject

Any custom settings configured for the agent.

statusstring

The current status of the agent, such as "pending", "ready", or "error".

currentNodestring

The current node or state within the agent's flow or logic.

variablesobject

Custom variables stored for the agent.

createdAtstring

Timestamp when the agent was created.

updatedAtstring

Timestamp when the agent was last updated.

Errors

StatusBodyWhen
400{"error": "Workspace ID is required"}No x-workspace-id
400{"message", "code": "LLM_MODEL_INVALID"}A changed llmModel or fallbackLlmModel isn't an available model, or is the retired trillet-llm
400{"error", "code"}phoneNumberIds names a number from another workspace
500{"error": "..."}Unexpected server error
{
  "name": "Updated Customer Support Agent",
  "llmModel": "platform-llm",
  "ttsModel": {
    "provider": "rime",
    "voiceId": "mistv3_brook",
    "name": "Brook",
    "rimeModel": "mistv3"
  },
  "smartCallback": true,
  "gapBetweenEachAttemptForSmartCallback": [
    { "days": 1, "hours": 0 },
    { "days": 1, "hours": 12 },
    { "days": 2, "hours": 0 }
  ],
  "settings": {
    "temperature": 0.4
  }
}
{
  "_id": "d5d5d5d5d5d5d5d5d5d5d5d5",
  "workspaceId": "d1d1d1d1d1d1d1d1d1d1d1d1",
  "userId": "a0a0a0a0a0a0a0a0a0a0a0a0",
  "name": "Updated Customer Support Agent",
  "ttsModel": {
    "provider": "rime",
    "voiceId": "mistv3_brook",
    "name": "Brook",
    "language": "en",
    "rimeModel": "mistv3"
  },
  "llmModel": "platform-llm",
  "smartCallback": true,
  "maxAttemptsForSmartCallback": 5,
  "gapBetweenEachAttemptForSmartCallback": [
    { "days": 1, "hours": 0 },
    { "days": 1, "hours": 12 },
    { "days": 2, "hours": 0 }
  ],
  "type": "voice",
  "settings": { "speed": 0, "volume": 1, "temperature": 0.4 },
  "status": "ready",
  "phoneNumberIds": [],
  "activeSessions": [],
  "createdAt": "2026-10-29T10:00:00.000Z",
  "updatedAt": "2026-10-29T11:30:00.000Z"
}

Last updated on