telnyx 7.24.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 +7 -0
- package/client.d.mts +19 -4
- package/client.d.mts.map +1 -1
- package/client.d.ts +19 -4
- 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 +7 -6
- package/resources/ai/ai.d.mts.map +1 -1
- package/resources/ai/ai.d.ts +7 -6
- package/resources/ai/ai.d.ts.map +1 -1
- package/resources/ai/ai.js.map +1 -1
- package/resources/ai/ai.mjs.map +1 -1
- package/resources/ai/assistants/assistants.d.mts +320 -28
- package/resources/ai/assistants/assistants.d.mts.map +1 -1
- package/resources/ai/assistants/assistants.d.ts +320 -28
- 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 +36 -0
- package/resources/ai/assistants/versions.d.mts.map +1 -1
- package/resources/ai/assistants/versions.d.ts +36 -0
- 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/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 +2 -2
- package/resources/ai/index.d.mts.map +1 -1
- package/resources/ai/index.d.ts +2 -2
- package/resources/ai/index.d.ts.map +1 -1
- package/resources/ai/index.js.map +1 -1
- package/resources/ai/index.mjs.map +1 -1
- package/resources/ai/memory/index.d.mts +1 -1
- package/resources/ai/memory/index.d.mts.map +1 -1
- package/resources/ai/memory/index.d.ts +1 -1
- package/resources/ai/memory/index.d.ts.map +1 -1
- package/resources/ai/memory/index.js.map +1 -1
- package/resources/ai/memory/index.mjs +1 -1
- package/resources/ai/memory/index.mjs.map +1 -1
- package/resources/ai/memory/memory.d.mts +2 -2
- package/resources/ai/memory/memory.d.mts.map +1 -1
- package/resources/ai/memory/memory.d.ts +2 -2
- package/resources/ai/memory/memory.d.ts.map +1 -1
- package/resources/ai/memory/memory.js.map +1 -1
- package/resources/ai/memory/memory.mjs +1 -1
- package/resources/ai/memory/memory.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 +1 -1
- package/resources/ai/memory/namespaces/index.mjs.map +1 -1
- package/resources/ai/memory/namespaces/namespaces.d.mts +60 -4
- package/resources/ai/memory/namespaces/namespaces.d.mts.map +1 -1
- package/resources/ai/memory/namespaces/namespaces.d.ts +60 -4
- package/resources/ai/memory/namespaces/namespaces.d.ts.map +1 -1
- package/resources/ai/memory/namespaces/namespaces.js +41 -3
- package/resources/ai/memory/namespaces/namespaces.js.map +1 -1
- package/resources/ai/memory/namespaces/namespaces.mjs +41 -3
- package/resources/ai/memory/namespaces/namespaces.mjs.map +1 -1
- 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/calls/actions.d.mts +76 -17
- package/resources/calls/actions.d.mts.map +1 -1
- package/resources/calls/actions.d.ts +76 -17
- 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 +48 -11
- package/resources/calls/calls.d.mts.map +1 -1
- package/resources/calls/calls.d.ts +48 -11
- 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/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/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 +4 -2
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +4 -2
- 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/meeting-sessions.d.mts +8 -9
- package/resources/meeting-sessions/meeting-sessions.d.mts.map +1 -1
- package/resources/meeting-sessions/meeting-sessions.d.ts +8 -9
- package/resources/meeting-sessions/meeting-sessions.d.ts.map +1 -1
- package/resources/meeting-sessions/meeting-sessions.js +6 -6
- package/resources/meeting-sessions/meeting-sessions.js.map +1 -1
- package/resources/meeting-sessions/meeting-sessions.mjs +6 -6
- package/resources/meeting-sessions/meeting-sessions.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/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/text-to-speech/text-to-speech.d.mts +4 -2
- package/resources/text-to-speech/text-to-speech.d.mts.map +1 -1
- package/resources/text-to-speech/text-to-speech.d.ts +4 -2
- package/resources/text-to-speech/text-to-speech.d.ts.map +1 -1
- package/resources/webhooks.d.mts +403 -5
- package/resources/webhooks.d.mts.map +1 -1
- package/resources/webhooks.d.ts +403 -5
- 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 +55 -0
- package/src/resources/ai/ai.ts +13 -4
- package/src/resources/ai/assistants/assistants.ts +384 -28
- package/src/resources/ai/assistants/deleted.ts +86 -0
- package/src/resources/ai/assistants/index.ts +11 -0
- package/src/resources/ai/assistants/versions.ts +40 -0
- package/src/resources/ai/chat.ts +7 -2
- package/src/resources/ai/embeddings/embeddings.ts +1 -1
- package/src/resources/ai/index.ts +5 -1
- package/src/resources/ai/memory/index.ts +9 -1
- package/src/resources/ai/memory/memory.ts +13 -1
- package/src/resources/ai/memory/namespaces/index.ts +9 -1
- package/src/resources/ai/memory/namespaces/namespaces.ts +81 -3
- package/src/resources/ai/openai/chat.ts +7 -2
- package/src/resources/ai/tools.ts +6 -6
- package/src/resources/calls/actions.ts +76 -15
- package/src/resources/calls/calls.ts +49 -9
- 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/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 +20 -0
- 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/meeting-sessions.ts +8 -9
- 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/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/text-to-speech/text-to-speech.ts +4 -2
- package/src/resources/webhooks.ts +495 -2
- 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
|
@@ -150,6 +150,9 @@ export class Calls extends APIResource {
|
|
|
150
150
|
* `answering_machine_detection=premium` was requested
|
|
151
151
|
* - `call.machine.premium.greeting.ended` if `answering_machine_detection=premium`
|
|
152
152
|
* was requested and a beep was detected
|
|
153
|
+
* - `call.machine.premium.call_screening.detected` if
|
|
154
|
+
* `answering_machine_detection=premium_ios_call_screening_detection` was
|
|
155
|
+
* requested and an Apple Call Screening tone was detected
|
|
153
156
|
* - `call.deepfake_detection.result` if `deepfake_detection` was enabled
|
|
154
157
|
* - `call.deepfake_detection.error` if `deepfake_detection` was enabled and an
|
|
155
158
|
* error occurred
|
|
@@ -188,9 +191,11 @@ export class Calls extends APIResource {
|
|
|
188
191
|
}
|
|
189
192
|
|
|
190
193
|
/**
|
|
191
|
-
* AI Assistant configuration. All fields except `id` are
|
|
192
|
-
*
|
|
193
|
-
*
|
|
194
|
+
* AI Assistant configuration and per-call overrides. All fields except `id` are
|
|
195
|
+
* optional. Omitted assistant fields use the stored configuration. Supplied
|
|
196
|
+
* `voice_settings` and `transcription` objects replace their stored objects rather
|
|
197
|
+
* than merging individual settings; include every setting you want to retain.
|
|
198
|
+
* `dynamic_variables` are merged, with request values taking precedence.
|
|
194
199
|
*/
|
|
195
200
|
export interface CallAssistantRequest {
|
|
196
201
|
/**
|
|
@@ -282,6 +287,19 @@ export interface CallAssistantRequest {
|
|
|
282
287
|
| Shared.CallControlRetrievalTool
|
|
283
288
|
>;
|
|
284
289
|
|
|
290
|
+
/**
|
|
291
|
+
* Per-call speech-to-text configuration for the assistant. If omitted, the stored
|
|
292
|
+
* assistant transcription configuration is used. If supplied, this object replaces
|
|
293
|
+
* the stored transcription settings. This is separate from the top-level
|
|
294
|
+
* `transcription` boolean on answer and dial commands.
|
|
295
|
+
*/
|
|
296
|
+
transcription?: ActionsAPI.TranscriptionConfig;
|
|
297
|
+
|
|
298
|
+
/**
|
|
299
|
+
* Per-call voice configuration. Set the voice identifier in
|
|
300
|
+
* `voice_settings.voice`, not in `assistant.voice`. If supplied, this object
|
|
301
|
+
* replaces the stored voice settings.
|
|
302
|
+
*/
|
|
285
303
|
voice_settings?: AssistantsAPI.VoiceSettings;
|
|
286
304
|
}
|
|
287
305
|
|
|
@@ -921,10 +939,20 @@ export interface CallDialParams {
|
|
|
921
939
|
* `greeting_end` or `detect_words` is used and a `machine` is detected, you will
|
|
922
940
|
* receive another `call.machine.greeting.ended` webhook when the answering machine
|
|
923
941
|
* greeting ends with a beep or silence. If `detect_beep` is used, you will only
|
|
924
|
-
* receive `call.machine.greeting.ended` if a beep is detected.
|
|
942
|
+
* receive `call.machine.greeting.ended` if a beep is detected. If
|
|
943
|
+
* `answering_machine_detection` is set to `premium_ios_call_screening_detection`,
|
|
944
|
+
* Premium AMD runs with iOS Call Screening support: after an initial `machine`
|
|
945
|
+
* result, Telnyx listens for the iOS call-screening prompt to end or for an Apple
|
|
946
|
+
* Call Screening tone, sends `call.machine.premium.greeting.ended` with
|
|
947
|
+
* `result=prompt_ended` or `call.machine.premium.call_screening.detected` with
|
|
948
|
+
* `result=screening` respectively. When the Apple Call Screening tone is detected,
|
|
949
|
+
* Premium AMD is restarted on the screened call and a
|
|
950
|
+
* `call.machine.premium.detection.ended` webhook with the post-screening
|
|
951
|
+
* classification follows.
|
|
925
952
|
*/
|
|
926
953
|
answering_machine_detection?:
|
|
927
954
|
| 'premium'
|
|
955
|
+
| 'premium_ios_call_screening_detection'
|
|
928
956
|
| 'detect'
|
|
929
957
|
| 'detect_beep'
|
|
930
958
|
| 'detect_words'
|
|
@@ -935,14 +963,17 @@ export interface CallDialParams {
|
|
|
935
963
|
* Optional configuration parameters to modify 'answering_machine_detection'
|
|
936
964
|
* performance. Only `total_analysis_time_millis` and `greeting_duration_millis`
|
|
937
965
|
* parameters are applicable when `premium` is selected as
|
|
938
|
-
* answering_machine_detection.
|
|
966
|
+
* answering_machine_detection. `prompt_end_timeout_millis` is additionally
|
|
967
|
+
* applicable when `premium_ios_call_screening_detection` is selected.
|
|
939
968
|
*/
|
|
940
969
|
answering_machine_detection_config?: CallDialParams.AnsweringMachineDetectionConfig;
|
|
941
970
|
|
|
942
971
|
/**
|
|
943
|
-
* AI Assistant configuration. All fields except `id` are
|
|
944
|
-
*
|
|
945
|
-
*
|
|
972
|
+
* AI Assistant configuration and per-call overrides. All fields except `id` are
|
|
973
|
+
* optional. Omitted assistant fields use the stored configuration. Supplied
|
|
974
|
+
* `voice_settings` and `transcription` objects replace their stored objects rather
|
|
975
|
+
* than merging individual settings; include every setting you want to retain.
|
|
976
|
+
* `dynamic_variables` are merged, with request values taking precedence.
|
|
946
977
|
*/
|
|
947
978
|
assistant?: CallAssistantRequest;
|
|
948
979
|
|
|
@@ -1329,7 +1360,8 @@ export namespace CallDialParams {
|
|
|
1329
1360
|
* Optional configuration parameters to modify 'answering_machine_detection'
|
|
1330
1361
|
* performance. Only `total_analysis_time_millis` and `greeting_duration_millis`
|
|
1331
1362
|
* parameters are applicable when `premium` is selected as
|
|
1332
|
-
* answering_machine_detection.
|
|
1363
|
+
* answering_machine_detection. `prompt_end_timeout_millis` is additionally
|
|
1364
|
+
* applicable when `premium_ios_call_screening_detection` is selected.
|
|
1333
1365
|
*/
|
|
1334
1366
|
export interface AnsweringMachineDetectionConfig {
|
|
1335
1367
|
/**
|
|
@@ -1429,6 +1461,14 @@ export namespace CallDialParams {
|
|
|
1429
1461
|
*/
|
|
1430
1462
|
maximum_word_length_millis?: number;
|
|
1431
1463
|
|
|
1464
|
+
/**
|
|
1465
|
+
* Maximum time Telnyx waits, in milliseconds, for the iOS call-screening prompt to
|
|
1466
|
+
* end after Premium AMD initially detects a `machine`. Used when
|
|
1467
|
+
* `answering_machine_detection` is `premium_ios_call_screening_detection`.
|
|
1468
|
+
* Defaults to 5000 milliseconds.
|
|
1469
|
+
*/
|
|
1470
|
+
prompt_end_timeout_millis?: number;
|
|
1471
|
+
|
|
1432
1472
|
/**
|
|
1433
1473
|
* Minimum noise threshold for any analysis.
|
|
1434
1474
|
*/
|
package/src/resources/dir/dir.ts
CHANGED
|
@@ -110,22 +110,23 @@ export class DirResource extends APIResource {
|
|
|
110
110
|
}
|
|
111
111
|
|
|
112
112
|
/**
|
|
113
|
-
*
|
|
114
|
-
*
|
|
115
|
-
*
|
|
113
|
+
* Request deletion of a DIR. This does not remove the DIR on this call: it records
|
|
114
|
+
* the request, moves the DIR to `delete_requested`, and Telnyx completes the
|
|
115
|
+
* removal (de-registration and cleanup) shortly after. A verified DIR keeps
|
|
116
|
+
* serving its branded identity, and keeps billing, until the removal is executed.
|
|
117
|
+
* Failure modes: `400` if a child phone number is still attached or the DIR is
|
|
118
|
+
* `in_review` (wait for the review to finish), `409` if the DIR has an unresolved
|
|
119
|
+
* infringement claim, `404` if the DIR is not yours.
|
|
116
120
|
*
|
|
117
121
|
* @example
|
|
118
122
|
* ```ts
|
|
119
|
-
* await client.dir.delete(
|
|
123
|
+
* const dir = await client.dir.delete(
|
|
120
124
|
* '16635d38-75a6-4481-82e8-69af60e05011',
|
|
121
125
|
* );
|
|
122
126
|
* ```
|
|
123
127
|
*/
|
|
124
|
-
delete(dirID: string, options?: RequestOptions): APIPromise<
|
|
125
|
-
return this._client.delete(path`/dir/${dirID}`,
|
|
126
|
-
...options,
|
|
127
|
-
headers: buildHeaders([{ Accept: '*/*' }, options?.headers]),
|
|
128
|
-
});
|
|
128
|
+
delete(dirID: string, options?: RequestOptions): APIPromise<DirDeleteResponse> {
|
|
129
|
+
return this._client.delete(path`/dir/${dirID}`, options);
|
|
129
130
|
}
|
|
130
131
|
|
|
131
132
|
/**
|
|
@@ -147,11 +148,14 @@ export class DirResource extends APIResource {
|
|
|
147
148
|
* Edit a DIR. DIRs in `draft`, `rejected`, `unsuccessful`, or `suspended` can be
|
|
148
149
|
* edited freely: PATCH is a pure edit, `status` is never changed, and you re-vet
|
|
149
150
|
* by calling `POST /v2/dir/{dir_id}/submit` explicitly. A `verified` DIR can also
|
|
150
|
-
* be edited in place: a PATCH that changes any value returns the DIR to `draft
|
|
151
|
-
*
|
|
152
|
-
*
|
|
153
|
-
*
|
|
154
|
-
*
|
|
151
|
+
* be edited in place: a PATCH that changes any value returns the DIR to `draft`;
|
|
152
|
+
* the currently approved identity keeps displaying, and the edited content goes
|
|
153
|
+
* live only after you re-submit and the DIR is approved again. A PATCH that
|
|
154
|
+
* changes nothing (an empty body or values identical to the current ones) leaves
|
|
155
|
+
* the DIR `verified`, so idempotent retries are safe. Changing only
|
|
156
|
+
* `bpo_authorizations` or `webhook_url` is the exception: the DIR stays
|
|
157
|
+
* `verified`. Each BPO authorization is reviewed on its own instead. DIRs in any
|
|
158
|
+
* other status (`submitted`, `in_review`, `expired`, `infringement_claimed`,
|
|
155
159
|
* `permanently_rejected`) cannot be edited.
|
|
156
160
|
*
|
|
157
161
|
* @example
|
|
@@ -289,10 +293,95 @@ export class DirResource extends APIResource {
|
|
|
289
293
|
__binaryResponse: true,
|
|
290
294
|
});
|
|
291
295
|
}
|
|
296
|
+
|
|
297
|
+
/**
|
|
298
|
+
* List the BPO (Business Process Outsourcer) accounts a Brand Owner has authorized
|
|
299
|
+
* on this DIR, together with the review state of each authorization.
|
|
300
|
+
*
|
|
301
|
+
* Authorizations are supplied as the `bpo_authorizations` array when creating or
|
|
302
|
+
* updating a DIR, and each one is reviewed on its own. Only an `approved`
|
|
303
|
+
* authorization adds that BPO to this DIR's authorized callers in the branded
|
|
304
|
+
* calling registry; `pending` and `rejected` authorizations do not. Each entry
|
|
305
|
+
* includes the `loa_document_id` you submitted: because `bpo_authorizations`
|
|
306
|
+
* replaces the whole list on every DIR update, send each entry you want to keep
|
|
307
|
+
* back with its `loa_document_id` unchanged, and it keeps its review state. A
|
|
308
|
+
* rejected entry carries a `rejection_reason`. Returns an empty list when the DIR
|
|
309
|
+
* has authorized no BPOs.
|
|
310
|
+
*
|
|
311
|
+
* @example
|
|
312
|
+
* ```ts
|
|
313
|
+
* const response = await client.dir.retrieveBpoAuthorizations(
|
|
314
|
+
* '16635d38-75a6-4481-82e8-69af60e05011',
|
|
315
|
+
* );
|
|
316
|
+
* ```
|
|
317
|
+
*/
|
|
318
|
+
retrieveBpoAuthorizations(
|
|
319
|
+
dirID: string,
|
|
320
|
+
query: DirRetrieveBpoAuthorizationsParams | null | undefined = {},
|
|
321
|
+
options?: RequestOptions,
|
|
322
|
+
): APIPromise<DirRetrieveBpoAuthorizationsResponse> {
|
|
323
|
+
return this._client.get(path`/dir/${dirID}/bpo_authorizations`, { query, ...options });
|
|
324
|
+
}
|
|
325
|
+
|
|
326
|
+
/**
|
|
327
|
+
* The Letter of Authorization in which a Brand Owner authorizes an approved BPO
|
|
328
|
+
* (Business Process Outsourcer) to place branded calls that display this DIR on
|
|
329
|
+
* the owner's behalf. Both parties are read from the caller's account: the Brand
|
|
330
|
+
* Owner is the enterprise that owns the DIR, and the BPO is `bpo_enterprise_id`.
|
|
331
|
+
* No business identity is accepted in the body.
|
|
332
|
+
*
|
|
333
|
+
* When `signature` is omitted the PDF is returned unsigned so the Brand Owner can
|
|
334
|
+
* sign it externally and the BPO can upload it via the Documents API. When
|
|
335
|
+
* `signature` is present the PDF embeds the supplied image, printed name, and
|
|
336
|
+
* signed-at date.
|
|
337
|
+
*
|
|
338
|
+
* Returns `application/pdf`.
|
|
339
|
+
*
|
|
340
|
+
* @example
|
|
341
|
+
* ```ts
|
|
342
|
+
* const response = await client.dir.bpoLoa(
|
|
343
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
344
|
+
* {
|
|
345
|
+
* bpo_enterprise_id:
|
|
346
|
+
* '4a6192a4-573d-446d-b3ce-aff9117272a6',
|
|
347
|
+
* },
|
|
348
|
+
* );
|
|
349
|
+
*
|
|
350
|
+
* const content = await response.blob();
|
|
351
|
+
* console.log(content);
|
|
352
|
+
* ```
|
|
353
|
+
*/
|
|
354
|
+
bpoLoa(dirID: string, body: DirBpoLoaParams, options?: RequestOptions): APIPromise<Response> {
|
|
355
|
+
return this._client.post(path`/dir/${dirID}/bpo_loa`, {
|
|
356
|
+
body,
|
|
357
|
+
...options,
|
|
358
|
+
headers: buildHeaders([{ Accept: 'application/pdf' }, options?.headers]),
|
|
359
|
+
__binaryResponse: true,
|
|
360
|
+
});
|
|
361
|
+
}
|
|
292
362
|
}
|
|
293
363
|
|
|
294
364
|
export type DirsDefaultFlatPagination = DefaultFlatPagination<Dir>;
|
|
295
365
|
|
|
366
|
+
/**
|
|
367
|
+
* One authorization to include when creating or updating a DIR: an approved BPO
|
|
368
|
+
* (Business Process Outsourcer) account plus the signed Letter of Authorization
|
|
369
|
+
* the Brand Owner granted it.
|
|
370
|
+
*/
|
|
371
|
+
export interface BpoAuthorizationInput {
|
|
372
|
+
/**
|
|
373
|
+
* Enterprise id of an approved BPO (Business Process Outsourcer) account on your
|
|
374
|
+
* organization to authorize for this DIR.
|
|
375
|
+
*/
|
|
376
|
+
bpo_enterprise_id: string;
|
|
377
|
+
|
|
378
|
+
/**
|
|
379
|
+
* Id of the signed Letter of Authorization document (uploaded via the Telnyx
|
|
380
|
+
* Documents API) in which the Brand Owner authorizes this BPO.
|
|
381
|
+
*/
|
|
382
|
+
loa_document_id: string;
|
|
383
|
+
}
|
|
384
|
+
|
|
296
385
|
export interface Dir {
|
|
297
386
|
id?: string;
|
|
298
387
|
|
|
@@ -310,6 +399,12 @@ export interface Dir {
|
|
|
310
399
|
|
|
311
400
|
created_at?: string;
|
|
312
401
|
|
|
402
|
+
/**
|
|
403
|
+
* When deletion was requested. Set once the DIR enters `delete_requested`; `null`
|
|
404
|
+
* otherwise.
|
|
405
|
+
*/
|
|
406
|
+
delete_requested_at?: string | null;
|
|
407
|
+
|
|
313
408
|
display_name?: string;
|
|
314
409
|
|
|
315
410
|
documents?: Array<Document> | null;
|
|
@@ -345,6 +440,10 @@ export interface Dir {
|
|
|
345
440
|
* - `infringement_claimed` - a trademark/impersonation claim is open against this
|
|
346
441
|
* DIR.
|
|
347
442
|
* - `permanently_rejected` - terminal; cannot be resubmitted.
|
|
443
|
+
* - `delete_requested` - you have requested deletion; the DIR still exists and
|
|
444
|
+
* Telnyx is completing the removal (de-registration and cleanup). A verified DIR
|
|
445
|
+
* keeps serving its branded identity, and keeps billing, until the removal
|
|
446
|
+
* finishes.
|
|
348
447
|
*/
|
|
349
448
|
status?: DirStatus;
|
|
350
449
|
|
|
@@ -353,6 +452,12 @@ export interface Dir {
|
|
|
353
452
|
updated_at?: string;
|
|
354
453
|
|
|
355
454
|
verified_at?: string | null;
|
|
455
|
+
|
|
456
|
+
/**
|
|
457
|
+
* `https://` URL that receives webhook notifications for this DIR's
|
|
458
|
+
* compliance-review outcomes. `null` when not subscribed.
|
|
459
|
+
*/
|
|
460
|
+
webhook_url?: string | null;
|
|
356
461
|
}
|
|
357
462
|
|
|
358
463
|
export namespace Dir {
|
|
@@ -390,6 +495,10 @@ export interface DirList {
|
|
|
390
495
|
* - `infringement_claimed` - a trademark/impersonation claim is open against this
|
|
391
496
|
* DIR.
|
|
392
497
|
* - `permanently_rejected` - terminal; cannot be resubmitted.
|
|
498
|
+
* - `delete_requested` - you have requested deletion; the DIR still exists and
|
|
499
|
+
* Telnyx is completing the removal (de-registration and cleanup). A verified DIR
|
|
500
|
+
* keeps serving its branded identity, and keeps billing, until the removal
|
|
501
|
+
* finishes.
|
|
393
502
|
*/
|
|
394
503
|
export type DirStatus =
|
|
395
504
|
| 'draft'
|
|
@@ -401,7 +510,8 @@ export type DirStatus =
|
|
|
401
510
|
| 'suspended'
|
|
402
511
|
| 'expired'
|
|
403
512
|
| 'infringement_claimed'
|
|
404
|
-
| 'permanently_rejected'
|
|
513
|
+
| 'permanently_rejected'
|
|
514
|
+
| 'delete_requested';
|
|
405
515
|
|
|
406
516
|
export interface DirWrapped {
|
|
407
517
|
data: Dir;
|
|
@@ -434,9 +544,43 @@ export interface Document {
|
|
|
434
544
|
| 'bank_statement'
|
|
435
545
|
| 'other';
|
|
436
546
|
|
|
547
|
+
/**
|
|
548
|
+
* An optional note describing this document, for example what it proves.
|
|
549
|
+
*/
|
|
437
550
|
description?: string;
|
|
438
551
|
}
|
|
439
552
|
|
|
553
|
+
export interface SignaturePayload {
|
|
554
|
+
/**
|
|
555
|
+
* PNG image, base64-encoded.
|
|
556
|
+
*/
|
|
557
|
+
image_base64: string;
|
|
558
|
+
|
|
559
|
+
/**
|
|
560
|
+
* Optional. When absent the rendered PDF falls back to the enterprise contact's
|
|
561
|
+
* legal name.
|
|
562
|
+
*/
|
|
563
|
+
signer_name?: string | null;
|
|
564
|
+
}
|
|
565
|
+
|
|
566
|
+
export interface DirDeleteResponse {
|
|
567
|
+
data: DirDeleteResponse.Data;
|
|
568
|
+
}
|
|
569
|
+
|
|
570
|
+
export namespace DirDeleteResponse {
|
|
571
|
+
export interface Data {
|
|
572
|
+
/**
|
|
573
|
+
* Id of the DIR whose deletion was requested.
|
|
574
|
+
*/
|
|
575
|
+
id: string;
|
|
576
|
+
|
|
577
|
+
/**
|
|
578
|
+
* Always `delete_requested`: the DIR has been queued for removal, not yet removed.
|
|
579
|
+
*/
|
|
580
|
+
status: 'delete_requested';
|
|
581
|
+
}
|
|
582
|
+
}
|
|
583
|
+
|
|
440
584
|
export interface DirListDocumentTypesResponse {
|
|
441
585
|
data: Array<DirListDocumentTypesResponse.Data>;
|
|
442
586
|
|
|
@@ -463,6 +607,58 @@ export namespace DirListDocumentTypesResponse {
|
|
|
463
607
|
}
|
|
464
608
|
}
|
|
465
609
|
|
|
610
|
+
/**
|
|
611
|
+
* Paginated list of a DIR's BPO authorizations.
|
|
612
|
+
*/
|
|
613
|
+
export interface DirRetrieveBpoAuthorizationsResponse {
|
|
614
|
+
data: Array<DirRetrieveBpoAuthorizationsResponse.Data>;
|
|
615
|
+
|
|
616
|
+
/**
|
|
617
|
+
* JSON:API pagination metadata returned with every paginated list response. Page
|
|
618
|
+
* numbering is 1-based. `page_size` reports the number of items actually returned
|
|
619
|
+
* in `data` for this page; the requested size is taken from the `page[size]` query
|
|
620
|
+
* parameter.
|
|
621
|
+
*/
|
|
622
|
+
meta: CallReasonsAPI.BrandedCallingPaginationMeta;
|
|
623
|
+
}
|
|
624
|
+
|
|
625
|
+
export namespace DirRetrieveBpoAuthorizationsResponse {
|
|
626
|
+
/**
|
|
627
|
+
* A single authorization of a BPO (Business Process Outsourcer) account on a DIR.
|
|
628
|
+
*/
|
|
629
|
+
export interface Data {
|
|
630
|
+
/**
|
|
631
|
+
* The authorized BPO account's enterprise id.
|
|
632
|
+
*/
|
|
633
|
+
bpo_enterprise_id: string;
|
|
634
|
+
|
|
635
|
+
/**
|
|
636
|
+
* Id of the signed Letter of Authorization document submitted for this BPO. Send
|
|
637
|
+
* it back unchanged in `bpo_authorizations` when updating the DIR to keep this
|
|
638
|
+
* authorization and its review state.
|
|
639
|
+
*/
|
|
640
|
+
loa_document_id: string;
|
|
641
|
+
|
|
642
|
+
/**
|
|
643
|
+
* Always `bpo_authorization`.
|
|
644
|
+
*/
|
|
645
|
+
record_type: 'bpo_authorization';
|
|
646
|
+
|
|
647
|
+
/**
|
|
648
|
+
* Review state of this authorization. `pending` on create or when the Letter of
|
|
649
|
+
* Authorization is re-uploaded; an admin moves it to `approved` or `rejected`.
|
|
650
|
+
* Only an `approved` authorization adds the BPO to this DIR's authorized callers
|
|
651
|
+
* in the branded calling registry.
|
|
652
|
+
*/
|
|
653
|
+
status: 'pending' | 'approved' | 'rejected';
|
|
654
|
+
|
|
655
|
+
/**
|
|
656
|
+
* Why the authorization was rejected. `null` unless `status` is `rejected`.
|
|
657
|
+
*/
|
|
658
|
+
rejection_reason?: string | null;
|
|
659
|
+
}
|
|
660
|
+
}
|
|
661
|
+
|
|
466
662
|
export interface DirListParams extends DefaultFlatPaginationParams {
|
|
467
663
|
/**
|
|
468
664
|
* Case-insensitive partial match on call reason.
|
|
@@ -523,6 +719,16 @@ export interface DirUpdateParams {
|
|
|
523
719
|
*/
|
|
524
720
|
authorizer_name?: string;
|
|
525
721
|
|
|
722
|
+
/**
|
|
723
|
+
* Optional. Replace this DIR's authorized BPO (Business Process Outsourcer)
|
|
724
|
+
* accounts with these, each with its signed Letter of Authorization. The supplied
|
|
725
|
+
* list replaces the current one: a BPO left out has its authorization removed, and
|
|
726
|
+
* a new BPO (or a changed Letter of Authorization) is created `pending` admin
|
|
727
|
+
* review. Send an empty list to clear all authorizations; omit the field to leave
|
|
728
|
+
* them unchanged. Editing this list does not re-vet the DIR. Maximum 10.
|
|
729
|
+
*/
|
|
730
|
+
bpo_authorizations?: Array<BpoAuthorizationInput>;
|
|
731
|
+
|
|
526
732
|
/**
|
|
527
733
|
* 1–10 reasons your business calls customers. Validate phrasing against
|
|
528
734
|
* `POST /call_reasons/validate`.
|
|
@@ -570,6 +776,13 @@ export interface DirUpdateParams {
|
|
|
570
776
|
* (BPO/reseller). Updating this triggers re-vetting on next submit.
|
|
571
777
|
*/
|
|
572
778
|
reselling?: boolean;
|
|
779
|
+
|
|
780
|
+
/**
|
|
781
|
+
* Optional `https://` URL that receives webhook notifications when this DIR's
|
|
782
|
+
* compliance review completes. Send `null` to clear. Changing only this field on a
|
|
783
|
+
* `verified` DIR does not re-vet it. Maximum 2048 characters.
|
|
784
|
+
*/
|
|
785
|
+
webhook_url?: string | null;
|
|
573
786
|
}
|
|
574
787
|
|
|
575
788
|
export interface DirListInfringementClaimsParams extends DefaultFlatPaginationParams {}
|
|
@@ -586,7 +799,8 @@ export interface DirUpdateInfringementParams {
|
|
|
586
799
|
certify_ip_ownership: true;
|
|
587
800
|
|
|
588
801
|
/**
|
|
589
|
-
*
|
|
802
|
+
* Check to certify that the brand no longer infringes anyone else's trademark or
|
|
803
|
+
* intellectual property.
|
|
590
804
|
*/
|
|
591
805
|
certify_no_infringement: true;
|
|
592
806
|
|
|
@@ -602,6 +816,10 @@ export interface DirUpdateInfringementParams {
|
|
|
602
816
|
|
|
603
817
|
call_reasons?: Array<string> | null;
|
|
604
818
|
|
|
819
|
+
/**
|
|
820
|
+
* The business name shown to call recipients, 1 to 35 characters, no emoji, not
|
|
821
|
+
* blank.
|
|
822
|
+
*/
|
|
605
823
|
display_name?: string | null;
|
|
606
824
|
|
|
607
825
|
/**
|
|
@@ -634,27 +852,34 @@ export interface DirNewLoaParams {
|
|
|
634
852
|
* name, and signed-at date. When absent the PDF is returned unsigned so the
|
|
635
853
|
* customer can sign externally and upload it via the Documents API.
|
|
636
854
|
*/
|
|
637
|
-
signature?:
|
|
855
|
+
signature?: SignaturePayload;
|
|
638
856
|
}
|
|
639
857
|
|
|
640
|
-
export
|
|
858
|
+
export interface DirRetrieveBpoAuthorizationsParams {
|
|
641
859
|
/**
|
|
642
|
-
*
|
|
643
|
-
* name, and signed-at date. When absent the PDF is returned unsigned so the
|
|
644
|
-
* customer can sign externally and upload it via the Documents API.
|
|
860
|
+
* 1-based page number. Out-of-range values return an empty page with correct meta.
|
|
645
861
|
*/
|
|
646
|
-
|
|
647
|
-
/**
|
|
648
|
-
* PNG image, base64-encoded.
|
|
649
|
-
*/
|
|
650
|
-
image_base64: string;
|
|
862
|
+
'page[number]'?: number;
|
|
651
863
|
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
864
|
+
/**
|
|
865
|
+
* Items per page. Maximum 250; values above are clamped to 250.
|
|
866
|
+
*/
|
|
867
|
+
'page[size]'?: number;
|
|
868
|
+
}
|
|
869
|
+
|
|
870
|
+
export interface DirBpoLoaParams {
|
|
871
|
+
/**
|
|
872
|
+
* The approved BPO enterprise the Brand Owner is authorizing. Must be a BPO
|
|
873
|
+
* account on the caller's organization that has already been approved.
|
|
874
|
+
*/
|
|
875
|
+
bpo_enterprise_id: string;
|
|
876
|
+
|
|
877
|
+
/**
|
|
878
|
+
* Optional. When provided the rendered PDF embeds the signature image, printed
|
|
879
|
+
* name, and signed-at date. When absent the PDF is returned unsigned so the Brand
|
|
880
|
+
* Owner can sign externally and the BPO can upload it via the Documents API.
|
|
881
|
+
*/
|
|
882
|
+
signature?: SignaturePayload;
|
|
658
883
|
}
|
|
659
884
|
|
|
660
885
|
DirResource.Comments = Comments;
|
|
@@ -665,18 +890,24 @@ DirResource.VerifyEmail = VerifyEmail;
|
|
|
665
890
|
|
|
666
891
|
export declare namespace DirResource {
|
|
667
892
|
export {
|
|
893
|
+
type BpoAuthorizationInput as BpoAuthorizationInput,
|
|
668
894
|
type Dir as Dir,
|
|
669
895
|
type DirList as DirList,
|
|
670
896
|
type DirStatus as DirStatus,
|
|
671
897
|
type DirWrapped as DirWrapped,
|
|
672
898
|
type Document as Document,
|
|
899
|
+
type SignaturePayload as SignaturePayload,
|
|
900
|
+
type DirDeleteResponse as DirDeleteResponse,
|
|
673
901
|
type DirListDocumentTypesResponse as DirListDocumentTypesResponse,
|
|
902
|
+
type DirRetrieveBpoAuthorizationsResponse as DirRetrieveBpoAuthorizationsResponse,
|
|
674
903
|
type DirsDefaultFlatPagination as DirsDefaultFlatPagination,
|
|
675
904
|
type DirListParams as DirListParams,
|
|
676
905
|
type DirUpdateParams as DirUpdateParams,
|
|
677
906
|
type DirListInfringementClaimsParams as DirListInfringementClaimsParams,
|
|
678
907
|
type DirUpdateInfringementParams as DirUpdateInfringementParams,
|
|
679
908
|
type DirNewLoaParams as DirNewLoaParams,
|
|
909
|
+
type DirRetrieveBpoAuthorizationsParams as DirRetrieveBpoAuthorizationsParams,
|
|
910
|
+
type DirBpoLoaParams as DirBpoLoaParams,
|
|
680
911
|
};
|
|
681
912
|
|
|
682
913
|
export {
|
|
@@ -11,17 +11,23 @@ export {
|
|
|
11
11
|
} from './comments';
|
|
12
12
|
export {
|
|
13
13
|
DirResource,
|
|
14
|
+
type BpoAuthorizationInput,
|
|
14
15
|
type Dir,
|
|
15
16
|
type DirList,
|
|
16
17
|
type DirStatus,
|
|
17
18
|
type DirWrapped,
|
|
18
19
|
type Document,
|
|
20
|
+
type SignaturePayload,
|
|
21
|
+
type DirDeleteResponse,
|
|
19
22
|
type DirListDocumentTypesResponse,
|
|
23
|
+
type DirRetrieveBpoAuthorizationsResponse,
|
|
20
24
|
type DirListParams,
|
|
21
25
|
type DirUpdateParams,
|
|
22
26
|
type DirListInfringementClaimsParams,
|
|
23
27
|
type DirUpdateInfringementParams,
|
|
24
28
|
type DirNewLoaParams,
|
|
29
|
+
type DirRetrieveBpoAuthorizationsParams,
|
|
30
|
+
type DirBpoLoaParams,
|
|
25
31
|
type DirsDefaultFlatPagination,
|
|
26
32
|
} from './dir';
|
|
27
33
|
export {
|
|
@@ -59,11 +59,11 @@ export class PhoneNumbers extends APIResource {
|
|
|
59
59
|
|
|
60
60
|
/**
|
|
61
61
|
* Register phone numbers under a DIR. The enterprise is resolved server-side from
|
|
62
|
-
* the DIR id.
|
|
63
|
-
* you use.
|
|
62
|
+
* the DIR id.
|
|
64
63
|
*
|
|
65
|
-
* **Pricing:**
|
|
66
|
-
*
|
|
64
|
+
* **Pricing:** Adding phone numbers is free. Branded Calling fees are charged per
|
|
65
|
+
* DIR and per branded call. See https://telnyx.com/pricing/branded-calling for
|
|
66
|
+
* current pricing.
|
|
67
67
|
*
|
|
68
68
|
* @example
|
|
69
69
|
* ```ts
|
|
@@ -225,6 +225,10 @@ export namespace PhoneNumberRemoveResponse {
|
|
|
225
225
|
}
|
|
226
226
|
|
|
227
227
|
export interface PhoneNumberRemoveParams {
|
|
228
|
+
/**
|
|
229
|
+
* The phone numbers to remove from this brand, in E.164 format, up to 100 per
|
|
230
|
+
* request. They must currently be attached to this brand.
|
|
231
|
+
*/
|
|
228
232
|
phone_numbers: Array<string>;
|
|
229
233
|
}
|
|
230
234
|
|
|
@@ -268,27 +268,29 @@ export interface ReferenceUpdateParams {
|
|
|
268
268
|
ref_type: 'business' | 'financial';
|
|
269
269
|
|
|
270
270
|
/**
|
|
271
|
-
* Body param:
|
|
271
|
+
* Body param: The reference's email address. We email them scheduling and dial-in
|
|
272
|
+
* instructions before we call, so use an address they check.
|
|
272
273
|
*/
|
|
273
274
|
email?: string;
|
|
274
275
|
|
|
275
276
|
/**
|
|
276
|
-
* Body param:
|
|
277
|
+
* Body param: The full name of the person we should contact as your reference.
|
|
277
278
|
*/
|
|
278
279
|
full_name?: string;
|
|
279
280
|
|
|
280
281
|
/**
|
|
281
|
-
* Body param:
|
|
282
|
+
* Body param: The reference contact's job title, for example CFO or Owner.
|
|
282
283
|
*/
|
|
283
284
|
job_title?: string | null;
|
|
284
285
|
|
|
285
286
|
/**
|
|
286
|
-
* Body param:
|
|
287
|
+
* Body param: The name of the organization the reference contact works for.
|
|
287
288
|
*/
|
|
288
289
|
organization?: string | null;
|
|
289
290
|
|
|
290
291
|
/**
|
|
291
|
-
* Body param:
|
|
292
|
+
* Body param: The reference's phone number in E.164 format, for example
|
|
293
|
+
* +14155550123. We call this number during their local business hours.
|
|
292
294
|
*/
|
|
293
295
|
phone_e164?: string;
|
|
294
296
|
|
|
@@ -298,7 +300,8 @@ export interface ReferenceUpdateParams {
|
|
|
298
300
|
relationship_to_registrant?: string | null;
|
|
299
301
|
|
|
300
302
|
/**
|
|
301
|
-
* Body param: IANA
|
|
303
|
+
* Body param: The reference's IANA time zone, for example America/New_York. We
|
|
304
|
+
* only call during their local 8am to 9pm hours, which is why we need it.
|
|
302
305
|
*/
|
|
303
306
|
timezone?: string;
|
|
304
307
|
}
|
|
@@ -176,7 +176,8 @@ export interface DirCreateParams {
|
|
|
176
176
|
call_reasons: Array<string>;
|
|
177
177
|
|
|
178
178
|
/**
|
|
179
|
-
* Must be `true
|
|
179
|
+
* Certification that the DIR information is accurate. Must be `true` for the DIR
|
|
180
|
+
* to be submitted for vetting.
|
|
180
181
|
*/
|
|
181
182
|
certify_brand_is_accurate: true;
|
|
182
183
|
|
|
@@ -196,6 +197,16 @@ export interface DirCreateParams {
|
|
|
196
197
|
*/
|
|
197
198
|
display_name: string;
|
|
198
199
|
|
|
200
|
+
/**
|
|
201
|
+
* Optional. Approved BPO (Business Process Outsourcer) accounts on your
|
|
202
|
+
* organization authorized to place branded calls for this DIR, each with the
|
|
203
|
+
* signed Letter of Authorization the Brand Owner granted it. Each authorization
|
|
204
|
+
* starts `pending` and takes effect only after an admin reviews its Letter of
|
|
205
|
+
* Authorization. Omit or send an empty list to authorize no BPO on this DIR.
|
|
206
|
+
* Maximum 10.
|
|
207
|
+
*/
|
|
208
|
+
bpo_authorizations?: Array<DirAPI.BpoAuthorizationInput>;
|
|
209
|
+
|
|
199
210
|
/**
|
|
200
211
|
* Supporting documents. Each `document_id` may appear at most once on a DIR.
|
|
201
212
|
*/
|
|
@@ -211,6 +222,13 @@ export interface DirCreateParams {
|
|
|
211
222
|
* (BPO/reseller).
|
|
212
223
|
*/
|
|
213
224
|
reselling?: boolean;
|
|
225
|
+
|
|
226
|
+
/**
|
|
227
|
+
* Optional `https://` URL that receives webhook notifications when this DIR's
|
|
228
|
+
* compliance review completes (rejection outcomes include structured rejection
|
|
229
|
+
* reasons). Maximum 2048 characters.
|
|
230
|
+
*/
|
|
231
|
+
webhook_url?: string | null;
|
|
214
232
|
}
|
|
215
233
|
|
|
216
234
|
export declare namespace Dir {
|