telnyx 7.23.0 → 7.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/client.d.mts +27 -12
- package/client.d.mts.map +1 -1
- package/client.d.ts +27 -12
- package/client.d.ts.map +1 -1
- package/client.js +15 -0
- package/client.js.map +1 -1
- package/client.mjs +15 -0
- package/client.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/ai/ai.d.mts +11 -6
- package/resources/ai/ai.d.mts.map +1 -1
- package/resources/ai/ai.d.ts +11 -6
- package/resources/ai/ai.d.ts.map +1 -1
- package/resources/ai/ai.js +4 -0
- package/resources/ai/ai.js.map +1 -1
- package/resources/ai/ai.mjs +4 -0
- package/resources/ai/ai.mjs.map +1 -1
- package/resources/ai/assistants/assistants.d.mts +469 -35
- package/resources/ai/assistants/assistants.d.mts.map +1 -1
- package/resources/ai/assistants/assistants.d.ts +469 -35
- package/resources/ai/assistants/assistants.d.ts.map +1 -1
- package/resources/ai/assistants/assistants.js +79 -2
- package/resources/ai/assistants/assistants.js.map +1 -1
- package/resources/ai/assistants/assistants.mjs +79 -2
- package/resources/ai/assistants/assistants.mjs.map +1 -1
- package/resources/ai/assistants/deleted.d.mts +60 -0
- package/resources/ai/assistants/deleted.d.mts.map +1 -0
- package/resources/ai/assistants/deleted.d.ts +60 -0
- package/resources/ai/assistants/deleted.d.ts.map +1 -0
- package/resources/ai/assistants/deleted.js +49 -0
- package/resources/ai/assistants/deleted.js.map +1 -0
- package/resources/ai/assistants/deleted.mjs +45 -0
- package/resources/ai/assistants/deleted.mjs.map +1 -0
- package/resources/ai/assistants/index.d.mts +2 -1
- package/resources/ai/assistants/index.d.mts.map +1 -1
- package/resources/ai/assistants/index.d.ts +2 -1
- package/resources/ai/assistants/index.d.ts.map +1 -1
- package/resources/ai/assistants/index.js +3 -1
- package/resources/ai/assistants/index.js.map +1 -1
- package/resources/ai/assistants/index.mjs +1 -0
- package/resources/ai/assistants/index.mjs.map +1 -1
- package/resources/ai/assistants/versions.d.mts +38 -2
- package/resources/ai/assistants/versions.d.mts.map +1 -1
- package/resources/ai/assistants/versions.d.ts +38 -2
- package/resources/ai/assistants/versions.d.ts.map +1 -1
- package/resources/ai/chat.d.mts +7 -2
- package/resources/ai/chat.d.mts.map +1 -1
- package/resources/ai/chat.d.ts +7 -2
- package/resources/ai/chat.d.ts.map +1 -1
- package/resources/ai/collections/collections.d.mts +3 -3
- package/resources/ai/collections/collections.d.mts.map +1 -1
- package/resources/ai/collections/collections.d.ts +3 -3
- package/resources/ai/collections/collections.d.ts.map +1 -1
- package/resources/ai/collections/collections.js.map +1 -1
- package/resources/ai/collections/collections.mjs.map +1 -1
- package/resources/ai/collections/index.d.mts +1 -1
- package/resources/ai/collections/index.d.mts.map +1 -1
- package/resources/ai/collections/index.d.ts +1 -1
- package/resources/ai/collections/index.d.ts.map +1 -1
- package/resources/ai/collections/index.js.map +1 -1
- package/resources/ai/collections/index.mjs.map +1 -1
- package/resources/ai/collections/sources.d.mts +32 -5
- package/resources/ai/collections/sources.d.mts.map +1 -1
- package/resources/ai/collections/sources.d.ts +32 -5
- package/resources/ai/collections/sources.d.ts.map +1 -1
- package/resources/ai/collections/sources.js.map +1 -1
- package/resources/ai/collections/sources.mjs.map +1 -1
- package/resources/ai/embeddings/embeddings.d.mts +1 -1
- package/resources/ai/embeddings/embeddings.d.ts +1 -1
- package/resources/ai/embeddings/embeddings.js +1 -1
- package/resources/ai/embeddings/embeddings.mjs +1 -1
- package/resources/ai/index.d.mts +3 -2
- package/resources/ai/index.d.mts.map +1 -1
- package/resources/ai/index.d.ts +3 -2
- package/resources/ai/index.d.ts.map +1 -1
- package/resources/ai/index.js +9 -7
- package/resources/ai/index.js.map +1 -1
- package/resources/ai/index.mjs +1 -0
- package/resources/ai/index.mjs.map +1 -1
- package/resources/ai/memory/index.d.mts +3 -0
- package/resources/ai/memory/index.d.mts.map +1 -0
- package/resources/ai/memory/index.d.ts +3 -0
- package/resources/ai/memory/index.d.ts.map +1 -0
- package/resources/ai/memory/index.js +9 -0
- package/resources/ai/memory/index.js.map +1 -0
- package/resources/ai/memory/index.mjs +4 -0
- package/resources/ai/memory/index.mjs.map +1 -0
- package/resources/ai/memory/memory.d.mts +10 -0
- package/resources/ai/memory/memory.d.mts.map +1 -0
- package/resources/ai/memory/memory.d.ts +10 -0
- package/resources/ai/memory/memory.d.ts.map +1 -0
- package/resources/ai/memory/memory.js +17 -0
- package/resources/ai/memory/memory.js.map +1 -0
- package/resources/ai/memory/memory.mjs +12 -0
- package/resources/ai/memory/memory.mjs.map +1 -0
- package/resources/ai/memory/namespaces/index.d.mts +4 -0
- package/resources/ai/memory/namespaces/index.d.mts.map +1 -0
- package/resources/ai/memory/namespaces/index.d.ts +4 -0
- package/resources/ai/memory/namespaces/index.d.ts.map +1 -0
- package/resources/ai/memory/namespaces/index.js +11 -0
- package/resources/ai/memory/namespaces/index.js.map +1 -0
- package/resources/ai/memory/namespaces/index.mjs +5 -0
- package/resources/ai/memory/namespaces/index.mjs.map +1 -0
- package/resources/ai/memory/namespaces/namespaces.d.mts +110 -0
- package/resources/ai/memory/namespaces/namespaces.d.mts.map +1 -0
- package/resources/ai/memory/namespaces/namespaces.d.ts +110 -0
- package/resources/ai/memory/namespaces/namespaces.d.ts.map +1 -0
- package/resources/ai/memory/namespaces/namespaces.js +81 -0
- package/resources/ai/memory/namespaces/namespaces.js.map +1 -0
- package/resources/ai/memory/namespaces/namespaces.mjs +76 -0
- package/resources/ai/memory/namespaces/namespaces.mjs.map +1 -0
- package/resources/ai/memory/namespaces/profiles/index.d.mts +4 -0
- package/resources/ai/memory/namespaces/profiles/index.d.mts.map +1 -0
- package/resources/ai/memory/namespaces/profiles/index.d.ts +4 -0
- package/resources/ai/memory/namespaces/profiles/index.d.ts.map +1 -0
- package/resources/ai/memory/namespaces/profiles/index.js +11 -0
- package/resources/ai/memory/namespaces/profiles/index.js.map +1 -0
- package/resources/ai/memory/namespaces/profiles/index.mjs +5 -0
- package/resources/ai/memory/namespaces/profiles/index.mjs.map +1 -0
- package/resources/ai/memory/namespaces/profiles/memories.d.mts +118 -0
- package/resources/ai/memory/namespaces/profiles/memories.d.mts.map +1 -0
- package/resources/ai/memory/namespaces/profiles/memories.d.ts +118 -0
- package/resources/ai/memory/namespaces/profiles/memories.d.ts.map +1 -0
- package/resources/ai/memory/namespaces/profiles/memories.js +63 -0
- package/resources/ai/memory/namespaces/profiles/memories.js.map +1 -0
- package/resources/ai/memory/namespaces/profiles/memories.mjs +59 -0
- package/resources/ai/memory/namespaces/profiles/memories.mjs.map +1 -0
- package/resources/ai/memory/namespaces/profiles/profiles.d.mts +324 -0
- package/resources/ai/memory/namespaces/profiles/profiles.d.mts.map +1 -0
- package/resources/ai/memory/namespaces/profiles/profiles.d.ts +324 -0
- package/resources/ai/memory/namespaces/profiles/profiles.d.ts.map +1 -0
- package/resources/ai/memory/namespaces/profiles/profiles.js +161 -0
- package/resources/ai/memory/namespaces/profiles/profiles.js.map +1 -0
- package/resources/ai/memory/namespaces/profiles/profiles.mjs +156 -0
- package/resources/ai/memory/namespaces/profiles/profiles.mjs.map +1 -0
- package/resources/ai/memory/namespaces/profiles/sources.d.mts +163 -0
- package/resources/ai/memory/namespaces/profiles/sources.d.mts.map +1 -0
- package/resources/ai/memory/namespaces/profiles/sources.d.ts +163 -0
- package/resources/ai/memory/namespaces/profiles/sources.d.ts.map +1 -0
- package/resources/ai/memory/namespaces/profiles/sources.js +80 -0
- package/resources/ai/memory/namespaces/profiles/sources.js.map +1 -0
- package/resources/ai/memory/namespaces/profiles/sources.mjs +76 -0
- package/resources/ai/memory/namespaces/profiles/sources.mjs.map +1 -0
- package/resources/ai/memory/namespaces/profiles.d.mts +2 -0
- package/resources/ai/memory/namespaces/profiles.d.mts.map +1 -0
- package/resources/ai/memory/namespaces/profiles.d.ts +2 -0
- package/resources/ai/memory/namespaces/profiles.d.ts.map +1 -0
- package/resources/ai/memory/namespaces/profiles.js +6 -0
- package/resources/ai/memory/namespaces/profiles.js.map +1 -0
- package/resources/ai/memory/namespaces/profiles.mjs +3 -0
- package/resources/ai/memory/namespaces/profiles.mjs.map +1 -0
- package/resources/ai/memory/namespaces/settings.d.mts +108 -0
- package/resources/ai/memory/namespaces/settings.d.mts.map +1 -0
- package/resources/ai/memory/namespaces/settings.d.ts +108 -0
- package/resources/ai/memory/namespaces/settings.d.ts.map +1 -0
- package/resources/ai/memory/namespaces/settings.js +54 -0
- package/resources/ai/memory/namespaces/settings.js.map +1 -0
- package/resources/ai/memory/namespaces/settings.mjs +50 -0
- package/resources/ai/memory/namespaces/settings.mjs.map +1 -0
- package/resources/ai/memory/namespaces.d.mts +2 -0
- package/resources/ai/memory/namespaces.d.mts.map +1 -0
- package/resources/ai/memory/namespaces.d.ts +2 -0
- package/resources/ai/memory/namespaces.d.ts.map +1 -0
- package/resources/ai/memory/namespaces.js +6 -0
- package/resources/ai/memory/namespaces.js.map +1 -0
- package/resources/ai/memory/namespaces.mjs +3 -0
- package/resources/ai/memory/namespaces.mjs.map +1 -0
- package/resources/ai/memory.d.mts +2 -0
- package/resources/ai/memory.d.mts.map +1 -0
- package/resources/ai/memory.d.ts +2 -0
- package/resources/ai/memory.d.ts.map +1 -0
- package/resources/ai/memory.js +6 -0
- package/resources/ai/memory.js.map +1 -0
- package/resources/ai/memory.mjs +3 -0
- package/resources/ai/memory.mjs.map +1 -0
- package/resources/ai/openai/chat.d.mts +7 -2
- package/resources/ai/openai/chat.d.mts.map +1 -1
- package/resources/ai/openai/chat.d.ts +7 -2
- package/resources/ai/openai/chat.d.ts.map +1 -1
- package/resources/ai/tools.d.mts +3 -4
- package/resources/ai/tools.d.mts.map +1 -1
- package/resources/ai/tools.d.ts +3 -4
- package/resources/ai/tools.d.ts.map +1 -1
- package/resources/ai/tools.js +5 -2
- package/resources/ai/tools.js.map +1 -1
- package/resources/ai/tools.mjs +5 -2
- package/resources/ai/tools.mjs.map +1 -1
- package/resources/ai/typesafe/v1.d.mts +25 -14
- package/resources/ai/typesafe/v1.d.mts.map +1 -1
- package/resources/ai/typesafe/v1.d.ts +25 -14
- package/resources/ai/typesafe/v1.d.ts.map +1 -1
- package/resources/ai/typesafe/v1.js +15 -10
- package/resources/ai/typesafe/v1.js.map +1 -1
- package/resources/ai/typesafe/v1.mjs +15 -10
- package/resources/ai/typesafe/v1.mjs.map +1 -1
- package/resources/calls/actions.d.mts +119 -22
- package/resources/calls/actions.d.mts.map +1 -1
- package/resources/calls/actions.d.ts +119 -22
- package/resources/calls/actions.d.ts.map +1 -1
- package/resources/calls/actions.js +31 -0
- package/resources/calls/actions.js.map +1 -1
- package/resources/calls/actions.mjs +31 -0
- package/resources/calls/actions.mjs.map +1 -1
- package/resources/calls/calls.d.mts +58 -15
- package/resources/calls/calls.d.mts.map +1 -1
- package/resources/calls/calls.d.ts +58 -15
- package/resources/calls/calls.d.ts.map +1 -1
- package/resources/calls/calls.js +3 -0
- package/resources/calls/calls.js.map +1 -1
- package/resources/calls/calls.mjs +3 -0
- package/resources/calls/calls.mjs.map +1 -1
- package/resources/calls/index.d.mts +1 -1
- package/resources/calls/index.d.mts.map +1 -1
- package/resources/calls/index.d.ts +1 -1
- package/resources/calls/index.d.ts.map +1 -1
- package/resources/calls/index.js.map +1 -1
- package/resources/calls/index.mjs.map +1 -1
- package/resources/conferences/actions.d.mts +7 -1
- package/resources/conferences/actions.d.mts.map +1 -1
- package/resources/conferences/actions.d.ts +7 -1
- package/resources/conferences/actions.d.ts.map +1 -1
- package/resources/dir/dir.d.mts +220 -28
- package/resources/dir/dir.d.mts.map +1 -1
- package/resources/dir/dir.d.ts +220 -28
- package/resources/dir/dir.d.ts.map +1 -1
- package/resources/dir/dir.js +77 -13
- package/resources/dir/dir.js.map +1 -1
- package/resources/dir/dir.mjs +77 -13
- package/resources/dir/dir.mjs.map +1 -1
- package/resources/dir/index.d.mts +1 -1
- package/resources/dir/index.d.mts.map +1 -1
- package/resources/dir/index.d.ts +1 -1
- package/resources/dir/index.d.ts.map +1 -1
- package/resources/dir/index.js.map +1 -1
- package/resources/dir/index.mjs.map +1 -1
- package/resources/dir/phone-numbers.d.mts +8 -4
- package/resources/dir/phone-numbers.d.mts.map +1 -1
- package/resources/dir/phone-numbers.d.ts +8 -4
- package/resources/dir/phone-numbers.d.ts.map +1 -1
- package/resources/dir/phone-numbers.js +4 -4
- package/resources/dir/phone-numbers.mjs +4 -4
- package/resources/dir/references.d.mts +9 -6
- package/resources/dir/references.d.mts.map +1 -1
- package/resources/dir/references.d.ts +9 -6
- package/resources/dir/references.d.ts.map +1 -1
- package/resources/email-blocks/email-blocks.d.mts +12 -4
- package/resources/email-blocks/email-blocks.d.mts.map +1 -1
- package/resources/email-blocks/email-blocks.d.ts +12 -4
- package/resources/email-blocks/email-blocks.d.ts.map +1 -1
- package/resources/email-blocks/email-blocks.js +5 -3
- package/resources/email-blocks/email-blocks.js.map +1 -1
- package/resources/email-blocks/email-blocks.mjs +5 -3
- package/resources/email-blocks/email-blocks.mjs.map +1 -1
- package/resources/email-blocks/imports.d.mts +20 -4
- package/resources/email-blocks/imports.d.mts.map +1 -1
- package/resources/email-blocks/imports.d.ts +20 -4
- package/resources/email-blocks/imports.d.ts.map +1 -1
- package/resources/email-blocks/imports.js +17 -3
- package/resources/email-blocks/imports.js.map +1 -1
- package/resources/email-blocks/imports.mjs +17 -3
- package/resources/email-blocks/imports.mjs.map +1 -1
- package/resources/email-domains/email-domains.d.mts +98 -1
- package/resources/email-domains/email-domains.d.mts.map +1 -1
- package/resources/email-domains/email-domains.d.ts +98 -1
- package/resources/email-domains/email-domains.d.ts.map +1 -1
- package/resources/email-domains/email-domains.js +21 -0
- package/resources/email-domains/email-domains.js.map +1 -1
- package/resources/email-domains/email-domains.mjs +21 -0
- package/resources/email-domains/email-domains.mjs.map +1 -1
- package/resources/email-domains/index.d.mts +1 -1
- package/resources/email-domains/index.d.mts.map +1 -1
- package/resources/email-domains/index.d.ts +1 -1
- package/resources/email-domains/index.d.ts.map +1 -1
- package/resources/email-domains/index.js.map +1 -1
- package/resources/email-domains/index.mjs.map +1 -1
- package/resources/email-domains/webhooks.d.mts +6 -4
- package/resources/email-domains/webhooks.d.mts.map +1 -1
- package/resources/email-domains/webhooks.d.ts +6 -4
- package/resources/email-domains/webhooks.d.ts.map +1 -1
- package/resources/email-events.d.mts +162 -28
- package/resources/email-events.d.mts.map +1 -1
- package/resources/email-events.d.ts +162 -28
- package/resources/email-events.d.ts.map +1 -1
- package/resources/email-events.js +15 -6
- package/resources/email-events.js.map +1 -1
- package/resources/email-events.mjs +15 -6
- package/resources/email-events.mjs.map +1 -1
- package/resources/email-inboxes/drafts.d.mts +31 -1
- package/resources/email-inboxes/drafts.d.mts.map +1 -1
- package/resources/email-inboxes/drafts.d.ts +31 -1
- package/resources/email-inboxes/drafts.d.ts.map +1 -1
- package/resources/email-inboxes/drafts.js.map +1 -1
- package/resources/email-inboxes/drafts.mjs.map +1 -1
- package/resources/email-messages/email-messages.d.mts +174 -43
- package/resources/email-messages/email-messages.d.mts.map +1 -1
- package/resources/email-messages/email-messages.d.ts +174 -43
- package/resources/email-messages/email-messages.d.ts.map +1 -1
- package/resources/email-messages/email-messages.js +39 -7
- package/resources/email-messages/email-messages.js.map +1 -1
- package/resources/email-messages/email-messages.mjs +39 -7
- package/resources/email-messages/email-messages.mjs.map +1 -1
- package/resources/email-messages/index.d.mts +1 -1
- package/resources/email-messages/index.d.mts.map +1 -1
- package/resources/email-messages/index.d.ts +1 -1
- package/resources/email-messages/index.d.ts.map +1 -1
- package/resources/email-messages/index.js.map +1 -1
- package/resources/email-messages/index.mjs.map +1 -1
- package/resources/email-messages/recipients.d.mts +2 -2
- package/resources/email-messages/recipients.d.mts.map +1 -1
- package/resources/email-messages/recipients.d.ts +2 -2
- package/resources/email-messages/recipients.d.ts.map +1 -1
- package/resources/email-templates.d.mts +170 -0
- package/resources/email-templates.d.mts.map +1 -1
- package/resources/email-templates.d.ts +170 -0
- package/resources/email-templates.d.ts.map +1 -1
- package/resources/email-templates.js +6 -0
- package/resources/email-templates.js.map +1 -1
- package/resources/email-templates.mjs +6 -0
- package/resources/email-templates.mjs.map +1 -1
- package/resources/enterprises/dir.d.mts +17 -1
- package/resources/enterprises/dir.d.mts.map +1 -1
- package/resources/enterprises/dir.d.ts +17 -1
- package/resources/enterprises/dir.d.ts.map +1 -1
- package/resources/enterprises/enterprises.d.mts +237 -23
- package/resources/enterprises/enterprises.d.mts.map +1 -1
- package/resources/enterprises/enterprises.d.ts +237 -23
- package/resources/enterprises/enterprises.d.ts.map +1 -1
- package/resources/enterprises/enterprises.js +26 -4
- package/resources/enterprises/enterprises.js.map +1 -1
- package/resources/enterprises/enterprises.mjs +26 -4
- package/resources/enterprises/enterprises.mjs.map +1 -1
- package/resources/enterprises/index.d.mts +1 -0
- package/resources/enterprises/index.d.mts.map +1 -1
- package/resources/enterprises/index.d.ts +1 -0
- package/resources/enterprises/index.d.ts.map +1 -1
- package/resources/enterprises/index.js +3 -1
- package/resources/enterprises/index.js.map +1 -1
- package/resources/enterprises/index.mjs +1 -0
- package/resources/enterprises/index.mjs.map +1 -1
- package/resources/enterprises/reputation/loa.d.mts +61 -1
- package/resources/enterprises/reputation/loa.d.mts.map +1 -1
- package/resources/enterprises/reputation/loa.d.ts +61 -1
- package/resources/enterprises/reputation/loa.d.ts.map +1 -1
- package/resources/enterprises/verify-email.d.mts +91 -0
- package/resources/enterprises/verify-email.d.mts.map +1 -0
- package/resources/enterprises/verify-email.d.ts +91 -0
- package/resources/enterprises/verify-email.d.ts.map +1 -0
- package/resources/enterprises/verify-email.js +55 -0
- package/resources/enterprises/verify-email.js.map +1 -0
- package/resources/enterprises/verify-email.mjs +51 -0
- package/resources/enterprises/verify-email.mjs.map +1 -0
- package/resources/index.d.mts +8 -6
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +8 -6
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +7 -3
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +2 -0
- package/resources/index.mjs.map +1 -1
- package/resources/infringement-claims.d.mts +4 -0
- package/resources/infringement-claims.d.mts.map +1 -1
- package/resources/infringement-claims.d.ts +4 -0
- package/resources/infringement-claims.d.ts.map +1 -1
- package/resources/llm-token-gateway/index.d.mts +3 -0
- package/resources/llm-token-gateway/index.d.mts.map +1 -0
- package/resources/llm-token-gateway/index.d.ts +3 -0
- package/resources/llm-token-gateway/index.d.ts.map +1 -0
- package/resources/llm-token-gateway/index.js +9 -0
- package/resources/llm-token-gateway/index.js.map +1 -0
- package/resources/llm-token-gateway/index.mjs +4 -0
- package/resources/llm-token-gateway/index.mjs.map +1 -0
- package/resources/llm-token-gateway/llm-token-gateway.d.mts +10 -0
- package/resources/llm-token-gateway/llm-token-gateway.d.mts.map +1 -0
- package/resources/llm-token-gateway/llm-token-gateway.d.ts +10 -0
- package/resources/llm-token-gateway/llm-token-gateway.d.ts.map +1 -0
- package/resources/llm-token-gateway/llm-token-gateway.js +17 -0
- package/resources/llm-token-gateway/llm-token-gateway.js.map +1 -0
- package/resources/llm-token-gateway/llm-token-gateway.mjs +12 -0
- package/resources/llm-token-gateway/llm-token-gateway.mjs.map +1 -0
- package/resources/llm-token-gateway/usage.d.mts +260 -0
- package/resources/llm-token-gateway/usage.d.mts.map +1 -0
- package/resources/llm-token-gateway/usage.d.ts +260 -0
- package/resources/llm-token-gateway/usage.d.ts.map +1 -0
- package/resources/llm-token-gateway/usage.js +31 -0
- package/resources/llm-token-gateway/usage.js.map +1 -0
- package/resources/llm-token-gateway/usage.mjs +27 -0
- package/resources/llm-token-gateway/usage.mjs.map +1 -0
- package/resources/llm-token-gateway.d.mts +2 -0
- package/resources/llm-token-gateway.d.mts.map +1 -0
- package/resources/llm-token-gateway.d.ts +2 -0
- package/resources/llm-token-gateway.d.ts.map +1 -0
- package/resources/llm-token-gateway.js +6 -0
- package/resources/llm-token-gateway.js.map +1 -0
- package/resources/llm-token-gateway.mjs +3 -0
- package/resources/llm-token-gateway.mjs.map +1 -0
- package/resources/meeting-sessions/actions.d.mts +7 -1
- package/resources/meeting-sessions/actions.d.mts.map +1 -1
- package/resources/meeting-sessions/actions.d.ts +7 -1
- package/resources/meeting-sessions/actions.d.ts.map +1 -1
- package/resources/meeting-sessions/actions.js +7 -1
- package/resources/meeting-sessions/actions.js.map +1 -1
- package/resources/meeting-sessions/actions.mjs +7 -1
- package/resources/meeting-sessions/actions.mjs.map +1 -1
- package/resources/meeting-sessions/artifacts.d.mts +38 -11
- package/resources/meeting-sessions/artifacts.d.mts.map +1 -1
- package/resources/meeting-sessions/artifacts.d.ts +38 -11
- package/resources/meeting-sessions/artifacts.d.ts.map +1 -1
- package/resources/meeting-sessions/artifacts.js +11 -5
- package/resources/meeting-sessions/artifacts.js.map +1 -1
- package/resources/meeting-sessions/artifacts.mjs +11 -5
- package/resources/meeting-sessions/artifacts.mjs.map +1 -1
- package/resources/meeting-sessions/meeting-sessions.d.mts +71 -32
- package/resources/meeting-sessions/meeting-sessions.d.mts.map +1 -1
- package/resources/meeting-sessions/meeting-sessions.d.ts +71 -32
- package/resources/meeting-sessions/meeting-sessions.d.ts.map +1 -1
- package/resources/meeting-sessions/meeting-sessions.js +6 -8
- package/resources/meeting-sessions/meeting-sessions.js.map +1 -1
- package/resources/meeting-sessions/meeting-sessions.mjs +6 -8
- package/resources/meeting-sessions/meeting-sessions.mjs.map +1 -1
- package/resources/phone-numbers/phone-numbers.d.mts +12 -2
- package/resources/phone-numbers/phone-numbers.d.mts.map +1 -1
- package/resources/phone-numbers/phone-numbers.d.ts +12 -2
- package/resources/phone-numbers/phone-numbers.d.ts.map +1 -1
- package/resources/phone-numbers/phone-numbers.js.map +1 -1
- package/resources/phone-numbers/phone-numbers.mjs.map +1 -1
- package/resources/porting-orders/phone-number-blocks.d.mts +1 -1
- package/resources/porting-orders/phone-number-blocks.d.mts.map +1 -1
- package/resources/porting-orders/phone-number-blocks.d.ts +1 -1
- package/resources/porting-orders/phone-number-blocks.d.ts.map +1 -1
- package/resources/porting-orders/porting-orders.d.mts +1 -1
- package/resources/porting-orders/porting-orders.d.mts.map +1 -1
- package/resources/porting-orders/porting-orders.d.ts +1 -1
- package/resources/porting-orders/porting-orders.d.ts.map +1 -1
- package/resources/porting-orders/porting-orders.js.map +1 -1
- package/resources/porting-orders/porting-orders.mjs.map +1 -1
- package/resources/porting-phone-numbers.d.mts +1 -1
- package/resources/porting-phone-numbers.d.mts.map +1 -1
- package/resources/porting-phone-numbers.d.ts +1 -1
- package/resources/porting-phone-numbers.d.ts.map +1 -1
- package/resources/private-wireless-gateways.d.mts +61 -7
- package/resources/private-wireless-gateways.d.mts.map +1 -1
- package/resources/private-wireless-gateways.d.ts +61 -7
- package/resources/private-wireless-gateways.d.ts.map +1 -1
- package/resources/private-wireless-gateways.js +1 -1
- package/resources/private-wireless-gateways.js.map +1 -1
- package/resources/private-wireless-gateways.mjs +1 -1
- package/resources/private-wireless-gateways.mjs.map +1 -1
- package/resources/requirements.d.mts +2 -2
- package/resources/requirements.d.mts.map +1 -1
- package/resources/requirements.d.ts +2 -2
- package/resources/requirements.d.ts.map +1 -1
- package/resources/spend-limits.d.mts +335 -0
- package/resources/spend-limits.d.mts.map +1 -0
- package/resources/spend-limits.d.ts +335 -0
- package/resources/spend-limits.d.ts.map +1 -0
- package/resources/spend-limits.js +91 -0
- package/resources/spend-limits.js.map +1 -0
- package/resources/spend-limits.mjs +87 -0
- package/resources/spend-limits.mjs.map +1 -0
- package/resources/terms-of-service/agreements.d.mts +12 -0
- package/resources/terms-of-service/agreements.d.mts.map +1 -1
- package/resources/terms-of-service/agreements.d.ts +12 -0
- package/resources/terms-of-service/agreements.d.ts.map +1 -1
- package/resources/terms-of-service/terms-of-service.d.mts +15 -0
- package/resources/terms-of-service/terms-of-service.d.mts.map +1 -1
- package/resources/terms-of-service/terms-of-service.d.ts +15 -0
- package/resources/terms-of-service/terms-of-service.d.ts.map +1 -1
- package/resources/terms-of-service/terms-of-service.js.map +1 -1
- package/resources/terms-of-service/terms-of-service.mjs.map +1 -1
- package/resources/texml/accounts/calls/calls.d.mts +9 -9
- package/resources/texml/accounts/calls/calls.d.mts.map +1 -1
- package/resources/texml/accounts/calls/calls.d.ts +9 -9
- package/resources/texml/accounts/calls/calls.d.ts.map +1 -1
- package/resources/texml/accounts/calls/calls.js +12 -2
- package/resources/texml/accounts/calls/calls.js.map +1 -1
- package/resources/texml/accounts/calls/calls.mjs +12 -2
- package/resources/texml/accounts/calls/calls.mjs.map +1 -1
- package/resources/text-to-speech/text-to-speech.d.mts +65 -11
- package/resources/text-to-speech/text-to-speech.d.mts.map +1 -1
- package/resources/text-to-speech/text-to-speech.d.ts +65 -11
- package/resources/text-to-speech/text-to-speech.d.ts.map +1 -1
- package/resources/text-to-speech/text-to-speech.js +10 -3
- package/resources/text-to-speech/text-to-speech.js.map +1 -1
- package/resources/text-to-speech/text-to-speech.mjs +10 -3
- package/resources/text-to-speech/text-to-speech.mjs.map +1 -1
- package/resources/webhooks.d.mts +417 -9
- package/resources/webhooks.d.mts.map +1 -1
- package/resources/webhooks.d.ts +417 -9
- package/resources/webhooks.d.ts.map +1 -1
- package/resources/whatsapp/phone-numbers/calling-routing.d.mts +89 -0
- package/resources/whatsapp/phone-numbers/calling-routing.d.mts.map +1 -0
- package/resources/whatsapp/phone-numbers/calling-routing.d.ts +89 -0
- package/resources/whatsapp/phone-numbers/calling-routing.d.ts.map +1 -0
- package/resources/whatsapp/phone-numbers/calling-routing.js +65 -0
- package/resources/whatsapp/phone-numbers/calling-routing.js.map +1 -0
- package/resources/whatsapp/phone-numbers/calling-routing.mjs +61 -0
- package/resources/whatsapp/phone-numbers/calling-routing.mjs.map +1 -0
- package/resources/whatsapp/phone-numbers/index.d.mts +1 -0
- package/resources/whatsapp/phone-numbers/index.d.mts.map +1 -1
- package/resources/whatsapp/phone-numbers/index.d.ts +1 -0
- package/resources/whatsapp/phone-numbers/index.d.ts.map +1 -1
- package/resources/whatsapp/phone-numbers/index.js +3 -1
- package/resources/whatsapp/phone-numbers/index.js.map +1 -1
- package/resources/whatsapp/phone-numbers/index.mjs +1 -0
- package/resources/whatsapp/phone-numbers/index.mjs.map +1 -1
- package/resources/whatsapp/phone-numbers/phone-numbers.d.mts +4 -0
- package/resources/whatsapp/phone-numbers/phone-numbers.d.mts.map +1 -1
- package/resources/whatsapp/phone-numbers/phone-numbers.d.ts +4 -0
- package/resources/whatsapp/phone-numbers/phone-numbers.d.ts.map +1 -1
- package/resources/whatsapp/phone-numbers/phone-numbers.js +4 -0
- package/resources/whatsapp/phone-numbers/phone-numbers.js.map +1 -1
- package/resources/whatsapp/phone-numbers/phone-numbers.mjs +4 -0
- package/resources/whatsapp/phone-numbers/phone-numbers.mjs.map +1 -1
- package/src/client.ts +67 -6
- package/src/resources/ai/ai.ts +21 -4
- package/src/resources/ai/assistants/assistants.ts +602 -36
- package/src/resources/ai/assistants/deleted.ts +86 -0
- package/src/resources/ai/assistants/index.ts +12 -0
- package/src/resources/ai/assistants/versions.ts +42 -2
- package/src/resources/ai/chat.ts +7 -2
- package/src/resources/ai/collections/collections.ts +3 -1
- package/src/resources/ai/collections/index.ts +2 -0
- package/src/resources/ai/collections/sources.ts +38 -4
- package/src/resources/ai/embeddings/embeddings.ts +1 -1
- package/src/resources/ai/index.ts +7 -1
- package/src/resources/ai/memory/index.ts +12 -0
- package/src/resources/ai/memory/memory.ts +31 -0
- package/src/resources/ai/memory/namespaces/index.ts +29 -0
- package/src/resources/ai/memory/namespaces/namespaces.ts +194 -0
- package/src/resources/ai/memory/namespaces/profiles/index.ts +35 -0
- package/src/resources/ai/memory/namespaces/profiles/memories.ts +170 -0
- package/src/resources/ai/memory/namespaces/profiles/profiles.ts +482 -0
- package/src/resources/ai/memory/namespaces/profiles/sources.ts +226 -0
- package/src/resources/ai/memory/namespaces/profiles.ts +3 -0
- package/src/resources/ai/memory/namespaces/settings.ts +129 -0
- package/src/resources/ai/memory/namespaces.ts +3 -0
- package/src/resources/ai/memory.ts +3 -0
- package/src/resources/ai/openai/chat.ts +7 -2
- package/src/resources/ai/tools.ts +6 -6
- package/src/resources/ai/typesafe/v1.ts +26 -14
- package/src/resources/calls/actions.ts +126 -19
- package/src/resources/calls/calls.ts +61 -11
- package/src/resources/calls/index.ts +1 -0
- package/src/resources/conferences/actions.ts +8 -1
- package/src/resources/dir/dir.ts +263 -32
- package/src/resources/dir/index.ts +6 -0
- package/src/resources/dir/phone-numbers.ts +8 -4
- package/src/resources/dir/references.ts +9 -6
- package/src/resources/email-blocks/email-blocks.ts +12 -4
- package/src/resources/email-blocks/imports.ts +20 -4
- package/src/resources/email-domains/email-domains.ts +120 -0
- package/src/resources/email-domains/index.ts +1 -0
- package/src/resources/email-domains/webhooks.ts +9 -4
- package/src/resources/email-events.ts +220 -35
- package/src/resources/email-inboxes/drafts.ts +32 -1
- package/src/resources/email-messages/email-messages.ts +191 -47
- package/src/resources/email-messages/index.ts +2 -1
- package/src/resources/email-messages/recipients.ts +6 -2
- package/src/resources/email-templates.ts +185 -0
- package/src/resources/enterprises/dir.ts +19 -1
- package/src/resources/enterprises/enterprises.ts +250 -23
- package/src/resources/enterprises/index.ts +5 -0
- package/src/resources/enterprises/reputation/loa.ts +73 -1
- package/src/resources/enterprises/verify-email.ts +117 -0
- package/src/resources/index.ts +26 -3
- package/src/resources/infringement-claims.ts +4 -0
- package/src/resources/llm-token-gateway/index.ts +4 -0
- package/src/resources/llm-token-gateway/llm-token-gateway.ts +19 -0
- package/src/resources/llm-token-gateway/usage.ts +336 -0
- package/src/resources/llm-token-gateway.ts +3 -0
- package/src/resources/meeting-sessions/actions.ts +7 -1
- package/src/resources/meeting-sessions/artifacts.ts +42 -11
- package/src/resources/meeting-sessions/meeting-sessions.ts +71 -33
- package/src/resources/phone-numbers/phone-numbers.ts +13 -2
- package/src/resources/porting-orders/phone-number-blocks.ts +9 -1
- package/src/resources/porting-orders/porting-orders.ts +9 -1
- package/src/resources/porting-phone-numbers.ts +9 -1
- package/src/resources/private-wireless-gateways.ts +76 -8
- package/src/resources/requirements.ts +2 -2
- package/src/resources/spend-limits.ts +428 -0
- package/src/resources/terms-of-service/agreements.ts +12 -0
- package/src/resources/terms-of-service/terms-of-service.ts +15 -0
- package/src/resources/texml/accounts/calls/calls.ts +20 -10
- package/src/resources/text-to-speech/text-to-speech.ts +73 -11
- package/src/resources/webhooks.ts +511 -6
- package/src/resources/whatsapp/phone-numbers/calling-routing.ts +113 -0
- package/src/resources/whatsapp/phone-numbers/index.ts +7 -0
- package/src/resources/whatsapp/phone-numbers/phone-numbers.ts +18 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -18,6 +18,13 @@ import {
|
|
|
18
18
|
RuleOutput,
|
|
19
19
|
Serve,
|
|
20
20
|
} from './canary-deploys';
|
|
21
|
+
import * as DeletedAPI from './deleted';
|
|
22
|
+
import {
|
|
23
|
+
Deleted,
|
|
24
|
+
DeletedAssistant,
|
|
25
|
+
DeletedAssistantsDefaultFlatPagination,
|
|
26
|
+
DeletedListParams,
|
|
27
|
+
} from './deleted';
|
|
21
28
|
import * as InstructionsAPI from './instructions';
|
|
22
29
|
import { InstructionEnhanceParams, InstructionEnhanceResponse, Instructions } from './instructions';
|
|
23
30
|
import * as ScheduledEventsAPI from './scheduled-events';
|
|
@@ -84,6 +91,7 @@ export class Assistants extends APIResource {
|
|
|
84
91
|
versions: VersionsAPI.Versions = new VersionsAPI.Versions(this._client);
|
|
85
92
|
tags: TagsAPI.Tags = new TagsAPI.Tags(this._client);
|
|
86
93
|
instructions: InstructionsAPI.Instructions = new InstructionsAPI.Instructions(this._client);
|
|
94
|
+
deleted: DeletedAPI.Deleted = new DeletedAPI.Deleted(this._client);
|
|
87
95
|
|
|
88
96
|
/**
|
|
89
97
|
* Retrieve a list of all AI Assistants configured by the user.
|
|
@@ -151,6 +159,20 @@ export class Assistants extends APIResource {
|
|
|
151
159
|
/**
|
|
152
160
|
* Delete an AI Assistant by `assistant_id`.
|
|
153
161
|
*
|
|
162
|
+
* By default this performs a soft delete: the assistant moves to the Recently
|
|
163
|
+
* Deleted list and stays restorable for 30 days, after which it is permanently
|
|
164
|
+
* deleted automatically. The assistant's versions and TeXML application are
|
|
165
|
+
* preserved during the retention window.
|
|
166
|
+
*
|
|
167
|
+
* Pass `hard_delete=true` to skip the retention window and permanently delete the
|
|
168
|
+
* assistant immediately. A hard delete erases the assistant and all of its
|
|
169
|
+
* versions, and deletes its TeXML application unless phone numbers are still
|
|
170
|
+
* assigned to it. It does not delete conversations, recordings, shared tools the
|
|
171
|
+
* assistant referenced, or knowledge-base embeddings.
|
|
172
|
+
*
|
|
173
|
+
* Deletion fails with `400` if other assistants reference this one through a
|
|
174
|
+
* handoff tool or a conversation-flow edge — remove those references first.
|
|
175
|
+
*
|
|
154
176
|
* @example
|
|
155
177
|
* ```ts
|
|
156
178
|
* const assistant = await client.ai.assistants.delete(
|
|
@@ -158,8 +180,13 @@ export class Assistants extends APIResource {
|
|
|
158
180
|
* );
|
|
159
181
|
* ```
|
|
160
182
|
*/
|
|
161
|
-
delete(
|
|
162
|
-
|
|
183
|
+
delete(
|
|
184
|
+
assistantID: string,
|
|
185
|
+
params: AssistantDeleteParams | null | undefined = {},
|
|
186
|
+
options?: RequestOptions,
|
|
187
|
+
): APIPromise<AssistantDeleteResponse> {
|
|
188
|
+
const { hard_delete } = params ?? {};
|
|
189
|
+
return this._client.delete(path`/ai/assistants/${assistantID}`, { query: { hard_delete }, ...options });
|
|
163
190
|
}
|
|
164
191
|
|
|
165
192
|
/**
|
|
@@ -306,6 +333,70 @@ export class Assistants extends APIResource {
|
|
|
306
333
|
]),
|
|
307
334
|
});
|
|
308
335
|
}
|
|
336
|
+
|
|
337
|
+
/**
|
|
338
|
+
* Start a WhatsApp conversation with a customer from the business side. This
|
|
339
|
+
* endpoint:
|
|
340
|
+
*
|
|
341
|
+
* 1. Validates that `from` is a WhatsApp number on your account whose messaging
|
|
342
|
+
* profile has this assistant configured
|
|
343
|
+
* 2. Creates a new `whatsapp_chat` conversation with the provided metadata
|
|
344
|
+
* 3. Asks the assistant to pick one of its approved WhatsApp templates and fill
|
|
345
|
+
* its variables from `content`
|
|
346
|
+
* 4. Sends the template from `from` to `to`
|
|
347
|
+
* 5. Returns the conversation ID and the message ID
|
|
348
|
+
*
|
|
349
|
+
* When the customer replies, the reply is routed to the same conversation and the
|
|
350
|
+
* assistant answers within the 24-hour customer service window. The assistant
|
|
351
|
+
* needs a `whatsapp_template` tool with at least one approved template, data
|
|
352
|
+
* retention enabled and PII redaction disabled.
|
|
353
|
+
*
|
|
354
|
+
* @example
|
|
355
|
+
* ```ts
|
|
356
|
+
* const response = await client.ai.assistants.whatsapp(
|
|
357
|
+
* 'assistant_id',
|
|
358
|
+
* {
|
|
359
|
+
* content:
|
|
360
|
+
* 'Send the login verification code 482913 to the customer.',
|
|
361
|
+
* from: '+13125550001',
|
|
362
|
+
* to: '+13125550002',
|
|
363
|
+
* conversation_metadata: { order_id: 'A1' },
|
|
364
|
+
* },
|
|
365
|
+
* );
|
|
366
|
+
* ```
|
|
367
|
+
*/
|
|
368
|
+
whatsapp(
|
|
369
|
+
assistantID: string,
|
|
370
|
+
params: AssistantWhatsappParams,
|
|
371
|
+
options?: RequestOptions,
|
|
372
|
+
): APIPromise<AssistantWhatsappResponse> {
|
|
373
|
+
const { 'Idempotency-Key': idempotencyKey, ...body } = params;
|
|
374
|
+
return this._client.post(path`/ai/assistants/${assistantID}/chat/whatsapp`, {
|
|
375
|
+
body,
|
|
376
|
+
...options,
|
|
377
|
+
headers: buildHeaders([
|
|
378
|
+
{ ...(idempotencyKey != null ? { 'Idempotency-Key': idempotencyKey } : undefined) },
|
|
379
|
+
options?.headers,
|
|
380
|
+
]),
|
|
381
|
+
});
|
|
382
|
+
}
|
|
383
|
+
|
|
384
|
+
/**
|
|
385
|
+
* Restore a soft-deleted assistant from the Recently Deleted list.
|
|
386
|
+
*
|
|
387
|
+
* The assistant becomes fully active again with its versions and TeXML application
|
|
388
|
+
* as they were at deletion time. Restoring does not re-enable numbers or
|
|
389
|
+
* connections that were released separately after the deletion.
|
|
390
|
+
*
|
|
391
|
+
* @example
|
|
392
|
+
* ```ts
|
|
393
|
+
* const inferenceEmbedding =
|
|
394
|
+
* await client.ai.assistants.restore('assistant_id');
|
|
395
|
+
* ```
|
|
396
|
+
*/
|
|
397
|
+
restore(assistantID: string, options?: RequestOptions): APIPromise<InferenceEmbedding> {
|
|
398
|
+
return this._client.post(path`/ai/assistants/${assistantID}/restore`, options);
|
|
399
|
+
}
|
|
309
400
|
}
|
|
310
401
|
|
|
311
402
|
/**
|
|
@@ -806,6 +897,15 @@ export namespace AssistantTool {
|
|
|
806
897
|
*/
|
|
807
898
|
to: string;
|
|
808
899
|
|
|
900
|
+
/**
|
|
901
|
+
* DTMF digits to send automatically after the transfer destination answers. Useful
|
|
902
|
+
* for reaching an extension behind an IVR (e.g. `"200"` to dial extension 200 once
|
|
903
|
+
* the called party picks up). Allowed characters: `0-9`, `A-D`, `w` (0.5s pause),
|
|
904
|
+
* `W` (1s pause), `*`, `#`. Maximum 64 characters. When omitted, no automatic DTMF
|
|
905
|
+
* is sent.
|
|
906
|
+
*/
|
|
907
|
+
extension?: string;
|
|
908
|
+
|
|
809
909
|
/**
|
|
810
910
|
* The warm transfer message to deliver to this specific target. When set, it takes
|
|
811
911
|
* precedence over the message the assistant composes from
|
|
@@ -817,6 +917,18 @@ export namespace AssistantTool {
|
|
|
817
917
|
* The name of the target.
|
|
818
918
|
*/
|
|
819
919
|
name?: string;
|
|
920
|
+
|
|
921
|
+
/**
|
|
922
|
+
* SIP Authentication password used for SIP challenges. Applies when `to` is a SIP
|
|
923
|
+
* URI.
|
|
924
|
+
*/
|
|
925
|
+
sip_auth_password?: string;
|
|
926
|
+
|
|
927
|
+
/**
|
|
928
|
+
* SIP Authentication username used for SIP challenges. Applies when `to` is a SIP
|
|
929
|
+
* URI.
|
|
930
|
+
*/
|
|
931
|
+
sip_auth_username?: string;
|
|
820
932
|
}
|
|
821
933
|
|
|
822
934
|
export interface CustomHeader {
|
|
@@ -1408,7 +1520,7 @@ export interface ConversationFlow {
|
|
|
1408
1520
|
export interface ConversationFlowReq {
|
|
1409
1521
|
/**
|
|
1410
1522
|
* All nodes in the flow. Must contain `start_node_id`. Each node is a prompt node
|
|
1411
|
-
* (`type: prompt`)
|
|
1523
|
+
* (`type: prompt`), a tool node (`type: tool`), or a speak node (`type: speak`).
|
|
1412
1524
|
*/
|
|
1413
1525
|
nodes: Array<FlowNodeReq | ToolNodeReq | SpeakNodeReq>;
|
|
1414
1526
|
|
|
@@ -1423,6 +1535,73 @@ export interface ConversationFlowReq {
|
|
|
1423
1535
|
edges?: Array<FlowEdge>;
|
|
1424
1536
|
}
|
|
1425
1537
|
|
|
1538
|
+
/**
|
|
1539
|
+
* Splits the conversation between a frontend model that talks to the caller and a
|
|
1540
|
+
* backend model that does the work. On the GPT-Live route the frontend model
|
|
1541
|
+
* cannot call tools at all — when it needs something done it raises a delegation
|
|
1542
|
+
* and waits. On the chat completion route the frontend keeps a single `delegate`
|
|
1543
|
+
* tool that returns immediately, so the conversation carries on while the backend
|
|
1544
|
+
* works. Either way the backend's answer is spoken as commentary or kept as silent
|
|
1545
|
+
* context, depending on `speak_results`. Beta feature.
|
|
1546
|
+
*/
|
|
1547
|
+
export interface DelegationSettings {
|
|
1548
|
+
/**
|
|
1549
|
+
* Whether the assistant delegates work to a backend model. Defaults to `true`: a
|
|
1550
|
+
* GPT-Live assistant with delegation disabled can hold a conversation but can
|
|
1551
|
+
* never look anything up or run a tool.
|
|
1552
|
+
*/
|
|
1553
|
+
enabled?: boolean;
|
|
1554
|
+
|
|
1555
|
+
/**
|
|
1556
|
+
* Run the backend on your own OpenAI-compatible endpoint instead of a
|
|
1557
|
+
* Telnyx-hosted model. As above, a raw `api_key` here is rejected — reference an
|
|
1558
|
+
* integration secret with `external_llm.llm_api_key_ref` instead.
|
|
1559
|
+
*/
|
|
1560
|
+
external_llm?: ExternalLlm;
|
|
1561
|
+
|
|
1562
|
+
/**
|
|
1563
|
+
* Extra instructions for the backend model, in addition to the assistant's own.
|
|
1564
|
+
* Use this for the business rules the backend needs and the talking model does
|
|
1565
|
+
* not.
|
|
1566
|
+
*/
|
|
1567
|
+
instructions?: string;
|
|
1568
|
+
|
|
1569
|
+
/**
|
|
1570
|
+
* Integration secret identifier for the backend model's API key. Required for
|
|
1571
|
+
* models from providers other than Telnyx, OpenAI and Anthropic. A raw `api_key`
|
|
1572
|
+
* is rejected rather than ignored, so that no plaintext credential is stored on
|
|
1573
|
+
* the assistant.
|
|
1574
|
+
*/
|
|
1575
|
+
llm_api_key_ref?: string;
|
|
1576
|
+
|
|
1577
|
+
/**
|
|
1578
|
+
* Who answers a delegation. `telnyx` runs the backend model on Telnyx with the
|
|
1579
|
+
* assistant's own tools, MCP servers and observability. `client` relays the
|
|
1580
|
+
* delegation to a server you host over the WebSocket configured in
|
|
1581
|
+
* `websocket_settings`: Telnyx sends a `session.delegation.created` frame and
|
|
1582
|
+
* waits for your `session.delegation.completed` answer. That answer is text only,
|
|
1583
|
+
* since the socket offers no tool vocabulary. If no socket is connected the
|
|
1584
|
+
* delegation is refused and the assistant tells the caller it cannot look things
|
|
1585
|
+
* up right now. Defaults to `telnyx`.
|
|
1586
|
+
*/
|
|
1587
|
+
mode?: 'telnyx' | 'client';
|
|
1588
|
+
|
|
1589
|
+
/**
|
|
1590
|
+
* The backend model that answers delegations. Must be a model available for AI
|
|
1591
|
+
* Assistants. When enabling `telnyx` delegation, explicitly set this field or
|
|
1592
|
+
* `external_llm.model`; a configuration without either backend model is rejected.
|
|
1593
|
+
* Only applies when `mode` is `telnyx`.
|
|
1594
|
+
*/
|
|
1595
|
+
model?: string;
|
|
1596
|
+
|
|
1597
|
+
/**
|
|
1598
|
+
* Whether the backend's answer is spoken to the caller. When `true` the result is
|
|
1599
|
+
* appended as commentary and paraphrased aloud; when `false` it is kept as silent
|
|
1600
|
+
* context that informs later answers without being read out. Defaults to `true`.
|
|
1601
|
+
*/
|
|
1602
|
+
speak_results?: boolean;
|
|
1603
|
+
}
|
|
1604
|
+
|
|
1426
1605
|
/**
|
|
1427
1606
|
* If `telephony` is enabled, the assistant will be able to make and receive calls.
|
|
1428
1607
|
* If `messaging` is enabled, the assistant will be able to send and receive
|
|
@@ -1623,9 +1802,14 @@ export interface FallbackConfigReq {
|
|
|
1623
1802
|
* Directed transition from one node to a target, gated by a condition.
|
|
1624
1803
|
*
|
|
1625
1804
|
* The target is either another node in the same flow (`NodeTarget`) or a different
|
|
1626
|
-
* assistant (`AssistantTarget`). Multiple edges may share a `start_node_id
|
|
1627
|
-
*
|
|
1628
|
-
*
|
|
1805
|
+
* assistant (`AssistantTarget`). Multiple edges may share a `start_node_id`. On
|
|
1806
|
+
* calls, `expression` conditions are evaluated before the model turn and take
|
|
1807
|
+
* precedence over `llm` conditions regardless of declaration order, while `llm`
|
|
1808
|
+
* conditions are offered to the assistant's model as transition tools and fire
|
|
1809
|
+
* when the model selects one. On chat channels, an `expression` condition that is
|
|
1810
|
+
* true when the turn begins routes before the reply is generated; all conditioned
|
|
1811
|
+
* edges that remain are considered together in declaration order after the reply,
|
|
1812
|
+
* and the first true one wins.
|
|
1629
1813
|
*/
|
|
1630
1814
|
export interface FlowEdge {
|
|
1631
1815
|
/**
|
|
@@ -1653,15 +1837,22 @@ export interface FlowEdge {
|
|
|
1653
1837
|
|
|
1654
1838
|
export namespace FlowEdge {
|
|
1655
1839
|
/**
|
|
1656
|
-
* Edge condition
|
|
1840
|
+
* Edge condition routed by the assistant's LLM from a natural-language prompt.
|
|
1657
1841
|
*
|
|
1658
|
-
*
|
|
1659
|
-
*
|
|
1660
|
-
*
|
|
1842
|
+
* How the edge is decided depends on the channel. On calls, each outgoing `llm`
|
|
1843
|
+
* condition is offered to the assistant's model as a transition tool alongside the
|
|
1844
|
+
* assistant's tools, and the edge fires when the model selects it; the platform
|
|
1845
|
+
* does not evaluate the prompt itself, and instructions that forbid or discourage
|
|
1846
|
+
* tool calls can stop these edges from firing. On chat channels, the edge prompts
|
|
1847
|
+
* are evaluated in a separate model call after the reply, which does not use the
|
|
1848
|
+
* assistant's instructions. Use this for fuzzy intents that aren't expressible as
|
|
1849
|
+
* a deterministic expression (e.g. 'user wants to escalate to a human').
|
|
1661
1850
|
*/
|
|
1662
1851
|
export interface LlmCondition {
|
|
1663
1852
|
/**
|
|
1664
|
-
* Natural-language criterion the
|
|
1853
|
+
* Natural-language criterion the model routes on. On calls this is offered to the
|
|
1854
|
+
* model as the transition tool's description; on chat channels it is judged as a
|
|
1855
|
+
* statement in the post-reply evaluation call.
|
|
1665
1856
|
*/
|
|
1666
1857
|
prompt: string;
|
|
1667
1858
|
|
|
@@ -1843,7 +2034,7 @@ export interface FlowNode {
|
|
|
1843
2034
|
/**
|
|
1844
2035
|
* Per-node voice override (response form).
|
|
1845
2036
|
*/
|
|
1846
|
-
voice_settings?:
|
|
2037
|
+
voice_settings?: InferenceEmbeddingVoiceSettings;
|
|
1847
2038
|
}
|
|
1848
2039
|
|
|
1849
2040
|
/**
|
|
@@ -1927,7 +2118,8 @@ export interface FlowNodeReq {
|
|
|
1927
2118
|
|
|
1928
2119
|
/**
|
|
1929
2120
|
* Node kind discriminator. `prompt` (default) is an LLM-driven step; `tool` is a
|
|
1930
|
-
* standalone tool execution (see `ToolNodeReq`
|
|
2121
|
+
* standalone tool execution and `speak` a scripted message (see `ToolNodeReq` /
|
|
2122
|
+
* `SpeakNodeReq`).
|
|
1931
2123
|
*/
|
|
1932
2124
|
type?: 'prompt';
|
|
1933
2125
|
|
|
@@ -1935,7 +2127,7 @@ export interface FlowNodeReq {
|
|
|
1935
2127
|
* Per-node voice override. Only fields set here override the assistant-level voice
|
|
1936
2128
|
* settings; unset fields cascade.
|
|
1937
2129
|
*/
|
|
1938
|
-
voice_settings?:
|
|
2130
|
+
voice_settings?: InferenceEmbeddingVoiceSettings;
|
|
1939
2131
|
}
|
|
1940
2132
|
|
|
1941
2133
|
export interface HangupTool {
|
|
@@ -2002,6 +2194,17 @@ export interface InferenceEmbedding {
|
|
|
2002
2194
|
*/
|
|
2003
2195
|
conversation_flow?: ConversationFlow;
|
|
2004
2196
|
|
|
2197
|
+
/**
|
|
2198
|
+
* Splits the conversation between a frontend model that talks to the caller and a
|
|
2199
|
+
* backend model that does the work. On the GPT-Live route the frontend model
|
|
2200
|
+
* cannot call tools at all — when it needs something done it raises a delegation
|
|
2201
|
+
* and waits. On the chat completion route the frontend keeps a single `delegate`
|
|
2202
|
+
* tool that returns immediately, so the conversation carries on while the backend
|
|
2203
|
+
* works. Either way the backend's answer is spoken as commentary or kept as silent
|
|
2204
|
+
* context, depending on `speak_results`. Beta feature.
|
|
2205
|
+
*/
|
|
2206
|
+
delegation_settings?: DelegationSettings;
|
|
2207
|
+
|
|
2005
2208
|
description?: string;
|
|
2006
2209
|
|
|
2007
2210
|
/**
|
|
@@ -2140,7 +2343,16 @@ export interface InferenceEmbedding {
|
|
|
2140
2343
|
*/
|
|
2141
2344
|
version_name?: string;
|
|
2142
2345
|
|
|
2143
|
-
voice_settings?:
|
|
2346
|
+
voice_settings?: InferenceEmbeddingVoiceSettings;
|
|
2347
|
+
|
|
2348
|
+
/**
|
|
2349
|
+
* Streams conversation and telephony events to a WebSocket server you host, and
|
|
2350
|
+
* accepts messages injected back into the conversation. Telnyx opens the
|
|
2351
|
+
* connection as a client, once per conversation. Delivery is best effort
|
|
2352
|
+
* throughout: while the connection is down events are dropped rather than queued,
|
|
2353
|
+
* and no socket failure is ever allowed to affect the call. Beta feature.
|
|
2354
|
+
*/
|
|
2355
|
+
websocket_settings?: WebsocketSettings;
|
|
2144
2356
|
|
|
2145
2357
|
/**
|
|
2146
2358
|
* Configuration settings for the assistant's web widget.
|
|
@@ -2182,6 +2394,185 @@ export interface InferenceEmbeddingInterruptionSettings {
|
|
|
2182
2394
|
start_speaking_plan?: StartSpeakingPlan;
|
|
2183
2395
|
}
|
|
2184
2396
|
|
|
2397
|
+
export interface InferenceEmbeddingVoiceSettings {
|
|
2398
|
+
/**
|
|
2399
|
+
* The voice to be used by the voice assistant. Check the full list of
|
|
2400
|
+
* [available voices](https://developers.telnyx.com/docs/tts-stt/tts-available-voices)
|
|
2401
|
+
* via our voices API. To use ElevenLabs, you must reference your ElevenLabs API
|
|
2402
|
+
* key as an integration secret under the `api_key_ref` field. See
|
|
2403
|
+
* [integration secrets documentation](https://developers.telnyx.com/api-reference/integration-secrets/create-a-secret)
|
|
2404
|
+
* for details. For Telnyx voices, use `Telnyx.<model_id>.<voice_id>` (e.g.
|
|
2405
|
+
* Telnyx.KokoroTTS.af_heart). For Soniox voices, use `Soniox.tts-rt-v2.<voice_id>`
|
|
2406
|
+
* (e.g. Soniox.tts-rt-v2.Emma); every Soniox voice speaks all supported languages.
|
|
2407
|
+
* The voice portion of the identifier supports
|
|
2408
|
+
* [dynamic variables](https://developers.telnyx.com/docs/inference/ai-assistants/dynamic-variables)
|
|
2409
|
+
* using mustache syntax (e.g. `Telnyx.Ultra.{{voice_id}}`). The variable is
|
|
2410
|
+
* resolved at call time from your dynamic variables webhook, allowing you to
|
|
2411
|
+
* select the voice dynamically per call.
|
|
2412
|
+
*/
|
|
2413
|
+
voice: string;
|
|
2414
|
+
|
|
2415
|
+
/**
|
|
2416
|
+
* The `identifier` for an integration secret
|
|
2417
|
+
* [/v2/integration_secrets](https://developers.telnyx.com/api-reference/integration-secrets/create-a-secret)
|
|
2418
|
+
* that refers to your ElevenLabs API key. Warning: Free plans are unlikely to work
|
|
2419
|
+
* with this integration.
|
|
2420
|
+
*/
|
|
2421
|
+
api_key_ref?: string;
|
|
2422
|
+
|
|
2423
|
+
/**
|
|
2424
|
+
* Optional background audio to play on the call. Use a predefined media bed, or
|
|
2425
|
+
* supply a looped MP3 URL. If a media URL is chosen in the portal, customers can
|
|
2426
|
+
* preview it before saving.
|
|
2427
|
+
*/
|
|
2428
|
+
background_audio?:
|
|
2429
|
+
| InferenceEmbeddingVoiceSettings.UnionMember0
|
|
2430
|
+
| InferenceEmbeddingVoiceSettings.UnionMember1
|
|
2431
|
+
| InferenceEmbeddingVoiceSettings.UnionMember2;
|
|
2432
|
+
|
|
2433
|
+
/**
|
|
2434
|
+
* Enables emotionally expressive speech using SSML emotion tags. When enabled, the
|
|
2435
|
+
* assistant uses audio tags like angry, excited, content, and sad to add emotional
|
|
2436
|
+
* nuance. Only supported for Telnyx Ultra voices.
|
|
2437
|
+
*/
|
|
2438
|
+
expressive_mode?: boolean;
|
|
2439
|
+
|
|
2440
|
+
/**
|
|
2441
|
+
* Enhances recognition for specific languages and dialects during MiniMax TTS
|
|
2442
|
+
* synthesis. Default is null (no boost). Set to 'auto' for automatic language
|
|
2443
|
+
* detection. Only applicable when using MiniMax voices.
|
|
2444
|
+
*/
|
|
2445
|
+
language_boost?:
|
|
2446
|
+
| 'auto'
|
|
2447
|
+
| 'Chinese'
|
|
2448
|
+
| 'Chinese,Yue'
|
|
2449
|
+
| 'English'
|
|
2450
|
+
| 'Arabic'
|
|
2451
|
+
| 'Russian'
|
|
2452
|
+
| 'Spanish'
|
|
2453
|
+
| 'French'
|
|
2454
|
+
| 'Portuguese'
|
|
2455
|
+
| 'German'
|
|
2456
|
+
| 'Turkish'
|
|
2457
|
+
| 'Dutch'
|
|
2458
|
+
| 'Ukrainian'
|
|
2459
|
+
| 'Vietnamese'
|
|
2460
|
+
| 'Indonesian'
|
|
2461
|
+
| 'Japanese'
|
|
2462
|
+
| 'Italian'
|
|
2463
|
+
| 'Korean'
|
|
2464
|
+
| 'Thai'
|
|
2465
|
+
| 'Polish'
|
|
2466
|
+
| 'Romanian'
|
|
2467
|
+
| 'Greek'
|
|
2468
|
+
| 'Czech'
|
|
2469
|
+
| 'Finnish'
|
|
2470
|
+
| 'Hindi'
|
|
2471
|
+
| 'Bulgarian'
|
|
2472
|
+
| 'Danish'
|
|
2473
|
+
| 'Hebrew'
|
|
2474
|
+
| 'Malay'
|
|
2475
|
+
| 'Persian'
|
|
2476
|
+
| 'Slovak'
|
|
2477
|
+
| 'Swedish'
|
|
2478
|
+
| 'Croatian'
|
|
2479
|
+
| 'Filipino'
|
|
2480
|
+
| 'Hungarian'
|
|
2481
|
+
| 'Norwegian'
|
|
2482
|
+
| 'Slovenian'
|
|
2483
|
+
| 'Catalan'
|
|
2484
|
+
| 'Nynorsk'
|
|
2485
|
+
| 'Tamil'
|
|
2486
|
+
| 'Afrikaans'
|
|
2487
|
+
| null;
|
|
2488
|
+
|
|
2489
|
+
/**
|
|
2490
|
+
* Determines how closely the AI should adhere to the original voice when
|
|
2491
|
+
* attempting to replicate it. Only applicable when using ElevenLabs.
|
|
2492
|
+
*/
|
|
2493
|
+
similarity_boost?: number;
|
|
2494
|
+
|
|
2495
|
+
/**
|
|
2496
|
+
* Adjusts speech velocity. 1.0 is default speed; values less than 1.0 slow speech;
|
|
2497
|
+
* values greater than 1.0 accelerate it. Only applicable when using ElevenLabs.
|
|
2498
|
+
*/
|
|
2499
|
+
speed?: number;
|
|
2500
|
+
|
|
2501
|
+
/**
|
|
2502
|
+
* Determines the style exaggeration of the voice. Amplifies speaker style but
|
|
2503
|
+
* consumes additional resources when set above 0. Only applicable when using
|
|
2504
|
+
* ElevenLabs.
|
|
2505
|
+
*/
|
|
2506
|
+
style?: number;
|
|
2507
|
+
|
|
2508
|
+
/**
|
|
2509
|
+
* Determines how stable the voice is and the randomness between each generation.
|
|
2510
|
+
* Lower values create a broader emotional range; higher values produce more
|
|
2511
|
+
* consistent, monotonous output. Only applicable when using ElevenLabs.
|
|
2512
|
+
*/
|
|
2513
|
+
temperature?: number;
|
|
2514
|
+
|
|
2515
|
+
/**
|
|
2516
|
+
* Amplifies similarity to the original speaker voice. Increases computational load
|
|
2517
|
+
* and latency slightly. Only applicable when using ElevenLabs.
|
|
2518
|
+
*/
|
|
2519
|
+
use_speaker_boost?: boolean;
|
|
2520
|
+
|
|
2521
|
+
/**
|
|
2522
|
+
* The speed of the voice in the range [0.6, 1.5]. 1.0 is the default speed. Larger
|
|
2523
|
+
* numbers make the voice faster, smaller numbers make it slower. Applies to Telnyx
|
|
2524
|
+
* `Ultra` voices; values outside this range are rejected by the synthesis engine.
|
|
2525
|
+
* Soniox voices support a speed range of 0.7 to 1.3.
|
|
2526
|
+
*/
|
|
2527
|
+
voice_speed?: number;
|
|
2528
|
+
}
|
|
2529
|
+
|
|
2530
|
+
export namespace InferenceEmbeddingVoiceSettings {
|
|
2531
|
+
export interface UnionMember0 {
|
|
2532
|
+
/**
|
|
2533
|
+
* Select from predefined media options.
|
|
2534
|
+
*/
|
|
2535
|
+
type: 'predefined_media';
|
|
2536
|
+
|
|
2537
|
+
/**
|
|
2538
|
+
* The predefined media to use. `silence` disables background audio.
|
|
2539
|
+
*/
|
|
2540
|
+
value: 'silence' | 'office';
|
|
2541
|
+
|
|
2542
|
+
/**
|
|
2543
|
+
* Volume level for the predefined background audio. Supports values from 0.1 to
|
|
2544
|
+
* 1.0 in 0.1 increments.
|
|
2545
|
+
*/
|
|
2546
|
+
volume?: number;
|
|
2547
|
+
}
|
|
2548
|
+
|
|
2549
|
+
export interface UnionMember1 {
|
|
2550
|
+
/**
|
|
2551
|
+
* Provide a direct URL to an MP3 file. The audio will loop during the call.
|
|
2552
|
+
*/
|
|
2553
|
+
type: 'media_url';
|
|
2554
|
+
|
|
2555
|
+
/**
|
|
2556
|
+
* HTTPS URL to an MP3 file.
|
|
2557
|
+
*/
|
|
2558
|
+
value: string;
|
|
2559
|
+
}
|
|
2560
|
+
|
|
2561
|
+
export interface UnionMember2 {
|
|
2562
|
+
/**
|
|
2563
|
+
* Reference a previously uploaded media by its name from Telnyx Media Storage.
|
|
2564
|
+
*/
|
|
2565
|
+
type: 'media_name';
|
|
2566
|
+
|
|
2567
|
+
/**
|
|
2568
|
+
* The `name` of a media asset created via
|
|
2569
|
+
* [Media Storage API](https://developers.telnyx.com/api/media-storage/create-media-storage).
|
|
2570
|
+
* The audio will loop during the call.
|
|
2571
|
+
*/
|
|
2572
|
+
value: string;
|
|
2573
|
+
}
|
|
2574
|
+
}
|
|
2575
|
+
|
|
2185
2576
|
export interface InferenceEmbeddingWebhookToolParams {
|
|
2186
2577
|
type: 'webhook';
|
|
2187
2578
|
|
|
@@ -2197,6 +2588,14 @@ export interface InferenceEmbeddingWebhookToolParams {
|
|
|
2197
2588
|
* per assistant).
|
|
2198
2589
|
*/
|
|
2199
2590
|
shared?: boolean;
|
|
2591
|
+
|
|
2592
|
+
/**
|
|
2593
|
+
* The maximum number of milliseconds to wait for the webhook to respond before the
|
|
2594
|
+
* tool call is aborted. Set this at the tool level, as a sibling of `type` — a
|
|
2595
|
+
* `timeout_ms` nested inside the `webhook` object is stored but not applied, and
|
|
2596
|
+
* the tool runs at this default instead. Applies when `webhook.async` is false.
|
|
2597
|
+
*/
|
|
2598
|
+
timeout_ms?: number;
|
|
2200
2599
|
}
|
|
2201
2600
|
|
|
2202
2601
|
export namespace InferenceEmbeddingWebhookToolParams {
|
|
@@ -2308,12 +2707,6 @@ export namespace InferenceEmbeddingWebhookToolParams {
|
|
|
2308
2707
|
* dot-notation path to the value in the response body.
|
|
2309
2708
|
*/
|
|
2310
2709
|
store_fields_as_variables?: Array<Webhook.StoreFieldsAsVariable>;
|
|
2311
|
-
|
|
2312
|
-
/**
|
|
2313
|
-
* The maximum number of milliseconds to wait for the webhook to respond. Only
|
|
2314
|
-
* applicable when async is false.
|
|
2315
|
-
*/
|
|
2316
|
-
timeout_ms?: number;
|
|
2317
2710
|
}
|
|
2318
2711
|
|
|
2319
2712
|
export namespace Webhook {
|
|
@@ -2968,13 +3361,24 @@ export interface ToolNode {
|
|
|
2968
3361
|
/**
|
|
2969
3362
|
* ID of the single shared (org-level) tool this node executes. When the flow
|
|
2970
3363
|
* reaches this node the tool runs as a deliberate step (no LLM turn); its outgoing
|
|
2971
|
-
* `
|
|
2972
|
-
* conversation's dynamic variables by name — a dynamic variable
|
|
2973
|
-
* one of the tool's parameters supplies that argument.
|
|
2974
|
-
* org's shared tools on write.
|
|
3364
|
+
* `llm` / `expression` edges route the flow on the tool's outcome. Arguments are
|
|
3365
|
+
* filled from the conversation's dynamic variables by name — a dynamic variable
|
|
3366
|
+
* whose name matches one of the tool's parameters supplies that argument.
|
|
3367
|
+
* Cross-validated against the org's shared tools on write.
|
|
2975
3368
|
*/
|
|
2976
3369
|
shared_tool_id: string;
|
|
2977
3370
|
|
|
3371
|
+
/**
|
|
3372
|
+
* Optional message delivered to the user verbatim immediately before the tool
|
|
3373
|
+
* executes — an announcement such as 'One moment while I look that up.' No LLM
|
|
3374
|
+
* turn and no customer turn: the message is spoken/sent, then the tool runs, in
|
|
3375
|
+
* the same deterministic step. `{{variable}}` placeholders are interpolated from
|
|
3376
|
+
* the conversation's dynamic variables (unresolved → empty string); the tool's own
|
|
3377
|
+
* result is not yet available when the message is rendered. Omit for a silent tool
|
|
3378
|
+
* step.
|
|
3379
|
+
*/
|
|
3380
|
+
message?: string;
|
|
3381
|
+
|
|
2978
3382
|
/**
|
|
2979
3383
|
* Optional human-readable label, displayed in authoring UIs.
|
|
2980
3384
|
*/
|
|
@@ -3005,8 +3409,10 @@ export interface ToolNode {
|
|
|
3005
3409
|
*
|
|
3006
3410
|
* Unlike a prompt node, a tool node has no instructions or model — it isn't an LLM
|
|
3007
3411
|
* turn. Reaching it deterministically runs one shared tool (arguments filled from
|
|
3008
|
-
* matching dynamic variables by name), then routes
|
|
3009
|
-
* `
|
|
3412
|
+
* matching dynamic variables by name), then routes via outgoing `llm` /
|
|
3413
|
+
* `expression` edges, with exactly one `default` fallback edge required when the
|
|
3414
|
+
* node has any outgoing edges (the tool's outcome is readable as
|
|
3415
|
+
* `telnyx_last_tool_status_code` in `expression` conditions).
|
|
3010
3416
|
*/
|
|
3011
3417
|
export interface ToolNodeReq {
|
|
3012
3418
|
/**
|
|
@@ -3017,13 +3423,24 @@ export interface ToolNodeReq {
|
|
|
3017
3423
|
/**
|
|
3018
3424
|
* ID of the single shared (org-level) tool this node executes. When the flow
|
|
3019
3425
|
* reaches this node the tool runs as a deliberate step (no LLM turn); its outgoing
|
|
3020
|
-
* `
|
|
3021
|
-
* conversation's dynamic variables by name — a dynamic variable
|
|
3022
|
-
* one of the tool's parameters supplies that argument.
|
|
3023
|
-
* org's shared tools on write.
|
|
3426
|
+
* `llm` / `expression` edges route the flow on the tool's outcome. Arguments are
|
|
3427
|
+
* filled from the conversation's dynamic variables by name — a dynamic variable
|
|
3428
|
+
* whose name matches one of the tool's parameters supplies that argument.
|
|
3429
|
+
* Cross-validated against the org's shared tools on write.
|
|
3024
3430
|
*/
|
|
3025
3431
|
shared_tool_id: string;
|
|
3026
3432
|
|
|
3433
|
+
/**
|
|
3434
|
+
* Optional message delivered to the user verbatim immediately before the tool
|
|
3435
|
+
* executes — an announcement such as 'One moment while I look that up.' No LLM
|
|
3436
|
+
* turn and no customer turn: the message is spoken/sent, then the tool runs, in
|
|
3437
|
+
* the same deterministic step. `{{variable}}` placeholders are interpolated from
|
|
3438
|
+
* the conversation's dynamic variables (unresolved → empty string); the tool's own
|
|
3439
|
+
* result is not yet available when the message is rendered. Omit for a silent tool
|
|
3440
|
+
* step.
|
|
3441
|
+
*/
|
|
3442
|
+
message?: string;
|
|
3443
|
+
|
|
3027
3444
|
/**
|
|
3028
3445
|
* Optional human-readable label, displayed in authoring UIs.
|
|
3029
3446
|
*/
|
|
@@ -3397,9 +3814,9 @@ export interface VoiceSettings {
|
|
|
3397
3814
|
use_speaker_boost?: boolean;
|
|
3398
3815
|
|
|
3399
3816
|
/**
|
|
3400
|
-
* The speed of the voice in the range [0.
|
|
3401
|
-
* numbers make the voice faster, smaller numbers make it slower.
|
|
3402
|
-
*
|
|
3817
|
+
* The speed of the voice in the range [0.6, 1.5]. 1.0 is the default speed. Larger
|
|
3818
|
+
* numbers make the voice faster, smaller numbers make it slower. Applies to Telnyx
|
|
3819
|
+
* `Ultra` voices; values outside this range are rejected by the synthesis engine.
|
|
3403
3820
|
*/
|
|
3404
3821
|
voice_speed?: number;
|
|
3405
3822
|
}
|
|
@@ -3454,6 +3871,14 @@ export interface WebhookTool {
|
|
|
3454
3871
|
type: 'webhook';
|
|
3455
3872
|
|
|
3456
3873
|
webhook: WebhookTool.Webhook;
|
|
3874
|
+
|
|
3875
|
+
/**
|
|
3876
|
+
* The maximum number of milliseconds to wait for the webhook to respond before the
|
|
3877
|
+
* tool call is aborted. Set this at the tool level, as a sibling of `type` — a
|
|
3878
|
+
* `timeout_ms` nested inside the `webhook` object is not applied, and the tool
|
|
3879
|
+
* runs at this default instead.
|
|
3880
|
+
*/
|
|
3881
|
+
timeout_ms?: number;
|
|
3457
3882
|
}
|
|
3458
3883
|
|
|
3459
3884
|
export namespace WebhookTool {
|
|
@@ -3590,6 +4015,35 @@ export namespace WebhookTool {
|
|
|
3590
4015
|
}
|
|
3591
4016
|
}
|
|
3592
4017
|
|
|
4018
|
+
/**
|
|
4019
|
+
* Streams conversation and telephony events to a WebSocket server you host, and
|
|
4020
|
+
* accepts messages injected back into the conversation. Telnyx opens the
|
|
4021
|
+
* connection as a client, once per conversation. Delivery is best effort
|
|
4022
|
+
* throughout: while the connection is down events are dropped rather than queued,
|
|
4023
|
+
* and no socket failure is ever allowed to affect the call. Beta feature.
|
|
4024
|
+
*/
|
|
4025
|
+
export interface WebsocketSettings {
|
|
4026
|
+
/**
|
|
4027
|
+
* Integration secret identifier whose value Telnyx sends as an
|
|
4028
|
+
* `Authorization: Bearer <value>` header on the upgrade request. Resolved on every
|
|
4029
|
+
* connection attempt, so a rotated secret is picked up by the next reconnect.
|
|
4030
|
+
*/
|
|
4031
|
+
auth_ref?: string;
|
|
4032
|
+
|
|
4033
|
+
/**
|
|
4034
|
+
* Whether Telnyx opens a WebSocket to `url` for each of this assistant's
|
|
4035
|
+
* conversations. Defaults to `false`.
|
|
4036
|
+
*/
|
|
4037
|
+
enabled?: boolean;
|
|
4038
|
+
|
|
4039
|
+
/**
|
|
4040
|
+
* The `ws://` or `wss://` endpoint Telnyx connects to. Required when `enabled` is
|
|
4041
|
+
* `true`. Must be externally reachable — localhost, private IP ranges and `.local`
|
|
4042
|
+
* domains are rejected.
|
|
4043
|
+
*/
|
|
4044
|
+
url?: string;
|
|
4045
|
+
}
|
|
4046
|
+
|
|
3593
4047
|
/**
|
|
3594
4048
|
* Configuration settings for the assistant's web widget.
|
|
3595
4049
|
*/
|
|
@@ -3672,6 +4126,18 @@ export interface AssistantSendSMSResponse {
|
|
|
3672
4126
|
conversation_id?: string;
|
|
3673
4127
|
}
|
|
3674
4128
|
|
|
4129
|
+
export interface AssistantWhatsappResponse {
|
|
4130
|
+
/**
|
|
4131
|
+
* ID of the conversation created for this WhatsApp chat.
|
|
4132
|
+
*/
|
|
4133
|
+
conversation_id: string;
|
|
4134
|
+
|
|
4135
|
+
/**
|
|
4136
|
+
* ID of the WhatsApp template message that was sent.
|
|
4137
|
+
*/
|
|
4138
|
+
message_id: string;
|
|
4139
|
+
}
|
|
4140
|
+
|
|
3675
4141
|
export interface AssistantCreateParams {
|
|
3676
4142
|
/**
|
|
3677
4143
|
* Body param: System instructions for the assistant. These may be templated with
|
|
@@ -3705,6 +4171,17 @@ export interface AssistantCreateParams {
|
|
|
3705
4171
|
*/
|
|
3706
4172
|
conversation_flow?: ConversationFlowReq;
|
|
3707
4173
|
|
|
4174
|
+
/**
|
|
4175
|
+
* Body param: Splits the conversation between a frontend model that talks to the
|
|
4176
|
+
* caller and a backend model that does the work. On the GPT-Live route the
|
|
4177
|
+
* frontend model cannot call tools at all — when it needs something done it raises
|
|
4178
|
+
* a delegation and waits. On the chat completion route the frontend keeps a single
|
|
4179
|
+
* `delegate` tool that returns immediately, so the conversation carries on while
|
|
4180
|
+
* the backend works. Either way the backend's answer is spoken as commentary or
|
|
4181
|
+
* kept as silent context, depending on `speak_results`. Beta feature.
|
|
4182
|
+
*/
|
|
4183
|
+
delegation_settings?: DelegationSettings;
|
|
4184
|
+
|
|
3708
4185
|
/**
|
|
3709
4186
|
* Body param
|
|
3710
4187
|
*/
|
|
@@ -3866,7 +4343,16 @@ export interface AssistantCreateParams {
|
|
|
3866
4343
|
/**
|
|
3867
4344
|
* Body param
|
|
3868
4345
|
*/
|
|
3869
|
-
voice_settings?:
|
|
4346
|
+
voice_settings?: InferenceEmbeddingVoiceSettings;
|
|
4347
|
+
|
|
4348
|
+
/**
|
|
4349
|
+
* Body param: Streams conversation and telephony events to a WebSocket server you
|
|
4350
|
+
* host, and accepts messages injected back into the conversation. Telnyx opens the
|
|
4351
|
+
* connection as a client, once per conversation. Delivery is best effort
|
|
4352
|
+
* throughout: while the connection is down events are dropped rather than queued,
|
|
4353
|
+
* and no socket failure is ever allowed to affect the call. Beta feature.
|
|
4354
|
+
*/
|
|
4355
|
+
websocket_settings?: WebsocketSettings;
|
|
3870
4356
|
|
|
3871
4357
|
/**
|
|
3872
4358
|
* Body param: Configuration settings for the assistant's web widget.
|
|
@@ -3918,6 +4404,14 @@ export interface AssistantImportsParams {
|
|
|
3918
4404
|
'Idempotency-Key'?: string;
|
|
3919
4405
|
}
|
|
3920
4406
|
|
|
4407
|
+
export interface AssistantDeleteParams {
|
|
4408
|
+
/**
|
|
4409
|
+
* Permanently delete the assistant immediately instead of soft-deleting it to the
|
|
4410
|
+
* Recently Deleted list, where it stays restorable for 30 days.
|
|
4411
|
+
*/
|
|
4412
|
+
hard_delete?: boolean;
|
|
4413
|
+
}
|
|
4414
|
+
|
|
3921
4415
|
export interface AssistantRetrieveParams {
|
|
3922
4416
|
/**
|
|
3923
4417
|
* Filter results by call control id.
|
|
@@ -3963,6 +4457,17 @@ export interface AssistantUpdateParams {
|
|
|
3963
4457
|
*/
|
|
3964
4458
|
conversation_flow?: ConversationFlowReq;
|
|
3965
4459
|
|
|
4460
|
+
/**
|
|
4461
|
+
* Splits the conversation between a frontend model that talks to the caller and a
|
|
4462
|
+
* backend model that does the work. On the GPT-Live route the frontend model
|
|
4463
|
+
* cannot call tools at all — when it needs something done it raises a delegation
|
|
4464
|
+
* and waits. On the chat completion route the frontend keeps a single `delegate`
|
|
4465
|
+
* tool that returns immediately, so the conversation carries on while the backend
|
|
4466
|
+
* works. Either way the backend's answer is spoken as commentary or kept as silent
|
|
4467
|
+
* context, depending on `speak_results`. Beta feature.
|
|
4468
|
+
*/
|
|
4469
|
+
delegation_settings?: DelegationSettings;
|
|
4470
|
+
|
|
3966
4471
|
description?: string;
|
|
3967
4472
|
|
|
3968
4473
|
/**
|
|
@@ -4120,7 +4625,16 @@ export interface AssistantUpdateParams {
|
|
|
4120
4625
|
*/
|
|
4121
4626
|
version_name?: string;
|
|
4122
4627
|
|
|
4123
|
-
voice_settings?:
|
|
4628
|
+
voice_settings?: InferenceEmbeddingVoiceSettings;
|
|
4629
|
+
|
|
4630
|
+
/**
|
|
4631
|
+
* Streams conversation and telephony events to a WebSocket server you host, and
|
|
4632
|
+
* accepts messages injected back into the conversation. Telnyx opens the
|
|
4633
|
+
* connection as a client, once per conversation. Delivery is best effort
|
|
4634
|
+
* throughout: while the connection is down events are dropped rather than queued,
|
|
4635
|
+
* and no socket failure is ever allowed to affect the call. Beta feature.
|
|
4636
|
+
*/
|
|
4637
|
+
websocket_settings?: WebsocketSettings;
|
|
4124
4638
|
|
|
4125
4639
|
/**
|
|
4126
4640
|
* Configuration settings for the assistant's web widget.
|
|
@@ -4207,6 +4721,44 @@ export interface AssistantSendSMSParams {
|
|
|
4207
4721
|
'Idempotency-Key'?: string;
|
|
4208
4722
|
}
|
|
4209
4723
|
|
|
4724
|
+
export interface AssistantWhatsappParams {
|
|
4725
|
+
/**
|
|
4726
|
+
* Body param: Instruction for the assistant, including the values for the template
|
|
4727
|
+
* variables, e.g. `Send the login verification code 482913 to the customer.`
|
|
4728
|
+
*/
|
|
4729
|
+
content: string;
|
|
4730
|
+
|
|
4731
|
+
/**
|
|
4732
|
+
* Body param: WhatsApp number on your account to send from, in E.164 format. Its
|
|
4733
|
+
* messaging profile must have this assistant configured.
|
|
4734
|
+
*/
|
|
4735
|
+
from: string;
|
|
4736
|
+
|
|
4737
|
+
/**
|
|
4738
|
+
* Body param: Customer to message, as an E.164 phone number or a WhatsApp
|
|
4739
|
+
* business-scoped user ID (BSUID).
|
|
4740
|
+
*/
|
|
4741
|
+
to: string;
|
|
4742
|
+
|
|
4743
|
+
/**
|
|
4744
|
+
* Body param: Metadata stored on the conversation. Keys starting with `telnyx_`
|
|
4745
|
+
* and the `assistant_id` key are reserved.
|
|
4746
|
+
*/
|
|
4747
|
+
conversation_metadata?: { [key: string]: string | number | boolean };
|
|
4748
|
+
|
|
4749
|
+
/**
|
|
4750
|
+
* Header param: Optional opaque, unquoted key for safely retrying the same logical
|
|
4751
|
+
* request. Keys must contain 1 to 255 letters, numbers, hyphens, or underscores.
|
|
4752
|
+
* Generate a unique UUID v4 for each operation and reuse it only when retrying
|
|
4753
|
+
* that operation with the same request. Invalid headers—including duplicate,
|
|
4754
|
+
* empty, malformed, or overlong values—return 400 with error code 10015. A request
|
|
4755
|
+
* already in progress with the same key returns 409; reusing the key with a
|
|
4756
|
+
* different request returns 422. Only successful responses are replayed, for up to
|
|
4757
|
+
* 24 hours. Do not include sensitive data in the key.
|
|
4758
|
+
*/
|
|
4759
|
+
'Idempotency-Key'?: string;
|
|
4760
|
+
}
|
|
4761
|
+
|
|
4210
4762
|
Assistants.Tests = Tests;
|
|
4211
4763
|
Assistants.CanaryDeploys = CanaryDeploys;
|
|
4212
4764
|
Assistants.ScheduledEvents = ScheduledEvents;
|
|
@@ -4214,6 +4766,7 @@ Assistants.Tools = Tools;
|
|
|
4214
4766
|
Assistants.Versions = Versions;
|
|
4215
4767
|
Assistants.Tags = Tags;
|
|
4216
4768
|
Assistants.Instructions = Instructions;
|
|
4769
|
+
Assistants.Deleted = Deleted;
|
|
4217
4770
|
|
|
4218
4771
|
export declare namespace Assistants {
|
|
4219
4772
|
export {
|
|
@@ -4230,6 +4783,7 @@ export declare namespace Assistants {
|
|
|
4230
4783
|
type ComparisonExpression as ComparisonExpression,
|
|
4231
4784
|
type ConversationFlow as ConversationFlow,
|
|
4232
4785
|
type ConversationFlowReq as ConversationFlowReq,
|
|
4786
|
+
type DelegationSettings as DelegationSettings,
|
|
4233
4787
|
type EnabledFeatures as EnabledFeatures,
|
|
4234
4788
|
type Expression as Expression,
|
|
4235
4789
|
type ExternalLlm as ExternalLlm,
|
|
@@ -4244,6 +4798,7 @@ export declare namespace Assistants {
|
|
|
4244
4798
|
type ImportMetadata as ImportMetadata,
|
|
4245
4799
|
type InferenceEmbedding as InferenceEmbedding,
|
|
4246
4800
|
type InferenceEmbeddingInterruptionSettings as InferenceEmbeddingInterruptionSettings,
|
|
4801
|
+
type InferenceEmbeddingVoiceSettings as InferenceEmbeddingVoiceSettings,
|
|
4247
4802
|
type InferenceEmbeddingWebhookToolParams as InferenceEmbeddingWebhookToolParams,
|
|
4248
4803
|
type InsightSettings as InsightSettings,
|
|
4249
4804
|
type MessagingSettings as MessagingSettings,
|
|
@@ -4268,18 +4823,22 @@ export declare namespace Assistants {
|
|
|
4268
4823
|
type TransferTool as TransferTool,
|
|
4269
4824
|
type VoiceSettings as VoiceSettings,
|
|
4270
4825
|
type WebhookTool as WebhookTool,
|
|
4826
|
+
type WebsocketSettings as WebsocketSettings,
|
|
4271
4827
|
type WidgetSettings as WidgetSettings,
|
|
4272
4828
|
type AssistantDeleteResponse as AssistantDeleteResponse,
|
|
4273
4829
|
type AssistantChatResponse as AssistantChatResponse,
|
|
4274
4830
|
type AssistantGetTexmlResponse as AssistantGetTexmlResponse,
|
|
4275
4831
|
type AssistantSendSMSResponse as AssistantSendSMSResponse,
|
|
4832
|
+
type AssistantWhatsappResponse as AssistantWhatsappResponse,
|
|
4276
4833
|
type AssistantCreateParams as AssistantCreateParams,
|
|
4277
4834
|
type AssistantImportsParams as AssistantImportsParams,
|
|
4835
|
+
type AssistantDeleteParams as AssistantDeleteParams,
|
|
4278
4836
|
type AssistantRetrieveParams as AssistantRetrieveParams,
|
|
4279
4837
|
type AssistantUpdateParams as AssistantUpdateParams,
|
|
4280
4838
|
type AssistantChatParams as AssistantChatParams,
|
|
4281
4839
|
type AssistantCloneParams as AssistantCloneParams,
|
|
4282
4840
|
type AssistantSendSMSParams as AssistantSendSMSParams,
|
|
4841
|
+
type AssistantWhatsappParams as AssistantWhatsappParams,
|
|
4283
4842
|
};
|
|
4284
4843
|
|
|
4285
4844
|
export {
|
|
@@ -4352,4 +4911,11 @@ export declare namespace Assistants {
|
|
|
4352
4911
|
type InstructionEnhanceResponse as InstructionEnhanceResponse,
|
|
4353
4912
|
type InstructionEnhanceParams as InstructionEnhanceParams,
|
|
4354
4913
|
};
|
|
4914
|
+
|
|
4915
|
+
export {
|
|
4916
|
+
Deleted as Deleted,
|
|
4917
|
+
type DeletedAssistant as DeletedAssistant,
|
|
4918
|
+
type DeletedAssistantsDefaultFlatPagination as DeletedAssistantsDefaultFlatPagination,
|
|
4919
|
+
type DeletedListParams as DeletedListParams,
|
|
4920
|
+
};
|
|
4355
4921
|
}
|