bandwidth-sdk 7.2.0 → 7.4.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.
Files changed (142) hide show
  1. package/.openapi-generator/FILES +2 -0
  2. package/README.md +1 -0
  3. package/api/messages-api.ts +4 -4
  4. package/bandwidth.yml +127 -35
  5. package/configuration.ts +1 -1
  6. package/coverage/clover.xml +11 -6
  7. package/coverage/coverage-final.json +4 -3
  8. package/coverage/lcov-report/index.html +7 -7
  9. package/coverage/lcov-report/node-sdk/api/calls-api.ts.html +1 -1
  10. package/coverage/lcov-report/node-sdk/api/conferences-api.ts.html +1 -1
  11. package/coverage/lcov-report/node-sdk/api/index.html +1 -1
  12. package/coverage/lcov-report/node-sdk/api/media-api.ts.html +1 -1
  13. package/coverage/lcov-report/node-sdk/api/messages-api.ts.html +5 -5
  14. package/coverage/lcov-report/node-sdk/api/mfaapi.ts.html +1 -1
  15. package/coverage/lcov-report/node-sdk/api/multi-channel-api.ts.html +1 -1
  16. package/coverage/lcov-report/node-sdk/api/phone-number-lookup-api.ts.html +1 -1
  17. package/coverage/lcov-report/node-sdk/api/recordings-api.ts.html +1 -1
  18. package/coverage/lcov-report/node-sdk/api/statistics-api.ts.html +1 -1
  19. package/coverage/lcov-report/node-sdk/api/toll-free-verification-api.ts.html +1 -1
  20. package/coverage/lcov-report/node-sdk/api/transcriptions-api.ts.html +1 -1
  21. package/coverage/lcov-report/node-sdk/api.ts.html +1 -1
  22. package/coverage/lcov-report/node-sdk/base.ts.html +1 -1
  23. package/coverage/lcov-report/node-sdk/common.ts.html +2 -2
  24. package/coverage/lcov-report/node-sdk/configuration.ts.html +2 -2
  25. package/coverage/lcov-report/node-sdk/index.html +1 -1
  26. package/coverage/lcov-report/node-sdk/models/business-entity-type-enum.ts.html +2 -2
  27. package/coverage/lcov-report/node-sdk/models/business-registration-issuing-country-enum.ts.html +205 -0
  28. package/coverage/lcov-report/node-sdk/models/business-registration-type-enum.ts.html +52 -4
  29. package/coverage/lcov-report/node-sdk/models/bxml/Bxml.ts.html +1 -1
  30. package/coverage/lcov-report/node-sdk/models/bxml/NestableVerb.ts.html +1 -1
  31. package/coverage/lcov-report/node-sdk/models/bxml/Response.ts.html +1 -1
  32. package/coverage/lcov-report/node-sdk/models/bxml/Root.ts.html +1 -1
  33. package/coverage/lcov-report/node-sdk/models/bxml/Verb.ts.html +1 -1
  34. package/coverage/lcov-report/node-sdk/models/bxml/index.html +1 -1
  35. package/coverage/lcov-report/node-sdk/models/bxml/index.ts.html +1 -1
  36. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Bridge.ts.html +1 -1
  37. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Conference.ts.html +1 -1
  38. package/coverage/lcov-report/node-sdk/models/bxml/verbs/CustomParam.ts.html +1 -1
  39. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Forward.ts.html +1 -1
  40. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Gather.ts.html +1 -1
  41. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Hangup.ts.html +1 -1
  42. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Pause.ts.html +1 -1
  43. package/coverage/lcov-report/node-sdk/models/bxml/verbs/PauseRecording.ts.html +1 -1
  44. package/coverage/lcov-report/node-sdk/models/bxml/verbs/PhoneNumber.ts.html +1 -1
  45. package/coverage/lcov-report/node-sdk/models/bxml/verbs/PlayAudio.ts.html +1 -1
  46. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Record.ts.html +1 -1
  47. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Redirect.ts.html +1 -1
  48. package/coverage/lcov-report/node-sdk/models/bxml/verbs/ResumeRecording.ts.html +1 -1
  49. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Ring.ts.html +1 -1
  50. package/coverage/lcov-report/node-sdk/models/bxml/verbs/SendDtmf.ts.html +1 -1
  51. package/coverage/lcov-report/node-sdk/models/bxml/verbs/SipUri.ts.html +1 -1
  52. package/coverage/lcov-report/node-sdk/models/bxml/verbs/SpeakSentence.ts.html +1 -1
  53. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StartGather.ts.html +1 -1
  54. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StartRecording.ts.html +1 -1
  55. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StartStream.ts.html +1 -1
  56. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StartTranscription.ts.html +1 -1
  57. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StopGather.ts.html +1 -1
  58. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StopRecording.ts.html +1 -1
  59. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StopStream.ts.html +1 -1
  60. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StopTranscription.ts.html +1 -1
  61. package/coverage/lcov-report/node-sdk/models/bxml/verbs/StreamParam.ts.html +1 -1
  62. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Tag.ts.html +1 -1
  63. package/coverage/lcov-report/node-sdk/models/bxml/verbs/Transfer.ts.html +1 -1
  64. package/coverage/lcov-report/node-sdk/models/bxml/verbs/index.html +1 -1
  65. package/coverage/lcov-report/node-sdk/models/bxml/verbs/index.ts.html +1 -1
  66. package/coverage/lcov-report/node-sdk/models/call-direction-enum.ts.html +1 -1
  67. package/coverage/lcov-report/node-sdk/models/call-state-enum.ts.html +1 -1
  68. package/coverage/lcov-report/node-sdk/models/call-transcription-detected-language-enum.ts.html +1 -1
  69. package/coverage/lcov-report/node-sdk/models/call-transcription-track-enum.ts.html +1 -1
  70. package/coverage/lcov-report/node-sdk/models/callback-method-enum.ts.html +1 -1
  71. package/coverage/lcov-report/node-sdk/models/card-width-enum.ts.html +1 -1
  72. package/coverage/lcov-report/node-sdk/models/completed-lookup-status-enum.ts.html +1 -1
  73. package/coverage/lcov-report/node-sdk/models/conference-state-enum.ts.html +1 -1
  74. package/coverage/lcov-report/node-sdk/models/deactivation-event-enum.ts.html +1 -1
  75. package/coverage/lcov-report/node-sdk/models/file-format-enum.ts.html +1 -1
  76. package/coverage/lcov-report/node-sdk/models/in-progress-lookup-status-enum.ts.html +1 -1
  77. package/coverage/lcov-report/node-sdk/models/inbound-callback-type-enum.ts.html +1 -1
  78. package/coverage/lcov-report/node-sdk/models/index.html +20 -5
  79. package/coverage/lcov-report/node-sdk/models/index.ts.html +7 -4
  80. package/coverage/lcov-report/node-sdk/models/latest-message-delivery-status-enum.ts.html +1 -1
  81. package/coverage/lcov-report/node-sdk/models/line-type-enum.ts.html +1 -1
  82. package/coverage/lcov-report/node-sdk/models/list-message-direction-enum.ts.html +1 -1
  83. package/coverage/lcov-report/node-sdk/models/machine-detection-mode-enum.ts.html +1 -1
  84. package/coverage/lcov-report/node-sdk/models/message-direction-enum.ts.html +1 -1
  85. package/coverage/lcov-report/node-sdk/models/message-status-enum.ts.html +1 -1
  86. package/coverage/lcov-report/node-sdk/models/message-type-enum.ts.html +1 -1
  87. package/coverage/lcov-report/node-sdk/models/multi-channel-message-channel-enum.ts.html +1 -1
  88. package/coverage/lcov-report/node-sdk/models/priority-enum.ts.html +1 -1
  89. package/coverage/lcov-report/node-sdk/models/product-type-enum.ts.html +1 -1
  90. package/coverage/lcov-report/node-sdk/models/rbm-action-type-enum.ts.html +1 -1
  91. package/coverage/lcov-report/node-sdk/models/rbm-media-height-enum.ts.html +1 -1
  92. package/coverage/lcov-report/node-sdk/models/rbm-open-url-enum.ts.html +1 -1
  93. package/coverage/lcov-report/node-sdk/models/rbm-web-view-enum.ts.html +1 -1
  94. package/coverage/lcov-report/node-sdk/models/recording-state-enum.ts.html +1 -1
  95. package/coverage/lcov-report/node-sdk/models/redirect-method-enum.ts.html +1 -1
  96. package/coverage/lcov-report/node-sdk/models/standalone-card-orientation-enum.ts.html +1 -1
  97. package/coverage/lcov-report/node-sdk/models/status-callback-type-enum.ts.html +1 -1
  98. package/coverage/lcov-report/node-sdk/models/tfv-callback-status-enum.ts.html +1 -1
  99. package/coverage/lcov-report/node-sdk/models/tfv-status-enum.ts.html +1 -1
  100. package/coverage/lcov-report/node-sdk/models/thumbnail-alignment-enum.ts.html +1 -1
  101. package/coverage/lcov-report/node-sdk/models/webhook-subscription-type-enum.ts.html +1 -1
  102. package/coverage/lcov.info +16 -5
  103. package/dist/api/messages-api.d.ts +4 -4
  104. package/dist/api/messages-api.js +4 -4
  105. package/dist/configuration.js +1 -1
  106. package/dist/models/business-entity-type-enum.d.ts +1 -1
  107. package/dist/models/business-entity-type-enum.js +1 -1
  108. package/dist/models/business-registration-issuing-country-enum.d.ts +30 -0
  109. package/dist/models/business-registration-issuing-country-enum.js +34 -0
  110. package/dist/models/business-registration-type-enum.d.ts +17 -1
  111. package/dist/models/business-registration-type-enum.js +18 -2
  112. package/dist/models/index.d.ts +1 -0
  113. package/dist/models/index.js +1 -0
  114. package/dist/models/rbm-message-media.d.ts +1 -1
  115. package/dist/models/tfv-status.d.ts +1 -1
  116. package/dist/models/tfv-submission-info.d.ts +4 -2
  117. package/dist/models/verification-request.d.ts +5 -3
  118. package/dist/models/verification-update-request.d.ts +5 -3
  119. package/docs/BusinessEntityTypeEnum.md +1 -1
  120. package/docs/BusinessRegistrationIssuingCountryEnum.md +33 -0
  121. package/docs/BusinessRegistrationTypeEnum.md +33 -1
  122. package/docs/MessagesApi.md +3 -2
  123. package/docs/MultiChannelChannelListRBMObjectAllOfContent.md +1 -1
  124. package/docs/RbmMessageMedia.md +1 -1
  125. package/docs/TfvStatus.md +1 -1
  126. package/docs/TfvSubmissionInfo.md +3 -1
  127. package/docs/VerificationRequest.md +5 -3
  128. package/docs/VerificationUpdateRequest.md +4 -2
  129. package/models/business-entity-type-enum.ts +1 -1
  130. package/models/business-registration-issuing-country-enum.ts +40 -0
  131. package/models/business-registration-type-enum.ts +18 -2
  132. package/models/index.ts +1 -0
  133. package/models/rbm-message-media.ts +1 -1
  134. package/models/tfv-status.ts +1 -1
  135. package/models/tfv-submission-info.ts +6 -2
  136. package/models/verification-request.ts +7 -3
  137. package/models/verification-update-request.ts +7 -3
  138. package/package.json +1 -1
  139. package/tests/smoke/multi-channel-api.test.ts +240 -4
  140. package/tests/unit/api/toll-free-verification-api.test.ts +2 -1
  141. package/tests/unit/models/business-registration-issuing-country-enum.test.ts +19 -0
  142. package/tests/unit/models/business-registration-type-enum.test.ts +16 -0
@@ -11,7 +11,20 @@ import {
11
11
  RbmMessageContentText,
12
12
  MultiChannelMessageRequest,
13
13
  MessageDirectionEnum,
14
- RbmActionTypeEnum
14
+ RbmActionTypeEnum,
15
+ CardWidthEnum,
16
+ RbmMediaHeightEnum,
17
+ RbmCardContent,
18
+ RbmMessageCarouselCard,
19
+ RbmMessageMedia,
20
+ RbmActionDial,
21
+ MultiChannelChannelListRBMResponseObject,
22
+ RbmStandaloneCard,
23
+ StandaloneCardOrientationEnum,
24
+ ThumbnailAlignmentEnum,
25
+ MultiChannelChannelListSMSObject,
26
+ MultiChannelChannelListMMSObject,
27
+ MultiChannelChannelListRBMObject
15
28
  } from '../../models';
16
29
 
17
30
  describe('MultiChannelApi', () => {
@@ -103,8 +116,8 @@ describe('MultiChannelApi', () => {
103
116
  });
104
117
  });
105
118
 
106
- describe('createMultiChannelRBMMessage', () => {
107
- test('should create a multi-channel RBM message', async () => {
119
+ describe('createMultiChannelRBMTextMessage', () => {
120
+ test('should create a multi-channel RBM text message', async () => {
108
121
  const content: RbmMessageContentText = {
109
122
  text: "Hello World!",
110
123
  suggestions: [{
@@ -145,7 +158,230 @@ describe('MultiChannelApi', () => {
145
158
  expect(data.data?.priority).toBeOneOf(Object.values(PriorityEnum));
146
159
  expect(data.data?.expiration).toBeDateString();
147
160
  expect(data.data?.channelList).toBeArray();
148
- expect(data.data?.channelList![0].channel).toEqual(MultiChannelMessageChannelEnum.Rbm);
161
+ expect(data.data?.channelList![0]).toBeObject();
162
+ const channelListObject = data.data?.channelList![0] as MultiChannelChannelListRBMResponseObject;
163
+ expect(channelListObject.from).toEqual(BW_NUMBER);
164
+ expect(channelListObject.applicationId).toEqual(BW_MESSAGING_APPLICATION_ID);
165
+ expect(channelListObject.channel).toEqual(MultiChannelMessageChannelEnum.Rbm);
166
+ expect(channelListObject.content).toBeObject();
167
+ expect(channelListObject.owner).toEqual(BW_NUMBER);
168
+ const rbmContent = channelListObject.content as RbmMessageContentText;
169
+ expect(rbmContent.text).toBeString();
170
+ expect(rbmContent.suggestions).toBeArray();
171
+ expect(rbmContent.suggestions[0]).toBeObject();
172
+ const rbmActionDial = rbmContent.suggestions[0] as RbmActionDial;
173
+ expect(rbmActionDial.type).toEqual(RbmActionTypeEnum.DialPhone);
174
+ expect(rbmActionDial.text).toBeString();
175
+ expect(rbmActionDial.postbackData).toBeString();
176
+ expect(rbmActionDial.phoneNumber).toBeString();
177
+ });
178
+ });
179
+
180
+ describe('createMultiChannelRBMMediaMessage', () => {
181
+ test('should create a multi-channel RBM media message', async () => {
182
+ const content: RbmMessageMedia = {
183
+ media:[{
184
+ fileUrl: "https://example.com/image.jpg",
185
+ thumbnailUrl: "https://example.com/thumbnail.jpg",
186
+ }],
187
+ suggestions: [{
188
+ type: RbmActionTypeEnum.DialPhone,
189
+ text: "Call Us",
190
+ postbackData: "tel:+1234567890",
191
+ phoneNumber: BW_NUMBER
192
+ }]
193
+ };
194
+
195
+ const channelListObject: MultiChannelChannelListRBMObject = {
196
+ from: BW_NUMBER,
197
+ applicationId: BW_MESSAGING_APPLICATION_ID,
198
+ channel: MultiChannelMessageChannelEnum.Rbm,
199
+ content,
200
+ };
201
+
202
+ const multiChannelMessageRequest: MultiChannelMessageRequest = {
203
+ to: USER_NUMBER,
204
+ tag: "tag",
205
+ priority: PriorityEnum.High,
206
+ expiration,
207
+ channelList: [channelListObject],
208
+ };
209
+
210
+ const { status, data } = await multiChannelApi.createMultiChannelMessage(
211
+ BW_ACCOUNT_ID,
212
+ multiChannelMessageRequest
213
+ );
214
+
215
+ expect(status).toEqual(202);
216
+ expect(data.links).toBeArray();
217
+ expect(data.data?.id).toBeString();
218
+ expect(data.data?.time).toBeDateString();
219
+ expect(data.data?.direction).toBeOneOf(Object.values(MessageDirectionEnum));
220
+ expect(data.data?.to).toBeArray();
221
+ expect(data.data?.tag).toBeString();
222
+ expect(data.data?.priority).toBeOneOf(Object.values(PriorityEnum));
223
+ expect(data.data?.expiration).toBeDateString();
224
+ expect(data.data?.channelList).toBeArray();
225
+ expect(data.data?.channelList![0]).toBeObject();
226
+ const channelListObject = data.data?.channelList![0] as MultiChannelChannelListRBMResponseObject;
227
+ expect(channelListObject.from).toEqual(BW_NUMBER);
228
+ expect(channelListObject.applicationId).toEqual(BW_MESSAGING_APPLICATION_ID);
229
+ expect(channelListObject.channel).toEqual(MultiChannelMessageChannelEnum.Rbm);
230
+ expect(channelListObject.content).toBeObject();
231
+ expect(channelListObject.owner).toEqual(BW_NUMBER);
232
+ const rbmContent = channelListObject.content as RbmMessageMedia;
233
+ expect(rbmContent.media).toBeArray();
234
+ expect(rbmContent.media[0].fileUrl).toBeString();
235
+ expect(rbmContent.media[0].thumbnailUrl).toBeString();
236
+ expect(rbmContent.suggestions).toBeArray();
237
+ expect(rbmContent.suggestions[0]).toBeObject();
238
+ const rbmActionDial = rbmContent.suggestions[0] as RbmActionDial;
239
+ expect(rbmActionDial.type).toEqual(RbmActionTypeEnum.DialPhone);
240
+ expect(rbmActionDial.text).toBeString();
241
+ expect(rbmActionDial.postbackData).toBeString();
242
+ expect(rbmActionDial.phoneNumber).toBeString();
243
+ });
244
+ });
245
+
246
+ describe('createMultiChannelRBMRichStandaloneMessage', () => {
247
+ test('should create a multi-channel RBM standalone rich card message', async () => {
248
+ const content: RbmStandaloneCard = {
249
+ orientation: StandaloneCardOrientationEnum.Horizontal,
250
+ thumbnailImageAlignment: ThumbnailAlignmentEnum.Left,
251
+ cardContent: {
252
+ title: "Test Title"
253
+ }
254
+ };
255
+
256
+ const channelListObject: MultiChannelChannelListRBMObject = {
257
+ from: BW_NUMBER,
258
+ applicationId: BW_MESSAGING_APPLICATION_ID,
259
+ channel: MultiChannelMessageChannelEnum.Rbm,
260
+ content,
261
+ };
262
+
263
+ const multiChannelMessageRequest: MultiChannelMessageRequest = {
264
+ to: USER_NUMBER,
265
+ tag: "tag",
266
+ priority: PriorityEnum.High,
267
+ expiration,
268
+ channelList: [channelListObject],
269
+ };
270
+
271
+ const { status, data } = await multiChannelApi.createMultiChannelMessage(
272
+ BW_ACCOUNT_ID,
273
+ multiChannelMessageRequest
274
+ );
275
+
276
+ expect(status).toEqual(202);
277
+ expect(data.links).toBeArray();
278
+ expect(data.data?.id).toBeString();
279
+ expect(data.data?.time).toBeDateString();
280
+ expect(data.data?.direction).toBeOneOf(Object.values(MessageDirectionEnum));
281
+ expect(data.data?.to).toBeArray();
282
+ expect(data.data?.tag).toBeString();
283
+ expect(data.data?.priority).toBeOneOf(Object.values(PriorityEnum));
284
+ expect(data.data?.expiration).toBeDateString();
285
+ expect(data.data?.channelList).toBeArray();
286
+ expect(data.data?.channelList![0]).toBeObject();
287
+ const channelListObject = data.data?.channelList![0] as MultiChannelChannelListRBMResponseObject;
288
+ expect(channelListObject.from).toEqual(BW_NUMBER);
289
+ expect(channelListObject.applicationId).toEqual(BW_MESSAGING_APPLICATION_ID);
290
+ expect(channelListObject.channel).toEqual(MultiChannelMessageChannelEnum.Rbm);
291
+ expect(channelListObject.content).toBeObject();
292
+ expect(channelListObject.owner).toEqual(BW_NUMBER);
293
+ const rbmContent = channelListObject.content as RbmStandaloneCard;
294
+ expect(rbmContent.orientation).toEqual(StandaloneCardOrientationEnum.Horizontal);
295
+ expect(rbmContent.thumbnailImageAlignment).toEqual(ThumbnailAlignmentEnum.Left);
296
+ expect(rbmContent.cardContent.title).toBeString();
297
+ });
298
+ });
299
+
300
+ describe('createMultiChannelRBMRichCarouselMessage', () => {
301
+ test('should create a multi-channel RBM carousel rich card message', async () => {
302
+ const carouselCard: RbmCardContent = {
303
+ title: "Card 1 Title",
304
+ description: "Card 1 Description",
305
+ media: {
306
+ fileUrl: "https://example.com/image.jpg",
307
+ thumbnailUrl: "https://example.com/thumbnail.jpg",
308
+ height: RbmMediaHeightEnum.Tall
309
+ },
310
+ suggestions: [{
311
+ type: RbmActionTypeEnum.DialPhone,
312
+ text: "Call Us",
313
+ postbackData: "tel:+1234567890",
314
+ phoneNumber: BW_NUMBER
315
+ }]
316
+ };
317
+
318
+ const content: RbmMessageCarouselCard = {
319
+ cardWidth: CardWidthEnum.Medium,
320
+ cardContents: [
321
+ carouselCard,
322
+ { title: "Card 2 Title" }
323
+ ]
324
+ };
325
+
326
+ const channelListObject: MultiChannelChannelListRBMObject = {
327
+ from: BW_NUMBER,
328
+ applicationId: BW_MESSAGING_APPLICATION_ID,
329
+ channel: MultiChannelMessageChannelEnum.Rbm,
330
+ content,
331
+ };
332
+
333
+ const multiChannelMessageRequest: MultiChannelMessageRequest = {
334
+ to: USER_NUMBER,
335
+ tag: "tag",
336
+ priority: PriorityEnum.High,
337
+ expiration,
338
+ channelList: [channelListObject],
339
+ };
340
+
341
+ const { status, data } = await multiChannelApi.createMultiChannelMessage(
342
+ BW_ACCOUNT_ID,
343
+ multiChannelMessageRequest
344
+ );
345
+
346
+ expect(status).toEqual(202);
347
+ expect(data.links).toBeArray();
348
+ expect(data.data?.id).toBeString();
349
+ expect(data.data?.time).toBeDateString();
350
+ expect(data.data?.direction).toBeOneOf(Object.values(MessageDirectionEnum));
351
+ expect(data.data?.to).toBeArray();
352
+ expect(data.data?.tag).toBeString();
353
+ expect(data.data?.priority).toBeOneOf(Object.values(PriorityEnum));
354
+ expect(data.data?.expiration).toBeDateString();
355
+ expect(data.data?.channelList).toBeArray();
356
+ expect(data.data?.channelList![0]).toBeObject();
357
+ const channelListObject = data.data?.channelList![0] as MultiChannelChannelListRBMResponseObject;
358
+ expect(channelListObject.from).toEqual(BW_NUMBER);
359
+ expect(channelListObject.applicationId).toEqual(BW_MESSAGING_APPLICATION_ID);
360
+ expect(channelListObject.channel).toEqual(MultiChannelMessageChannelEnum.Rbm);
361
+ expect(channelListObject.content).toBeObject();
362
+ expect(channelListObject.owner).toEqual(BW_NUMBER);
363
+ const rbmContent = channelListObject.content as RbmMessageCarouselCard;
364
+ expect(rbmContent.cardWidth).toEqual(CardWidthEnum.Medium);
365
+ expect(rbmContent.cardContents).toBeArray();
366
+ expect(rbmContent.cardContents).toHaveLength(2);
367
+ expect(rbmContent.cardContents[0]).toBeObject();
368
+ const firstCard = rbmContent.cardContents[0] as RbmCardContent;
369
+ expect(firstCard.title).toBeString();
370
+ expect(firstCard.description).toBeString();
371
+ expect(firstCard.media).toBeObject();
372
+ expect(firstCard.media!.fileUrl).toBeString();
373
+ expect(firstCard.media!.thumbnailUrl).toBeString();
374
+ expect(firstCard.media!.height).toEqual(RbmMediaHeightEnum.Tall);
375
+ expect(firstCard.suggestions).toBeArray();
376
+ expect(firstCard.suggestions[0]).toBeObject();
377
+ const rbmActionDial = firstCard.suggestions[0] as RbmActionDial;
378
+ expect(rbmActionDial.type).toEqual(RbmActionTypeEnum.DialPhone);
379
+ expect(rbmActionDial.text).toBeString();
380
+ expect(rbmActionDial.postbackData).toBeString();
381
+ expect(rbmActionDial.phoneNumber).toBeString();
382
+ expect(rbmContent.cardContents[1]).toBeObject();
383
+ const secondCard = rbmContent.cardContents[1] as RbmCardContent;
384
+ expect(secondCard.title).toBeString();
149
385
  });
150
386
  });
151
387
  });
@@ -1,7 +1,7 @@
1
1
  //@ts-nocheck
2
2
  import { TollFreeVerificationApi } from '../../../api';
3
3
  import { Configuration } from '../../../configuration';
4
- import { BusinessEntityTypeEnum, BusinessRegistrationTypeEnum, CallbackTypeEnum, TfvStatusEnum, WebhookSubscriptionTypeEnum } from '../../../models';
4
+ import { BusinessEntityTypeEnum, BusinessRegistrationIssuingCountryEnum, BusinessRegistrationTypeEnum, CallbackTypeEnum, TfvStatusEnum, WebhookSubscriptionTypeEnum } from '../../../models';
5
5
 
6
6
  describe('TollFreeVerificationApi', () => {
7
7
  const config = new Configuration({
@@ -140,6 +140,7 @@ describe('TollFreeVerificationApi', () => {
140
140
  businessDba: 'businessDba',
141
141
  businessRegistrationNumber: 'businessRegistrationNumber',
142
142
  businessRegistrationType: BusinessRegistrationTypeEnum.Ein,
143
+ businessRegistrationIssuingCountry: BusinessRegistrationIssuingCountryEnum.Us,
143
144
  businessEntityType: BusinessEntityTypeEnum.NonProfit,
144
145
  helpMessageResponse: 'helpMessageResponse',
145
146
  ageGatedContent: true,
@@ -0,0 +1,19 @@
1
+ import { BusinessRegistrationIssuingCountryEnum } from '../../../models/business-registration-issuing-country-enum';
2
+
3
+ describe('BusinessRegistrationIssuingCountryEnum', () => {
4
+ test('should define the expected values', () => {
5
+ expect(BusinessRegistrationIssuingCountryEnum.Usa).toBe('USA');
6
+ expect(BusinessRegistrationIssuingCountryEnum.Can).toBe('CAN');
7
+ expect(BusinessRegistrationIssuingCountryEnum.Hkg).toBe('HKG');
8
+ expect(BusinessRegistrationIssuingCountryEnum.Gbr).toBe('GBR');
9
+ expect(BusinessRegistrationIssuingCountryEnum.Irl).toBe('IRL');
10
+ expect(BusinessRegistrationIssuingCountryEnum.Bra).toBe('BRA');
11
+ expect(BusinessRegistrationIssuingCountryEnum.Nld).toBe('NLD');
12
+ expect(BusinessRegistrationIssuingCountryEnum.Aus).toBe('AUS');
13
+ expect(BusinessRegistrationIssuingCountryEnum.Fra).toBe('FRA');
14
+ expect(BusinessRegistrationIssuingCountryEnum.Nzl).toBe('NZL');
15
+ expect(BusinessRegistrationIssuingCountryEnum.Deu).toBe('DEU');
16
+ expect(BusinessRegistrationIssuingCountryEnum.Esp).toBe('ESP');
17
+ expect(BusinessRegistrationIssuingCountryEnum.Che).toBe('CHE');
18
+ });
19
+ });
@@ -4,5 +4,21 @@ describe('BusinessRegistrationTypeEnum', () => {
4
4
  test('should define the expected values', () => {
5
5
  expect(BusinessRegistrationTypeEnum.Ein).toBe('EIN');
6
6
  expect(BusinessRegistrationTypeEnum.Cbn).toBe('CBN');
7
+ expect(BusinessRegistrationTypeEnum.Neq).toBe('NEQ');
8
+ expect(BusinessRegistrationTypeEnum.ProvincialNumber).toBe('PROVINCIAL_NUMBER');
9
+ expect(BusinessRegistrationTypeEnum.Crn).toBe('CRN');
10
+ expect(BusinessRegistrationTypeEnum.Vat).toBe('VAT');
11
+ expect(BusinessRegistrationTypeEnum.Acn).toBe('ACN');
12
+ expect(BusinessRegistrationTypeEnum.Abn).toBe('ABN');
13
+ expect(BusinessRegistrationTypeEnum.Brn).toBe('BRN');
14
+ expect(BusinessRegistrationTypeEnum.Siren).toBe('SIREN');
15
+ expect(BusinessRegistrationTypeEnum.Siret).toBe('SIRET');
16
+ expect(BusinessRegistrationTypeEnum.Nzbn).toBe('NZBN');
17
+ expect(BusinessRegistrationTypeEnum.UstIdnr).toBe('UST_IDNR');
18
+ expect(BusinessRegistrationTypeEnum.Cif).toBe('CIF');
19
+ expect(BusinessRegistrationTypeEnum.Nif).toBe('NIF');
20
+ expect(BusinessRegistrationTypeEnum.Cnpj).toBe('CNPJ');
21
+ expect(BusinessRegistrationTypeEnum.Uid).toBe('UID');
22
+ expect(BusinessRegistrationTypeEnum.Other).toBe('OTHER');
7
23
  });
8
24
  });