client.tts.audio.speech({ ...params }) -> Speechify.GetSpeechResponse
-
-
-
Gets the speech data for the given input
-
-
-
await client.tts.audio.speech({ input: "input", voiceId: "voice_id", });
-
-
-
request:
Speechify.tts.GetSpeechRequest
-
requestOptions:
Audio.RequestOptions
-
-
client.tts.audio.stream({ ...params }) -> stream.Readable
-
-
-
Gets the stream speech for the given input
-
-
-
await client.tts.audio.stream({ accept: "audio/mpeg", input: "input", language: undefined, model: undefined, options: undefined, voiceId: "voice_id", });
-
-
-
request:
Speechify.tts.GetStreamRequest
-
requestOptions:
Audio.RequestOptions
-
-
client.tts.auth.createAccessToken({ ...params }) -> Speechify.AccessToken
-
-
-
WARNING: This endpoint is deprecated. Create a new API token for the logged in user.
-
-
-
await client.tts.auth.createAccessToken({ grantType: "client_credentials", });
-
-
-
request:
Speechify.tts.CreateAccessTokenRequest
-
requestOptions:
Auth.RequestOptions
-
-
client.tts.voices.list() -> Speechify.GetVoice[]
-
-
-
Gets the list of voices available for the user
-
-
-
await client.tts.voices.list();
-
-
-
requestOptions:
Voices.RequestOptions
-
-
client.tts.voices.create({ ...params }) -> Speechify.CreatedVoice
-
-
-
Create a personal (cloned) voice for the user
-
-
-
await client.tts.voices.create({ sample: fs.createReadStream("/path/to/your/file"), name: "name", gender: "male", consent: "consent", });
-
-
-
request:
Speechify.tts.CreateVoicesRequest
-
requestOptions:
Voices.RequestOptions
-
-
client.tts.voices.delete(id, { ...params }) -> void
-
-
-
Delete a personal (cloned) voice
-
-
-
await client.tts.voices.delete("id");
-
-
-
id:
stringβ The ID of the voice to delete
-
request:
Speechify.tts.DeleteVoicesRequest
-
requestOptions:
Voices.RequestOptions
-
-
client.tts.voices.downloadSample(id, { ...params }) -> stream.Readable
-
-
-
Download a personal (cloned) voice sample
-
-
-
await client.tts.voices.downloadSample("id");
-
-
-
id:
stringβ The ID of the voice to download sample for
-
request:
Speechify.tts.DownloadSampleVoicesRequest
-
requestOptions:
Voices.RequestOptions
-
-
client.tts.agents.list() -> Speechify.ListAgentsResponse
-
-
-
List voice agents owned by the caller.
-
-
-
await client.tts.agents.list();
-
-
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.create({ ...params }) -> Speechify.Agent
-
-
-
Create a voice agent.
-
-
-
await client.tts.agents.create({ name: "name", voiceId: "voice_id", });
-
-
-
request:
Speechify.tts.CreateAgentRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.get(id, { ...params }) -> Speechify.Agent
-
-
-
Retrieve a voice agent by ID.
-
-
-
await client.tts.agents.get("id");
-
-
-
id:
string
-
request:
Speechify.tts.GetAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.delete(id, { ...params }) -> void
-
-
-
Delete a voice agent. Conversations and attached tools remain.
-
-
-
await client.tts.agents.delete("id");
-
-
-
id:
string
-
request:
Speechify.tts.DeleteAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.update(id, { ...params }) -> Speechify.Agent
-
-
-
Update a voice agent. Only fields present on the request body are changed.
-
-
-
await client.tts.agents.update("id");
-
-
-
id:
string
-
request:
Speechify.tts.UpdateAgentRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.listTools(id, { ...params }) -> Speechify.ListToolsResponse
-
-
-
List tools currently attached to the agent.
-
-
-
await client.tts.agents.listTools("id");
-
-
-
id:
string
-
request:
Speechify.tts.ListToolsAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.attachTool(id, toolId, { ...params }) -> void
-
-
-
Attach an existing tool to the agent so the LLM can call it.
-
-
-
await client.tts.agents.attachTool("id", "toolId");
-
-
-
id:
string
-
toolId:
string
-
request:
Speechify.tts.AttachToolAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.detachTool(id, toolId, { ...params }) -> void
-
-
-
Detach a tool from the agent.
-
-
-
await client.tts.agents.detachTool("id", "toolId");
-
-
-
id:
string
-
toolId:
string
-
request:
Speechify.tts.DetachToolAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.getEvaluationConfig(id, { ...params }) -> Speechify.EvaluationConfig
-
-
-
Retrieve the agent's post-call evaluation criteria + data-collection config.
-
-
-
await client.tts.agents.getEvaluationConfig("id");
-
-
-
id:
string
-
request:
Speechify.tts.GetEvaluationConfigAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.updateEvaluationConfig(id, { ...params }) -> Speechify.EvaluationConfig
-
-
-
Replace the agent's evaluation criteria + data-collection fields.
-
-
-
await client.tts.agents.updateEvaluationConfig("id", { criteria: [ { id: "id", name: "name", description: "description", }, ], dataCollection: [ { key: "key", description: "description", type: "string", }, ], });
-
-
-
id:
string
-
request:
Speechify.tts.UpdateEvaluationConfigRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.getDynamicVariables(id, { ...params }) -> Speechify.ListDynamicVariablesResponse
-
-
-
Retrieve the agent's customer-scope dynamic variables and the read-only catalogue of reserved
system__*keys. The system variables list is provided so editor UIs can render the reference list without maintaining a client-side copy of the catalogue.
-
-
-
await client.tts.agents.getDynamicVariables("id");
-
-
-
id:
string
-
request:
Speechify.tts.GetDynamicVariablesAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.updateDynamicVariables(id, { ...params }) -> Speechify.ListDynamicVariablesResponse
-
-
-
Replace the agent's customer-scope dynamic variable definitions. The supplied list overwrites the stored list wholesale (same semantics as
updateEvaluationConfig). Pass an empty array to clear all variables. Up to 20 variables per agent. Keys must match[a-zA-Z0-9_]+and must not start with the reservedsystem__prefix.
-
-
-
await client.tts.agents.updateDynamicVariables("id", { variables: [ { key: "product_name", type: "string", default: "Speechify", description: "Product the agent is supporting.", }, { key: "support_tier", type: "number", default: 1, }, { key: "account_metadata", type: "json", description: "Arbitrary account context injected into tool bodies.", }, ], });
-
-
-
id:
string
-
request:
Speechify.tts.UpdateDynamicVariablesRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.createConversation(id, { ...params }) -> Speechify.CreateConversationResponse
-
-
-
Start a new voice conversation with the agent. Returns a realtime voice session + short-lived client token so the caller can connect the audio pipeline directly. The agent is dispatched server-side; no additional client action required.
Pass
dynamic_variablesto supply per-session values that override the agent's stored variable defaults for this one conversation. Keys in thesystem__namespace are rejected at this boundary.
-
-
-
await client.tts.agents.createConversation("id");
-
-
-
id:
string
-
request:
Speechify.tts.CreateConversationRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.createSession(id, { ...params }) -> Speechify.CreateConversationResponse
-
-
-
Mint a realtime voice session for the given agent. Widget-friendly counterpart to
createConversationβ same response shape, dual authentication:- Authenticated (Bearer): works for any agent the caller owns. Typical server-to-server flow where the embedding site's backend mints a token and hands it to the browser so the API key never reaches the client.
- Unauthenticated: works only when
agent.is_public = trueAND the request'sOriginheader matchesagent.allowed_origins(or that list is empty). Whenagent.hostname_allowlistis non-empty, theOriginhostname must additionally be a member of that list. Used directly by the<speechify-agent>web component.
Responds with the same
CreateConversationResponseascreateConversation.
-
-
-
await client.tts.agents.createSession("id");
-
-
-
id:
string
-
request:
Speechify.tts.CreateSessionRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.listAgentKnowledgeBases(id, { ...params }) -> Speechify.ListKnowledgeBasesResponse
-
-
-
List knowledge bases attached to an agent.
-
-
-
await client.tts.agents.listAgentKnowledgeBases("id");
-
-
-
id:
string
-
request:
Speechify.tts.ListAgentKnowledgeBasesAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.attachKnowledgeBase(id, kbId, { ...params }) -> void
-
-
-
Attach a knowledge base to an agent. The
search_knowledgetool is auto-registered on the next conversation and can only query the attached knowledge bases.
-
-
-
await client.tts.agents.attachKnowledgeBase("id", "kbId");
-
-
-
id:
string
-
kbId:
string
-
request:
Speechify.tts.AttachKnowledgeBaseAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.detachKnowledgeBase(id, kbId, { ...params }) -> void
-
-
-
Detach a knowledge base from an agent.
-
-
-
await client.tts.agents.detachKnowledgeBase("id", "kbId");
-
-
-
id:
string
-
kbId:
string
-
request:
Speechify.tts.DetachKnowledgeBaseAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.listMemories(id, { ...params }) -> Speechify.ListMemoriesResponse
-
-
-
List per-caller memories extracted for an agent. Memories are written post-call by the built-in extractor when
memory_enabledis true on the agent; the list is sorted newest-first.
-
-
-
await client.tts.agents.listMemories("id");
-
-
-
id:
string
-
request:
Speechify.tts.ListMemoriesAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.deleteMemoriesByCaller(id, { ...params }) -> Speechify.DeleteMemoriesByCallerResponse
-
-
-
Delete every memory ever extracted for a specific caller on this agent. Privacy / GDPR surface. Returns the count of rows soft-deleted; rows become permanently unreachable immediately and are hard-deleted by the retention job after the tenant's configured retention window.
-
-
-
await client.tts.agents.deleteMemoriesByCaller("id", { agentId: "agent_id", callerIdentity: "caller_identity", });
-
-
-
id:
string
-
request:
Speechify.tts.DeleteMemoriesByCallerRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.listTests(id, { ...params }) -> Speechify.ListAgentTestsResponse
-
-
-
List all tests configured for the agent. Each entry includes the most recent run so the console can render pass/fail badges without an extra round-trip.
-
-
-
await client.tts.agents.listTests("id");
-
-
-
id:
stringβ Agent ID.
-
request:
Speechify.tts.ListTestsAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.createTest(id, { ...params }) -> Speechify.AgentTest
-
-
-
Create a new test for the agent.
-
-
-
await client.tts.agents.createTest("id", { name: "Greet the caller by name", description: "Agent should greet the caller using their name when provided.", type: "scenario", config: { context: "The caller says: Hi, I'm Alice.", successCriteria: "The agent greets Alice by name.", successExamples: ["Hi Alice! How can I help you today?"], failureExamples: ["Hello! How can I help you?"], }, });
-
-
-
id:
stringβ Agent ID.
-
request:
Speechify.tts.CreateAgentTestRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.runAllTests(id, { ...params }) -> Speechify.RunAgentTestsResponse
-
-
-
Enqueue runs for every test on the agent concurrently. Up to 50 tests are dispatched in one call. Each returned run starts in
queuedstatus; pollGET /v1/test-runs/{id}for the terminal result.
-
-
-
await client.tts.agents.runAllTests("id");
-
-
-
id:
stringβ Agent ID.
-
request:
Speechify.tts.RunAllTestsAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.getTest(id, { ...params }) -> Speechify.AgentTest
-
-
-
Retrieve a test by ID.
-
-
-
await client.tts.agents.getTest("id");
-
-
-
id:
stringβ Test ID.
-
request:
Speechify.tts.GetTestAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.deleteTest(id, { ...params }) -> void
-
-
-
Delete a test and all its run history.
-
-
-
await client.tts.agents.deleteTest("id");
-
-
-
id:
stringβ Test ID.
-
request:
Speechify.tts.DeleteTestAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.updateTest(id, { ...params }) -> Speechify.AgentTest
-
-
-
Update a test. Only fields present on the request body are changed.
-
-
-
await client.tts.agents.updateTest("id");
-
-
-
id:
stringβ Test ID.
-
request:
Speechify.tts.UpdateAgentTestRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.listTestRuns(id, { ...params }) -> Speechify.ListAgentTestRunsResponse
-
-
-
List the run history for a test, newest first.
-
-
-
await client.tts.agents.listTestRuns("id");
-
-
-
id:
stringβ Test ID.
-
request:
Speechify.tts.ListTestRunsAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.runTest(id, { ...params }) -> Speechify.AgentTestRun
-
-
-
Enqueue a single run of the test. The returned run starts in
queuedstatus. PollGET /v1/test-runs/{id}until the status reaches a terminal state (passed,failed, orerror).
-
-
-
await client.tts.agents.runTest("id");
-
-
-
id:
stringβ Test ID.
-
request:
Speechify.tts.RunTestAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.getTestRun(id, { ...params }) -> Speechify.AgentTestRun
-
-
-
Retrieve a single test run by ID. Poll this endpoint until
statusreaches a terminal state (passed,failed, orerror). Theresultfield is populated on terminal states.
-
-
-
await client.tts.agents.getTestRun("id");
-
-
-
id:
stringβ Test run ID.
-
request:
Speechify.tts.GetTestRunAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.listAllTests({ ...params }) -> Speechify.ListTestsResponse
-
-
-
Workspace-wide list of tests across every agent the caller owns. Supports filters (agent, type, last-run status, folder), full-text search on name/description, and cursor pagination. Each row carries its newest run and attached agent IDs so the list renders without N+1 round-trips.
-
-
-
await client.tts.agents.listAllTests();
-
-
-
request:
Speechify.tts.ListAllTestsAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.getTestStats({ ...params }) -> Speechify.TestStats
-
-
-
Aggregate pass-rate metrics over the last N days. Returns dense daily buckets (one entry per day, zero-filled) plus totals and a per-type breakdown. Powers the header chart on the global tests page. Default window is 30 days, max 90.
-
-
-
await client.tts.agents.getTestStats();
-
-
-
request:
Speechify.tts.GetTestStatsAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.runTestsBatch({ ...params }) -> Speechify.RunBatchResponse
-
-
-
Queue runs for every (test, agent) pair in the body. Entries without an
agent_idfan out to every agent the test is attached to. Total expanded runs are capped at 100 per call. Each entry in the response is a queued run; pollGET /v1/test-runs/{id}for each.
-
-
-
await client.tts.agents.runTestsBatch({ entries: [ { testId: "test_id", }, ], });
-
-
-
request:
Speechify.tts.RunBatchRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.listTestAttachments(id, { ...params }) -> Speechify.ListAgentTestAttachmentsResponse
-
-
-
List every agent a test is attached to.
-
-
-
await client.tts.agents.listTestAttachments("id");
-
-
-
id:
string
-
request:
Speechify.tts.ListTestAttachmentsAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.attachTest(id, agentId, { ...params }) -> void
-
-
-
Attach a test to an additional agent. After this call, the test will also run as part of that agent's regression suite (and against its prompt + tool config when invoked with
agent_id = {agentId}). Idempotent.
-
-
-
await client.tts.agents.attachTest("id", "agentId");
-
-
-
id:
string
-
agentId:
string
-
request:
Speechify.tts.AttachTestAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.detachTest(id, agentId, { ...params }) -> void
-
-
-
Detach a test from an agent. The owner agent (the agent the test was authored against) cannot be detached; delete the test instead.
-
-
-
await client.tts.agents.detachTest("id", "agentId");
-
-
-
id:
string
-
agentId:
string
-
request:
Speechify.tts.DetachTestAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.moveTest(id, { ...params }) -> void
-
-
-
Move a test into a folder. Pass
folder_id: nullfor root.
-
-
-
await client.tts.agents.moveTest("id");
-
-
-
id:
string
-
request:
Speechify.tts.MoveAgentTestRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.listTestFolders() -> Speechify.ListAgentTestFoldersResponse
-
-
-
List every test folder the caller owns. Flat list; build the tree client-side.
-
-
-
await client.tts.agents.listTestFolders();
-
-
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.createTestFolder({ ...params }) -> Speechify.AgentTestFolder
-
-
-
Create a test folder. Max depth is 3.
-
-
-
await client.tts.agents.createTestFolder({ name: "name", });
-
-
-
request:
Speechify.tts.CreateAgentTestFolderRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.deleteTestFolder(id, { ...params }) -> void
-
-
-
Soft-delete a folder. Child tests drop back to root.
-
-
-
await client.tts.agents.deleteTestFolder("id");
-
-
-
id:
string
-
request:
Speechify.tts.DeleteTestFolderAgentsRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.agents.updateTestFolder(id, { ...params }) -> Speechify.AgentTestFolder
-
-
-
Rename or reparent a test folder. Cycles are rejected.
-
-
-
await client.tts.agents.updateTestFolder("id");
-
-
-
id:
string
-
request:
Speechify.tts.UpdateAgentTestFolderRequest
-
requestOptions:
Agents.RequestOptions
-
-
client.tts.tools.list() -> Speechify.ListToolsResponse
-
-
-
List tools owned by the caller.
-
-
-
await client.tts.tools.list();
-
-
-
requestOptions:
Tools.RequestOptions
-
-
client.tts.tools.create({ ...params }) -> Speechify.Tool
-
-
-
Create a tool. For webhook tools, the response includes the HMAC
webhook_secretexactly once β store it immediately; subsequent reads return a masked placeholder.
-
-
-
await client.tts.tools.create({ name: "name", description: "description", kind: "system", config: { builtin: "end_call", }, });
-
-
-
request:
Speechify.tts.CreateToolRequest
-
requestOptions:
Tools.RequestOptions
-
-
client.tts.tools.get(id, { ...params }) -> Speechify.Tool
-
-
-
Retrieve a tool by ID. Webhook secrets are always masked here.
-
-
-
await client.tts.tools.get("id");
-
-
-
id:
string
-
request:
Speechify.tts.GetToolsRequest
-
requestOptions:
Tools.RequestOptions
-
-
client.tts.tools.delete(id, { ...params }) -> void
-
-
-
Delete a tool. Agents that had it attached get a soft-detach.
-
-
-
await client.tts.tools.delete("id");
-
-
-
id:
string
-
request:
Speechify.tts.DeleteToolsRequest
-
requestOptions:
Tools.RequestOptions
-
-
client.tts.tools.update(id, { ...params }) -> Speechify.Tool
-
-
-
Update a tool. Tool kind is immutable β create a new tool to change it.
-
-
-
await client.tts.tools.update("id");
-
-
-
id:
string
-
request:
Speechify.tts.UpdateToolRequest
-
requestOptions:
Tools.RequestOptions
-
-
client.tts.conversations.list() -> Speechify.ListConversationsResponse
-
-
-
List conversations owned by the caller, ordered by most recent.
-
-
-
await client.tts.conversations.list();
-
-
-
requestOptions:
Conversations.RequestOptions
-
-
client.tts.conversations.stats() -> Speechify.ConversationStats
-
-
-
Aggregated counts and averages over the caller's conversations, scoped by the same filters as the list endpoint.
-
-
-
await client.tts.conversations.stats();
-
-
-
requestOptions:
Conversations.RequestOptions
-
-
client.tts.conversations.get(id, { ...params }) -> Speechify.Conversation
-
-
-
Retrieve a conversation by ID.
-
-
-
await client.tts.conversations.get("id");
-
-
-
id:
string
-
request:
Speechify.tts.GetConversationsRequest
-
requestOptions:
Conversations.RequestOptions
-
-
client.tts.conversations.listMessages(id, { ...params }) -> Speechify.ListMessagesResponse
-
-
-
Retrieve the full transcript for a conversation, in order.
-
-
-
await client.tts.conversations.listMessages("id");
-
-
-
id:
string
-
request:
Speechify.tts.ListMessagesConversationsRequest
-
requestOptions:
Conversations.RequestOptions
-
-
client.tts.conversations.listEvaluations(id, { ...params }) -> Speechify.ListEvaluationsResponse
-
-
-
Retrieve post-call evaluation results for a conversation.
-
-
-
await client.tts.conversations.listEvaluations("id");
-
-
-
id:
string
-
request:
Speechify.tts.ListEvaluationsConversationsRequest
-
requestOptions:
Conversations.RequestOptions
-
-
client.tts.conversations.listMemories(id, { ...params }) -> Speechify.ListMemoriesResponse
-
-
-
List memories extracted from a specific conversation.
-
-
-
await client.tts.conversations.listMemories("id");
-
-
-
id:
string
-
request:
Speechify.tts.ListMemoriesConversationsRequest
-
requestOptions:
Conversations.RequestOptions
-
-
client.tts.knowledgeBases.list() -> Speechify.ListKnowledgeBasesResponse
-
-
-
List knowledge bases owned by the caller.
-
-
-
await client.tts.knowledgeBases.list();
-
-
-
requestOptions:
KnowledgeBases.RequestOptions
-
-
client.tts.knowledgeBases.create({ ...params }) -> Speechify.KnowledgeBase
-
-
-
Create a new knowledge base.
-
-
-
await client.tts.knowledgeBases.create({ name: "name", });
-
-
-
request:
Speechify.tts.CreateKnowledgeBaseRequest
-
requestOptions:
KnowledgeBases.RequestOptions
-
-
client.tts.knowledgeBases.get(id, { ...params }) -> Speechify.KnowledgeBase
-
-
-
Retrieve a knowledge base by ID.
-
-
-
await client.tts.knowledgeBases.get("id");
-
-
-
id:
string
-
request:
Speechify.tts.GetKnowledgeBasesRequest
-
requestOptions:
KnowledgeBases.RequestOptions
-
-
client.tts.knowledgeBases.delete(id, { ...params }) -> void
-
-
-
Soft-delete a knowledge base. Documents and chunks are cascaded.
-
-
-
await client.tts.knowledgeBases.delete("id");
-
-
-
id:
string
-
request:
Speechify.tts.DeleteKnowledgeBasesRequest
-
requestOptions:
KnowledgeBases.RequestOptions
-
-
client.tts.knowledgeBases.update(id, { ...params }) -> Speechify.KnowledgeBase
-
-
-
Update a knowledge base.
-
-
-
await client.tts.knowledgeBases.update("id");
-
-
-
id:
string
-
request:
Speechify.tts.UpdateKnowledgeBaseRequest
-
requestOptions:
KnowledgeBases.RequestOptions
-
-
client.tts.knowledgeBases.listDocuments(id, { ...params }) -> Speechify.ListKnowledgeBaseDocumentsResponse
-
-
-
List documents ingested into a knowledge base.
-
-
-
await client.tts.knowledgeBases.listDocuments("id");
-
-
-
id:
string
-
request:
Speechify.tts.ListDocumentsKnowledgeBasesRequest
-
requestOptions:
KnowledgeBases.RequestOptions
-
-
client.tts.knowledgeBases.uploadDocument(id, { ...params }) -> Speechify.KnowledgeBaseDocument
-
-
-
Upload a document (PDF, plain text, markdown, or HTML) to a knowledge base. The document is extracted, chunked, embedded, and indexed synchronously; expect a few seconds per MB of input. Maximum 10 MB per upload.
-
-
-
await client.tts.knowledgeBases.uploadDocument("id", { file: fs.createReadStream("/path/to/your/file"), });
-
-
-
id:
string
-
request:
Speechify.tts.UploadDocumentKnowledgeBasesRequest
-
requestOptions:
KnowledgeBases.RequestOptions
-
-
client.tts.knowledgeBases.getDocument(docId, { ...params }) -> Speechify.KnowledgeBaseDocument
-
-
-
Retrieve a document by ID.
-
-
-
await client.tts.knowledgeBases.getDocument("docId");
-
-
-
docId:
string
-
request:
Speechify.tts.GetDocumentKnowledgeBasesRequest
-
requestOptions:
KnowledgeBases.RequestOptions
-
-
client.tts.knowledgeBases.deleteDocument(docId, { ...params }) -> void
-
-
-
Delete a document and all its chunks.
-
-
-
await client.tts.knowledgeBases.deleteDocument("docId");
-
-
-
docId:
string
-
request:
Speechify.tts.DeleteDocumentKnowledgeBasesRequest
-
requestOptions:
KnowledgeBases.RequestOptions
-
-
client.tts.knowledgeBases.listChunks(docId, { ...params }) -> Speechify.ListKnowledgeBaseChunksResponse
-
-
-
List the chunks for a document.
-
-
-
await client.tts.knowledgeBases.listChunks("docId");
-
-
-
docId:
string
-
request:
Speechify.tts.ListChunksKnowledgeBasesRequest
-
requestOptions:
KnowledgeBases.RequestOptions
-
-
client.tts.knowledgeBases.search({ ...params }) -> Speechify.SearchKnowledgeBasesResponse
-
-
-
Semantic search across a caller-owned list of knowledge bases. Returns ranked chunks with source filename and a cosine-similarity score. Limited to 50 results per request.
-
-
-
await client.tts.knowledgeBases.search({ query: "query", kbIds: ["kb_ids"], });
-
-
-
request:
Speechify.tts.SearchKnowledgeBasesRequest
-
requestOptions:
KnowledgeBases.RequestOptions
-
-
client.tts.memories.delete(memoryId, { ...params }) -> void
-
-
-
Soft-delete one memory row.
-
-
-
await client.tts.memories.delete("memoryId");
-
-
-
memoryId:
string
-
request:
Speechify.tts.DeleteMemoriesRequest
-
requestOptions:
Memories.RequestOptions
-
-
client.tts.phoneNumbers.list() -> unknown
-
-
-
List all phone numbers in the caller's workspace.
-
-
-
await client.tts.phoneNumbers.list();
-
-
-
requestOptions:
PhoneNumbers.RequestOptions
-
-
client.tts.phoneNumbers.import({ ...params }) -> unknown
-
-
-
Import a phone number into the workspace. The
sourcefield determines the provisioning path:livekit- LiveKit purchases the number on your behalf. US inbound only. Quickest path for local testing.twilio- Provide your Twilio Account SID, Auth Token, and the E.164 number you already own. We provision an Elastic SIP Trunk on your Twilio account automatically.byoc- Provide an existing SIP trunk ID. The number is registered against that trunk.
Returns 402 when the workspace has reached the 100-number cap.
-
-
-
await client.tts.phoneNumbers.import({ key: "value", });
-
-
-
request:
unknown
-
requestOptions:
PhoneNumbers.RequestOptions
-
-
client.tts.phoneNumbers.get(id, { ...params }) -> unknown
-
-
-
Retrieve a phone number by ID.
-
-
-
await client.tts.phoneNumbers.get("id");
-
-
-
id:
string
-
request:
Speechify.tts.GetPhoneNumbersRequest
-
requestOptions:
PhoneNumbers.RequestOptions
-
-
client.tts.phoneNumbers.delete(id, { ...params }) -> void
-
-
-
Delete a phone number from the workspace. For Twilio and LiveKit numbers this also deprovisions the backing SIP trunk and dispatch rule on LiveKit Cloud.
-
-
-
await client.tts.phoneNumbers.delete("id");
-
-
-
id:
string
-
request:
Speechify.tts.DeletePhoneNumbersRequest
-
requestOptions:
PhoneNumbers.RequestOptions
-
-
client.tts.phoneNumbers.update(id, { ...params }) -> unknown
-
-
-
Update a phone number. Only
labelandagent_idare mutable;sourceande164are immutable after import. Passnullforagent_idto unbind the number from its current agent.
-
-
-
await client.tts.phoneNumbers.update("id", { body: { key: "value", }, });
-
-
-
id:
string
-
request:
Speechify.tts.UpdatePhoneNumbersRequest
-
requestOptions:
PhoneNumbers.RequestOptions
-
-
client.tts.sipTrunks.list() -> unknown
-
-
-
List all SIP trunks in the caller's workspace.
-
-
-
await client.tts.sipTrunks.list();
-
-
-
requestOptions:
SipTrunks.RequestOptions
-
-
client.tts.sipTrunks.create({ ...params }) -> unknown
-
-
-
Create a SIP trunk. For
kind=byocsupplysip_addressplus optional digest credentials and IP allowlist. Forkind=twiliouseImportPhoneNumberwith atwiliospec instead - trunk creation is handled automatically. Returns 402 when the workspace has reached the 20-trunk cap.
-
-
-
await client.tts.sipTrunks.create({ key: "value", });
-
-
-
request:
unknown
-
requestOptions:
SipTrunks.RequestOptions
-
-
client.tts.sipTrunks.get(id, { ...params }) -> unknown
-
-
-
Retrieve a SIP trunk by ID.
-
-
-
await client.tts.sipTrunks.get("id");
-
-
-
id:
string
-
request:
Speechify.tts.GetSipTrunksRequest
-
requestOptions:
SipTrunks.RequestOptions
-
-
client.tts.sipTrunks.delete(id, { ...params }) -> void
-
-
-
Delete a SIP trunk. This also removes the backing LiveKit inbound trunk, outbound trunk, and dispatch rule if they were provisioned by us. Phone numbers attached to this trunk are left in place but become non-functional until rebound to a new trunk.
-
-
-
await client.tts.sipTrunks.delete("id");
-
-
-
id:
string
-
request:
Speechify.tts.DeleteSipTrunksRequest
-
requestOptions:
SipTrunks.RequestOptions
-
-
client.tts.outboundCalls.create({ ...params }) -> unknown
-
-
-
Place an outbound call from an agent to a phone number. LiveKit originates the SIP INVITE through the outbound trunk bound to the agent's workspace; the agent worker is dispatched into the room automatically.
The response is returned as soon as LiveKit accepts the INVITE. Poll
GET /v1/conversations/{conversation_id}for status transitions:pendingβactive(answered) βcompleted.Requires a Twilio or BYOC trunk. LiveKit-native numbers are inbound-only.
-
-
-
await client.tts.outboundCalls.create({ key: "value", });
-
-
-
request:
unknown
-
requestOptions:
OutboundCalls.RequestOptions
-
-
client.tts.workspaces.list() -> Speechify.TenantsListResponse
-
-
-
List every workspace the authenticated user belongs to. Powers the workspace switcher.
-
-
-
await client.tts.workspaces.list();
-
-
-
requestOptions:
Workspaces.RequestOptions
-
-
client.tts.workspaces.create({ ...params }) -> Speechify.Tenant
-
-
-
Create a new workspace with the authenticated user as owner. The caller must switch their active workspace client-side via the
X-Tenant-IDheader to act on the new tenant.
-
-
-
await client.tts.workspaces.create();
-
-
-
request:
Speechify.tts.CreateWorkspaceRequest
-
requestOptions:
Workspaces.RequestOptions
-
-
client.tts.workspaces.getCurrent() -> Speechify.Tenant
-
-
-
Retrieve the workspace currently selected by the caller (via
X-Tenant-IDor auto-resolved).
-
-
-
await client.tts.workspaces.getCurrent();
-
-
-
requestOptions:
Workspaces.RequestOptions
-
-
client.tts.workspaces.updateCurrent({ ...params }) -> Speechify.Tenant
-
-
-
Rename the current workspace. Owner or admin only.
-
-
-
await client.tts.workspaces.updateCurrent({ name: "name", });
-
-
-
request:
Speechify.tts.UpdateWorkspaceRequest
-
requestOptions:
Workspaces.RequestOptions
-
-
client.tts.workspaces.listMembers() -> Speechify.MembersListResponse
-
-
-
List every member of the current workspace. Any member may call this.
-
-
-
await client.tts.workspaces.listMembers();
-
-
-
requestOptions:
Workspaces.RequestOptions
-
-
client.tts.workspaces.leave() -> void
-
-
-
Remove the authenticated caller from the current workspace. Refused with 409 when the caller is the last owner β promote another member to owner first.
-
-
-
await client.tts.workspaces.leave();
-
-
-
requestOptions:
Workspaces.RequestOptions
-
-
client.tts.workspaces.removeMember(userUid, { ...params }) -> void
-
-
-
Remove a member from the current workspace. Owner or admin only. The caller cannot remove themselves β use
POST /v1/tenants/current/members/leaveinstead.
-
-
-
await client.tts.workspaces.removeMember("user_uid");
-
-
-
userUid:
string
-
request:
Speechify.tts.RemoveMemberWorkspacesRequest
-
requestOptions:
Workspaces.RequestOptions
-
-
client.tts.workspaces.updateMemberRole(userUid, { ...params }) -> Speechify.Member
-
-
-
Change a member's role. Owner only β admins may add or remove members but may not change roles. Refused with 409 when demoting the last remaining owner.
-
-
-
await client.tts.workspaces.updateMemberRole("user_uid", { role: "owner", });
-
-
-
userUid:
string
-
request:
Speechify.tts.UpdateMemberRoleRequest
-
requestOptions:
Workspaces.RequestOptions
-
-
client.tts.workspaces.listInvites() -> Speechify.InvitesListResponse
-
-
-
List outstanding invites for the current workspace. Invite tokens are redacted.
-
-
-
await client.tts.workspaces.listInvites();
-
-
-
requestOptions:
Workspaces.RequestOptions
-
-
client.tts.workspaces.createInvite({ ...params }) -> Speechify.Invite
-
-
-
Create an invite to the current workspace. Owner or admin only. The response contains the invite token ONCE β subsequent list calls redact it.
-
-
-
await client.tts.workspaces.createInvite({ email: "email", });
-
-
-
request:
Speechify.tts.CreateInviteRequest
-
requestOptions:
Workspaces.RequestOptions
-
-
client.tts.workspaces.revokeInvite(id, { ...params }) -> void
-
-
-
Revoke an outstanding invite. Owner or admin only. Idempotent.
-
-
-
await client.tts.workspaces.revokeInvite("id");
-
-
-
id:
string
-
request:
Speechify.tts.RevokeInviteWorkspacesRequest
-
requestOptions:
Workspaces.RequestOptions
-
-
client.tts.workspaces.acceptInvite(token, { ...params }) -> Speechify.Tenant
-
-
-
Accept a workspace invite. The authenticated caller is joined to the invite's workspace as a member. Expired, revoked, or already-accepted tokens return 404 to avoid token enumeration.
-
-
-
await client.tts.workspaces.acceptInvite("token");
-
-
-
token:
string
-
request:
Speechify.tts.AcceptInviteWorkspacesRequest
-
requestOptions:
Workspaces.RequestOptions
-
-
client.tts.workspaces.previewInvite(token, { ...params }) -> Speechify.InvitePreview
-
-
-
Preview a workspace invite without authenticating. Returns the workspace name, inviter details, and expiry so the
/join/{token}page can render before the recipient signs in. Anyone with the token can already accept, so this endpoint deliberately surfaces the same information a caller would see after accepting. Invalid tokens (unknown, expired, revoked, already-accepted, or pointing at a soft-deleted workspace) collapse to a single 404 to prevent enumeration.
-
-
-
await client.tts.workspaces.previewInvite("token");
-
-
-
token:
string
-
request:
Speechify.tts.PreviewInviteWorkspacesRequest
-
requestOptions:
Workspaces.RequestOptions
-
-
client.tts.workspaces.transferWorkspaceOwner({ ...params }) -> void
-
-
-
Transfer ownership of the current workspace atomically. Promotes the target member to owner and demotes the caller to admin in a single transaction. Owner-only; admins cannot hand off a role they were never granted. Prefer this over two PATCH calls to
/v1/tenants/current/members/{user_uid}: a sole-owner caller cannot demote themselves first without tripping the last-owner guard, which this endpoint sidesteps by promoting before demoting.
-
-
-
await client.tts.workspaces.transferWorkspaceOwner({ userUid: "user_uid", });
-
-
-
request:
Speechify.tts.TransferOwnershipRequest
-
requestOptions:
Workspaces.RequestOptions
-
-