telnyx 7.25.0 → 7.27.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 +25 -10
- package/client.d.mts.map +1 -1
- package/client.d.ts +25 -10
- 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/addresses/addresses.d.mts +22 -2
- package/resources/addresses/addresses.d.mts.map +1 -1
- package/resources/addresses/addresses.d.ts +22 -2
- package/resources/addresses/addresses.d.ts.map +1 -1
- package/resources/addresses/addresses.js +12 -0
- package/resources/addresses/addresses.js.map +1 -1
- package/resources/addresses/addresses.mjs +12 -0
- package/resources/addresses/addresses.mjs.map +1 -1
- package/resources/ai/ai.d.mts +16 -7
- package/resources/ai/ai.d.mts.map +1 -1
- package/resources/ai/ai.d.ts +16 -7
- 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 +383 -22
- package/resources/ai/assistants/assistants.d.mts.map +1 -1
- package/resources/ai/assistants/assistants.d.ts +383 -22
- package/resources/ai/assistants/assistants.d.ts.map +1 -1
- package/resources/ai/assistants/assistants.js +4 -1
- package/resources/ai/assistants/assistants.js.map +1 -1
- package/resources/ai/assistants/assistants.mjs +4 -1
- package/resources/ai/assistants/assistants.mjs.map +1 -1
- package/resources/ai/assistants/index.d.mts +1 -1
- package/resources/ai/assistants/index.d.mts.map +1 -1
- package/resources/ai/assistants/index.d.ts +1 -1
- package/resources/ai/assistants/index.d.ts.map +1 -1
- package/resources/ai/assistants/index.js.map +1 -1
- package/resources/ai/assistants/index.mjs.map +1 -1
- package/resources/ai/assistants/versions.d.mts +18 -1
- package/resources/ai/assistants/versions.d.mts.map +1 -1
- package/resources/ai/assistants/versions.d.ts +18 -1
- package/resources/ai/assistants/versions.d.ts.map +1 -1
- package/resources/ai/assistants/versions.js +4 -1
- package/resources/ai/assistants/versions.js.map +1 -1
- package/resources/ai/assistants/versions.mjs +4 -1
- package/resources/ai/assistants/versions.mjs.map +1 -1
- package/resources/ai/audio.d.mts +17 -5
- package/resources/ai/audio.d.mts.map +1 -1
- package/resources/ai/audio.d.ts +17 -5
- package/resources/ai/audio.d.ts.map +1 -1
- package/resources/ai/avatars.d.mts +200 -0
- package/resources/ai/avatars.d.mts.map +1 -0
- package/resources/ai/avatars.d.ts +200 -0
- package/resources/ai/avatars.d.ts.map +1 -0
- package/resources/ai/avatars.js +95 -0
- package/resources/ai/avatars.js.map +1 -0
- package/resources/ai/avatars.mjs +91 -0
- package/resources/ai/avatars.mjs.map +1 -0
- package/resources/ai/chat.d.mts +20 -6
- package/resources/ai/chat.d.mts.map +1 -1
- package/resources/ai/chat.d.ts +20 -6
- package/resources/ai/chat.d.ts.map +1 -1
- package/resources/ai/conversations/conversations.d.mts +8 -0
- package/resources/ai/conversations/conversations.d.mts.map +1 -1
- package/resources/ai/conversations/conversations.d.ts +8 -0
- package/resources/ai/conversations/conversations.d.ts.map +1 -1
- package/resources/ai/conversations/conversations.js.map +1 -1
- package/resources/ai/conversations/conversations.mjs.map +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 +3 -1
- 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/namespaces/index.d.mts +1 -1
- package/resources/ai/memory/namespaces/index.d.mts.map +1 -1
- package/resources/ai/memory/namespaces/index.d.ts +1 -1
- package/resources/ai/memory/namespaces/index.d.ts.map +1 -1
- package/resources/ai/memory/namespaces/index.js.map +1 -1
- package/resources/ai/memory/namespaces/index.mjs.map +1 -1
- package/resources/ai/memory/namespaces/namespaces.d.mts +2 -2
- package/resources/ai/memory/namespaces/namespaces.d.mts.map +1 -1
- package/resources/ai/memory/namespaces/namespaces.d.ts +2 -2
- package/resources/ai/memory/namespaces/namespaces.d.ts.map +1 -1
- package/resources/ai/memory/namespaces/namespaces.js.map +1 -1
- package/resources/ai/memory/namespaces/namespaces.mjs.map +1 -1
- package/resources/ai/memory/namespaces/profiles/index.d.mts +1 -1
- package/resources/ai/memory/namespaces/profiles/index.d.mts.map +1 -1
- package/resources/ai/memory/namespaces/profiles/index.d.ts +1 -1
- package/resources/ai/memory/namespaces/profiles/index.d.ts.map +1 -1
- package/resources/ai/memory/namespaces/profiles/index.js.map +1 -1
- package/resources/ai/memory/namespaces/profiles/index.mjs.map +1 -1
- package/resources/ai/memory/namespaces/profiles/profiles.d.mts +54 -1
- package/resources/ai/memory/namespaces/profiles/profiles.d.mts.map +1 -1
- package/resources/ai/memory/namespaces/profiles/profiles.d.ts +54 -1
- package/resources/ai/memory/namespaces/profiles/profiles.d.ts.map +1 -1
- package/resources/ai/memory/namespaces/profiles/profiles.js +31 -0
- package/resources/ai/memory/namespaces/profiles/profiles.js.map +1 -1
- package/resources/ai/memory/namespaces/profiles/profiles.mjs +31 -0
- package/resources/ai/memory/namespaces/profiles/profiles.mjs.map +1 -1
- package/resources/ai/openai/chat.d.mts +20 -6
- package/resources/ai/openai/chat.d.mts.map +1 -1
- package/resources/ai/openai/chat.d.ts +20 -6
- package/resources/ai/openai/chat.d.ts.map +1 -1
- package/resources/ai/tools.d.mts +30 -2
- package/resources/ai/tools.d.mts.map +1 -1
- package/resources/ai/tools.d.ts +30 -2
- package/resources/ai/tools.d.ts.map +1 -1
- package/resources/calls/actions.d.mts +260 -25
- package/resources/calls/actions.d.mts.map +1 -1
- package/resources/calls/actions.d.ts +260 -25
- package/resources/calls/actions.d.ts.map +1 -1
- package/resources/calls/calls.d.mts +24 -14
- package/resources/calls/calls.d.mts.map +1 -1
- package/resources/calls/calls.d.ts +24 -14
- package/resources/calls/calls.d.ts.map +1 -1
- package/resources/calls/calls.js +8 -0
- package/resources/calls/calls.js.map +1 -1
- package/resources/calls/calls.mjs +8 -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/credential-connections/credential-connections.d.mts +38 -8
- package/resources/credential-connections/credential-connections.d.mts.map +1 -1
- package/resources/credential-connections/credential-connections.d.ts +38 -8
- package/resources/credential-connections/credential-connections.d.ts.map +1 -1
- package/resources/credential-connections/credential-connections.js.map +1 -1
- package/resources/credential-connections/credential-connections.mjs.map +1 -1
- package/resources/dial-metrics.d.mts +151 -0
- package/resources/dial-metrics.d.mts.map +1 -0
- package/resources/dial-metrics.d.ts +151 -0
- package/resources/dial-metrics.d.ts.map +1 -0
- package/resources/dial-metrics.js +44 -0
- package/resources/dial-metrics.js.map +1 -0
- package/resources/dial-metrics.mjs +40 -0
- package/resources/dial-metrics.mjs.map +1 -0
- package/resources/dir/dir.d.mts +11 -9
- package/resources/dir/dir.d.mts.map +1 -1
- package/resources/dir/dir.d.ts +11 -9
- package/resources/dir/dir.d.ts.map +1 -1
- package/resources/dir/dir.js +1 -2
- package/resources/dir/dir.js.map +1 -1
- package/resources/dir/dir.mjs +1 -2
- package/resources/dir/dir.mjs.map +1 -1
- package/resources/dir/phone-numbers.d.mts +0 -4
- package/resources/dir/phone-numbers.d.mts.map +1 -1
- package/resources/dir/phone-numbers.d.ts +0 -4
- package/resources/dir/phone-numbers.d.ts.map +1 -1
- package/resources/dir/references.d.mts +15 -9
- package/resources/dir/references.d.mts.map +1 -1
- package/resources/dir/references.d.ts +15 -9
- package/resources/dir/references.d.ts.map +1 -1
- package/resources/dir/references.js +15 -9
- package/resources/dir/references.js.map +1 -1
- package/resources/dir/references.mjs +15 -9
- package/resources/dir/references.mjs.map +1 -1
- package/resources/dir/verify-email.d.mts +17 -5
- package/resources/dir/verify-email.d.mts.map +1 -1
- package/resources/dir/verify-email.d.ts +17 -5
- package/resources/dir/verify-email.d.ts.map +1 -1
- package/resources/dir/verify-email.js +17 -5
- package/resources/dir/verify-email.js.map +1 -1
- package/resources/dir/verify-email.mjs +17 -5
- package/resources/dir/verify-email.mjs.map +1 -1
- package/resources/email-domains/email-domains.d.mts +1 -1
- package/resources/email-domains/email-domains.d.mts.map +1 -1
- package/resources/email-domains/email-domains.d.ts +1 -1
- package/resources/email-domains/email-domains.d.ts.map +1 -1
- package/resources/email-templates.d.mts +109 -18
- package/resources/email-templates.d.mts.map +1 -1
- package/resources/email-templates.d.ts +109 -18
- package/resources/email-templates.d.ts.map +1 -1
- package/resources/email-templates.js +5 -1
- package/resources/email-templates.js.map +1 -1
- package/resources/email-templates.mjs +5 -1
- package/resources/email-templates.mjs.map +1 -1
- package/resources/enterprises/dir.d.mts +8 -2
- package/resources/enterprises/dir.d.mts.map +1 -1
- package/resources/enterprises/dir.d.ts +8 -2
- package/resources/enterprises/dir.d.ts.map +1 -1
- package/resources/enterprises/dir.js +8 -2
- package/resources/enterprises/dir.js.map +1 -1
- package/resources/enterprises/dir.mjs +8 -2
- package/resources/enterprises/dir.mjs.map +1 -1
- package/resources/enterprises/enterprises.d.mts +7 -5
- package/resources/enterprises/enterprises.d.mts.map +1 -1
- package/resources/enterprises/enterprises.d.ts +7 -5
- package/resources/enterprises/enterprises.d.ts.map +1 -1
- package/resources/enterprises/enterprises.js +5 -3
- package/resources/enterprises/enterprises.js.map +1 -1
- package/resources/enterprises/enterprises.mjs +5 -3
- package/resources/enterprises/enterprises.mjs.map +1 -1
- package/resources/enterprises/index.d.mts +1 -1
- package/resources/enterprises/index.d.mts.map +1 -1
- package/resources/enterprises/index.d.ts +1 -1
- package/resources/enterprises/index.d.ts.map +1 -1
- package/resources/enterprises/index.js.map +1 -1
- package/resources/enterprises/index.mjs.map +1 -1
- package/resources/enterprises/reputation/external-verification.d.mts +94 -0
- package/resources/enterprises/reputation/external-verification.d.mts.map +1 -0
- package/resources/enterprises/reputation/external-verification.d.ts +94 -0
- package/resources/enterprises/reputation/external-verification.d.ts.map +1 -0
- package/resources/enterprises/reputation/external-verification.js +54 -0
- package/resources/enterprises/reputation/external-verification.js.map +1 -0
- package/resources/enterprises/reputation/external-verification.mjs +50 -0
- package/resources/enterprises/reputation/external-verification.mjs.map +1 -0
- package/resources/enterprises/reputation/index.d.mts +3 -2
- package/resources/enterprises/reputation/index.d.mts.map +1 -1
- package/resources/enterprises/reputation/index.d.ts +3 -2
- package/resources/enterprises/reputation/index.d.ts.map +1 -1
- package/resources/enterprises/reputation/index.js +3 -1
- package/resources/enterprises/reputation/index.js.map +1 -1
- package/resources/enterprises/reputation/index.mjs +1 -0
- package/resources/enterprises/reputation/index.mjs.map +1 -1
- package/resources/enterprises/reputation/loa.d.mts +3 -2
- package/resources/enterprises/reputation/loa.d.mts.map +1 -1
- package/resources/enterprises/reputation/loa.d.ts +3 -2
- package/resources/enterprises/reputation/loa.d.ts.map +1 -1
- package/resources/enterprises/reputation/numbers.d.mts +197 -4
- package/resources/enterprises/reputation/numbers.d.mts.map +1 -1
- package/resources/enterprises/reputation/numbers.d.ts +197 -4
- package/resources/enterprises/reputation/numbers.d.ts.map +1 -1
- package/resources/enterprises/reputation/numbers.js +58 -2
- package/resources/enterprises/reputation/numbers.js.map +1 -1
- package/resources/enterprises/reputation/numbers.mjs +58 -2
- package/resources/enterprises/reputation/numbers.mjs.map +1 -1
- package/resources/enterprises/reputation/remediation.d.mts +3 -2
- package/resources/enterprises/reputation/remediation.d.mts.map +1 -1
- package/resources/enterprises/reputation/remediation.d.ts +3 -2
- package/resources/enterprises/reputation/remediation.d.ts.map +1 -1
- package/resources/enterprises/reputation/reputation.d.mts +39 -3
- package/resources/enterprises/reputation/reputation.d.mts.map +1 -1
- package/resources/enterprises/reputation/reputation.d.ts +39 -3
- package/resources/enterprises/reputation/reputation.d.ts.map +1 -1
- package/resources/enterprises/reputation/reputation.js +22 -0
- package/resources/enterprises/reputation/reputation.js.map +1 -1
- package/resources/enterprises/reputation/reputation.mjs +22 -0
- package/resources/enterprises/reputation/reputation.mjs.map +1 -1
- package/resources/enterprises/verify-email.d.mts +1 -1
- package/resources/enterprises/verify-email.d.ts +1 -1
- package/resources/enterprises/verify-email.js +1 -1
- package/resources/enterprises/verify-email.mjs +1 -1
- package/resources/fqdn-connections/fqdn-connections.d.mts +38 -8
- package/resources/fqdn-connections/fqdn-connections.d.mts.map +1 -1
- package/resources/fqdn-connections/fqdn-connections.d.ts +38 -8
- package/resources/fqdn-connections/fqdn-connections.d.ts.map +1 -1
- package/resources/fqdn-connections/fqdn-connections.js.map +1 -1
- package/resources/fqdn-connections/fqdn-connections.mjs.map +1 -1
- package/resources/global-ip-assignment-health.d.mts +4 -4
- package/resources/global-ip-assignment-health.d.mts.map +1 -1
- package/resources/global-ip-assignment-health.d.ts +4 -4
- package/resources/global-ip-assignment-health.d.ts.map +1 -1
- package/resources/global-ip-assignments-usage.d.mts +4 -4
- package/resources/global-ip-assignments-usage.d.mts.map +1 -1
- package/resources/global-ip-assignments-usage.d.ts +4 -4
- package/resources/global-ip-assignments-usage.d.ts.map +1 -1
- package/resources/index.d.mts +8 -5
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +8 -5
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +10 -4
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +3 -0
- package/resources/index.mjs.map +1 -1
- package/resources/ip-connections.d.mts +36 -6
- package/resources/ip-connections.d.mts.map +1 -1
- package/resources/ip-connections.d.ts +36 -6
- package/resources/ip-connections.d.ts.map +1 -1
- package/resources/llm-token-gateway/index.d.mts +4 -1
- package/resources/llm-token-gateway/index.d.mts.map +1 -1
- package/resources/llm-token-gateway/index.d.ts +4 -1
- package/resources/llm-token-gateway/index.d.ts.map +1 -1
- package/resources/llm-token-gateway/index.js +7 -1
- package/resources/llm-token-gateway/index.js.map +1 -1
- package/resources/llm-token-gateway/index.mjs +4 -1
- package/resources/llm-token-gateway/index.mjs.map +1 -1
- package/resources/llm-token-gateway/llm-token-gateway.d.mts +14 -2
- package/resources/llm-token-gateway/llm-token-gateway.d.mts.map +1 -1
- package/resources/llm-token-gateway/llm-token-gateway.d.ts +14 -2
- package/resources/llm-token-gateway/llm-token-gateway.d.ts.map +1 -1
- package/resources/llm-token-gateway/llm-token-gateway.js +12 -0
- package/resources/llm-token-gateway/llm-token-gateway.js.map +1 -1
- package/resources/llm-token-gateway/llm-token-gateway.mjs +13 -1
- package/resources/llm-token-gateway/llm-token-gateway.mjs.map +1 -1
- package/resources/llm-token-gateway/spend.d.mts +223 -0
- package/resources/llm-token-gateway/spend.d.mts.map +1 -0
- package/resources/llm-token-gateway/spend.d.ts +223 -0
- package/resources/llm-token-gateway/spend.d.ts.map +1 -0
- package/resources/llm-token-gateway/spend.js +56 -0
- package/resources/llm-token-gateway/spend.js.map +1 -0
- package/resources/llm-token-gateway/spend.mjs +52 -0
- package/resources/llm-token-gateway/spend.mjs.map +1 -0
- package/resources/llm-token-gateway/token-groups.d.mts +577 -0
- package/resources/llm-token-gateway/token-groups.d.mts.map +1 -0
- package/resources/llm-token-gateway/token-groups.d.ts +577 -0
- package/resources/llm-token-gateway/token-groups.d.ts.map +1 -0
- package/resources/llm-token-gateway/token-groups.js +139 -0
- package/resources/llm-token-gateway/token-groups.js.map +1 -0
- package/resources/llm-token-gateway/token-groups.mjs +135 -0
- package/resources/llm-token-gateway/token-groups.mjs.map +1 -0
- package/resources/llm-token-gateway/token-keys.d.mts +318 -0
- package/resources/llm-token-gateway/token-keys.d.mts.map +1 -0
- package/resources/llm-token-gateway/token-keys.d.ts +318 -0
- package/resources/llm-token-gateway/token-keys.d.ts.map +1 -0
- package/resources/llm-token-gateway/token-keys.js +127 -0
- package/resources/llm-token-gateway/token-keys.js.map +1 -0
- package/resources/llm-token-gateway/token-keys.mjs +123 -0
- package/resources/llm-token-gateway/token-keys.mjs.map +1 -0
- package/resources/llm-token-gateway/usage.d.mts +205 -146
- package/resources/llm-token-gateway/usage.d.mts.map +1 -1
- package/resources/llm-token-gateway/usage.d.ts +205 -146
- package/resources/llm-token-gateway/usage.d.ts.map +1 -1
- package/resources/llm-token-gateway/usage.js +47 -15
- package/resources/llm-token-gateway/usage.js.map +1 -1
- package/resources/llm-token-gateway/usage.mjs +47 -15
- package/resources/llm-token-gateway/usage.mjs.map +1 -1
- package/resources/meeting-sessions/actions.d.mts +13 -7
- package/resources/meeting-sessions/actions.d.mts.map +1 -1
- package/resources/meeting-sessions/actions.d.ts +13 -7
- package/resources/meeting-sessions/actions.d.ts.map +1 -1
- package/resources/meeting-sessions/actions.js +13 -7
- package/resources/meeting-sessions/actions.js.map +1 -1
- package/resources/meeting-sessions/actions.mjs +13 -7
- package/resources/meeting-sessions/actions.mjs.map +1 -1
- package/resources/meeting-sessions/index.d.mts +1 -1
- package/resources/meeting-sessions/index.d.mts.map +1 -1
- package/resources/meeting-sessions/index.d.ts +1 -1
- package/resources/meeting-sessions/index.d.ts.map +1 -1
- package/resources/meeting-sessions/index.js.map +1 -1
- package/resources/meeting-sessions/index.mjs.map +1 -1
- package/resources/meeting-sessions/meeting-sessions.d.mts +46 -65
- package/resources/meeting-sessions/meeting-sessions.d.mts.map +1 -1
- package/resources/meeting-sessions/meeting-sessions.d.ts +46 -65
- package/resources/meeting-sessions/meeting-sessions.d.ts.map +1 -1
- package/resources/meeting-sessions/meeting-sessions.js +14 -23
- package/resources/meeting-sessions/meeting-sessions.js.map +1 -1
- package/resources/meeting-sessions/meeting-sessions.mjs +14 -23
- package/resources/meeting-sessions/meeting-sessions.mjs.map +1 -1
- package/resources/messages/messages.d.mts +581 -118
- package/resources/messages/messages.d.mts.map +1 -1
- package/resources/messages/messages.d.ts +581 -118
- package/resources/messages/messages.d.ts.map +1 -1
- package/resources/messages/messages.js +71 -14
- package/resources/messages/messages.js.map +1 -1
- package/resources/messages/messages.mjs +71 -14
- package/resources/messages/messages.mjs.map +1 -1
- package/resources/messages/rcs.d.mts +26 -6
- package/resources/messages/rcs.d.mts.map +1 -1
- package/resources/messages/rcs.d.ts +26 -6
- package/resources/messages/rcs.d.ts.map +1 -1
- package/resources/messages/rcs.js +11 -2
- package/resources/messages/rcs.js.map +1 -1
- package/resources/messages/rcs.mjs +11 -2
- package/resources/messages/rcs.mjs.map +1 -1
- package/resources/phone-numbers/csv-downloads.d.mts +9 -0
- package/resources/phone-numbers/csv-downloads.d.mts.map +1 -1
- package/resources/phone-numbers/csv-downloads.d.ts +9 -0
- package/resources/phone-numbers/csv-downloads.d.ts.map +1 -1
- package/resources/phone-numbers/csv-downloads.js +5 -2
- package/resources/phone-numbers/csv-downloads.js.map +1 -1
- package/resources/phone-numbers/csv-downloads.mjs +5 -2
- package/resources/phone-numbers/csv-downloads.mjs.map +1 -1
- package/resources/phone-numbers/index.d.mts +2 -2
- package/resources/phone-numbers/index.d.mts.map +1 -1
- package/resources/phone-numbers/index.d.ts +2 -2
- package/resources/phone-numbers/index.d.ts.map +1 -1
- package/resources/phone-numbers/index.js.map +1 -1
- package/resources/phone-numbers/index.mjs.map +1 -1
- package/resources/phone-numbers/jobs.d.mts +277 -14
- package/resources/phone-numbers/jobs.d.mts.map +1 -1
- package/resources/phone-numbers/jobs.d.ts +277 -14
- package/resources/phone-numbers/jobs.d.ts.map +1 -1
- package/resources/phone-numbers/jobs.js +5 -4
- package/resources/phone-numbers/jobs.js.map +1 -1
- package/resources/phone-numbers/jobs.mjs +5 -4
- package/resources/phone-numbers/jobs.mjs.map +1 -1
- package/resources/phone-numbers/phone-numbers.d.mts +28 -3
- package/resources/phone-numbers/phone-numbers.d.mts.map +1 -1
- package/resources/phone-numbers/phone-numbers.d.ts +28 -3
- 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/reputation/numbers.d.mts +10 -0
- package/resources/reputation/numbers.d.mts.map +1 -1
- package/resources/reputation/numbers.d.ts +10 -0
- package/resources/reputation/numbers.d.ts.map +1 -1
- package/resources/shared.d.mts +4 -0
- package/resources/shared.d.mts.map +1 -1
- package/resources/shared.d.ts +4 -0
- package/resources/shared.d.ts.map +1 -1
- package/resources/sip-registration-status.d.mts +149 -0
- package/resources/sip-registration-status.d.mts.map +1 -0
- package/resources/sip-registration-status.d.ts +149 -0
- package/resources/sip-registration-status.d.ts.map +1 -0
- package/resources/sip-registration-status.js +32 -0
- package/resources/sip-registration-status.js.map +1 -0
- package/resources/sip-registration-status.mjs +28 -0
- package/resources/sip-registration-status.mjs.map +1 -0
- package/resources/speech-to-text/speech-to-text.d.mts +12 -5
- package/resources/speech-to-text/speech-to-text.d.mts.map +1 -1
- package/resources/speech-to-text/speech-to-text.d.ts +12 -5
- package/resources/speech-to-text/speech-to-text.d.ts.map +1 -1
- package/resources/telephony-credentials.d.mts +11 -2
- package/resources/telephony-credentials.d.mts.map +1 -1
- package/resources/telephony-credentials.d.ts +11 -2
- package/resources/telephony-credentials.d.ts.map +1 -1
- package/resources/telephony-credentials.js +9 -2
- package/resources/telephony-credentials.js.map +1 -1
- package/resources/telephony-credentials.mjs +9 -2
- package/resources/telephony-credentials.mjs.map +1 -1
- package/resources/texml/accounts/accounts.d.mts +2 -2
- package/resources/texml/accounts/accounts.d.ts +2 -2
- package/resources/texml/accounts/accounts.js +2 -2
- package/resources/texml/accounts/accounts.mjs +2 -2
- package/resources/texml/accounts/calls/calls.d.mts +49 -14
- package/resources/texml/accounts/calls/calls.d.mts.map +1 -1
- package/resources/texml/accounts/calls/calls.d.ts +49 -14
- package/resources/texml/accounts/calls/calls.d.ts.map +1 -1
- package/resources/texml/accounts/calls/calls.js +7 -7
- package/resources/texml/accounts/calls/calls.js.map +1 -1
- package/resources/texml/accounts/calls/calls.mjs +7 -7
- package/resources/texml/accounts/calls/calls.mjs.map +1 -1
- package/resources/texml/accounts/calls/recordings-json.d.mts +14 -4
- package/resources/texml/accounts/calls/recordings-json.d.mts.map +1 -1
- package/resources/texml/accounts/calls/recordings-json.d.ts +14 -4
- package/resources/texml/accounts/calls/recordings-json.d.ts.map +1 -1
- package/resources/texml/accounts/calls/recordings-json.js +2 -2
- package/resources/texml/accounts/calls/recordings-json.mjs +2 -2
- package/resources/texml/accounts/calls/recordings.d.mts +10 -2
- package/resources/texml/accounts/calls/recordings.d.mts.map +1 -1
- package/resources/texml/accounts/calls/recordings.d.ts +10 -2
- package/resources/texml/accounts/calls/recordings.d.ts.map +1 -1
- package/resources/texml/accounts/calls/recordings.js +4 -1
- package/resources/texml/accounts/calls/recordings.js.map +1 -1
- package/resources/texml/accounts/calls/recordings.mjs +4 -1
- package/resources/texml/accounts/calls/recordings.mjs.map +1 -1
- package/resources/texml/accounts/calls/siprec.d.mts +10 -2
- package/resources/texml/accounts/calls/siprec.d.mts.map +1 -1
- package/resources/texml/accounts/calls/siprec.d.ts +10 -2
- package/resources/texml/accounts/calls/siprec.d.ts.map +1 -1
- package/resources/texml/accounts/calls/siprec.js +4 -1
- package/resources/texml/accounts/calls/siprec.js.map +1 -1
- package/resources/texml/accounts/calls/siprec.mjs +4 -1
- package/resources/texml/accounts/calls/siprec.mjs.map +1 -1
- package/resources/texml/accounts/calls/streams.d.mts +10 -2
- package/resources/texml/accounts/calls/streams.d.mts.map +1 -1
- package/resources/texml/accounts/calls/streams.d.ts +10 -2
- package/resources/texml/accounts/calls/streams.d.ts.map +1 -1
- package/resources/texml/accounts/calls/streams.js +4 -1
- package/resources/texml/accounts/calls/streams.js.map +1 -1
- package/resources/texml/accounts/calls/streams.mjs +4 -1
- package/resources/texml/accounts/calls/streams.mjs.map +1 -1
- package/resources/texml/accounts/conferences/conferences.d.mts +29 -9
- package/resources/texml/accounts/conferences/conferences.d.mts.map +1 -1
- package/resources/texml/accounts/conferences/conferences.d.ts +29 -9
- package/resources/texml/accounts/conferences/conferences.d.ts.map +1 -1
- package/resources/texml/accounts/conferences/conferences.js +5 -5
- package/resources/texml/accounts/conferences/conferences.js.map +1 -1
- package/resources/texml/accounts/conferences/conferences.mjs +5 -5
- package/resources/texml/accounts/conferences/conferences.mjs.map +1 -1
- package/resources/texml/accounts/conferences/participants.d.mts +35 -10
- package/resources/texml/accounts/conferences/participants.d.mts.map +1 -1
- package/resources/texml/accounts/conferences/participants.d.ts +35 -10
- package/resources/texml/accounts/conferences/participants.d.ts.map +1 -1
- package/resources/texml/accounts/conferences/participants.js +5 -5
- package/resources/texml/accounts/conferences/participants.mjs +5 -5
- package/resources/texml/accounts/queues.d.mts +25 -8
- package/resources/texml/accounts/queues.d.mts.map +1 -1
- package/resources/texml/accounts/queues.d.ts +25 -8
- package/resources/texml/accounts/queues.d.ts.map +1 -1
- package/resources/texml/accounts/queues.js +7 -5
- package/resources/texml/accounts/queues.js.map +1 -1
- package/resources/texml/accounts/queues.mjs +7 -5
- package/resources/texml/accounts/queues.mjs.map +1 -1
- package/resources/texml/accounts/recordings/json.d.mts +14 -4
- package/resources/texml/accounts/recordings/json.d.mts.map +1 -1
- package/resources/texml/accounts/recordings/json.d.ts +14 -4
- package/resources/texml/accounts/recordings/json.d.ts.map +1 -1
- package/resources/texml/accounts/recordings/json.js +2 -2
- package/resources/texml/accounts/recordings/json.mjs +2 -2
- package/resources/texml/accounts/transcriptions/json.d.mts +14 -4
- package/resources/texml/accounts/transcriptions/json.d.mts.map +1 -1
- package/resources/texml/accounts/transcriptions/json.d.ts +14 -4
- package/resources/texml/accounts/transcriptions/json.d.ts.map +1 -1
- package/resources/texml/accounts/transcriptions/json.js +2 -2
- package/resources/texml/accounts/transcriptions/json.mjs +2 -2
- package/resources/texml/texml.d.mts +7 -3
- package/resources/texml/texml.d.mts.map +1 -1
- package/resources/texml/texml.d.ts +7 -3
- package/resources/texml/texml.d.ts.map +1 -1
- package/resources/texml/texml.js +4 -2
- package/resources/texml/texml.js.map +1 -1
- package/resources/texml/texml.mjs +4 -2
- package/resources/texml/texml.mjs.map +1 -1
- package/resources/text-to-speech/text-to-speech.d.mts +15 -6
- package/resources/text-to-speech/text-to-speech.d.mts.map +1 -1
- package/resources/text-to-speech/text-to-speech.d.ts +15 -6
- package/resources/text-to-speech/text-to-speech.d.ts.map +1 -1
- package/resources/tts-integrations/actions.d.mts +4 -0
- package/resources/tts-integrations/actions.d.mts.map +1 -0
- package/resources/tts-integrations/actions.d.ts +4 -0
- package/resources/tts-integrations/actions.d.ts.map +1 -0
- package/resources/tts-integrations/actions.js +9 -0
- package/resources/tts-integrations/actions.js.map +1 -0
- package/resources/tts-integrations/actions.mjs +5 -0
- package/resources/tts-integrations/actions.mjs.map +1 -0
- package/resources/tts-integrations/index.d.mts +3 -0
- package/resources/tts-integrations/index.d.mts.map +1 -0
- package/resources/tts-integrations/index.d.ts +3 -0
- package/resources/tts-integrations/index.d.ts.map +1 -0
- package/resources/tts-integrations/index.js +9 -0
- package/resources/tts-integrations/index.js.map +1 -0
- package/resources/tts-integrations/index.mjs +4 -0
- package/resources/tts-integrations/index.mjs.map +1 -0
- package/resources/tts-integrations/tts-integrations.d.mts +10 -0
- package/resources/tts-integrations/tts-integrations.d.mts.map +1 -0
- package/resources/tts-integrations/tts-integrations.d.ts +10 -0
- package/resources/tts-integrations/tts-integrations.d.ts.map +1 -0
- package/resources/tts-integrations/tts-integrations.js +17 -0
- package/resources/tts-integrations/tts-integrations.js.map +1 -0
- package/resources/tts-integrations/tts-integrations.mjs +12 -0
- package/resources/tts-integrations/tts-integrations.mjs.map +1 -0
- package/resources/tts-integrations.d.mts +2 -0
- package/resources/tts-integrations.d.mts.map +1 -0
- package/resources/tts-integrations.d.ts +2 -0
- package/resources/tts-integrations.d.ts.map +1 -0
- package/resources/tts-integrations.js +6 -0
- package/resources/tts-integrations.js.map +1 -0
- package/resources/tts-integrations.mjs +3 -0
- package/resources/tts-integrations.mjs.map +1 -0
- package/resources/uac-connections/uac-connections.d.mts +36 -6
- package/resources/uac-connections/uac-connections.d.mts.map +1 -1
- package/resources/uac-connections/uac-connections.d.ts +36 -6
- package/resources/uac-connections/uac-connections.d.ts.map +1 -1
- package/resources/uac-connections/uac-connections.js.map +1 -1
- package/resources/uac-connections/uac-connections.mjs.map +1 -1
- package/resources/voice-clones.d.mts +57 -10
- package/resources/voice-clones.d.mts.map +1 -1
- package/resources/voice-clones.d.ts +57 -10
- package/resources/voice-clones.d.ts.map +1 -1
- package/resources/voice-clones.js +6 -4
- package/resources/voice-clones.js.map +1 -1
- package/resources/voice-clones.mjs +6 -4
- package/resources/voice-clones.mjs.map +1 -1
- package/resources/webhooks.d.mts +986 -71
- package/resources/webhooks.d.mts.map +1 -1
- package/resources/webhooks.d.ts +986 -71
- package/resources/webhooks.d.ts.map +1 -1
- package/resources/webhooks.js.map +1 -1
- package/resources/webhooks.mjs.map +1 -1
- package/resources/whatsapp/hosted-signups.d.mts +165 -0
- package/resources/whatsapp/hosted-signups.d.mts.map +1 -0
- package/resources/whatsapp/hosted-signups.d.ts +165 -0
- package/resources/whatsapp/hosted-signups.d.ts.map +1 -0
- package/resources/whatsapp/hosted-signups.js +56 -0
- package/resources/whatsapp/hosted-signups.js.map +1 -0
- package/resources/whatsapp/hosted-signups.mjs +52 -0
- package/resources/whatsapp/hosted-signups.mjs.map +1 -0
- package/resources/whatsapp/index.d.mts +2 -0
- package/resources/whatsapp/index.d.mts.map +1 -1
- package/resources/whatsapp/index.d.ts +2 -0
- package/resources/whatsapp/index.d.ts.map +1 -1
- package/resources/whatsapp/index.js +5 -1
- package/resources/whatsapp/index.js.map +1 -1
- package/resources/whatsapp/index.mjs +2 -0
- package/resources/whatsapp/index.mjs.map +1 -1
- package/resources/whatsapp/phone-numbers/calling-routing.d.mts +6 -5
- package/resources/whatsapp/phone-numbers/calling-routing.d.mts.map +1 -1
- package/resources/whatsapp/phone-numbers/calling-routing.d.ts +6 -5
- package/resources/whatsapp/phone-numbers/calling-routing.d.ts.map +1 -1
- package/resources/whatsapp/phone-numbers/calling-routing.js +6 -5
- package/resources/whatsapp/phone-numbers/calling-routing.js.map +1 -1
- package/resources/whatsapp/phone-numbers/calling-routing.mjs +6 -5
- package/resources/whatsapp/phone-numbers/calling-routing.mjs.map +1 -1
- package/resources/whatsapp/signup.d.mts +128 -0
- package/resources/whatsapp/signup.d.mts.map +1 -0
- package/resources/whatsapp/signup.d.ts +128 -0
- package/resources/whatsapp/signup.d.ts.map +1 -0
- package/resources/whatsapp/signup.js +42 -0
- package/resources/whatsapp/signup.js.map +1 -0
- package/resources/whatsapp/signup.mjs +38 -0
- package/resources/whatsapp/signup.mjs.map +1 -0
- package/resources/whatsapp/whatsapp.d.mts +8 -0
- package/resources/whatsapp/whatsapp.d.mts.map +1 -1
- package/resources/whatsapp/whatsapp.d.ts +8 -0
- package/resources/whatsapp/whatsapp.d.ts.map +1 -1
- package/resources/whatsapp/whatsapp.js +8 -0
- package/resources/whatsapp/whatsapp.js.map +1 -1
- package/resources/whatsapp/whatsapp.mjs +8 -0
- package/resources/whatsapp/whatsapp.mjs.map +1 -1
- package/src/client.ts +57 -4
- package/src/resources/addresses/addresses.ts +22 -2
- package/src/resources/ai/ai.ts +40 -3
- package/src/resources/ai/assistants/assistants.ts +455 -20
- package/src/resources/ai/assistants/index.ts +2 -0
- package/src/resources/ai/assistants/versions.ts +20 -1
- package/src/resources/ai/audio.ts +18 -5
- package/src/resources/ai/avatars.ts +252 -0
- package/src/resources/ai/chat.ts +20 -6
- package/src/resources/ai/conversations/conversations.ts +9 -0
- package/src/resources/ai/index.ts +14 -0
- package/src/resources/ai/memory/namespaces/index.ts +2 -0
- package/src/resources/ai/memory/namespaces/namespaces.ts +4 -0
- package/src/resources/ai/memory/namespaces/profiles/index.ts +2 -0
- package/src/resources/ai/memory/namespaces/profiles/profiles.ts +71 -0
- package/src/resources/ai/openai/chat.ts +20 -6
- package/src/resources/ai/tools.ts +35 -1
- package/src/resources/calls/actions.ts +346 -20
- package/src/resources/calls/calls.ts +26 -8
- package/src/resources/calls/index.ts +2 -0
- package/src/resources/credential-connections/credential-connections.ts +41 -8
- package/src/resources/dial-metrics.ts +185 -0
- package/src/resources/dir/dir.ts +13 -8
- package/src/resources/dir/phone-numbers.ts +1 -6
- package/src/resources/dir/references.ts +15 -9
- package/src/resources/dir/verify-email.ts +17 -5
- package/src/resources/email-domains/email-domains.ts +1 -1
- package/src/resources/email-templates.ts +121 -19
- package/src/resources/enterprises/dir.ts +8 -2
- package/src/resources/enterprises/enterprises.ts +7 -3
- package/src/resources/enterprises/index.ts +1 -0
- package/src/resources/enterprises/reputation/external-verification.ts +125 -0
- package/src/resources/enterprises/reputation/index.ts +12 -0
- package/src/resources/enterprises/reputation/loa.ts +3 -2
- package/src/resources/enterprises/reputation/numbers.ts +256 -3
- package/src/resources/enterprises/reputation/remediation.ts +3 -2
- package/src/resources/enterprises/reputation/reputation.ts +70 -0
- package/src/resources/enterprises/verify-email.ts +1 -1
- package/src/resources/fqdn-connections/fqdn-connections.ts +41 -8
- package/src/resources/global-ip-assignment-health.ts +4 -4
- package/src/resources/global-ip-assignments-usage.ts +4 -4
- package/src/resources/index.ts +21 -2
- package/src/resources/ip-connections.ts +39 -6
- package/src/resources/llm-token-gateway/index.ts +38 -1
- package/src/resources/llm-token-gateway/llm-token-gateway.ts +83 -1
- package/src/resources/llm-token-gateway/spend.ts +309 -0
- package/src/resources/llm-token-gateway/token-groups.ts +724 -0
- package/src/resources/llm-token-gateway/token-keys.ts +422 -0
- package/src/resources/llm-token-gateway/usage.ts +273 -149
- package/src/resources/meeting-sessions/actions.ts +13 -7
- package/src/resources/meeting-sessions/index.ts +0 -1
- package/src/resources/meeting-sessions/meeting-sessions.ts +48 -79
- package/src/resources/messages/messages.ts +786 -125
- package/src/resources/messages/rcs.ts +37 -7
- package/src/resources/phone-numbers/csv-downloads.ts +15 -2
- package/src/resources/phone-numbers/index.ts +3 -1
- package/src/resources/phone-numbers/jobs.ts +332 -15
- package/src/resources/phone-numbers/phone-numbers.ts +38 -2
- package/src/resources/porting-orders/phone-number-blocks.ts +1 -0
- package/src/resources/porting-orders/porting-orders.ts +1 -0
- package/src/resources/porting-phone-numbers.ts +1 -0
- package/src/resources/reputation/numbers.ts +12 -0
- package/src/resources/shared.ts +5 -0
- package/src/resources/sip-registration-status.ts +188 -0
- package/src/resources/speech-to-text/speech-to-text.ts +12 -4
- package/src/resources/telephony-credentials.ts +24 -2
- package/src/resources/texml/accounts/accounts.ts +2 -2
- package/src/resources/texml/accounts/calls/calls.ts +49 -14
- package/src/resources/texml/accounts/calls/recordings-json.ts +14 -4
- package/src/resources/texml/accounts/calls/recordings.ts +10 -2
- package/src/resources/texml/accounts/calls/siprec.ts +10 -2
- package/src/resources/texml/accounts/calls/streams.ts +10 -2
- package/src/resources/texml/accounts/conferences/conferences.ts +29 -9
- package/src/resources/texml/accounts/conferences/participants.ts +35 -10
- package/src/resources/texml/accounts/queues.ts +25 -8
- package/src/resources/texml/accounts/recordings/json.ts +14 -4
- package/src/resources/texml/accounts/transcriptions/json.ts +14 -4
- package/src/resources/texml/texml.ts +7 -3
- package/src/resources/text-to-speech/text-to-speech.ts +15 -6
- package/src/resources/tts-integrations/actions.ts +5 -0
- package/src/resources/tts-integrations/index.ts +4 -0
- package/src/resources/tts-integrations/tts-integrations.ts +15 -0
- package/src/resources/tts-integrations.ts +3 -0
- package/src/resources/uac-connections/uac-connections.ts +39 -6
- package/src/resources/voice-clones.ts +65 -9
- package/src/resources/webhooks.ts +1257 -96
- package/src/resources/whatsapp/hosted-signups.ts +221 -0
- package/src/resources/whatsapp/index.ts +16 -0
- package/src/resources/whatsapp/phone-numbers/calling-routing.ts +6 -5
- package/src/resources/whatsapp/signup.ts +188 -0
- package/src/resources/whatsapp/whatsapp.ts +40 -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
|
@@ -0,0 +1,318 @@
|
|
|
1
|
+
import { APIResource } from "../../core/resource.js";
|
|
2
|
+
import * as TokenGroupsAPI from "./token-groups.js";
|
|
3
|
+
import { APIPromise } from "../../core/api-promise.js";
|
|
4
|
+
import { DefaultFlatPagination, type DefaultFlatPaginationParams, PagePromise } from "../../core/pagination.js";
|
|
5
|
+
import { RequestOptions } from "../../internal/request-options.js";
|
|
6
|
+
/**
|
|
7
|
+
* Manage and report AI Gateway usage.
|
|
8
|
+
*/
|
|
9
|
+
export declare class TokenKeys extends APIResource {
|
|
10
|
+
/**
|
|
11
|
+
* List gateway token keys within the authenticated Telnyx account. Foreign and
|
|
12
|
+
* unknown resource IDs return the same 404 response.
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```ts
|
|
16
|
+
* // Automatically fetches more pages as needed.
|
|
17
|
+
* for await (const tokenKey of client.llmTokenGateway.tokenKeys.list()) {
|
|
18
|
+
* // ...
|
|
19
|
+
* }
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
list(query?: TokenKeyListParams | null | undefined, options?: RequestOptions): PagePromise<TokenKeysDefaultFlatPagination, TokenKey>;
|
|
23
|
+
/**
|
|
24
|
+
* Create gateway token key within the authenticated Telnyx account. Foreign and
|
|
25
|
+
* unknown resource IDs return the same 404 response. The token secret is returned
|
|
26
|
+
* only on the original create response. A replay returns metadata without the
|
|
27
|
+
* secret. Provisioning is advisory; ready is not a guarantee of inference
|
|
28
|
+
* availability.
|
|
29
|
+
*
|
|
30
|
+
* @example
|
|
31
|
+
* ```ts
|
|
32
|
+
* const tokenKeyResponse =
|
|
33
|
+
* await client.llmTokenGateway.tokenKeys.create({
|
|
34
|
+
* name: 'support-service',
|
|
35
|
+
* token_group_id: '11111111-1111-4111-8111-111111111111',
|
|
36
|
+
* 'Idempotency-Key': 'Idempotency-Key',
|
|
37
|
+
* max_parallel_requests: 5,
|
|
38
|
+
* });
|
|
39
|
+
* ```
|
|
40
|
+
*/
|
|
41
|
+
create(params: TokenKeyCreateParams, options?: RequestOptions): APIPromise<TokenKeyResponse>;
|
|
42
|
+
/**
|
|
43
|
+
* Revoke this token key. Acknowledged revocation blocks new admissions with the
|
|
44
|
+
* key; requests already admitted may complete. Historical usage attribution is
|
|
45
|
+
* retained. Other keys in the group are unchanged.
|
|
46
|
+
*
|
|
47
|
+
* @example
|
|
48
|
+
* ```ts
|
|
49
|
+
* await client.llmTokenGateway.tokenKeys.delete(
|
|
50
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
51
|
+
* {
|
|
52
|
+
* 'Idempotency-Key': 'Idempotency-Key',
|
|
53
|
+
* 'If-Match': 'If-Match',
|
|
54
|
+
* },
|
|
55
|
+
* );
|
|
56
|
+
* ```
|
|
57
|
+
*/
|
|
58
|
+
delete(id: string, params: TokenKeyDeleteParams, options?: RequestOptions): APIPromise<void>;
|
|
59
|
+
/**
|
|
60
|
+
* Get gateway token key within the authenticated Telnyx account. Foreign and
|
|
61
|
+
* unknown resource IDs return the same 404 response.
|
|
62
|
+
*
|
|
63
|
+
* @example
|
|
64
|
+
* ```ts
|
|
65
|
+
* const tokenKeyResponse =
|
|
66
|
+
* await client.llmTokenGateway.tokenKeys.retrieve(
|
|
67
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
68
|
+
* );
|
|
69
|
+
* ```
|
|
70
|
+
*/
|
|
71
|
+
retrieve(id: string, options?: RequestOptions): APIPromise<TokenKeyResponse>;
|
|
72
|
+
/**
|
|
73
|
+
* Update gateway token key within the authenticated Telnyx account. Foreign and
|
|
74
|
+
* unknown resource IDs return the same 404 response. Omitted fields are preserved.
|
|
75
|
+
* Null clears max_parallel_requests; null resets budget and rate limits to their
|
|
76
|
+
* maximum. A stale If-Match returns 412.
|
|
77
|
+
*
|
|
78
|
+
* @example
|
|
79
|
+
* ```ts
|
|
80
|
+
* const tokenKeyResponse =
|
|
81
|
+
* await client.llmTokenGateway.tokenKeys.update(
|
|
82
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
83
|
+
* {
|
|
84
|
+
* 'Idempotency-Key': 'Idempotency-Key',
|
|
85
|
+
* 'If-Match': 'If-Match',
|
|
86
|
+
* max_parallel_requests: 5,
|
|
87
|
+
* },
|
|
88
|
+
* );
|
|
89
|
+
* ```
|
|
90
|
+
*/
|
|
91
|
+
update(id: string, params: TokenKeyUpdateParams, options?: RequestOptions): APIPromise<TokenKeyResponse>;
|
|
92
|
+
}
|
|
93
|
+
export type TokenKeysDefaultFlatPagination = DefaultFlatPagination<TokenKey>;
|
|
94
|
+
export interface TokenKey {
|
|
95
|
+
id: string;
|
|
96
|
+
allowed_models: Array<string> | null;
|
|
97
|
+
blocked: boolean;
|
|
98
|
+
budget_duration: TokenGroupsAPI.BudgetDuration | null;
|
|
99
|
+
budget_started_at: string | null;
|
|
100
|
+
created_at: string;
|
|
101
|
+
expires_at: string | null;
|
|
102
|
+
/**
|
|
103
|
+
* USD, decimal precision at most 6 places; parse exactly to integer micro-USD,
|
|
104
|
+
* never binary float accounting.
|
|
105
|
+
*/
|
|
106
|
+
max_budget: number | null;
|
|
107
|
+
name: string;
|
|
108
|
+
record_type: 'token_key';
|
|
109
|
+
/**
|
|
110
|
+
* Require a nonempty caller-asserted end-user ID; not proof of identity.
|
|
111
|
+
*/
|
|
112
|
+
required_end_user_id: boolean;
|
|
113
|
+
/**
|
|
114
|
+
* USD, decimal precision at most 6 places; parse exactly to integer micro-USD,
|
|
115
|
+
* never binary float accounting.
|
|
116
|
+
*/
|
|
117
|
+
reserved_spend: number;
|
|
118
|
+
resets_at: string | null;
|
|
119
|
+
/**
|
|
120
|
+
* Stored key limit; set to the maximum when the key was written without one (on a
|
|
121
|
+
* blocked key, null is kept until the key is unblocked).
|
|
122
|
+
*/
|
|
123
|
+
rpm_limit: number | null;
|
|
124
|
+
/**
|
|
125
|
+
* USD, decimal precision at most 6 places; parse exactly to integer micro-USD,
|
|
126
|
+
* never binary float accounting.
|
|
127
|
+
*/
|
|
128
|
+
spend: number;
|
|
129
|
+
token_group_id: string;
|
|
130
|
+
token_user_id: string | null;
|
|
131
|
+
/**
|
|
132
|
+
* Stored key limit; set to the maximum when the key was written without one (on a
|
|
133
|
+
* blocked key, null is kept until the key is unblocked).
|
|
134
|
+
*/
|
|
135
|
+
tpm_limit: number | null;
|
|
136
|
+
updated_at: string;
|
|
137
|
+
version: number;
|
|
138
|
+
/**
|
|
139
|
+
* Optional maximum concurrent reserved/dispatched cache misses across replicas.
|
|
140
|
+
* Null means no concurrency cap. Cache hits do not consume slots; unknown usage
|
|
141
|
+
* retains its budget hold without a slot.
|
|
142
|
+
*/
|
|
143
|
+
max_parallel_requests?: number | null;
|
|
144
|
+
/**
|
|
145
|
+
* Provisioning state of the key's current policy. `pending`: retry readiness with
|
|
146
|
+
* bounded backoff (treat `unknown` the same). `inactive` and `unsupported` are
|
|
147
|
+
* terminal until the key, group, user or catalog changes. `unavailable` means
|
|
148
|
+
* provisioning is stuck and is retried slowly; surface it. Absent while the
|
|
149
|
+
* gateway runs in compatibility mode.
|
|
150
|
+
*/
|
|
151
|
+
provisioning?: 'ready' | 'pending' | 'unavailable' | 'inactive' | 'unsupported' | 'unknown';
|
|
152
|
+
}
|
|
153
|
+
export interface TokenKeyResponse {
|
|
154
|
+
data: TokenKey;
|
|
155
|
+
}
|
|
156
|
+
export interface TokenKeyListParams extends DefaultFlatPaginationParams {
|
|
157
|
+
/**
|
|
158
|
+
* Required after page 1; account/filter-bound 15-minute stable snapshot;
|
|
159
|
+
* expired/mismatch 409.
|
|
160
|
+
*/
|
|
161
|
+
'page[snapshot]'?: string;
|
|
162
|
+
token_group_id?: string;
|
|
163
|
+
token_user_id?: string;
|
|
164
|
+
}
|
|
165
|
+
export interface TokenKeyCreateParams {
|
|
166
|
+
/**
|
|
167
|
+
* Body param
|
|
168
|
+
*/
|
|
169
|
+
name: string;
|
|
170
|
+
/**
|
|
171
|
+
* Body param
|
|
172
|
+
*/
|
|
173
|
+
token_group_id: string;
|
|
174
|
+
/**
|
|
175
|
+
* Header param: 24h, scoped by account+method+path. Same key/body returns same
|
|
176
|
+
* outcome; changed body 409; in-progress 409 with Retry-After. Token-create replay
|
|
177
|
+
* returns 200 metadata WITHOUT secret.
|
|
178
|
+
*/
|
|
179
|
+
'Idempotency-Key': string;
|
|
180
|
+
/**
|
|
181
|
+
* Body param
|
|
182
|
+
*/
|
|
183
|
+
allowed_models?: Array<string> | null;
|
|
184
|
+
/**
|
|
185
|
+
* Body param
|
|
186
|
+
*/
|
|
187
|
+
blocked?: boolean;
|
|
188
|
+
/**
|
|
189
|
+
* Body param
|
|
190
|
+
*/
|
|
191
|
+
budget_duration?: TokenGroupsAPI.BudgetDuration | null;
|
|
192
|
+
/**
|
|
193
|
+
* Body param
|
|
194
|
+
*/
|
|
195
|
+
expires_at?: string | null;
|
|
196
|
+
/**
|
|
197
|
+
* Body param: USD, decimal precision at most 6 places; parse exactly to integer
|
|
198
|
+
* micro-USD, never binary float accounting.
|
|
199
|
+
*/
|
|
200
|
+
max_budget?: number | null;
|
|
201
|
+
/**
|
|
202
|
+
* Body param: Optional maximum concurrent reserved/dispatched cache misses across
|
|
203
|
+
* replicas. Null means no concurrency cap. Cache hits do not consume slots;
|
|
204
|
+
* unknown usage retains its budget hold without a slot.
|
|
205
|
+
*/
|
|
206
|
+
max_parallel_requests?: number | null;
|
|
207
|
+
/**
|
|
208
|
+
* Body param: Require a nonempty caller-asserted end-user ID; not proof of
|
|
209
|
+
* identity.
|
|
210
|
+
*/
|
|
211
|
+
required_end_user_id?: boolean;
|
|
212
|
+
/**
|
|
213
|
+
* Body param: Omitted or null defaults to the maximum (6000) (on a blocked key,
|
|
214
|
+
* null is kept until the key is unblocked); a value below the minimum (1) or above
|
|
215
|
+
* the maximum is rejected with 400 limit_out_of_range; a malformed value
|
|
216
|
+
* (negative, wrong type or precision) is 400 invalid_request. Block the key
|
|
217
|
+
* (blocked: true) to deny it; blocking is always accepted.
|
|
218
|
+
*/
|
|
219
|
+
rpm_limit?: number | null;
|
|
220
|
+
/**
|
|
221
|
+
* Body param
|
|
222
|
+
*/
|
|
223
|
+
token_user_id?: string | null;
|
|
224
|
+
/**
|
|
225
|
+
* Body param: Omitted or null defaults to the maximum (10000000) (on a blocked
|
|
226
|
+
* key, null is kept until the key is unblocked); a value below the minimum (1) or
|
|
227
|
+
* above the maximum is rejected with 400 limit_out_of_range; a malformed value
|
|
228
|
+
* (negative, wrong type or precision) is 400 invalid_request. Block the key
|
|
229
|
+
* (blocked: true) to deny it; blocking is always accepted.
|
|
230
|
+
*/
|
|
231
|
+
tpm_limit?: number | null;
|
|
232
|
+
}
|
|
233
|
+
export interface TokenKeyDeleteParams {
|
|
234
|
+
/**
|
|
235
|
+
* 24h, scoped by account+method+path. Same key/body returns same outcome; changed
|
|
236
|
+
* body 409; in-progress 409 with Retry-After. Token-create replay returns 200
|
|
237
|
+
* metadata WITHOUT secret.
|
|
238
|
+
*/
|
|
239
|
+
'Idempotency-Key': string;
|
|
240
|
+
/**
|
|
241
|
+
* Exact quoted resource-version ETag; an exact intermediary-weakened echo W/"n" is
|
|
242
|
+
* accepted. Wildcard, combined and malformed validators are rejected; stale 412;
|
|
243
|
+
* missing 428. HTTP field names are case-insensitive. Replayed idempotent result
|
|
244
|
+
* is checked first.
|
|
245
|
+
*/
|
|
246
|
+
'If-Match': string;
|
|
247
|
+
}
|
|
248
|
+
export interface TokenKeyUpdateParams {
|
|
249
|
+
/**
|
|
250
|
+
* Header param: 24h, scoped by account+method+path. Same key/body returns same
|
|
251
|
+
* outcome; changed body 409; in-progress 409 with Retry-After. Token-create replay
|
|
252
|
+
* returns 200 metadata WITHOUT secret.
|
|
253
|
+
*/
|
|
254
|
+
'Idempotency-Key': string;
|
|
255
|
+
/**
|
|
256
|
+
* Header param: Exact quoted resource-version ETag; an exact intermediary-weakened
|
|
257
|
+
* echo W/"n" is accepted. Wildcard, combined and malformed validators are
|
|
258
|
+
* rejected; stale 412; missing 428. HTTP field names are case-insensitive.
|
|
259
|
+
* Replayed idempotent result is checked first.
|
|
260
|
+
*/
|
|
261
|
+
'If-Match': string;
|
|
262
|
+
/**
|
|
263
|
+
* Body param
|
|
264
|
+
*/
|
|
265
|
+
allowed_models?: Array<string> | null;
|
|
266
|
+
/**
|
|
267
|
+
* Body param
|
|
268
|
+
*/
|
|
269
|
+
blocked?: boolean;
|
|
270
|
+
/**
|
|
271
|
+
* Body param
|
|
272
|
+
*/
|
|
273
|
+
budget_duration?: TokenGroupsAPI.BudgetDuration | null;
|
|
274
|
+
/**
|
|
275
|
+
* Body param
|
|
276
|
+
*/
|
|
277
|
+
expires_at?: string | null;
|
|
278
|
+
/**
|
|
279
|
+
* Body param: USD, decimal precision at most 6 places; parse exactly to integer
|
|
280
|
+
* micro-USD, never binary float accounting.
|
|
281
|
+
*/
|
|
282
|
+
max_budget?: number | null;
|
|
283
|
+
/**
|
|
284
|
+
* Body param: Optional maximum concurrent reserved/dispatched cache misses across
|
|
285
|
+
* replicas. Null means no concurrency cap. Cache hits do not consume slots;
|
|
286
|
+
* unknown usage retains its budget hold without a slot.
|
|
287
|
+
*/
|
|
288
|
+
max_parallel_requests?: number | null;
|
|
289
|
+
/**
|
|
290
|
+
* Body param
|
|
291
|
+
*/
|
|
292
|
+
name?: string;
|
|
293
|
+
/**
|
|
294
|
+
* Body param: Require a nonempty caller-asserted end-user ID; not proof of
|
|
295
|
+
* identity. Omission preserves the current requirement.
|
|
296
|
+
*/
|
|
297
|
+
required_end_user_id?: boolean;
|
|
298
|
+
/**
|
|
299
|
+
* Body param: Omitted or null defaults to the maximum (6000) (on a blocked key,
|
|
300
|
+
* null is kept until the key is unblocked); a value below the minimum (1) or above
|
|
301
|
+
* the maximum is rejected with 400 limit_out_of_range; a malformed value
|
|
302
|
+
* (negative, wrong type or precision) is 400 invalid_request. Block the key
|
|
303
|
+
* (blocked: true) to deny it; blocking is always accepted.
|
|
304
|
+
*/
|
|
305
|
+
rpm_limit?: number | null;
|
|
306
|
+
/**
|
|
307
|
+
* Body param: Omitted or null defaults to the maximum (10000000) (on a blocked
|
|
308
|
+
* key, null is kept until the key is unblocked); a value below the minimum (1) or
|
|
309
|
+
* above the maximum is rejected with 400 limit_out_of_range; a malformed value
|
|
310
|
+
* (negative, wrong type or precision) is 400 invalid_request. Block the key
|
|
311
|
+
* (blocked: true) to deny it; blocking is always accepted.
|
|
312
|
+
*/
|
|
313
|
+
tpm_limit?: number | null;
|
|
314
|
+
}
|
|
315
|
+
export declare namespace TokenKeys {
|
|
316
|
+
export { type TokenKey as TokenKey, type TokenKeyResponse as TokenKeyResponse, type TokenKeysDefaultFlatPagination as TokenKeysDefaultFlatPagination, type TokenKeyListParams as TokenKeyListParams, type TokenKeyCreateParams as TokenKeyCreateParams, type TokenKeyDeleteParams as TokenKeyDeleteParams, type TokenKeyUpdateParams as TokenKeyUpdateParams, };
|
|
317
|
+
}
|
|
318
|
+
//# sourceMappingURL=token-keys.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"token-keys.d.ts","sourceRoot":"","sources":["../../src/resources/llm-token-gateway/token-keys.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,+B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C;IAE3B;;;;OAIG;IACH,qBAAqB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAEtC;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;OAGG;IACH,oBAAoB,CAAC,EAAE,OAAO,CAAC;IAE/B;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAE1B;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC3B;AAED,MAAM,CAAC,OAAO,WAAW,SAAS,CAAC;IACjC,OAAO,EACL,KAAK,QAAQ,IAAI,QAAQ,EACzB,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,8BAA8B,IAAI,8BAA8B,EACrE,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,oBAAoB,IAAI,oBAAoB,GAClD,CAAC;CACH"}
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.TokenKeys = void 0;
|
|
5
|
+
const resource_1 = require("../../core/resource.js");
|
|
6
|
+
const pagination_1 = require("../../core/pagination.js");
|
|
7
|
+
const headers_1 = require("../../internal/headers.js");
|
|
8
|
+
const path_1 = require("../../internal/utils/path.js");
|
|
9
|
+
/**
|
|
10
|
+
* Manage and report AI Gateway usage.
|
|
11
|
+
*/
|
|
12
|
+
class TokenKeys extends resource_1.APIResource {
|
|
13
|
+
/**
|
|
14
|
+
* List gateway token keys within the authenticated Telnyx account. Foreign and
|
|
15
|
+
* unknown resource IDs return the same 404 response.
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* ```ts
|
|
19
|
+
* // Automatically fetches more pages as needed.
|
|
20
|
+
* for await (const tokenKey of client.llmTokenGateway.tokenKeys.list()) {
|
|
21
|
+
* // ...
|
|
22
|
+
* }
|
|
23
|
+
* ```
|
|
24
|
+
*/
|
|
25
|
+
list(query = {}, options) {
|
|
26
|
+
return this._client.getAPIList('/llm_token_gateway/token_keys', (pagination_1.DefaultFlatPagination), {
|
|
27
|
+
query,
|
|
28
|
+
...options,
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Create gateway token key within the authenticated Telnyx account. Foreign and
|
|
33
|
+
* unknown resource IDs return the same 404 response. The token secret is returned
|
|
34
|
+
* only on the original create response. A replay returns metadata without the
|
|
35
|
+
* secret. Provisioning is advisory; ready is not a guarantee of inference
|
|
36
|
+
* availability.
|
|
37
|
+
*
|
|
38
|
+
* @example
|
|
39
|
+
* ```ts
|
|
40
|
+
* const tokenKeyResponse =
|
|
41
|
+
* await client.llmTokenGateway.tokenKeys.create({
|
|
42
|
+
* name: 'support-service',
|
|
43
|
+
* token_group_id: '11111111-1111-4111-8111-111111111111',
|
|
44
|
+
* 'Idempotency-Key': 'Idempotency-Key',
|
|
45
|
+
* max_parallel_requests: 5,
|
|
46
|
+
* });
|
|
47
|
+
* ```
|
|
48
|
+
*/
|
|
49
|
+
create(params, options) {
|
|
50
|
+
const { 'Idempotency-Key': idempotencyKey, ...body } = params;
|
|
51
|
+
return this._client.post('/llm_token_gateway/token_keys', {
|
|
52
|
+
body,
|
|
53
|
+
...options,
|
|
54
|
+
headers: (0, headers_1.buildHeaders)([{ 'Idempotency-Key': idempotencyKey }, options?.headers]),
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Revoke this token key. Acknowledged revocation blocks new admissions with the
|
|
59
|
+
* key; requests already admitted may complete. Historical usage attribution is
|
|
60
|
+
* retained. Other keys in the group are unchanged.
|
|
61
|
+
*
|
|
62
|
+
* @example
|
|
63
|
+
* ```ts
|
|
64
|
+
* await client.llmTokenGateway.tokenKeys.delete(
|
|
65
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
66
|
+
* {
|
|
67
|
+
* 'Idempotency-Key': 'Idempotency-Key',
|
|
68
|
+
* 'If-Match': 'If-Match',
|
|
69
|
+
* },
|
|
70
|
+
* );
|
|
71
|
+
* ```
|
|
72
|
+
*/
|
|
73
|
+
delete(id, params, options) {
|
|
74
|
+
const { 'Idempotency-Key': idempotencyKey, 'If-Match': ifMatch } = params;
|
|
75
|
+
return this._client.delete((0, path_1.path) `/llm_token_gateway/token_keys/${id}`, {
|
|
76
|
+
...options,
|
|
77
|
+
headers: (0, headers_1.buildHeaders)([
|
|
78
|
+
{ Accept: '*/*', 'Idempotency-Key': idempotencyKey, 'If-Match': ifMatch },
|
|
79
|
+
options?.headers,
|
|
80
|
+
]),
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Get gateway token key within the authenticated Telnyx account. Foreign and
|
|
85
|
+
* unknown resource IDs return the same 404 response.
|
|
86
|
+
*
|
|
87
|
+
* @example
|
|
88
|
+
* ```ts
|
|
89
|
+
* const tokenKeyResponse =
|
|
90
|
+
* await client.llmTokenGateway.tokenKeys.retrieve(
|
|
91
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
92
|
+
* );
|
|
93
|
+
* ```
|
|
94
|
+
*/
|
|
95
|
+
retrieve(id, options) {
|
|
96
|
+
return this._client.get((0, path_1.path) `/llm_token_gateway/token_keys/${id}`, options);
|
|
97
|
+
}
|
|
98
|
+
/**
|
|
99
|
+
* Update gateway token key within the authenticated Telnyx account. Foreign and
|
|
100
|
+
* unknown resource IDs return the same 404 response. Omitted fields are preserved.
|
|
101
|
+
* Null clears max_parallel_requests; null resets budget and rate limits to their
|
|
102
|
+
* maximum. A stale If-Match returns 412.
|
|
103
|
+
*
|
|
104
|
+
* @example
|
|
105
|
+
* ```ts
|
|
106
|
+
* const tokenKeyResponse =
|
|
107
|
+
* await client.llmTokenGateway.tokenKeys.update(
|
|
108
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
109
|
+
* {
|
|
110
|
+
* 'Idempotency-Key': 'Idempotency-Key',
|
|
111
|
+
* 'If-Match': 'If-Match',
|
|
112
|
+
* max_parallel_requests: 5,
|
|
113
|
+
* },
|
|
114
|
+
* );
|
|
115
|
+
* ```
|
|
116
|
+
*/
|
|
117
|
+
update(id, params, options) {
|
|
118
|
+
const { 'Idempotency-Key': idempotencyKey, 'If-Match': ifMatch, ...body } = params;
|
|
119
|
+
return this._client.patch((0, path_1.path) `/llm_token_gateway/token_keys/${id}`, {
|
|
120
|
+
body,
|
|
121
|
+
...options,
|
|
122
|
+
headers: (0, headers_1.buildHeaders)([{ 'Idempotency-Key': idempotencyKey, 'If-Match': ifMatch }, options?.headers]),
|
|
123
|
+
});
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
exports.TokenKeys = TokenKeys;
|
|
127
|
+
//# sourceMappingURL=token-keys.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"token-keys.js","sourceRoot":"","sources":["../../src/resources/llm-token-gateway/token-keys.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,qDAAkD;AAGlD,yDAA6G;AAC7G,uDAAsD;AAEtD,uDAAiD;AAEjD;;GAEG;AACH,MAAa,SAAU,SAAQ,sBAAW;IACxC;;;;;;;;;;;OAWG;IACH,IAAI,CACF,QAA+C,EAAE,EACjD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,+BAA+B,EAAE,CAAA,kCAA+B,CAAA,EAAE;YAC/F,KAAK;YACL,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;;;;;;;OAiBG;IACH,MAAM,CAAC,MAA4B,EAAE,OAAwB;QAC3D,MAAM,EAAE,iBAAiB,EAAE,cAAc,EAAE,GAAG,IAAI,EAAE,GAAG,MAAM,CAAC;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C,EAAE,iBAAiB,EAAE,cAAc,EAAE,UAAU,EAAE,OAAO,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SACtG,CAAC,CAAC;IACL,CAAC;CACF;AAxHD,8BAwHC"}
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../../core/resource.mjs";
|
|
3
|
+
import { DefaultFlatPagination } from "../../core/pagination.mjs";
|
|
4
|
+
import { buildHeaders } from "../../internal/headers.mjs";
|
|
5
|
+
import { path } from "../../internal/utils/path.mjs";
|
|
6
|
+
/**
|
|
7
|
+
* Manage and report AI Gateway usage.
|
|
8
|
+
*/
|
|
9
|
+
export class TokenKeys extends APIResource {
|
|
10
|
+
/**
|
|
11
|
+
* List gateway token keys within the authenticated Telnyx account. Foreign and
|
|
12
|
+
* unknown resource IDs return the same 404 response.
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```ts
|
|
16
|
+
* // Automatically fetches more pages as needed.
|
|
17
|
+
* for await (const tokenKey of client.llmTokenGateway.tokenKeys.list()) {
|
|
18
|
+
* // ...
|
|
19
|
+
* }
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
list(query = {}, options) {
|
|
23
|
+
return this._client.getAPIList('/llm_token_gateway/token_keys', (DefaultFlatPagination), {
|
|
24
|
+
query,
|
|
25
|
+
...options,
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Create gateway token key within the authenticated Telnyx account. Foreign and
|
|
30
|
+
* unknown resource IDs return the same 404 response. The token secret is returned
|
|
31
|
+
* only on the original create response. A replay returns metadata without the
|
|
32
|
+
* secret. Provisioning is advisory; ready is not a guarantee of inference
|
|
33
|
+
* availability.
|
|
34
|
+
*
|
|
35
|
+
* @example
|
|
36
|
+
* ```ts
|
|
37
|
+
* const tokenKeyResponse =
|
|
38
|
+
* await client.llmTokenGateway.tokenKeys.create({
|
|
39
|
+
* name: 'support-service',
|
|
40
|
+
* token_group_id: '11111111-1111-4111-8111-111111111111',
|
|
41
|
+
* 'Idempotency-Key': 'Idempotency-Key',
|
|
42
|
+
* max_parallel_requests: 5,
|
|
43
|
+
* });
|
|
44
|
+
* ```
|
|
45
|
+
*/
|
|
46
|
+
create(params, options) {
|
|
47
|
+
const { 'Idempotency-Key': idempotencyKey, ...body } = params;
|
|
48
|
+
return this._client.post('/llm_token_gateway/token_keys', {
|
|
49
|
+
body,
|
|
50
|
+
...options,
|
|
51
|
+
headers: buildHeaders([{ 'Idempotency-Key': idempotencyKey }, options?.headers]),
|
|
52
|
+
});
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* Revoke this token key. Acknowledged revocation blocks new admissions with the
|
|
56
|
+
* key; requests already admitted may complete. Historical usage attribution is
|
|
57
|
+
* retained. Other keys in the group are unchanged.
|
|
58
|
+
*
|
|
59
|
+
* @example
|
|
60
|
+
* ```ts
|
|
61
|
+
* await client.llmTokenGateway.tokenKeys.delete(
|
|
62
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
63
|
+
* {
|
|
64
|
+
* 'Idempotency-Key': 'Idempotency-Key',
|
|
65
|
+
* 'If-Match': 'If-Match',
|
|
66
|
+
* },
|
|
67
|
+
* );
|
|
68
|
+
* ```
|
|
69
|
+
*/
|
|
70
|
+
delete(id, params, options) {
|
|
71
|
+
const { 'Idempotency-Key': idempotencyKey, 'If-Match': ifMatch } = params;
|
|
72
|
+
return this._client.delete(path `/llm_token_gateway/token_keys/${id}`, {
|
|
73
|
+
...options,
|
|
74
|
+
headers: buildHeaders([
|
|
75
|
+
{ Accept: '*/*', 'Idempotency-Key': idempotencyKey, 'If-Match': ifMatch },
|
|
76
|
+
options?.headers,
|
|
77
|
+
]),
|
|
78
|
+
});
|
|
79
|
+
}
|
|
80
|
+
/**
|
|
81
|
+
* Get gateway token key within the authenticated Telnyx account. Foreign and
|
|
82
|
+
* unknown resource IDs return the same 404 response.
|
|
83
|
+
*
|
|
84
|
+
* @example
|
|
85
|
+
* ```ts
|
|
86
|
+
* const tokenKeyResponse =
|
|
87
|
+
* await client.llmTokenGateway.tokenKeys.retrieve(
|
|
88
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
89
|
+
* );
|
|
90
|
+
* ```
|
|
91
|
+
*/
|
|
92
|
+
retrieve(id, options) {
|
|
93
|
+
return this._client.get(path `/llm_token_gateway/token_keys/${id}`, options);
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* Update gateway token key within the authenticated Telnyx account. Foreign and
|
|
97
|
+
* unknown resource IDs return the same 404 response. Omitted fields are preserved.
|
|
98
|
+
* Null clears max_parallel_requests; null resets budget and rate limits to their
|
|
99
|
+
* maximum. A stale If-Match returns 412.
|
|
100
|
+
*
|
|
101
|
+
* @example
|
|
102
|
+
* ```ts
|
|
103
|
+
* const tokenKeyResponse =
|
|
104
|
+
* await client.llmTokenGateway.tokenKeys.update(
|
|
105
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
106
|
+
* {
|
|
107
|
+
* 'Idempotency-Key': 'Idempotency-Key',
|
|
108
|
+
* 'If-Match': 'If-Match',
|
|
109
|
+
* max_parallel_requests: 5,
|
|
110
|
+
* },
|
|
111
|
+
* );
|
|
112
|
+
* ```
|
|
113
|
+
*/
|
|
114
|
+
update(id, params, options) {
|
|
115
|
+
const { 'Idempotency-Key': idempotencyKey, 'If-Match': ifMatch, ...body } = params;
|
|
116
|
+
return this._client.patch(path `/llm_token_gateway/token_keys/${id}`, {
|
|
117
|
+
body,
|
|
118
|
+
...options,
|
|
119
|
+
headers: buildHeaders([{ 'Idempotency-Key': idempotencyKey, 'If-Match': ifMatch }, options?.headers]),
|
|
120
|
+
});
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
//# sourceMappingURL=token-keys.mjs.map
|
|
@@ -0,0 +1 @@
|
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