twilio 3.74.0 → 3.76.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/lib/rest/Chat.d.ts +4 -0
- package/lib/rest/Chat.js +19 -0
- package/lib/rest/FlexApi.d.ts +2 -0
- package/lib/rest/FlexApi.js +8 -0
- package/lib/rest/Insights.d.ts +2 -0
- package/lib/rest/Insights.js +8 -0
- package/lib/rest/Media.d.ts +2 -0
- package/lib/rest/Media.js +9 -0
- package/lib/rest/Supersim.d.ts +0 -2
- package/lib/rest/Supersim.js +0 -8
- package/lib/rest/api/v2010/account/call/payment.d.ts +1 -1
- package/lib/rest/api/v2010/account/call/payment.js +1 -1
- package/lib/rest/api/v2010/account/call/siprec.d.ts +2 -0
- package/lib/rest/api/v2010/account/call/siprec.js +3 -0
- package/lib/rest/api/v2010/account/call/stream.d.ts +4 -8
- package/lib/rest/api/v2010/account/call/stream.js +11 -7
- package/lib/rest/api/v2010/account/recording.d.ts +31 -2
- package/lib/rest/api/v2010/account/recording.js +25 -4
- package/lib/rest/api/v2010/account/usage/record/allTime.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/daily.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/lastMonth.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/monthly.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/thisMonth.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/today.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/yearly.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/yesterday.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/trigger.d.ts +1 -1
- package/lib/rest/chat/V3.d.ts +25 -0
- package/lib/rest/chat/V3.js +46 -0
- package/lib/rest/chat/v2/service/user/userChannel.d.ts +26 -1
- package/lib/rest/chat/v2/service/user/userChannel.js +18 -4
- package/lib/rest/chat/v3/channel.d.ts +177 -0
- package/lib/rest/chat/v3/channel.js +373 -0
- package/lib/rest/conversations/v1/addressConfiguration.d.ts +3 -3
- package/lib/rest/conversations/v1/addressConfiguration.js +4 -4
- package/lib/rest/flexApi/V1.d.ts +3 -0
- package/lib/rest/flexApi/V1.js +11 -0
- package/lib/rest/flexApi/v1/configuration.d.ts +2 -0
- package/lib/rest/flexApi/v1/configuration.js +3 -0
- package/lib/rest/flexApi/v1/interaction/interactionChannel/interactionChannelInvite.d.ts +266 -0
- package/lib/rest/flexApi/v1/interaction/interactionChannel/interactionChannelInvite.js +505 -0
- package/lib/rest/flexApi/v1/interaction/interactionChannel/interactionChannelParticipant.d.ts +323 -0
- package/lib/rest/flexApi/v1/interaction/interactionChannel/interactionChannelParticipant.js +674 -0
- package/lib/rest/flexApi/v1/interaction/interactionChannel.d.ts +327 -0
- package/lib/rest/flexApi/v1/interaction/interactionChannel.js +718 -0
- package/lib/rest/flexApi/v1/interaction.d.ts +152 -0
- package/lib/rest/flexApi/v1/interaction.js +395 -0
- package/lib/rest/insights/V1.d.ts +3 -0
- package/lib/rest/insights/V1.js +11 -0
- package/lib/rest/insights/v1/annotation.d.ts +188 -0
- package/lib/rest/insights/v1/annotation.js +406 -0
- package/lib/rest/media/V1.d.ts +3 -0
- package/lib/rest/media/V1.js +12 -0
- package/lib/rest/media/v1/mediaProcessor.js +1 -1
- package/lib/rest/media/v1/mediaRecording.d.ts +358 -0
- package/lib/rest/{supersim/v1/command.js → media/v1/mediaRecording.js} +190 -176
- package/lib/rest/media/v1/playerStreamer.d.ts +4 -0
- package/lib/rest/media/v1/playerStreamer.js +5 -1
- package/lib/rest/numbers/v2/regulatoryCompliance/bundle.d.ts +5 -5
- package/lib/rest/numbers/v2/regulatoryCompliance/bundle.js +3 -3
- package/lib/rest/numbers/v2/regulatoryCompliance/supportingDocument.d.ts +2 -0
- package/lib/rest/numbers/v2/regulatoryCompliance/supportingDocument.js +3 -0
- package/lib/rest/supersim/V1.d.ts +0 -3
- package/lib/rest/supersim/V1.js +0 -11
- package/lib/rest/supersim/v1/fleet.d.ts +0 -16
- package/lib/rest/supersim/v1/fleet.js +0 -18
- package/lib/rest/supersim/v1/usageRecord.d.ts +3 -3
- package/lib/rest/supersim/v1/usageRecord.js +3 -3
- package/lib/rest/taskrouter/v1/workspace/taskQueue/taskQueueCumulativeStatistics.d.ts +1 -1
- package/lib/rest/taskrouter/v1/workspace/taskQueue/taskQueueCumulativeStatistics.js +2 -2
- package/lib/rest/taskrouter/v1/workspace/workflow/workflowCumulativeStatistics.d.ts +1 -1
- package/lib/rest/taskrouter/v1/workspace/workflow/workflowCumulativeStatistics.js +2 -2
- package/lib/rest/taskrouter/v1/workspace/workspaceCumulativeStatistics.d.ts +1 -1
- package/lib/rest/taskrouter/v1/workspace/workspaceCumulativeStatistics.js +2 -2
- package/lib/rest/verify/v2/service/accessToken.d.ts +6 -0
- package/lib/rest/verify/v2/service/accessToken.js +9 -1
- package/lib/rest/verify/v2/service/entity/challenge.d.ts +4 -0
- package/lib/rest/verify/v2/service/entity/challenge.js +8 -1
- package/lib/rest/verify/v2/service/entity/factor.d.ts +2 -0
- package/lib/rest/verify/v2/service/entity/factor.js +2 -0
- package/lib/rest/verify/v2/service/entity/newFactor.d.ts +4 -0
- package/lib/rest/verify/v2/service/entity/newFactor.js +9 -3
- package/lib/rest/video/v1/composition.d.ts +4 -0
- package/lib/rest/video/v1/composition.js +6 -0
- package/lib/rest/video/v1/recording.d.ts +4 -0
- package/lib/rest/video/v1/recording.js +6 -0
- package/lib/twiml/VoiceResponse.d.ts +2 -2
- package/package.json +3 -3
- package/lib/rest/supersim/v1/command.d.ts +0 -342
|
@@ -239,6 +239,7 @@ interface FactorResource {
|
|
|
239
239
|
factor_type: FactorFactorTypes;
|
|
240
240
|
friendly_name: string;
|
|
241
241
|
identity: string;
|
|
242
|
+
metadata: object;
|
|
242
243
|
service_sid: string;
|
|
243
244
|
sid: string;
|
|
244
245
|
status: FactorFactorStatuses;
|
|
@@ -327,6 +328,7 @@ declare class FactorInstance extends SerializableClass {
|
|
|
327
328
|
fetch(callback?: (error: Error | null, items: FactorInstance) => any): Promise<FactorInstance>;
|
|
328
329
|
friendlyName: string;
|
|
329
330
|
identity: string;
|
|
331
|
+
metadata: any;
|
|
330
332
|
/**
|
|
331
333
|
* remove a FactorInstance
|
|
332
334
|
*
|
|
@@ -429,6 +429,7 @@ FactorPage.prototype[util.inspect.custom] = function inspect(depth, options) {
|
|
|
429
429
|
* @property {factor.factor_statuses} status - The Status of this Factor
|
|
430
430
|
* @property {factor.factor_types} factorType - The Type of this Factor
|
|
431
431
|
* @property {object} config - Configurations for a `factor_type`.
|
|
432
|
+
* @property {object} metadata - Metadata of the factor.
|
|
432
433
|
* @property {string} url - The URL of this resource.
|
|
433
434
|
*
|
|
434
435
|
* @param {V2} version - Version of the resource
|
|
@@ -454,6 +455,7 @@ FactorInstance = function FactorInstance(version, payload, serviceSid, identity,
|
|
|
454
455
|
this.status = payload.status; // jshint ignore:line
|
|
455
456
|
this.factorType = payload.factor_type; // jshint ignore:line
|
|
456
457
|
this.config = payload.config; // jshint ignore:line
|
|
458
|
+
this.metadata = payload.metadata; // jshint ignore:line
|
|
457
459
|
this.url = payload.url; // jshint ignore:line
|
|
458
460
|
|
|
459
461
|
// Context
|
|
@@ -60,6 +60,7 @@ interface NewFactorListInstance {
|
|
|
60
60
|
* @property config.timeStep - How often, in seconds, are TOTP codes generated
|
|
61
61
|
* @property factorType - The Type of this Factor
|
|
62
62
|
* @property friendlyName - The friendly name of this Factor
|
|
63
|
+
* @property metadata - Metadata of the factor.
|
|
63
64
|
*/
|
|
64
65
|
interface NewFactorListInstanceCreateOptions {
|
|
65
66
|
binding?: {
|
|
@@ -79,6 +80,7 @@ interface NewFactorListInstanceCreateOptions {
|
|
|
79
80
|
};
|
|
80
81
|
factorType: NewFactorFactorTypes;
|
|
81
82
|
friendlyName: string;
|
|
83
|
+
metadata?: object;
|
|
82
84
|
}
|
|
83
85
|
|
|
84
86
|
interface NewFactorPayload extends NewFactorResource, Page.TwilioResponsePayload {
|
|
@@ -94,6 +96,7 @@ interface NewFactorResource {
|
|
|
94
96
|
factor_type: NewFactorFactorTypes;
|
|
95
97
|
friendly_name: string;
|
|
96
98
|
identity: string;
|
|
99
|
+
metadata: object;
|
|
97
100
|
service_sid: string;
|
|
98
101
|
sid: string;
|
|
99
102
|
status: NewFactorFactorStatuses;
|
|
@@ -129,6 +132,7 @@ declare class NewFactorInstance extends SerializableClass {
|
|
|
129
132
|
factorType: NewFactorFactorTypes;
|
|
130
133
|
friendlyName: string;
|
|
131
134
|
identity: string;
|
|
135
|
+
metadata: any;
|
|
132
136
|
serviceSid: string;
|
|
133
137
|
sid: string;
|
|
134
138
|
status: NewFactorFactorStatuses;
|
|
@@ -15,6 +15,8 @@ var util = require('util'); /* jshint ignore:line */
|
|
|
15
15
|
var Page = require('../../../../../base/Page'); /* jshint ignore:line */
|
|
16
16
|
var deserialize = require(
|
|
17
17
|
'../../../../../base/deserialize'); /* jshint ignore:line */
|
|
18
|
+
var serialize = require(
|
|
19
|
+
'../../../../../base/serialize'); /* jshint ignore:line */
|
|
18
20
|
var values = require('../../../../../base/values'); /* jshint ignore:line */
|
|
19
21
|
|
|
20
22
|
var NewFactorList;
|
|
@@ -84,6 +86,7 @@ NewFactorList = function NewFactorList(version, serviceSid, identity) {
|
|
|
84
86
|
* Number of digits for generated TOTP codes
|
|
85
87
|
* @param {new_factor.totp_algorithms} [opts.config.alg] -
|
|
86
88
|
* The algorithm used to derive the TOTP codes
|
|
89
|
+
* @param {object} [opts.metadata] - Metadata of the factor.
|
|
87
90
|
* @param {function} [callback] - Callback to handle processed record
|
|
88
91
|
*
|
|
89
92
|
* @returns {Promise} Resolves to processed NewFactorInstance
|
|
@@ -114,7 +117,8 @@ NewFactorList = function NewFactorList(version, serviceSid, identity) {
|
|
|
114
117
|
'Config.TimeStep': _.get(opts, 'config.timeStep'),
|
|
115
118
|
'Config.Skew': _.get(opts, 'config.skew'),
|
|
116
119
|
'Config.CodeLength': _.get(opts, 'config.codeLength'),
|
|
117
|
-
'Config.Alg': _.get(opts, 'config.alg')
|
|
120
|
+
'Config.Alg': _.get(opts, 'config.alg'),
|
|
121
|
+
'Metadata': serialize.object(_.get(opts, 'metadata'))
|
|
118
122
|
});
|
|
119
123
|
|
|
120
124
|
var promise = this._version.create({uri: this._uri, method: 'POST', data: data});
|
|
@@ -243,13 +247,14 @@ NewFactorPage.prototype[util.inspect.custom] = function inspect(depth, options)
|
|
|
243
247
|
* @property {string} serviceSid - Service Sid.
|
|
244
248
|
* @property {string} entitySid - Entity Sid.
|
|
245
249
|
* @property {string} identity - Unique external identifier of the Entity
|
|
246
|
-
* @property {object} binding -
|
|
250
|
+
* @property {object} binding - Binding of the factor
|
|
247
251
|
* @property {Date} dateCreated - The date this Factor was created
|
|
248
252
|
* @property {Date} dateUpdated - The date this Factor was updated
|
|
249
253
|
* @property {string} friendlyName - A human readable description of this resource.
|
|
250
254
|
* @property {new_factor.factor_statuses} status - The Status of this Factor
|
|
251
255
|
* @property {new_factor.factor_types} factorType - The Type of this Factor
|
|
252
|
-
* @property {object} config -
|
|
256
|
+
* @property {object} config - Configurations for a `factor_type`.
|
|
257
|
+
* @property {object} metadata - Metadata of the factor.
|
|
253
258
|
* @property {string} url - The URL of this resource.
|
|
254
259
|
*
|
|
255
260
|
* @param {V2} version - Version of the resource
|
|
@@ -275,6 +280,7 @@ NewFactorInstance = function NewFactorInstance(version, payload, serviceSid,
|
|
|
275
280
|
this.status = payload.status; // jshint ignore:line
|
|
276
281
|
this.factorType = payload.factor_type; // jshint ignore:line
|
|
277
282
|
this.config = payload.config; // jshint ignore:line
|
|
283
|
+
this.metadata = payload.metadata; // jshint ignore:line
|
|
278
284
|
this.url = payload.url; // jshint ignore:line
|
|
279
285
|
|
|
280
286
|
// Context
|
|
@@ -267,6 +267,8 @@ interface CompositionResource {
|
|
|
267
267
|
sid: string;
|
|
268
268
|
size: number;
|
|
269
269
|
status: CompositionStatus;
|
|
270
|
+
status_callback: string;
|
|
271
|
+
status_callback_method: string;
|
|
270
272
|
trim: boolean;
|
|
271
273
|
url: string;
|
|
272
274
|
video_layout: object;
|
|
@@ -343,6 +345,8 @@ declare class CompositionInstance extends SerializableClass {
|
|
|
343
345
|
sid: string;
|
|
344
346
|
size: number;
|
|
345
347
|
status: CompositionStatus;
|
|
348
|
+
statusCallback: string;
|
|
349
|
+
statusCallbackMethod: string;
|
|
346
350
|
/**
|
|
347
351
|
* Provide a user-friendly representation
|
|
348
352
|
*/
|
|
@@ -529,6 +529,10 @@ CompositionPage.prototype[util.inspect.custom] = function inspect(depth,
|
|
|
529
529
|
* The duration of the composition's media file in seconds
|
|
530
530
|
* @property {string} mediaExternalLocation -
|
|
531
531
|
* The URL of the media file associated with the composition when stored externally
|
|
532
|
+
* @property {string} statusCallback -
|
|
533
|
+
* The URL called to send status information on every composition event.
|
|
534
|
+
* @property {string} statusCallbackMethod -
|
|
535
|
+
* The HTTP method used to call `status_callback`
|
|
532
536
|
* @property {string} url - The absolute URL of the resource
|
|
533
537
|
* @property {string} links -
|
|
534
538
|
* The URL of the media file associated with the composition
|
|
@@ -559,6 +563,8 @@ CompositionInstance = function CompositionInstance(version, payload, sid) {
|
|
|
559
563
|
this.size = deserialize.integer(payload.size); // jshint ignore:line
|
|
560
564
|
this.duration = deserialize.integer(payload.duration); // jshint ignore:line
|
|
561
565
|
this.mediaExternalLocation = payload.media_external_location; // jshint ignore:line
|
|
566
|
+
this.statusCallback = payload.status_callback; // jshint ignore:line
|
|
567
|
+
this.statusCallbackMethod = payload.status_callback_method; // jshint ignore:line
|
|
562
568
|
this.url = payload.url; // jshint ignore:line
|
|
563
569
|
this.links = payload.links; // jshint ignore:line
|
|
564
570
|
|
|
@@ -248,6 +248,8 @@ interface RecordingResource {
|
|
|
248
248
|
size: number;
|
|
249
249
|
source_sid: string;
|
|
250
250
|
status: RecordingStatus;
|
|
251
|
+
status_callback: string;
|
|
252
|
+
status_callback_method: string;
|
|
251
253
|
track_name: string;
|
|
252
254
|
type: RecordingType;
|
|
253
255
|
url: string;
|
|
@@ -321,6 +323,8 @@ declare class RecordingInstance extends SerializableClass {
|
|
|
321
323
|
size: number;
|
|
322
324
|
sourceSid: string;
|
|
323
325
|
status: RecordingStatus;
|
|
326
|
+
statusCallback: string;
|
|
327
|
+
statusCallbackMethod: string;
|
|
324
328
|
/**
|
|
325
329
|
* Provide a user-friendly representation
|
|
326
330
|
*/
|
|
@@ -465,6 +465,10 @@ RecordingPage.prototype[util.inspect.custom] = function inspect(depth, options)
|
|
|
465
465
|
* The number of milliseconds between a point in time that is common to all rooms in a group and when the source room of the recording started
|
|
466
466
|
* @property {string} mediaExternalLocation -
|
|
467
467
|
* The URL of the media file associated with the recording when stored externally
|
|
468
|
+
* @property {string} statusCallback -
|
|
469
|
+
* The URL called to send status information on every recording event.
|
|
470
|
+
* @property {string} statusCallbackMethod -
|
|
471
|
+
* The HTTP method used to call `status_callback`
|
|
468
472
|
* @property {string} links - The URLs of related resources
|
|
469
473
|
*
|
|
470
474
|
* @param {V1} version - Version of the resource
|
|
@@ -491,6 +495,8 @@ RecordingInstance = function RecordingInstance(version, payload, sid) {
|
|
|
491
495
|
this.trackName = payload.track_name; // jshint ignore:line
|
|
492
496
|
this.offset = deserialize.integer(payload.offset); // jshint ignore:line
|
|
493
497
|
this.mediaExternalLocation = payload.media_external_location; // jshint ignore:line
|
|
498
|
+
this.statusCallback = payload.status_callback; // jshint ignore:line
|
|
499
|
+
this.statusCallbackMethod = payload.status_callback_method; // jshint ignore:line
|
|
494
500
|
this.links = payload.links; // jshint ignore:line
|
|
495
501
|
|
|
496
502
|
// Context
|
|
@@ -249,9 +249,9 @@ declare namespace VoiceResponse {
|
|
|
249
249
|
|
|
250
250
|
type RejectReason = 'rejected'|'busy';
|
|
251
251
|
|
|
252
|
-
type SayLanguage = 'arb'|'ca-ES'|'cy-GB'|'da-DK'|'de-DE'|'en-AU'|'en-CA'|'en-GB'|'en-GB-WLS'|'en-IN'|'en-US'|'es-ES'|'es-MX'|'es-US'|'fi-FI'|'fr-CA'|'fr-FR'|'hi-IN'|'is-IS'|'it-IT'|'ja-JP'|'ko-KR'|'nb-NO'|'nl-NL'|'pl-PL'|'pt-BR'|'pt-PT'|'ro-RO'|'ru-RU'|'sv-SE'|'tr-TR'|'zh-CN'|'zh-HK'|'zh-TW';
|
|
252
|
+
type SayLanguage = 'arb'|'ca-ES'|'cy-GB'|'da-DK'|'de-DE'|'en-AU'|'en-CA'|'en-GB'|'en-GB-WLS'|'en-IN'|'en-NZ'|'en-ZA'|'en-US'|'es-ES'|'es-MX'|'es-US'|'fi-FI'|'fr-CA'|'fr-FR'|'hi-IN'|'is-IS'|'it-IT'|'ja-JP'|'ko-KR'|'nb-NO'|'nl-NL'|'pl-PL'|'pt-BR'|'pt-PT'|'ro-RO'|'ru-RU'|'sv-SE'|'tr-TR'|'zh-CN'|'zh-HK'|'zh-TW';
|
|
253
253
|
|
|
254
|
-
type SayVoice = 'man'|'woman'|'alice'|'Polly.Aditi'|'Polly.Amy'|'Polly.Astrid'|'Polly.Bianca'|'Polly.Brian'|'Polly.Camila'|'Polly.Carla'|'Polly.Carmen'|'Polly.Celine'|'Polly.Chantal'|'Polly.Conchita'|'Polly.Cristiano'|'Polly.Dora'|'Polly.Emma'|'Polly.Enrique'|'Polly.Ewa'|'Polly.Filiz'|'Polly.Geraint'|'Polly.Giorgio'|'Polly.Gwyneth'|'Polly.Hans'|'Polly.Ines'|'Polly.Ivy'|'Polly.Jacek'|'Polly.Jan'|'Polly.Joanna'|'Polly.Joey'|'Polly.Justin'|'Polly.Karl'|'Polly.Kendra'|'Polly.Kimberly'|'Polly.Lea'|'Polly.Liv'|'Polly.Lotte'|'Polly.Lucia'|'Polly.Lupe'|'Polly.Mads'|'Polly.Maja'|'Polly.Marlene'|'Polly.Mathieu'|'Polly.Matthew'|'Polly.Maxim'|'Polly.Mia'|'Polly.Miguel'|'Polly.Mizuki'|'Polly.Naja'|'Polly.Nicole'|'Polly.Penelope'|'Polly.Raveena'|'Polly.Ricardo'|'Polly.Ruben'|'Polly.Russell'|'Polly.Salli'|'Polly.Seoyeon'|'Polly.Takumi'|'Polly.Tatyana'|'Polly.Vicki'|'Polly.Vitoria'|'Polly.Zeina'|'Polly.Zhiyu'|'Polly.Amy-Neural'|'Polly.Emma-Neural'|'Polly.Brian-Neural'|'Polly.Salli-Neural'|'Polly.Ivy-Neural'|'Polly.Joanna-Neural'|'Polly.Kendra-Neural'|'Polly.Kimberly-Neural'|'Polly.Joey-Neural'|'Polly.Justin-Neural'|'Polly.Matthew-Neural'|'Polly.Camila-Neural'|'Polly.Lupe-Neural'|'Polly.Olivia-Neural'|'Polly.Kevin-Neural';
|
|
254
|
+
type SayVoice = 'man'|'woman'|'alice'|'Polly.Aditi'|'Polly.Amy'|'Polly.Astrid'|'Polly.Bianca'|'Polly.Brian'|'Polly.Camila'|'Polly.Carla'|'Polly.Carmen'|'Polly.Celine'|'Polly.Chantal'|'Polly.Conchita'|'Polly.Cristiano'|'Polly.Dora'|'Polly.Emma'|'Polly.Enrique'|'Polly.Ewa'|'Polly.Filiz'|'Polly.Geraint'|'Polly.Giorgio'|'Polly.Gwyneth'|'Polly.Hans'|'Polly.Ines'|'Polly.Ivy'|'Polly.Jacek'|'Polly.Jan'|'Polly.Joanna'|'Polly.Joey'|'Polly.Justin'|'Polly.Karl'|'Polly.Kendra'|'Polly.Kimberly'|'Polly.Lea'|'Polly.Liv'|'Polly.Lotte'|'Polly.Lucia'|'Polly.Lupe'|'Polly.Mads'|'Polly.Maja'|'Polly.Marlene'|'Polly.Mathieu'|'Polly.Matthew'|'Polly.Maxim'|'Polly.Mia'|'Polly.Miguel'|'Polly.Mizuki'|'Polly.Naja'|'Polly.Nicole'|'Polly.Penelope'|'Polly.Raveena'|'Polly.Ricardo'|'Polly.Ruben'|'Polly.Russell'|'Polly.Salli'|'Polly.Seoyeon'|'Polly.Takumi'|'Polly.Tatyana'|'Polly.Vicki'|'Polly.Vitoria'|'Polly.Zeina'|'Polly.Zhiyu'|'Polly.Amy-Neural'|'Polly.Emma-Neural'|'Polly.Brian-Neural'|'Polly.Salli-Neural'|'Polly.Ivy-Neural'|'Polly.Joanna-Neural'|'Polly.Kendra-Neural'|'Polly.Kimberly-Neural'|'Polly.Joey-Neural'|'Polly.Justin-Neural'|'Polly.Matthew-Neural'|'Polly.Camila-Neural'|'Polly.Lupe-Neural'|'Polly.Olivia-Neural'|'Polly.Kevin-Neural'|'Polly.Aria-Neural'|'Polly.Ayanda-Neural'|'Polly.Gabrielle-Neural'|'Polly.Lea-Neural'|'Polly.Vicki-Neural'|'Polly.Bianca-Neural'|'Polly.Takumi-Neural'|'Polly.Seoyeon-Neural'|'Polly.Lucia-Neural';
|
|
255
255
|
|
|
256
256
|
type SipEvent = 'initiated'|'ringing'|'answered'|'completed';
|
|
257
257
|
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "twilio",
|
|
3
3
|
"description": "A Twilio helper library",
|
|
4
|
-
"version": "3.
|
|
4
|
+
"version": "3.76.0",
|
|
5
5
|
"author": "API Team <api@twilio.com>",
|
|
6
6
|
"contributors": [
|
|
7
7
|
{
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"url": "https://github.com/twilio/twilio-node.git"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"axios": "^0.
|
|
23
|
+
"axios": "^0.26.1",
|
|
24
24
|
"dayjs": "^1.8.29",
|
|
25
25
|
"https-proxy-agent": "^5.0.0",
|
|
26
26
|
"jsonwebtoken": "^8.5.1",
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"qs": "^6.9.4",
|
|
30
30
|
"rootpath": "^0.1.2",
|
|
31
31
|
"scmp": "^2.1.0",
|
|
32
|
-
"url-parse": "^1.5.
|
|
32
|
+
"url-parse": "^1.5.9",
|
|
33
33
|
"xmlbuilder": "^13.0.2"
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
@@ -1,342 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This code was generated by
|
|
3
|
-
* \ / _ _ _| _ _
|
|
4
|
-
* | (_)\/(_)(_|\/| |(/_ v1.0.0
|
|
5
|
-
* / /
|
|
6
|
-
*/
|
|
7
|
-
|
|
8
|
-
import Page = require('../../../base/Page');
|
|
9
|
-
import Response = require('../../../http/response');
|
|
10
|
-
import V1 = require('../V1');
|
|
11
|
-
import { SerializableClass } from '../../../interfaces';
|
|
12
|
-
|
|
13
|
-
type CommandDirection = 'to_sim'|'from_sim';
|
|
14
|
-
|
|
15
|
-
type CommandStatus = 'queued'|'sent'|'delivered'|'received'|'failed';
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* Initialize the CommandList
|
|
19
|
-
*
|
|
20
|
-
* PLEASE NOTE that this class contains beta products that are subject to change.
|
|
21
|
-
* Use them with caution.
|
|
22
|
-
*
|
|
23
|
-
* @param version - Version of the resource
|
|
24
|
-
*/
|
|
25
|
-
declare function CommandList(version: V1): CommandListInstance;
|
|
26
|
-
|
|
27
|
-
interface CommandListInstance {
|
|
28
|
-
/**
|
|
29
|
-
* @param sid - sid of instance
|
|
30
|
-
*/
|
|
31
|
-
(sid: string): CommandContext;
|
|
32
|
-
/**
|
|
33
|
-
* create a CommandInstance
|
|
34
|
-
*
|
|
35
|
-
* @param opts - Options for request
|
|
36
|
-
* @param callback - Callback to handle processed record
|
|
37
|
-
*/
|
|
38
|
-
create(opts: CommandListInstanceCreateOptions, callback?: (error: Error | null, item: CommandInstance) => any): Promise<CommandInstance>;
|
|
39
|
-
/**
|
|
40
|
-
* Streams CommandInstance records from the API.
|
|
41
|
-
*
|
|
42
|
-
* This operation lazily loads records as efficiently as possible until the limit
|
|
43
|
-
* is reached.
|
|
44
|
-
*
|
|
45
|
-
* The results are passed into the callback function, so this operation is memory
|
|
46
|
-
* efficient.
|
|
47
|
-
*
|
|
48
|
-
* If a function is passed as the first argument, it will be used as the callback
|
|
49
|
-
* function.
|
|
50
|
-
*
|
|
51
|
-
* @param callback - Function to process each record
|
|
52
|
-
*/
|
|
53
|
-
each(callback?: (item: CommandInstance, done: (err?: Error) => void) => void): void;
|
|
54
|
-
/**
|
|
55
|
-
* Streams CommandInstance records from the API.
|
|
56
|
-
*
|
|
57
|
-
* This operation lazily loads records as efficiently as possible until the limit
|
|
58
|
-
* is reached.
|
|
59
|
-
*
|
|
60
|
-
* The results are passed into the callback function, so this operation is memory
|
|
61
|
-
* efficient.
|
|
62
|
-
*
|
|
63
|
-
* If a function is passed as the first argument, it will be used as the callback
|
|
64
|
-
* function.
|
|
65
|
-
*
|
|
66
|
-
* @param opts - Options for request
|
|
67
|
-
* @param callback - Function to process each record
|
|
68
|
-
*/
|
|
69
|
-
each(opts?: CommandListInstanceEachOptions, callback?: (item: CommandInstance, done: (err?: Error) => void) => void): void;
|
|
70
|
-
/**
|
|
71
|
-
* Constructs a command
|
|
72
|
-
*
|
|
73
|
-
* @param sid - The SID that identifies the resource to fetch
|
|
74
|
-
*/
|
|
75
|
-
get(sid: string): CommandContext;
|
|
76
|
-
/**
|
|
77
|
-
* Retrieve a single target page of CommandInstance records from the API.
|
|
78
|
-
*
|
|
79
|
-
* The request is executed immediately.
|
|
80
|
-
*
|
|
81
|
-
* If a function is passed as the first argument, it will be used as the callback
|
|
82
|
-
* function.
|
|
83
|
-
*
|
|
84
|
-
* @param callback - Callback to handle list of records
|
|
85
|
-
*/
|
|
86
|
-
getPage(callback?: (error: Error | null, items: CommandPage) => any): Promise<CommandPage>;
|
|
87
|
-
/**
|
|
88
|
-
* Retrieve a single target page of CommandInstance records from the API.
|
|
89
|
-
*
|
|
90
|
-
* The request is executed immediately.
|
|
91
|
-
*
|
|
92
|
-
* If a function is passed as the first argument, it will be used as the callback
|
|
93
|
-
* function.
|
|
94
|
-
*
|
|
95
|
-
* @param targetUrl - API-generated URL for the requested results page
|
|
96
|
-
* @param callback - Callback to handle list of records
|
|
97
|
-
*/
|
|
98
|
-
getPage(targetUrl?: string, callback?: (error: Error | null, items: CommandPage) => any): Promise<CommandPage>;
|
|
99
|
-
/**
|
|
100
|
-
* Lists CommandInstance records from the API as a list.
|
|
101
|
-
*
|
|
102
|
-
* If a function is passed as the first argument, it will be used as the callback
|
|
103
|
-
* function.
|
|
104
|
-
*
|
|
105
|
-
* @param callback - Callback to handle list of records
|
|
106
|
-
*/
|
|
107
|
-
list(callback?: (error: Error | null, items: CommandInstance[]) => any): Promise<CommandInstance[]>;
|
|
108
|
-
/**
|
|
109
|
-
* Lists CommandInstance records from the API as a list.
|
|
110
|
-
*
|
|
111
|
-
* If a function is passed as the first argument, it will be used as the callback
|
|
112
|
-
* function.
|
|
113
|
-
*
|
|
114
|
-
* @param opts - Options for request
|
|
115
|
-
* @param callback - Callback to handle list of records
|
|
116
|
-
*/
|
|
117
|
-
list(opts?: CommandListInstanceOptions, callback?: (error: Error | null, items: CommandInstance[]) => any): Promise<CommandInstance[]>;
|
|
118
|
-
/**
|
|
119
|
-
* Retrieve a single page of CommandInstance records from the API.
|
|
120
|
-
*
|
|
121
|
-
* The request is executed immediately.
|
|
122
|
-
*
|
|
123
|
-
* If a function is passed as the first argument, it will be used as the callback
|
|
124
|
-
* function.
|
|
125
|
-
*
|
|
126
|
-
* @param callback - Callback to handle list of records
|
|
127
|
-
*/
|
|
128
|
-
page(callback?: (error: Error | null, items: CommandPage) => any): Promise<CommandPage>;
|
|
129
|
-
/**
|
|
130
|
-
* Retrieve a single page of CommandInstance records from the API.
|
|
131
|
-
*
|
|
132
|
-
* The request is executed immediately.
|
|
133
|
-
*
|
|
134
|
-
* If a function is passed as the first argument, it will be used as the callback
|
|
135
|
-
* function.
|
|
136
|
-
*
|
|
137
|
-
* @param opts - Options for request
|
|
138
|
-
* @param callback - Callback to handle list of records
|
|
139
|
-
*/
|
|
140
|
-
page(opts?: CommandListInstancePageOptions, callback?: (error: Error | null, items: CommandPage) => any): Promise<CommandPage>;
|
|
141
|
-
/**
|
|
142
|
-
* Provide a user-friendly representation
|
|
143
|
-
*/
|
|
144
|
-
toJSON(): any;
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
/**
|
|
148
|
-
* Options to pass to create
|
|
149
|
-
*
|
|
150
|
-
* @property callbackMethod - The HTTP method we should use to call callback_url
|
|
151
|
-
* @property callbackUrl - The URL we should call after we have sent the command
|
|
152
|
-
* @property command - The message body of the command
|
|
153
|
-
* @property sim - The sid or unique_name of the SIM to send the Command to
|
|
154
|
-
*/
|
|
155
|
-
interface CommandListInstanceCreateOptions {
|
|
156
|
-
callbackMethod?: string;
|
|
157
|
-
callbackUrl?: string;
|
|
158
|
-
command: string;
|
|
159
|
-
sim: string;
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
/**
|
|
163
|
-
* Options to pass to each
|
|
164
|
-
*
|
|
165
|
-
* @property callback -
|
|
166
|
-
* Function to process each record. If this and a positional
|
|
167
|
-
* callback are passed, this one will be used
|
|
168
|
-
* @property direction - The direction of the Command
|
|
169
|
-
* @property done - Function to be called upon completion of streaming
|
|
170
|
-
* @property limit -
|
|
171
|
-
* Upper limit for the number of records to return.
|
|
172
|
-
* each() guarantees never to return more than limit.
|
|
173
|
-
* Default is no limit
|
|
174
|
-
* @property pageSize -
|
|
175
|
-
* Number of records to fetch per request,
|
|
176
|
-
* when not set will use the default value of 50 records.
|
|
177
|
-
* If no pageSize is defined but a limit is defined,
|
|
178
|
-
* each() will attempt to read the limit with the most efficient
|
|
179
|
-
* page size, i.e. min(limit, 1000)
|
|
180
|
-
* @property sim - The SID or unique name of the Sim that Command was sent to or from.
|
|
181
|
-
* @property status - The status of the Command
|
|
182
|
-
*/
|
|
183
|
-
interface CommandListInstanceEachOptions {
|
|
184
|
-
callback?: (item: CommandInstance, done: (err?: Error) => void) => void;
|
|
185
|
-
direction?: CommandDirection;
|
|
186
|
-
done?: Function;
|
|
187
|
-
limit?: number;
|
|
188
|
-
pageSize?: number;
|
|
189
|
-
sim?: string;
|
|
190
|
-
status?: CommandStatus;
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
/**
|
|
194
|
-
* Options to pass to list
|
|
195
|
-
*
|
|
196
|
-
* @property direction - The direction of the Command
|
|
197
|
-
* @property limit -
|
|
198
|
-
* Upper limit for the number of records to return.
|
|
199
|
-
* list() guarantees never to return more than limit.
|
|
200
|
-
* Default is no limit
|
|
201
|
-
* @property pageSize -
|
|
202
|
-
* Number of records to fetch per request,
|
|
203
|
-
* when not set will use the default value of 50 records.
|
|
204
|
-
* If no page_size is defined but a limit is defined,
|
|
205
|
-
* list() will attempt to read the limit with the most
|
|
206
|
-
* efficient page size, i.e. min(limit, 1000)
|
|
207
|
-
* @property sim - The SID or unique name of the Sim that Command was sent to or from.
|
|
208
|
-
* @property status - The status of the Command
|
|
209
|
-
*/
|
|
210
|
-
interface CommandListInstanceOptions {
|
|
211
|
-
direction?: CommandDirection;
|
|
212
|
-
limit?: number;
|
|
213
|
-
pageSize?: number;
|
|
214
|
-
sim?: string;
|
|
215
|
-
status?: CommandStatus;
|
|
216
|
-
}
|
|
217
|
-
|
|
218
|
-
/**
|
|
219
|
-
* Options to pass to page
|
|
220
|
-
*
|
|
221
|
-
* @property direction - The direction of the Command
|
|
222
|
-
* @property pageNumber - Page Number, this value is simply for client state
|
|
223
|
-
* @property pageSize - Number of records to return, defaults to 50
|
|
224
|
-
* @property pageToken - PageToken provided by the API
|
|
225
|
-
* @property sim - The SID or unique name of the Sim that Command was sent to or from.
|
|
226
|
-
* @property status - The status of the Command
|
|
227
|
-
*/
|
|
228
|
-
interface CommandListInstancePageOptions {
|
|
229
|
-
direction?: CommandDirection;
|
|
230
|
-
pageNumber?: number;
|
|
231
|
-
pageSize?: number;
|
|
232
|
-
pageToken?: string;
|
|
233
|
-
sim?: string;
|
|
234
|
-
status?: CommandStatus;
|
|
235
|
-
}
|
|
236
|
-
|
|
237
|
-
interface CommandPayload extends CommandResource, Page.TwilioResponsePayload {
|
|
238
|
-
}
|
|
239
|
-
|
|
240
|
-
interface CommandResource {
|
|
241
|
-
account_sid: string;
|
|
242
|
-
command: string;
|
|
243
|
-
date_created: Date;
|
|
244
|
-
date_updated: Date;
|
|
245
|
-
direction: CommandDirection;
|
|
246
|
-
sid: string;
|
|
247
|
-
sim_sid: string;
|
|
248
|
-
status: CommandStatus;
|
|
249
|
-
url: string;
|
|
250
|
-
}
|
|
251
|
-
|
|
252
|
-
interface CommandSolution {
|
|
253
|
-
}
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
declare class CommandContext {
|
|
257
|
-
/**
|
|
258
|
-
* Initialize the CommandContext
|
|
259
|
-
*
|
|
260
|
-
* PLEASE NOTE that this class contains beta products that are subject to change.
|
|
261
|
-
* Use them with caution.
|
|
262
|
-
*
|
|
263
|
-
* @param version - Version of the resource
|
|
264
|
-
* @param sid - The SID that identifies the resource to fetch
|
|
265
|
-
*/
|
|
266
|
-
constructor(version: V1, sid: string);
|
|
267
|
-
|
|
268
|
-
/**
|
|
269
|
-
* fetch a CommandInstance
|
|
270
|
-
*
|
|
271
|
-
* @param callback - Callback to handle processed record
|
|
272
|
-
*/
|
|
273
|
-
fetch(callback?: (error: Error | null, items: CommandInstance) => any): Promise<CommandInstance>;
|
|
274
|
-
/**
|
|
275
|
-
* Provide a user-friendly representation
|
|
276
|
-
*/
|
|
277
|
-
toJSON(): any;
|
|
278
|
-
}
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
declare class CommandInstance extends SerializableClass {
|
|
282
|
-
/**
|
|
283
|
-
* Initialize the CommandContext
|
|
284
|
-
*
|
|
285
|
-
* PLEASE NOTE that this class contains beta products that are subject to change.
|
|
286
|
-
* Use them with caution.
|
|
287
|
-
*
|
|
288
|
-
* @param version - Version of the resource
|
|
289
|
-
* @param payload - The instance payload
|
|
290
|
-
* @param sid - The SID that identifies the resource to fetch
|
|
291
|
-
*/
|
|
292
|
-
constructor(version: V1, payload: CommandPayload, sid: string);
|
|
293
|
-
|
|
294
|
-
private _proxy: CommandContext;
|
|
295
|
-
accountSid: string;
|
|
296
|
-
command: string;
|
|
297
|
-
dateCreated: Date;
|
|
298
|
-
dateUpdated: Date;
|
|
299
|
-
direction: CommandDirection;
|
|
300
|
-
/**
|
|
301
|
-
* fetch a CommandInstance
|
|
302
|
-
*
|
|
303
|
-
* @param callback - Callback to handle processed record
|
|
304
|
-
*/
|
|
305
|
-
fetch(callback?: (error: Error | null, items: CommandInstance) => any): Promise<CommandInstance>;
|
|
306
|
-
sid: string;
|
|
307
|
-
simSid: string;
|
|
308
|
-
status: CommandStatus;
|
|
309
|
-
/**
|
|
310
|
-
* Provide a user-friendly representation
|
|
311
|
-
*/
|
|
312
|
-
toJSON(): any;
|
|
313
|
-
url: string;
|
|
314
|
-
}
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
declare class CommandPage extends Page<V1, CommandPayload, CommandResource, CommandInstance> {
|
|
318
|
-
/**
|
|
319
|
-
* Initialize the CommandPage
|
|
320
|
-
*
|
|
321
|
-
* PLEASE NOTE that this class contains beta products that are subject to change.
|
|
322
|
-
* Use them with caution.
|
|
323
|
-
*
|
|
324
|
-
* @param version - Version of the resource
|
|
325
|
-
* @param response - Response from the API
|
|
326
|
-
* @param solution - Path solution
|
|
327
|
-
*/
|
|
328
|
-
constructor(version: V1, response: Response<string>, solution: CommandSolution);
|
|
329
|
-
|
|
330
|
-
/**
|
|
331
|
-
* Build an instance of CommandInstance
|
|
332
|
-
*
|
|
333
|
-
* @param payload - Payload response from the API
|
|
334
|
-
*/
|
|
335
|
-
getInstance(payload: CommandPayload): CommandInstance;
|
|
336
|
-
/**
|
|
337
|
-
* Provide a user-friendly representation
|
|
338
|
-
*/
|
|
339
|
-
toJSON(): any;
|
|
340
|
-
}
|
|
341
|
-
|
|
342
|
-
export { CommandContext, CommandDirection, CommandInstance, CommandList, CommandListInstance, CommandListInstanceCreateOptions, CommandListInstanceEachOptions, CommandListInstanceOptions, CommandListInstancePageOptions, CommandPage, CommandPayload, CommandResource, CommandSolution, CommandStatus }
|