bandwidth-sdk 8.2.0 → 8.3.1

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.
Files changed (160) hide show
  1. package/.github/CODEOWNERS +0 -3
  2. package/.github/workflows/deploy.yml +1 -11
  3. package/api/media-api.ts +20 -20
  4. package/api/toll-free-verification-api.ts +12 -12
  5. package/bandwidth.yml +58 -15
  6. package/configuration.ts +1 -1
  7. package/coverage/clover.xml +32 -32
  8. package/coverage/coverage-final.json +7 -7
  9. package/coverage/lcov-report/index.html +1 -1
  10. package/coverage/lcov-report/node-sdk/api/calls-api.ts.html +1 -1
  11. package/coverage/lcov-report/node-sdk/api/conferences-api.ts.html +1 -1
  12. package/coverage/lcov-report/node-sdk/api/endpoints-api.ts.html +1 -1
  13. package/coverage/lcov-report/node-sdk/api/index.html +1 -1
  14. package/coverage/lcov-report/node-sdk/api/media-api.ts.html +21 -21
  15. package/coverage/lcov-report/node-sdk/api/messages-api.ts.html +1 -1
  16. package/coverage/lcov-report/node-sdk/api/mfaapi.ts.html +1 -1
  17. package/coverage/lcov-report/node-sdk/api/multi-channel-api.ts.html +1 -1
  18. package/coverage/lcov-report/node-sdk/api/phone-number-lookup-api.ts.html +1 -1
  19. package/coverage/lcov-report/node-sdk/api/recordings-api.ts.html +1 -1
  20. package/coverage/lcov-report/node-sdk/api/statistics-api.ts.html +1 -1
  21. package/coverage/lcov-report/node-sdk/api/toll-free-verification-api.ts.html +13 -13
  22. package/coverage/lcov-report/node-sdk/api/transcriptions-api.ts.html +1 -1
  23. package/coverage/lcov-report/node-sdk/api.ts.html +1 -1
  24. package/coverage/lcov-report/node-sdk/base.ts.html +1 -1
  25. package/coverage/lcov-report/node-sdk/common.ts.html +1 -1
  26. package/coverage/lcov-report/node-sdk/configuration.ts.html +2 -2
  27. package/coverage/lcov-report/node-sdk/index.html +1 -1
  28. package/coverage/lcov-report/node-sdk/models/business-entity-type-enum.ts.html +2 -2
  29. package/coverage/lcov-report/node-sdk/models/business-registration-type-enum.ts.html +2 -2
  30. package/coverage/lcov-report/node-sdk/models/bxml/Bxml.ts.html +1 -1
  31. package/coverage/lcov-report/node-sdk/models/bxml/NestableVerb.ts.html +1 -1
  32. package/coverage/lcov-report/node-sdk/models/bxml/Response.ts.html +1 -1
  33. package/coverage/lcov-report/node-sdk/models/bxml/Root.ts.html +1 -1
  34. package/coverage/lcov-report/node-sdk/models/bxml/Verb.ts.html +1 -1
  35. package/coverage/lcov-report/node-sdk/models/bxml/index.html +1 -1
  36. package/coverage/lcov-report/node-sdk/models/bxml/index.ts.html +1 -1
  37. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Bridge.ts.html +1 -1
  38. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Conference.ts.html +1 -1
  39. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Connect.ts.html +5 -2
  40. package/coverage/lcov-report/node-sdk/models/bxml/verbs/CustomParam.ts.html +1 -1
  41. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Endpoint.ts.html +1 -1
  42. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Forward.ts.html +8 -2
  43. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Gather.ts.html +26 -2
  44. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Hangup.ts.html +1 -1
  45. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Pause.ts.html +1 -1
  46. package/coverage/lcov-report/node-sdk/models/bxml/verbs/PauseRecording.ts.html +1 -1
  47. package/coverage/lcov-report/node-sdk/models/bxml/verbs/PhoneNumber.ts.html +1 -1
  48. package/coverage/lcov-report/node-sdk/models/bxml/verbs/PlayAudio.ts.html +1 -1
  49. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Record.ts.html +8 -2
  50. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Redirect.ts.html +1 -1
  51. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Refer.ts.html +1 -1
  52. package/coverage/lcov-report/node-sdk/models/bxml/verbs/ResumeRecording.ts.html +1 -1
  53. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Ring.ts.html +1 -1
  54. package/coverage/lcov-report/node-sdk/models/bxml/verbs/SendDtmf.ts.html +1 -1
  55. package/coverage/lcov-report/node-sdk/models/bxml/verbs/SipUri.ts.html +1 -1
  56. package/coverage/lcov-report/node-sdk/models/bxml/verbs/SpeakSentence.ts.html +1 -1
  57. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StartGather.ts.html +1 -1
  58. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StartRecording.ts.html +8 -2
  59. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StartStream.ts.html +1 -1
  60. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StartTranscription.ts.html +8 -2
  61. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StopGather.ts.html +1 -1
  62. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StopRecording.ts.html +1 -1
  63. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StopStream.ts.html +1 -1
  64. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StopTranscription.ts.html +1 -1
  65. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StreamParam.ts.html +1 -1
  66. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Tag.ts.html +1 -1
  67. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Transfer.ts.html +5 -2
  68. package/coverage/lcov-report/node-sdk/models/bxml/verbs/index.html +1 -1
  69. package/coverage/lcov-report/node-sdk/models/bxml/verbs/index.ts.html +1 -1
  70. package/coverage/lcov-report/node-sdk/models/call-direction-enum.ts.html +1 -1
  71. package/coverage/lcov-report/node-sdk/models/call-state-enum.ts.html +1 -1
  72. package/coverage/lcov-report/node-sdk/models/call-transcription-detected-language-enum.ts.html +1 -1
  73. package/coverage/lcov-report/node-sdk/models/call-transcription-track-enum.ts.html +1 -1
  74. package/coverage/lcov-report/node-sdk/models/callback-method-enum.ts.html +1 -1
  75. package/coverage/lcov-report/node-sdk/models/card-width-enum.ts.html +1 -1
  76. package/coverage/lcov-report/node-sdk/models/completed-lookup-status-enum.ts.html +1 -1
  77. package/coverage/lcov-report/node-sdk/models/conference-state-enum.ts.html +1 -1
  78. package/coverage/lcov-report/node-sdk/models/deactivation-event-enum.ts.html +1 -1
  79. package/coverage/lcov-report/node-sdk/models/device-status-enum.ts.html +1 -1
  80. package/coverage/lcov-report/node-sdk/models/endpoint-direction-enum.ts.html +1 -1
  81. package/coverage/lcov-report/node-sdk/models/endpoint-event-type-enum.ts.html +1 -1
  82. package/coverage/lcov-report/node-sdk/models/endpoint-status-enum.ts.html +1 -1
  83. package/coverage/lcov-report/node-sdk/models/endpoint-type-enum.ts.html +1 -1
  84. package/coverage/lcov-report/node-sdk/models/file-format-enum.ts.html +1 -1
  85. package/coverage/lcov-report/node-sdk/models/in-progress-lookup-status-enum.ts.html +1 -1
  86. package/coverage/lcov-report/node-sdk/models/inbound-callback-type-enum.ts.html +1 -1
  87. package/coverage/lcov-report/node-sdk/models/index.html +1 -1
  88. package/coverage/lcov-report/node-sdk/models/index.ts.html +1 -1
  89. package/coverage/lcov-report/node-sdk/models/latest-message-delivery-status-enum.ts.html +1 -1
  90. package/coverage/lcov-report/node-sdk/models/line-type-enum.ts.html +1 -1
  91. package/coverage/lcov-report/node-sdk/models/list-message-direction-enum.ts.html +1 -1
  92. package/coverage/lcov-report/node-sdk/models/machine-detection-mode-enum.ts.html +1 -1
  93. package/coverage/lcov-report/node-sdk/models/message-direction-enum.ts.html +1 -1
  94. package/coverage/lcov-report/node-sdk/models/message-status-enum.ts.html +1 -1
  95. package/coverage/lcov-report/node-sdk/models/message-type-enum.ts.html +1 -1
  96. package/coverage/lcov-report/node-sdk/models/multi-channel-message-channel-enum.ts.html +1 -1
  97. package/coverage/lcov-report/node-sdk/models/priority-enum.ts.html +1 -1
  98. package/coverage/lcov-report/node-sdk/models/product-type-enum.ts.html +1 -1
  99. package/coverage/lcov-report/node-sdk/models/rbm-action-type-enum.ts.html +1 -1
  100. package/coverage/lcov-report/node-sdk/models/rbm-media-height-enum.ts.html +1 -1
  101. package/coverage/lcov-report/node-sdk/models/rbm-open-url-enum.ts.html +1 -1
  102. package/coverage/lcov-report/node-sdk/models/rbm-web-view-enum.ts.html +1 -1
  103. package/coverage/lcov-report/node-sdk/models/recording-state-enum.ts.html +1 -1
  104. package/coverage/lcov-report/node-sdk/models/redirect-method-enum.ts.html +1 -1
  105. package/coverage/lcov-report/node-sdk/models/refer-call-status-enum.ts.html +1 -1
  106. package/coverage/lcov-report/node-sdk/models/standalone-card-orientation-enum.ts.html +1 -1
  107. package/coverage/lcov-report/node-sdk/models/status-callback-type-enum.ts.html +1 -1
  108. package/coverage/lcov-report/node-sdk/models/tfv-callback-status-enum.ts.html +1 -1
  109. package/coverage/lcov-report/node-sdk/models/tfv-status-enum.ts.html +1 -1
  110. package/coverage/lcov-report/node-sdk/models/thumbnail-alignment-enum.ts.html +1 -1
  111. package/coverage/lcov-report/node-sdk/models/webhook-subscription-type-enum.ts.html +1 -1
  112. package/coverage/lcov.info +63 -63
  113. package/dist/api/media-api.d.ts +20 -20
  114. package/dist/api/media-api.js +20 -20
  115. package/dist/api/toll-free-verification-api.d.ts +12 -12
  116. package/dist/api/toll-free-verification-api.js +12 -12
  117. package/dist/configuration.js +1 -1
  118. package/dist/models/business-entity-type-enum.d.ts +1 -1
  119. package/dist/models/business-entity-type-enum.js +1 -1
  120. package/dist/models/business-registration-type-enum.d.ts +1 -1
  121. package/dist/models/business-registration-type-enum.js +1 -1
  122. package/dist/models/bxml/verbs/Connect.d.ts +1 -0
  123. package/dist/models/bxml/verbs/Forward.d.ts +2 -0
  124. package/dist/models/bxml/verbs/Gather.d.ts +8 -0
  125. package/dist/models/bxml/verbs/Record.d.ts +2 -0
  126. package/dist/models/bxml/verbs/StartRecording.d.ts +2 -0
  127. package/dist/models/bxml/verbs/StartTranscription.d.ts +2 -0
  128. package/dist/models/bxml/verbs/Transfer.d.ts +1 -0
  129. package/dist/models/tfv-submission-info.d.ts +2 -2
  130. package/dist/models/verification-request.d.ts +2 -2
  131. package/dist/models/verification-update-request.d.ts +3 -3
  132. package/docs/BusinessEntityTypeEnum.md +1 -1
  133. package/docs/BusinessRegistrationTypeEnum.md +1 -1
  134. package/docs/MediaApi.md +9 -9
  135. package/docs/TfvSubmissionInfo.md +2 -2
  136. package/docs/TollFreeVerificationApi.md +6 -3
  137. package/docs/VerificationRequest.md +2 -2
  138. package/docs/VerificationUpdateRequest.md +3 -3
  139. package/generate.sh +6 -0
  140. package/models/business-entity-type-enum.ts +1 -1
  141. package/models/business-registration-type-enum.ts +1 -1
  142. package/models/bxml/verbs/Connect.ts +1 -0
  143. package/models/bxml/verbs/Forward.ts +2 -0
  144. package/models/bxml/verbs/Gather.ts +8 -0
  145. package/models/bxml/verbs/Record.ts +2 -0
  146. package/models/bxml/verbs/StartRecording.ts +2 -0
  147. package/models/bxml/verbs/StartTranscription.ts +2 -0
  148. package/models/bxml/verbs/Transfer.ts +1 -0
  149. package/models/tfv-submission-info.ts +2 -2
  150. package/models/verification-request.ts +2 -2
  151. package/models/verification-update-request.ts +3 -3
  152. package/package.json +1 -1
  153. package/tests/smoke/bxml.test.ts +24 -7
  154. package/tests/unit/models/bxml/verbs/Connect.test.ts +6 -5
  155. package/tests/unit/models/bxml/verbs/Forward.test.ts +4 -2
  156. package/tests/unit/models/bxml/verbs/Gather.test.ts +14 -6
  157. package/tests/unit/models/bxml/verbs/Record.test.ts +4 -2
  158. package/tests/unit/models/bxml/verbs/StartRecording.test.ts +4 -2
  159. package/tests/unit/models/bxml/verbs/StartTranscription.test.ts +8 -6
  160. package/tests/unit/models/bxml/verbs/Transfer.test.ts +7 -6
@@ -17,10 +17,10 @@ Name | Type | Description | Notes
17
17
  **privacyPolicyUrl** | **string** | The Toll-Free Verification request privacy policy URL. | [optional] [default to undefined]
18
18
  **termsAndConditionsUrl** | **string** | The Toll-Free Verification request terms and conditions policy URL. | [optional] [default to undefined]
19
19
  **businessDba** | **string** | The company \'Doing Business As\'. | [optional] [default to undefined]
20
- **businessRegistrationNumber** | **string** | Government-issued business identifying number. **Note: As of October 19th, 2026 this field will be required when `businessEntityType` is _not_ `SOLE_PROPRIETOR`. If this field is provided, `businessRegistrationType` and `businessRegistrationIssuingCountry` are also required.** | [optional] [default to undefined]
20
+ **businessRegistrationNumber** | **string** | Government-issued business identifying number. **As of October 19th, 2026 this field is required when `businessEntityType` is _not_ `SOLE_PROPRIETOR`. If this field is provided, `businessRegistrationType` and `businessRegistrationIssuingCountry` are also required.** | [optional] [default to undefined]
21
21
  **businessRegistrationType** | [**BusinessRegistrationTypeEnum**](BusinessRegistrationTypeEnum.md) | | [optional] [default to undefined]
22
- **businessEntityType** | [**BusinessEntityTypeEnum**](BusinessEntityTypeEnum.md) | | [optional] [default to undefined]
23
- **businessRegistrationIssuingCountry** | **string** | The country issuing the business registration in ISO-3166-1 alpha-3 format. Alpha-2 format is accepted by the API, but alpha-3 is highly encouraged. **Note: As of October 19th, 2026 this field will be required when `businessRegistrationNumber` is provided.** | Registration Type | Supported Countries | |----------------------|------------------------------------| | EIN | USA | | CBN | CAN | | NEQ | CAN | | PROVINCIAL_NUMBER | CAN | | CRN | GBR, HKG | | VAT | GBR, IRL, BRA, NLD | | ACN | AUS | | ABN | AUS | | BRN | HKG | | SIREN | FRA | | SIRET | FRA | | NZBN | NZL | | UST_IDNR | DEU | | CIF | ESP | | NIF | ESP | | CNPJ | BRA | | UID | CHE | | OTHER | Must Provide Country Code | | [optional] [default to undefined]
22
+ **businessEntityType** | [**BusinessEntityTypeEnum**](BusinessEntityTypeEnum.md) | | [default to undefined]
23
+ **businessRegistrationIssuingCountry** | **string** | The country issuing the business registration in ISO-3166-1 alpha-3 format. Alpha-2 format is accepted by the API, but alpha-3 is highly encouraged. **As of October 19th, 2026 this field is required when `businessRegistrationNumber` is provided.** | Registration Type | Supported Countries | |----------------------|------------------------------------| | EIN | USA | | CBN | CAN | | NEQ | CAN | | PROVINCIAL_NUMBER | CAN | | CRN | GBR, HKG | | VAT | GBR, IRL, BRA, NLD | | ACN | AUS | | ABN | AUS | | BRN | HKG | | SIREN | FRA | | SIRET | FRA | | NZBN | NZL | | UST_IDNR | DEU | | CIF | ESP | | NIF | ESP | | CNPJ | BRA | | UID | CHE | | OTHER | Must Provide Country Code | | [optional] [default to undefined]
24
24
  **helpMessageResponse** | **string** | A message that gets sent to users requesting help. | [optional] [default to undefined]
25
25
  **ageGatedContent** | **boolean** | Indicates whether the content is age-gated. | [optional] [default to undefined]
26
26
  **cvToken** | **string** | The token provided by Campaign Verify to validate your political use case. Only required for 527 political organizations. If you are not a 527 political organization, this field should be omitted. Supplying an empty string will likely result in rejection. | [optional] [default to undefined]
package/generate.sh ADDED
@@ -0,0 +1,6 @@
1
+ #!/bin/bash
2
+ set -euo pipefail
3
+ cd "$(dirname "${BASH_SOURCE[0]}")"
4
+
5
+ npx --yes @openapitools/openapi-generator-cli generate \
6
+ -i bandwidth.yml -g typescript-axios -c openapi-config.yml -o . "$@"
@@ -15,7 +15,7 @@
15
15
 
16
16
 
17
17
  /**
18
- * The type of registered business. **Note: As of October 19th, 2026 submissions using a value other than `SOLE_PROPRIETOR` must provide a value for `businessRegistrationNumber`, `businessRegistrationType`, and `businessRegistrationIssuingCountry`. Submissions using `SOLE_PROPRIETOR` must _omit_ `businessRegistrationNumber`, `businessRegistrationType`, and `businessRegistrationIssuingCountry`. Failure to adhere to these constraints will result in a 400 Bad Request rejection.**
18
+ * The type of registered business. **As of October 19th, 2026 submissions using a value other than `SOLE_PROPRIETOR` must provide a value for `businessRegistrationNumber`, `businessRegistrationType`, and `businessRegistrationIssuingCountry`. Submissions using `SOLE_PROPRIETOR` must _omit_ `businessRegistrationNumber`, `businessRegistrationType`, and `businessRegistrationIssuingCountry`. Failure to adhere to these constraints will result in a 400 Bad Request rejection.**
19
19
  */
20
20
 
21
21
  export const BusinessEntityTypeEnum = {
@@ -15,7 +15,7 @@
15
15
 
16
16
 
17
17
  /**
18
- * The type of business registration number. **Note: As of October 19th, 2026 this field will be required when `businessRegistrationNumber` is provided.**
18
+ * The type of business registration number. **As of October 19th, 2026 this field is required when `businessRegistrationNumber` is provided.**
19
19
  */
20
20
 
21
21
  export const BusinessRegistrationTypeEnum = {
@@ -3,6 +3,7 @@ import { Endpoint } from './Endpoint';
3
3
 
4
4
  export interface ConnectAttributes {
5
5
  eventCallbackUrl?: string;
6
+ eventFallbackUrl?: string;
6
7
  }
7
8
 
8
9
  /**
@@ -7,6 +7,8 @@ export interface ForwardAttributes {
7
7
  diversionTreatment?: string;
8
8
  diversionReason?: string;
9
9
  uui?: string;
10
+ privacy?: boolean;
11
+ callerDisplayName?: string;
10
12
  }
11
13
 
12
14
  /**
@@ -21,6 +21,14 @@ export interface GatherAttributes {
21
21
  interDigitTimeout?: number;
22
22
  firstDigitTimeout?: number;
23
23
  repeatCount?: number;
24
+ input?: string;
25
+ hints?: string;
26
+ language?: string;
27
+ partialResultCallback?: string;
28
+ partialResultCallbackMethod?: string;
29
+ profanityFilter?: boolean;
30
+ speechModel?: string;
31
+ speechTimeout?: number;
24
32
  }
25
33
 
26
34
  /**
@@ -19,6 +19,8 @@ export interface RecordAttributes {
19
19
  maxDuration?: number;
20
20
  silenceTimeout?: number;
21
21
  fileFormat?: string;
22
+ detectLanguage?: boolean;
23
+ recordingName?: string;
22
24
  }
23
25
 
24
26
  /**
@@ -11,6 +11,8 @@ export interface StartRecordingAttributes {
11
11
  tag?: string;
12
12
  fileFormat?: string;
13
13
  multiChannel?: boolean;
14
+ detectLanguage?: boolean;
15
+ recordingName?: string;
14
16
  }
15
17
 
16
18
  /**
@@ -10,6 +10,8 @@ export interface StartTranscriptionAttributes {
10
10
  password?: string
11
11
  destination?: string;
12
12
  stabilized?: boolean;
13
+ detectLanguage?: boolean;
14
+ preferredLanguages?: string;
13
15
  }
14
16
 
15
17
  /**
@@ -19,6 +19,7 @@ export interface TransferAttributes {
19
19
  tag?: string;
20
20
  diversionTreatment?: string;
21
21
  diversionReason?: string;
22
+ privacy?: boolean;
22
23
  }
23
24
 
24
25
  /**
@@ -70,12 +70,12 @@ export interface TfvSubmissionInfo {
70
70
  */
71
71
  'businessDba'?: string;
72
72
  /**
73
- * Government-issued business identifying number. **Note: As of October 19th, 2026 this field will be required when `businessEntityType` is _not_ `SOLE_PROPRIETOR`. If this field is provided, `businessRegistrationType` and `businessRegistrationIssuingCountry` are also required.**
73
+ * Government-issued business identifying number. **As of October 19th, 2026 this field is required when `businessEntityType` is _not_ `SOLE_PROPRIETOR`. If this field is provided, `businessRegistrationType` and `businessRegistrationIssuingCountry` are also required.**
74
74
  */
75
75
  'businessRegistrationNumber'?: string | null;
76
76
  'businessRegistrationType'?: BusinessRegistrationTypeEnum | null;
77
77
  /**
78
- * The country issuing the business registration in ISO-3166-1 alpha-3 format. Alpha-2 format is accepted by the API, but alpha-3 is highly encouraged. **Note: As of October 19th, 2026 this field will be required when `businessRegistrationNumber` is provided.** | Registration Type | Supported Countries | |----------------------|------------------------------------| | EIN | USA | | CBN | CAN | | NEQ | CAN | | PROVINCIAL_NUMBER | CAN | | CRN | GBR, HKG | | VAT | GBR, IRL, BRA, NLD | | ACN | AUS | | ABN | AUS | | BRN | HKG | | SIREN | FRA | | SIRET | FRA | | NZBN | NZL | | UST_IDNR | DEU | | CIF | ESP | | NIF | ESP | | CNPJ | BRA | | UID | CHE | | OTHER | Must Provide Country Code |
78
+ * The country issuing the business registration in ISO-3166-1 alpha-3 format. Alpha-2 format is accepted by the API, but alpha-3 is highly encouraged. **As of October 19th, 2026 this field is required when `businessRegistrationNumber` is provided.** | Registration Type | Supported Countries | |----------------------|------------------------------------| | EIN | USA | | CBN | CAN | | NEQ | CAN | | PROVINCIAL_NUMBER | CAN | | CRN | GBR, HKG | | VAT | GBR, IRL, BRA, NLD | | ACN | AUS | | ABN | AUS | | BRN | HKG | | SIREN | FRA | | SIRET | FRA | | NZBN | NZL | | UST_IDNR | DEU | | CIF | ESP | | NIF | ESP | | CNPJ | BRA | | UID | CHE | | OTHER | Must Provide Country Code |
79
79
  */
80
80
  'businessRegistrationIssuingCountry'?: string | null;
81
81
  'businessEntityType'?: BusinessEntityTypeEnum;
@@ -71,12 +71,12 @@ export interface VerificationRequest {
71
71
  */
72
72
  'businessDba'?: string;
73
73
  /**
74
- * Government-issued business identifying number. **Note: As of October 19th, 2026 this field will be required when `businessEntityType` is _not_ `SOLE_PROPRIETOR`. If this field is provided, `businessRegistrationType` and `businessRegistrationIssuingCountry` are also required.**
74
+ * Government-issued business identifying number. **As of October 19th, 2026 this field is required when `businessEntityType` is _not_ `SOLE_PROPRIETOR`. If this field is provided, `businessRegistrationType` and `businessRegistrationIssuingCountry` are also required.**
75
75
  */
76
76
  'businessRegistrationNumber'?: string | null;
77
77
  'businessRegistrationType'?: BusinessRegistrationTypeEnum | null;
78
78
  /**
79
- * The country issuing the business registration in ISO-3166-1 alpha-3 format. Alpha-2 format is accepted by the API, but alpha-3 is highly encouraged. **Note: As of October 19th, 2026 this field will be required when `businessRegistrationNumber` is provided.** | Registration Type | Supported Countries | |----------------------|------------------------------------| | EIN | USA | | CBN | CAN | | NEQ | CAN | | PROVINCIAL_NUMBER | CAN | | CRN | GBR, HKG | | VAT | GBR, IRL, BRA, NLD | | ACN | AUS | | ABN | AUS | | BRN | HKG | | SIREN | FRA | | SIRET | FRA | | NZBN | NZL | | UST_IDNR | DEU | | CIF | ESP | | NIF | ESP | | CNPJ | BRA | | UID | CHE | | OTHER | Must Provide Country Code |
79
+ * The country issuing the business registration in ISO-3166-1 alpha-3 format. Alpha-2 format is accepted by the API, but alpha-3 is highly encouraged. **As of October 19th, 2026 this field is required when `businessRegistrationNumber` is provided.** | Registration Type | Supported Countries | |----------------------|------------------------------------| | EIN | USA | | CBN | CAN | | NEQ | CAN | | PROVINCIAL_NUMBER | CAN | | CRN | GBR, HKG | | VAT | GBR, IRL, BRA, NLD | | ACN | AUS | | ABN | AUS | | BRN | HKG | | SIREN | FRA | | SIRET | FRA | | NZBN | NZL | | UST_IDNR | DEU | | CIF | ESP | | NIF | ESP | | CNPJ | BRA | | UID | CHE | | OTHER | Must Provide Country Code |
80
80
  */
81
81
  'businessRegistrationIssuingCountry'?: string | null;
82
82
  'businessEntityType': BusinessEntityTypeEnum;
@@ -70,13 +70,13 @@ export interface VerificationUpdateRequest {
70
70
  */
71
71
  'businessDba'?: string;
72
72
  /**
73
- * Government-issued business identifying number. **Note: As of October 19th, 2026 this field will be required when `businessEntityType` is _not_ `SOLE_PROPRIETOR`. If this field is provided, `businessRegistrationType` and `businessRegistrationIssuingCountry` are also required.**
73
+ * Government-issued business identifying number. **As of October 19th, 2026 this field is required when `businessEntityType` is _not_ `SOLE_PROPRIETOR`. If this field is provided, `businessRegistrationType` and `businessRegistrationIssuingCountry` are also required.**
74
74
  */
75
75
  'businessRegistrationNumber'?: string | null;
76
76
  'businessRegistrationType'?: BusinessRegistrationTypeEnum | null;
77
- 'businessEntityType'?: BusinessEntityTypeEnum;
77
+ 'businessEntityType': BusinessEntityTypeEnum;
78
78
  /**
79
- * The country issuing the business registration in ISO-3166-1 alpha-3 format. Alpha-2 format is accepted by the API, but alpha-3 is highly encouraged. **Note: As of October 19th, 2026 this field will be required when `businessRegistrationNumber` is provided.** | Registration Type | Supported Countries | |----------------------|------------------------------------| | EIN | USA | | CBN | CAN | | NEQ | CAN | | PROVINCIAL_NUMBER | CAN | | CRN | GBR, HKG | | VAT | GBR, IRL, BRA, NLD | | ACN | AUS | | ABN | AUS | | BRN | HKG | | SIREN | FRA | | SIRET | FRA | | NZBN | NZL | | UST_IDNR | DEU | | CIF | ESP | | NIF | ESP | | CNPJ | BRA | | UID | CHE | | OTHER | Must Provide Country Code |
79
+ * The country issuing the business registration in ISO-3166-1 alpha-3 format. Alpha-2 format is accepted by the API, but alpha-3 is highly encouraged. **As of October 19th, 2026 this field is required when `businessRegistrationNumber` is provided.** | Registration Type | Supported Countries | |----------------------|------------------------------------| | EIN | USA | | CBN | CAN | | NEQ | CAN | | PROVINCIAL_NUMBER | CAN | | CRN | GBR, HKG | | VAT | GBR, IRL, BRA, NLD | | ACN | AUS | | ABN | AUS | | BRN | HKG | | SIREN | FRA | | SIRET | FRA | | NZBN | NZL | | UST_IDNR | DEU | | CIF | ESP | | NIF | ESP | | CNPJ | BRA | | UID | CHE | | OTHER | Must Provide Country Code |
80
80
  */
81
81
  'businessRegistrationIssuingCountry'?: string | null;
82
82
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bandwidth-sdk",
3
- "version": "8.2.0",
3
+ "version": "8.3.1",
4
4
  "description": "OpenAPI client for bandwidth-sdk",
5
5
  "author": "OpenAPI-Generator Contributors",
6
6
  "repository": {
@@ -72,7 +72,15 @@ describe('BXML Integration Tests', () => {
72
72
  maxDigits: 1,
73
73
  interDigitTimeout: 1.1,
74
74
  firstDigitTimeout: 1.1,
75
- repeatCount: 1
75
+ repeatCount: 1,
76
+ input: 'dtmf_speech',
77
+ hints: 'yes, no',
78
+ language: 'en-US',
79
+ partialResultCallback: 'https://initial.com',
80
+ partialResultCallbackMethod: 'POST',
81
+ profanityFilter: true,
82
+ speechModel: 'default',
83
+ speechTimeout: 2
76
84
  };
77
85
 
78
86
  const speakSentenceAttributes: SpeakSentenceAttributes = {
@@ -99,7 +107,9 @@ describe('BXML Integration Tests', () => {
99
107
  terminatingDigits: '#',
100
108
  maxDuration: 2,
101
109
  silenceTimeout: 2,
102
- fileFormat: 'wav'
110
+ fileFormat: 'wav',
111
+ detectLanguage: true,
112
+ recordingName: 'initialRecordingName'
103
113
  };
104
114
 
105
115
  const sendDtmfAttributes: SendDtmfAttributes = {
@@ -130,7 +140,7 @@ describe('BXML Integration Tests', () => {
130
140
 
131
141
  const transferAttributes: TransferAttributes = {
132
142
  transferCallerId: '+19195551234',
133
- transferCallerDisplayName: 'initialDisplayName',
143
+ transferCallerDisplayName: 'Anonymous',
134
144
  callTimeout: 5,
135
145
  transferCompleteUrl: 'https://initial.com',
136
146
  transferCompleteMethod: 'POST',
@@ -142,7 +152,8 @@ describe('BXML Integration Tests', () => {
142
152
  fallbackPassword: 'initialFallbackPassword',
143
153
  tag: 'initialTag',
144
154
  diversionTreatment: 'propagate',
145
- diversionReason: 'user-busy'
155
+ diversionReason: 'user-busy',
156
+ privacy: true
146
157
  };
147
158
 
148
159
  const phoneNumber = new Bxml.PhoneNumber('+19195551234');
@@ -197,7 +208,9 @@ describe('BXML Integration Tests', () => {
197
208
  password: 'initialPassword',
198
209
  tag: 'initialTag',
199
210
  fileFormat: 'wav',
200
- multiChannel: true
211
+ multiChannel: true,
212
+ detectLanguage: true,
213
+ recordingName: 'initialRecordingName'
201
214
  };
202
215
 
203
216
  const startStreamAttributes: StartStreamAttributes = {
@@ -218,7 +231,9 @@ describe('BXML Integration Tests', () => {
218
231
  username: 'initialUsername',
219
232
  password: 'initialPassword',
220
233
  destination: 'wss://initial.com',
221
- stabilized: true
234
+ stabilized: true,
235
+ detectLanguage: false,
236
+ preferredLanguages: 'en-US,fr-FR'
222
237
  };
223
238
 
224
239
  const stopStreamAttributes: StopStreamAttributes = {
@@ -267,7 +282,9 @@ describe('BXML Integration Tests', () => {
267
282
  callTimeout: 5,
268
283
  diversionTreatment: 'propagate',
269
284
  diversionReason: 'user-busy',
270
- uui: '93d6f3c0be5845960b744fa28015d8ede84bd1a4;encoding=base64,asdf;encoding=jwt'
285
+ uui: '93d6f3c0be5845960b744fa28015d8ede84bd1a4;encoding=base64,asdf;encoding=jwt',
286
+ privacy: true,
287
+ callerDisplayName: 'Anonymous'
271
288
  };
272
289
 
273
290
  const forward = new Bxml.Forward(forwardAttributes);
@@ -4,14 +4,15 @@ import { Endpoint } from '../../../../../models/bxml/verbs/Endpoint';
4
4
 
5
5
  describe('Connect', () => {
6
6
  const attributes: ConnectAttributes = {
7
- eventCallbackUrl: 'https://example.com/events'
7
+ eventCallbackUrl: 'https://example.com/events',
8
+ eventFallbackUrl: 'https://example.com/fallback'
8
9
  };
9
10
 
10
11
  const endpoint = new Endpoint('ep-123456');
11
12
 
12
13
  test('should create a Connect Verb', () => {
13
14
  const connect = new Connect(attributes);
14
- const expected = '<Connect eventCallbackUrl="https://example.com/events"/>';
15
+ const expected = '<Connect eventCallbackUrl="https://example.com/events" eventFallbackUrl="https://example.com/fallback"/>';
15
16
 
16
17
  expect(connect).toBeInstanceOf(Connect);
17
18
  expect(connect).toBeInstanceOf(Verb);
@@ -20,7 +21,7 @@ describe('Connect', () => {
20
21
 
21
22
  test('should create a Connect Verb with nested Endpoint', () => {
22
23
  const connect = new Connect(attributes, endpoint);
23
- const expected = '<Connect eventCallbackUrl="https://example.com/events"><Endpoint>ep-123456</Endpoint></Connect>';
24
+ const expected = '<Connect eventCallbackUrl="https://example.com/events" eventFallbackUrl="https://example.com/fallback"><Endpoint>ep-123456</Endpoint></Connect>';
24
25
 
25
26
  expect(connect).toBeInstanceOf(Connect);
26
27
  expect(connect).toBeInstanceOf(Verb);
@@ -30,7 +31,7 @@ describe('Connect', () => {
30
31
  test('should create a Connect Verb with multiple nested Endpoints', () => {
31
32
  const endpoint2 = new Endpoint('ep-789012');
32
33
  const connect = new Connect(attributes, [endpoint, endpoint2]);
33
- const expected = '<Connect eventCallbackUrl="https://example.com/events"><Endpoint>ep-123456</Endpoint><Endpoint>ep-789012</Endpoint></Connect>';
34
+ const expected = '<Connect eventCallbackUrl="https://example.com/events" eventFallbackUrl="https://example.com/fallback"><Endpoint>ep-123456</Endpoint><Endpoint>ep-789012</Endpoint></Connect>';
34
35
 
35
36
  expect(connect).toBeInstanceOf(Connect);
36
37
  expect(connect).toBeInstanceOf(Verb);
@@ -39,7 +40,7 @@ describe('Connect', () => {
39
40
 
40
41
  test('should test the addEndpoints method when no verbs are initially nested', () => {
41
42
  const connect = new Connect(attributes);
42
- const expected = '<Connect eventCallbackUrl="https://example.com/events"><Endpoint>ep-123456</Endpoint></Connect>';
43
+ const expected = '<Connect eventCallbackUrl="https://example.com/events" eventFallbackUrl="https://example.com/fallback"><Endpoint>ep-123456</Endpoint></Connect>';
43
44
 
44
45
  connect.addEndpoints(endpoint);
45
46
  expect(connect.toBxml()).toBe(expected);
@@ -8,10 +8,12 @@ describe('Forward', () => {
8
8
  callTimeout: 5,
9
9
  diversionTreatment: 'propagate',
10
10
  diversionReason: 'user-busy',
11
- uui: '93d6f3c0be5845960b744fa28015d8ede84bd1a4;encoding=base64,asdf;encoding=jwt'
11
+ uui: '93d6f3c0be5845960b744fa28015d8ede84bd1a4;encoding=base64,asdf;encoding=jwt',
12
+ privacy: true,
13
+ callerDisplayName: 'Anonymous'
12
14
  };
13
15
 
14
- const expected = '<Forward to="+19195551234" from="+19195554321" callTimeout="5" diversionTreatment="propagate" diversionReason="user-busy" uui="93d6f3c0be5845960b744fa28015d8ede84bd1a4;encoding=base64,asdf;encoding=jwt"/>';
16
+ const expected = '<Forward to="+19195551234" from="+19195554321" callTimeout="5" diversionTreatment="propagate" diversionReason="user-busy" uui="93d6f3c0be5845960b744fa28015d8ede84bd1a4;encoding=base64,asdf;encoding=jwt" privacy="true" callerDisplayName="Anonymous"/>';
15
17
 
16
18
  test('should create a Forward Verb', () => {
17
19
  const forward = new Forward(attributes);
@@ -18,7 +18,15 @@ describe('Gather', () => {
18
18
  maxDigits: 5,
19
19
  interDigitTimeout: 5,
20
20
  firstDigitTimeout: 5,
21
- repeatCount: 5
21
+ repeatCount: 5,
22
+ input: 'dtmf_speech',
23
+ hints: 'yes,no',
24
+ language: 'en-US',
25
+ partialResultCallback: 'https://initial.com',
26
+ partialResultCallbackMethod: 'POST',
27
+ profanityFilter: true,
28
+ speechModel: 'default',
29
+ speechTimeout: 5
22
30
  };
23
31
 
24
32
  const playAudio = new PlayAudio('https://audio.url/audio1.wav');
@@ -26,7 +34,7 @@ describe('Gather', () => {
26
34
 
27
35
  test('should create a Gather Verb', () => {
28
36
  const gather = new Gather(attributes);
29
- const expected = '<Gather gatherUrl="https://initial.com" gatherMethod="POST" gatherFallbackUrl="https://initial.com" gatherFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" terminatingDigits="5" maxDigits="5" interDigitTimeout="5" firstDigitTimeout="5" repeatCount="5"/>';
37
+ const expected = '<Gather gatherUrl="https://initial.com" gatherMethod="POST" gatherFallbackUrl="https://initial.com" gatherFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" terminatingDigits="5" maxDigits="5" interDigitTimeout="5" firstDigitTimeout="5" repeatCount="5" input="dtmf_speech" hints="yes,no" language="en-US" partialResultCallback="https://initial.com" partialResultCallbackMethod="POST" profanityFilter="true" speechModel="default" speechTimeout="5"/>';
30
38
 
31
39
  expect(gather).toBeInstanceOf(Gather);
32
40
  expect(gather).toBeInstanceOf(Verb);
@@ -35,9 +43,9 @@ describe('Gather', () => {
35
43
 
36
44
  test('should create a Gather Verb with nested PlayAudio and SpeakSentence', () => {
37
45
  let gather = new Gather(attributes, playAudio);
38
- const expected = '<Gather gatherUrl="https://initial.com" gatherMethod="POST" gatherFallbackUrl="https://initial.com" gatherFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" terminatingDigits="5" maxDigits="5" interDigitTimeout="5" firstDigitTimeout="5" repeatCount="5"><PlayAudio>https://audio.url/audio1.wav</PlayAudio></Gather>';
39
- const expectedSingle = '<Gather gatherUrl="https://initial.com" gatherMethod="POST" gatherFallbackUrl="https://initial.com" gatherFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" terminatingDigits="5" maxDigits="5" interDigitTimeout="5" firstDigitTimeout="5" repeatCount="5"><PlayAudio>https://audio.url/audio1.wav</PlayAudio><SpeakSentence><lang xml:lang="es-MX">Hola</lang>nodejs speak sentence <emphasis>SSML test</emphasis></SpeakSentence></Gather>';
40
- const expectedMultiple = '<Gather gatherUrl="https://initial.com" gatherMethod="POST" gatherFallbackUrl="https://initial.com" gatherFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" terminatingDigits="5" maxDigits="5" interDigitTimeout="5" firstDigitTimeout="5" repeatCount="5"><PlayAudio>https://audio.url/audio1.wav</PlayAudio><SpeakSentence><lang xml:lang="es-MX">Hola</lang>nodejs speak sentence <emphasis>SSML test</emphasis></SpeakSentence><SpeakSentence><lang xml:lang="es-MX">Hola</lang>nodejs speak sentence <emphasis>SSML test</emphasis></SpeakSentence><PlayAudio>https://audio.url/audio1.wav</PlayAudio></Gather>';
46
+ const expected = '<Gather gatherUrl="https://initial.com" gatherMethod="POST" gatherFallbackUrl="https://initial.com" gatherFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" terminatingDigits="5" maxDigits="5" interDigitTimeout="5" firstDigitTimeout="5" repeatCount="5" input="dtmf_speech" hints="yes,no" language="en-US" partialResultCallback="https://initial.com" partialResultCallbackMethod="POST" profanityFilter="true" speechModel="default" speechTimeout="5"><PlayAudio>https://audio.url/audio1.wav</PlayAudio></Gather>';
47
+ const expectedSingle = '<Gather gatherUrl="https://initial.com" gatherMethod="POST" gatherFallbackUrl="https://initial.com" gatherFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" terminatingDigits="5" maxDigits="5" interDigitTimeout="5" firstDigitTimeout="5" repeatCount="5" input="dtmf_speech" hints="yes,no" language="en-US" partialResultCallback="https://initial.com" partialResultCallbackMethod="POST" profanityFilter="true" speechModel="default" speechTimeout="5"><PlayAudio>https://audio.url/audio1.wav</PlayAudio><SpeakSentence><lang xml:lang="es-MX">Hola</lang>nodejs speak sentence <emphasis>SSML test</emphasis></SpeakSentence></Gather>';
48
+ const expectedMultiple = '<Gather gatherUrl="https://initial.com" gatherMethod="POST" gatherFallbackUrl="https://initial.com" gatherFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" terminatingDigits="5" maxDigits="5" interDigitTimeout="5" firstDigitTimeout="5" repeatCount="5" input="dtmf_speech" hints="yes,no" language="en-US" partialResultCallback="https://initial.com" partialResultCallbackMethod="POST" profanityFilter="true" speechModel="default" speechTimeout="5"><PlayAudio>https://audio.url/audio1.wav</PlayAudio><SpeakSentence><lang xml:lang="es-MX">Hola</lang>nodejs speak sentence <emphasis>SSML test</emphasis></SpeakSentence><SpeakSentence><lang xml:lang="es-MX">Hola</lang>nodejs speak sentence <emphasis>SSML test</emphasis></SpeakSentence><PlayAudio>https://audio.url/audio1.wav</PlayAudio></Gather>';
41
49
 
42
50
  expect(gather).toBeInstanceOf(Gather);
43
51
  expect(gather).toBeInstanceOf(Verb);
@@ -52,7 +60,7 @@ describe('Gather', () => {
52
60
 
53
61
  test('should test the addAudioVerbs method when no verbs are initially nested', () => {
54
62
  const gather = new Gather(attributes);
55
- const expected = '<Gather gatherUrl="https://initial.com" gatherMethod="POST" gatherFallbackUrl="https://initial.com" gatherFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" terminatingDigits="5" maxDigits="5" interDigitTimeout="5" firstDigitTimeout="5" repeatCount="5"><PlayAudio>https://audio.url/audio1.wav</PlayAudio></Gather>';
63
+ const expected = '<Gather gatherUrl="https://initial.com" gatherMethod="POST" gatherFallbackUrl="https://initial.com" gatherFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" terminatingDigits="5" maxDigits="5" interDigitTimeout="5" firstDigitTimeout="5" repeatCount="5" input="dtmf_speech" hints="yes,no" language="en-US" partialResultCallback="https://initial.com" partialResultCallbackMethod="POST" profanityFilter="true" speechModel="default" speechTimeout="5"><PlayAudio>https://audio.url/audio1.wav</PlayAudio></Gather>';
56
64
 
57
65
  gather.addAudioVerbs(playAudio);
58
66
  expect(gather.toBxml()).toBe(expected);
@@ -20,10 +20,12 @@ describe('Record', () => {
20
20
  terminatingDigits: '5',
21
21
  maxDuration: 5,
22
22
  silenceTimeout: 5,
23
- fileFormat: 'wav'
23
+ fileFormat: 'wav',
24
+ detectLanguage: true,
25
+ recordingName: 'initialRecordingName'
24
26
  };
25
27
 
26
- const expected = '<Record recordCompleteUrl="https://initial.com" recordCompleteMethod="POST" recordCompleteFallbackUrl="https://initial.com" recordCompleteFallbackMethod="POST" recordingAvailableUrl="https://initial.com" recordingAvailableMethod="POST" transcribe="true" transcriptionAvailableUrl="https://initial.com" transcriptionAvailableMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" terminatingDigits="5" maxDuration="5" silenceTimeout="5" fileFormat="wav"/>';
28
+ const expected = '<Record recordCompleteUrl="https://initial.com" recordCompleteMethod="POST" recordCompleteFallbackUrl="https://initial.com" recordCompleteFallbackMethod="POST" recordingAvailableUrl="https://initial.com" recordingAvailableMethod="POST" transcribe="true" transcriptionAvailableUrl="https://initial.com" transcriptionAvailableMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" terminatingDigits="5" maxDuration="5" silenceTimeout="5" fileFormat="wav" detectLanguage="true" recordingName="initialRecordingName"/>';
27
29
 
28
30
  test('should create a Record Verb', () => {
29
31
  const record = new Record(attributes);
@@ -12,10 +12,12 @@ describe('StartRecording', () => {
12
12
  password: 'initialPassword',
13
13
  tag: 'initialTag',
14
14
  fileFormat: 'wav',
15
- multiChannel: true
15
+ multiChannel: true,
16
+ detectLanguage: true,
17
+ recordingName: 'initialRecordingName'
16
18
  };
17
19
 
18
- const expected = '<StartRecording recordingAvailableUrl="https://initial.com" recordingAvailableMethod="POST" transcribe="true" transcriptionAvailableUrl="https://initial.com" transcriptionAvailableMethod="POST" username="initialUsername" password="initialPassword" tag="initialTag" fileFormat="wav" multiChannel="true"/>';
20
+ const expected = '<StartRecording recordingAvailableUrl="https://initial.com" recordingAvailableMethod="POST" transcribe="true" transcriptionAvailableUrl="https://initial.com" transcriptionAvailableMethod="POST" username="initialUsername" password="initialPassword" tag="initialTag" fileFormat="wav" multiChannel="true" detectLanguage="true" recordingName="initialRecordingName"/>';
19
21
 
20
22
  test('should create a StartRecording Verb', () => {
21
23
  const startRecording = new StartRecording(attributes);
@@ -11,7 +11,9 @@ describe('StartTranscription', () => {
11
11
  username: 'initialUsername',
12
12
  password: 'initialPassword',
13
13
  destination: 'https://initial.com',
14
- stabilized: true
14
+ stabilized: true,
15
+ detectLanguage: true,
16
+ preferredLanguages: 'en-US,es-US'
15
17
  };
16
18
 
17
19
  const customParam1 = new CustomParam({ name: 'customParamName1', value: 'customParamValue1' });
@@ -19,7 +21,7 @@ describe('StartTranscription', () => {
19
21
 
20
22
  test('should create a StartTranscription Verb', () => {
21
23
  const startTranscription = new StartTranscription(attributes);
22
- const expected = '<StartTranscription name="initialName" tracks="inbound" transcriptionEventUrl="https://initial.com" transcriptionEventMethod="POST" username="initialUsername" password="initialPassword" destination="https://initial.com" stabilized="true"/>';
24
+ const expected = '<StartTranscription name="initialName" tracks="inbound" transcriptionEventUrl="https://initial.com" transcriptionEventMethod="POST" username="initialUsername" password="initialPassword" destination="https://initial.com" stabilized="true" detectLanguage="true" preferredLanguages="en-US,es-US"/>';
23
25
 
24
26
  expect(startTranscription).toBeInstanceOf(StartTranscription);
25
27
  expect(startTranscription).toBeInstanceOf(Verb);
@@ -28,9 +30,9 @@ describe('StartTranscription', () => {
28
30
 
29
31
  test('should create a StartTranscription Verb with nested CustomParam', () => {
30
32
  let startTranscription = new StartTranscription(attributes, customParam1);
31
- const expected = '<StartTranscription name="initialName" tracks="inbound" transcriptionEventUrl="https://initial.com" transcriptionEventMethod="POST" username="initialUsername" password="initialPassword" destination="https://initial.com" stabilized="true"><CustomParam name="customParamName1" value="customParamValue1"/></StartTranscription>';
32
- const expectedSingle = '<StartTranscription name="initialName" tracks="inbound" transcriptionEventUrl="https://initial.com" transcriptionEventMethod="POST" username="initialUsername" password="initialPassword" destination="https://initial.com" stabilized="true"><CustomParam name="customParamName1" value="customParamValue1"/><CustomParam name="customParamName2" value="customParamValue2"/></StartTranscription>';
33
- const expectedMultiple = '<StartTranscription name="initialName" tracks="inbound" transcriptionEventUrl="https://initial.com" transcriptionEventMethod="POST" username="initialUsername" password="initialPassword" destination="https://initial.com" stabilized="true"><CustomParam name="customParamName1" value="customParamValue1"/><CustomParam name="customParamName2" value="customParamValue2"/><CustomParam name="customParamName1" value="customParamValue1"/><CustomParam name="customParamName2" value="customParamValue2"/></StartTranscription>';
33
+ const expected = '<StartTranscription name="initialName" tracks="inbound" transcriptionEventUrl="https://initial.com" transcriptionEventMethod="POST" username="initialUsername" password="initialPassword" destination="https://initial.com" stabilized="true" detectLanguage="true" preferredLanguages="en-US,es-US"><CustomParam name="customParamName1" value="customParamValue1"/></StartTranscription>';
34
+ const expectedSingle = '<StartTranscription name="initialName" tracks="inbound" transcriptionEventUrl="https://initial.com" transcriptionEventMethod="POST" username="initialUsername" password="initialPassword" destination="https://initial.com" stabilized="true" detectLanguage="true" preferredLanguages="en-US,es-US"><CustomParam name="customParamName1" value="customParamValue1"/><CustomParam name="customParamName2" value="customParamValue2"/></StartTranscription>';
35
+ const expectedMultiple = '<StartTranscription name="initialName" tracks="inbound" transcriptionEventUrl="https://initial.com" transcriptionEventMethod="POST" username="initialUsername" password="initialPassword" destination="https://initial.com" stabilized="true" detectLanguage="true" preferredLanguages="en-US,es-US"><CustomParam name="customParamName1" value="customParamValue1"/><CustomParam name="customParamName2" value="customParamValue2"/><CustomParam name="customParamName1" value="customParamValue1"/><CustomParam name="customParamName2" value="customParamValue2"/></StartTranscription>';
34
36
 
35
37
  expect(startTranscription).toBeInstanceOf(StartTranscription);
36
38
  expect(startTranscription).toBeInstanceOf(Verb);
@@ -45,7 +47,7 @@ describe('StartTranscription', () => {
45
47
 
46
48
  test('should test the addCustomParams method method when no verbs are initially nested', () => {
47
49
  const startTranscription = new StartTranscription(attributes);
48
- const expected = '<StartTranscription name="initialName" tracks="inbound" transcriptionEventUrl="https://initial.com" transcriptionEventMethod="POST" username="initialUsername" password="initialPassword" destination="https://initial.com" stabilized="true"><CustomParam name="customParamName1" value="customParamValue1"/></StartTranscription>';
50
+ const expected = '<StartTranscription name="initialName" tracks="inbound" transcriptionEventUrl="https://initial.com" transcriptionEventMethod="POST" username="initialUsername" password="initialPassword" destination="https://initial.com" stabilized="true" detectLanguage="true" preferredLanguages="en-US,es-US"><CustomParam name="customParamName1" value="customParamValue1"/></StartTranscription>';
49
51
 
50
52
  startTranscription.addCustomParams(customParam1);
51
53
  expect(startTranscription.toBxml()).toBe(expected);
@@ -18,7 +18,8 @@ describe('Transfer', () => {
18
18
  fallbackPassword: 'initialFallbackPassword',
19
19
  tag: 'initialTag',
20
20
  diversionTreatment: 'propagate',
21
- diversionReason: 'user-busy'
21
+ diversionReason: 'user-busy',
22
+ privacy: true
22
23
  };
23
24
 
24
25
  const phoneNumber = new PhoneNumber('+19195551234');
@@ -26,7 +27,7 @@ describe('Transfer', () => {
26
27
 
27
28
  test('should create a Transfer Verb', () => {
28
29
  const transfer = new Transfer(attributes);
29
- const expected = '<Transfer transferCallerId="+19195551234" transferCallerDisplayName="initialDisplayName" callTimeout="5" transferCompleteUrl="https://initial.com" transferCompleteMethod="POST" transferCompleteFallbackUrl="https://initial.com" transferCompleteFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" diversionTreatment="propagate" diversionReason="user-busy"/>';
30
+ const expected = '<Transfer transferCallerId="+19195551234" transferCallerDisplayName="initialDisplayName" callTimeout="5" transferCompleteUrl="https://initial.com" transferCompleteMethod="POST" transferCompleteFallbackUrl="https://initial.com" transferCompleteFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" diversionTreatment="propagate" diversionReason="user-busy" privacy="true"/>';
30
31
 
31
32
  expect(transfer).toBeInstanceOf(Transfer);
32
33
  expect(transfer).toBeInstanceOf(Verb);
@@ -35,9 +36,9 @@ describe('Transfer', () => {
35
36
 
36
37
  test('should create a Transfer Verb with nested PhoneNumber and SipUri', () => {
37
38
  let transfer = new Transfer(attributes, phoneNumber);
38
- const expected = '<Transfer transferCallerId="+19195551234" transferCallerDisplayName="initialDisplayName" callTimeout="5" transferCompleteUrl="https://initial.com" transferCompleteMethod="POST" transferCompleteFallbackUrl="https://initial.com" transferCompleteFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" diversionTreatment="propagate" diversionReason="user-busy"><PhoneNumber>+19195551234</PhoneNumber></Transfer>';
39
- const expectedSingle = '<Transfer transferCallerId="+19195551234" transferCallerDisplayName="initialDisplayName" callTimeout="5" transferCompleteUrl="https://initial.com" transferCompleteMethod="POST" transferCompleteFallbackUrl="https://initial.com" transferCompleteFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" diversionTreatment="propagate" diversionReason="user-busy"><PhoneNumber>+19195551234</PhoneNumber><SipUri>sip:1-999-123-4567@voip-provider.example.net</SipUri></Transfer>';
40
- const expectedMultiple = '<Transfer transferCallerId="+19195551234" transferCallerDisplayName="initialDisplayName" callTimeout="5" transferCompleteUrl="https://initial.com" transferCompleteMethod="POST" transferCompleteFallbackUrl="https://initial.com" transferCompleteFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" diversionTreatment="propagate" diversionReason="user-busy"><PhoneNumber>+19195551234</PhoneNumber><SipUri>sip:1-999-123-4567@voip-provider.example.net</SipUri><SipUri>sip:1-999-123-4567@voip-provider.example.net</SipUri><PhoneNumber>+19195551234</PhoneNumber></Transfer>';
39
+ const expected = '<Transfer transferCallerId="+19195551234" transferCallerDisplayName="initialDisplayName" callTimeout="5" transferCompleteUrl="https://initial.com" transferCompleteMethod="POST" transferCompleteFallbackUrl="https://initial.com" transferCompleteFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" diversionTreatment="propagate" diversionReason="user-busy" privacy="true"><PhoneNumber>+19195551234</PhoneNumber></Transfer>';
40
+ const expectedSingle = '<Transfer transferCallerId="+19195551234" transferCallerDisplayName="initialDisplayName" callTimeout="5" transferCompleteUrl="https://initial.com" transferCompleteMethod="POST" transferCompleteFallbackUrl="https://initial.com" transferCompleteFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" diversionTreatment="propagate" diversionReason="user-busy" privacy="true"><PhoneNumber>+19195551234</PhoneNumber><SipUri>sip:1-999-123-4567@voip-provider.example.net</SipUri></Transfer>';
41
+ const expectedMultiple = '<Transfer transferCallerId="+19195551234" transferCallerDisplayName="initialDisplayName" callTimeout="5" transferCompleteUrl="https://initial.com" transferCompleteMethod="POST" transferCompleteFallbackUrl="https://initial.com" transferCompleteFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" diversionTreatment="propagate" diversionReason="user-busy" privacy="true"><PhoneNumber>+19195551234</PhoneNumber><SipUri>sip:1-999-123-4567@voip-provider.example.net</SipUri><SipUri>sip:1-999-123-4567@voip-provider.example.net</SipUri><PhoneNumber>+19195551234</PhoneNumber></Transfer>';
41
42
 
42
43
  expect(transfer).toBeInstanceOf(Transfer);
43
44
  expect(transfer).toBeInstanceOf(Verb);
@@ -52,7 +53,7 @@ describe('Transfer', () => {
52
53
 
53
54
  test('should test the addTransferRecipients method method when no verbs are initially nested', () => {
54
55
  const transfer = new Transfer(attributes);
55
- const expected = '<Transfer transferCallerId="+19195551234" transferCallerDisplayName="initialDisplayName" callTimeout="5" transferCompleteUrl="https://initial.com" transferCompleteMethod="POST" transferCompleteFallbackUrl="https://initial.com" transferCompleteFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" diversionTreatment="propagate" diversionReason="user-busy"><PhoneNumber>+19195551234</PhoneNumber></Transfer>';
56
+ const expected = '<Transfer transferCallerId="+19195551234" transferCallerDisplayName="initialDisplayName" callTimeout="5" transferCompleteUrl="https://initial.com" transferCompleteMethod="POST" transferCompleteFallbackUrl="https://initial.com" transferCompleteFallbackMethod="POST" username="initialUsername" password="initialPassword" fallbackUsername="initialFallbackUsername" fallbackPassword="initialFallbackPassword" tag="initialTag" diversionTreatment="propagate" diversionReason="user-busy" privacy="true"><PhoneNumber>+19195551234</PhoneNumber></Transfer>';
56
57
 
57
58
  transfer.addTransferRecipients(phoneNumber);
58
59
  expect(transfer.toBxml()).toBe(expected);