twilio 3.76.1 → 3.77.2
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/Twilio.d.ts +1 -3
- package/lib/rest/Twilio.js +3 -17
- package/lib/rest/api/v2010/account/message.d.ts +1 -1
- package/lib/rest/api/v2010/account/message.js +1 -1
- package/lib/rest/api/v2010/account/recording.d.ts +2 -0
- package/lib/rest/api/v2010/account/recording.js +2 -0
- package/lib/rest/conversations/v1/addressConfiguration.d.ts +6 -0
- package/lib/rest/conversations/v1/addressConfiguration.js +4 -0
- package/lib/rest/flexApi/v1/interaction/interactionChannel/interactionChannelInvite.d.ts +5 -5
- package/lib/rest/flexApi/v1/interaction/interactionChannel/interactionChannelInvite.js +10 -9
- package/lib/rest/flexApi/v1/interaction/interactionChannel.d.ts +8 -8
- package/lib/rest/flexApi/v1/interaction/interactionChannel.js +12 -13
- package/lib/rest/flexApi/v1/interaction.js +2 -1
- package/lib/rest/supersim/v1/esimProfile.d.ts +8 -2
- package/lib/rest/supersim/v1/esimProfile.js +9 -10
- package/lib/rest/supersim/v1/usageRecord.d.ts +4 -0
- package/lib/rest/supersim/v1/usageRecord.js +6 -0
- package/lib/rest/verify/v2/service/verification.d.ts +3 -1
- package/lib/rest/verify/v2/service/verification.js +3 -0
- package/lib/rest/verify/v2/service/verificationCheck.d.ts +1 -1
- package/lib/rest/verify/v2/service.d.ts +2 -2
- package/lib/rest/verify/v2/service.js +3 -3
- package/lib/rest/video/v1/room.d.ts +4 -0
- package/lib/rest/video/v1/room.js +5 -1
- package/package.json +1 -1
- package/lib/rest/Fax.d.ts +0 -26
- package/lib/rest/Fax.js +0 -54
- package/lib/rest/fax/V1.d.ts +0 -25
- package/lib/rest/fax/V1.js +0 -46
- package/lib/rest/fax/v1/fax/faxMedia.d.ts +0 -310
- package/lib/rest/fax/v1/fax/faxMedia.js +0 -633
- package/lib/rest/fax/v1/fax.d.ts +0 -367
- package/lib/rest/fax/v1/fax.js +0 -700
package/lib/rest/Twilio.d.ts
CHANGED
|
@@ -12,7 +12,6 @@ import Bulkexports = require('./Bulkexports');
|
|
|
12
12
|
import Chat = require('./Chat');
|
|
13
13
|
import Conversations = require('./Conversations');
|
|
14
14
|
import Events = require('./Events');
|
|
15
|
-
import Fax = require('./Fax');
|
|
16
15
|
import FlexApi = require('./FlexApi');
|
|
17
16
|
import FrontlineApi = require('./FrontlineApi');
|
|
18
17
|
import Insights = require('./Insights');
|
|
@@ -64,7 +63,6 @@ declare class Twilio {
|
|
|
64
63
|
connectApps: (typeof Api.prototype.account.connectApps);
|
|
65
64
|
conversations: Conversations;
|
|
66
65
|
events: Events;
|
|
67
|
-
fax: Fax;
|
|
68
66
|
flexApi: FlexApi;
|
|
69
67
|
frontlineApi: FrontlineApi;
|
|
70
68
|
httpClient?: RequestClient;
|
|
@@ -157,7 +155,7 @@ declare namespace Twilio {
|
|
|
157
155
|
* @property edge - Twilio edge to use. Defaults to none
|
|
158
156
|
* @property env - The environment object. Defaults to process.env
|
|
159
157
|
* @property httpClient - The client used for http requests. Defaults to RequestClient
|
|
160
|
-
* @property lazyLoading - Enable lazy loading, loading time will decrease if enabled
|
|
158
|
+
* @property lazyLoading - Enable lazy loading, loading time will decrease if enabled. Defaults to true
|
|
161
159
|
* @property logLevel - Debug logs will be shown. Defaults to none
|
|
162
160
|
* @property region - Twilio region to use. Defaults to us1 if edge defined
|
|
163
161
|
* @property userAgentExtensions - Additions to the user agent string
|
package/lib/rest/Twilio.js
CHANGED
|
@@ -28,7 +28,6 @@ var RestException = require('../base/RestException'); /* jshint ignore:line */
|
|
|
28
28
|
* @property {Twilio.Chat} chat - chat domain
|
|
29
29
|
* @property {Twilio.Conversations} conversations - conversations domain
|
|
30
30
|
* @property {Twilio.Events} events - events domain
|
|
31
|
-
* @property {Twilio.Fax} fax - fax domain
|
|
32
31
|
* @property {Twilio.FlexApi} flexApi - flex_api domain
|
|
33
32
|
* @property {Twilio.FrontlineApi} frontlineApi - frontline_api domain
|
|
34
33
|
* @property {Twilio.Insights} insights - insights domain
|
|
@@ -111,7 +110,7 @@ var RestException = require('../base/RestException'); /* jshint ignore:line */
|
|
|
111
110
|
* @param {string} [opts.region] -
|
|
112
111
|
* Twilio region to use. Defaults to us1 if edge defined
|
|
113
112
|
* @param {boolean} [opts.lazyLoading] -
|
|
114
|
-
* Enable lazy loading, loading time will decrease if enabled
|
|
113
|
+
* Enable lazy loading, loading time will decrease if enabled. Defaults to true
|
|
115
114
|
* @param {string} [opts.logLevel] - Debug logs will be shown. Defaults to none
|
|
116
115
|
* @param {string[]} [opts.userAgentExtensions] -
|
|
117
116
|
* Additions to the user agent string
|
|
@@ -127,7 +126,7 @@ function Twilio(username, password, opts) {
|
|
|
127
126
|
this.password = password || env.TWILIO_AUTH_TOKEN;
|
|
128
127
|
this.accountSid = opts.accountSid || this.username;
|
|
129
128
|
this._httpClient = opts.httpClient;
|
|
130
|
-
if (
|
|
129
|
+
if (opts.lazyLoading == false) {
|
|
131
130
|
this._httpClient = this.httpClient;
|
|
132
131
|
}
|
|
133
132
|
this.edge = opts.edge || env.TWILIO_EDGE;
|
|
@@ -154,7 +153,6 @@ function Twilio(username, password, opts) {
|
|
|
154
153
|
this._chat = undefined;
|
|
155
154
|
this._conversations = undefined;
|
|
156
155
|
this._events = undefined;
|
|
157
|
-
this._fax = undefined;
|
|
158
156
|
this._flexApi = undefined;
|
|
159
157
|
this._frontlineApi = undefined;
|
|
160
158
|
this._insights = undefined;
|
|
@@ -181,14 +179,13 @@ function Twilio(username, password, opts) {
|
|
|
181
179
|
this._supersim = undefined;
|
|
182
180
|
this._bulkexports = undefined;
|
|
183
181
|
|
|
184
|
-
if (
|
|
182
|
+
if (opts.lazyLoading == false) {
|
|
185
183
|
this.accounts;
|
|
186
184
|
this.api;
|
|
187
185
|
this.autopilot;
|
|
188
186
|
this.chat;
|
|
189
187
|
this.conversations;
|
|
190
188
|
this.events;
|
|
191
|
-
this.fax;
|
|
192
189
|
this.flexApi;
|
|
193
190
|
this.frontlineApi;
|
|
194
191
|
this.insights;
|
|
@@ -428,17 +425,6 @@ Object.defineProperty(Twilio.prototype,
|
|
|
428
425
|
}
|
|
429
426
|
});
|
|
430
427
|
|
|
431
|
-
Object.defineProperty(Twilio.prototype,
|
|
432
|
-
'fax', {
|
|
433
|
-
get: function() {
|
|
434
|
-
if (!this._fax) {
|
|
435
|
-
var Fax = require('./Fax'); /* jshint ignore:line */
|
|
436
|
-
this._fax = new Fax(this);
|
|
437
|
-
}
|
|
438
|
-
return this._fax;
|
|
439
|
-
}
|
|
440
|
-
});
|
|
441
|
-
|
|
442
428
|
Object.defineProperty(Twilio.prototype,
|
|
443
429
|
'flexApi', {
|
|
444
430
|
get: function() {
|
|
@@ -183,7 +183,7 @@ interface MessageListInstance {
|
|
|
183
183
|
* @property persistentAction - Rich actions for Channels Messages.
|
|
184
184
|
* @property provideFeedback - Whether to confirm delivery of the message
|
|
185
185
|
* @property scheduleType - Pass the value `fixed` to schedule a message at a fixed time.
|
|
186
|
-
* @property sendAsMms - If set to True, Twilio will deliver the message as a single MMS message, regardless of the presence of media
|
|
186
|
+
* @property sendAsMms - If set to True, Twilio will deliver the message as a single MMS message, regardless of the presence of media.
|
|
187
187
|
* @property sendAt - The time that Twilio will send the message. Must be in ISO 8601 format.
|
|
188
188
|
* @property smartEncoded - Whether to detect Unicode characters that have a similar GSM-7 character and replace them
|
|
189
189
|
* @property statusCallback - The URL we should call to send status information to your application
|
|
@@ -88,7 +88,7 @@ MessageList = function MessageList(version, accountSid) {
|
|
|
88
88
|
* @param {Date} [opts.sendAt] -
|
|
89
89
|
* The time that Twilio will send the message. Must be in ISO 8601 format.
|
|
90
90
|
* @param {boolean} [opts.sendAsMms] -
|
|
91
|
-
* If set to True, Twilio will deliver the message as a single MMS message, regardless of the presence of media
|
|
91
|
+
* If set to True, Twilio will deliver the message as a single MMS message, regardless of the presence of media.
|
|
92
92
|
* @param {string} [opts.from] - The phone number that initiated the message
|
|
93
93
|
* @param {string} [opts.messagingServiceSid] -
|
|
94
94
|
* The SID of the Messaging Service you want to associate with the message.
|
|
@@ -255,6 +255,7 @@ interface RecordingResource {
|
|
|
255
255
|
duration: string;
|
|
256
256
|
encryption_details: object;
|
|
257
257
|
error_code: number;
|
|
258
|
+
media_url: string;
|
|
258
259
|
price: string;
|
|
259
260
|
price_unit: string;
|
|
260
261
|
sid: string;
|
|
@@ -347,6 +348,7 @@ declare class RecordingInstance extends SerializableClass {
|
|
|
347
348
|
* @param callback - Callback to handle processed record
|
|
348
349
|
*/
|
|
349
350
|
fetch(opts?: RecordingInstanceFetchOptions, callback?: (error: Error | null, items: RecordingInstance) => any): Promise<RecordingInstance>;
|
|
351
|
+
mediaUrl: string;
|
|
350
352
|
price: string;
|
|
351
353
|
priceUnit: string;
|
|
352
354
|
/**
|
|
@@ -472,6 +472,7 @@ RecordingPage.prototype[util.inspect.custom] = function inspect(depth, options)
|
|
|
472
472
|
* @property {object} encryptionDetails - How to decrypt the recording.
|
|
473
473
|
* @property {string} subresourceUris -
|
|
474
474
|
* A list of related resources identified by their relative URIs
|
|
475
|
+
* @property {string} mediaUrl - The URL of the media file.
|
|
475
476
|
*
|
|
476
477
|
* @param {V2010} version - Version of the resource
|
|
477
478
|
* @param {RecordingPayload} payload - The instance payload
|
|
@@ -502,6 +503,7 @@ RecordingInstance = function RecordingInstance(version, payload, accountSid,
|
|
|
502
503
|
this.uri = payload.uri; // jshint ignore:line
|
|
503
504
|
this.encryptionDetails = payload.encryption_details; // jshint ignore:line
|
|
504
505
|
this.subresourceUris = payload.subresource_uris; // jshint ignore:line
|
|
506
|
+
this.mediaUrl = payload.media_url; // jshint ignore:line
|
|
505
507
|
|
|
506
508
|
// Context
|
|
507
509
|
this._context = undefined;
|
|
@@ -220,12 +220,14 @@ interface AddressConfigurationListInstanceCreateOptions {
|
|
|
220
220
|
* If no pageSize is defined but a limit is defined,
|
|
221
221
|
* each() will attempt to read the limit with the most efficient
|
|
222
222
|
* page size, i.e. min(limit, 1000)
|
|
223
|
+
* @property type - The type of address configuration.
|
|
223
224
|
*/
|
|
224
225
|
interface AddressConfigurationListInstanceEachOptions {
|
|
225
226
|
callback?: (item: AddressConfigurationInstance, done: (err?: Error) => void) => void;
|
|
226
227
|
done?: Function;
|
|
227
228
|
limit?: number;
|
|
228
229
|
pageSize?: number;
|
|
230
|
+
type?: string;
|
|
229
231
|
}
|
|
230
232
|
|
|
231
233
|
/**
|
|
@@ -241,10 +243,12 @@ interface AddressConfigurationListInstanceEachOptions {
|
|
|
241
243
|
* If no page_size is defined but a limit is defined,
|
|
242
244
|
* list() will attempt to read the limit with the most
|
|
243
245
|
* efficient page size, i.e. min(limit, 1000)
|
|
246
|
+
* @property type - The type of address configuration.
|
|
244
247
|
*/
|
|
245
248
|
interface AddressConfigurationListInstanceOptions {
|
|
246
249
|
limit?: number;
|
|
247
250
|
pageSize?: number;
|
|
251
|
+
type?: string;
|
|
248
252
|
}
|
|
249
253
|
|
|
250
254
|
/**
|
|
@@ -253,11 +257,13 @@ interface AddressConfigurationListInstanceOptions {
|
|
|
253
257
|
* @property pageNumber - Page Number, this value is simply for client state
|
|
254
258
|
* @property pageSize - Number of records to return, defaults to 50
|
|
255
259
|
* @property pageToken - PageToken provided by the API
|
|
260
|
+
* @property type - The type of address configuration.
|
|
256
261
|
*/
|
|
257
262
|
interface AddressConfigurationListInstancePageOptions {
|
|
258
263
|
pageNumber?: number;
|
|
259
264
|
pageSize?: number;
|
|
260
265
|
pageToken?: string;
|
|
266
|
+
type?: string;
|
|
261
267
|
}
|
|
262
268
|
|
|
263
269
|
interface AddressConfigurationPayload extends AddressConfigurationResource, Page.TwilioResponsePayload {
|
|
@@ -68,6 +68,7 @@ AddressConfigurationList = function AddressConfigurationList(version) {
|
|
|
68
68
|
* @memberof Twilio.Conversations.V1.AddressConfigurationList#
|
|
69
69
|
*
|
|
70
70
|
* @param {object} [opts] - Options for request
|
|
71
|
+
* @param {string} [opts.type] - The type of address configuration.
|
|
71
72
|
* @param {number} [opts.limit] -
|
|
72
73
|
* Upper limit for the number of records to return.
|
|
73
74
|
* each() guarantees never to return more than limit.
|
|
@@ -157,6 +158,7 @@ AddressConfigurationList = function AddressConfigurationList(version) {
|
|
|
157
158
|
* @memberof Twilio.Conversations.V1.AddressConfigurationList#
|
|
158
159
|
*
|
|
159
160
|
* @param {object} [opts] - Options for request
|
|
161
|
+
* @param {string} [opts.type] - The type of address configuration.
|
|
160
162
|
* @param {number} [opts.limit] -
|
|
161
163
|
* Upper limit for the number of records to return.
|
|
162
164
|
* list() guarantees never to return more than limit.
|
|
@@ -217,6 +219,7 @@ AddressConfigurationList = function AddressConfigurationList(version) {
|
|
|
217
219
|
* @memberof Twilio.Conversations.V1.AddressConfigurationList#
|
|
218
220
|
*
|
|
219
221
|
* @param {object} [opts] - Options for request
|
|
222
|
+
* @param {string} [opts.type] - The type of address configuration.
|
|
220
223
|
* @param {string} [opts.pageToken] - PageToken provided by the API
|
|
221
224
|
* @param {number} [opts.pageNumber] -
|
|
222
225
|
* Page Number, this value is simply for client state
|
|
@@ -235,6 +238,7 @@ AddressConfigurationList = function AddressConfigurationList(version) {
|
|
|
235
238
|
|
|
236
239
|
var deferred = Q.defer();
|
|
237
240
|
var data = values.of({
|
|
241
|
+
'Type': _.get(opts, 'type'),
|
|
238
242
|
'PageToken': opts.pageToken,
|
|
239
243
|
'Page': opts.pageNumber,
|
|
240
244
|
'PageSize': opts.pageSize
|
|
@@ -18,8 +18,8 @@ type InteractionChannelInviteType = 'taskrouter';
|
|
|
18
18
|
* Initialize the InteractionChannelInviteList
|
|
19
19
|
*
|
|
20
20
|
* @param version - Version of the resource
|
|
21
|
-
* @param interactionSid - The
|
|
22
|
-
* @param channelSid - The
|
|
21
|
+
* @param interactionSid - The Interaction SID for this Channel
|
|
22
|
+
* @param channelSid - The Channel SID for this Invite
|
|
23
23
|
*/
|
|
24
24
|
declare function InteractionChannelInviteList(version: V1, interactionSid: string, channelSid: string): InteractionChannelInviteListInstance;
|
|
25
25
|
|
|
@@ -138,7 +138,7 @@ interface InteractionChannelInviteListInstance {
|
|
|
138
138
|
/**
|
|
139
139
|
* Options to pass to create
|
|
140
140
|
*
|
|
141
|
-
* @property routing - The routing
|
|
141
|
+
* @property routing - The Interaction's routing logic
|
|
142
142
|
*/
|
|
143
143
|
interface InteractionChannelInviteListInstanceCreateOptions {
|
|
144
144
|
routing: object;
|
|
@@ -224,8 +224,8 @@ declare class InteractionChannelInviteInstance extends SerializableClass {
|
|
|
224
224
|
*
|
|
225
225
|
* @param version - Version of the resource
|
|
226
226
|
* @param payload - The instance payload
|
|
227
|
-
* @param interactionSid - The
|
|
228
|
-
* @param channelSid - The
|
|
227
|
+
* @param interactionSid - The Interaction SID for this Channel
|
|
228
|
+
* @param channelSid - The Channel SID for this Invite
|
|
229
229
|
*/
|
|
230
230
|
constructor(version: V1, payload: InteractionChannelInvitePayload, interactionSid: string, channelSid: string);
|
|
231
231
|
|
|
@@ -28,8 +28,8 @@ var InteractionChannelInviteInstance;
|
|
|
28
28
|
* @constructor Twilio.FlexApi.V1.InteractionContext.InteractionChannelContext.InteractionChannelInviteList
|
|
29
29
|
*
|
|
30
30
|
* @param {Twilio.FlexApi.V1} version - Version of the resource
|
|
31
|
-
* @param {string} interactionSid - The
|
|
32
|
-
* @param {string} channelSid - The
|
|
31
|
+
* @param {string} interactionSid - The Interaction SID for this Channel
|
|
32
|
+
* @param {string} channelSid - The Channel SID for this Invite
|
|
33
33
|
*/
|
|
34
34
|
/* jshint ignore:end */
|
|
35
35
|
InteractionChannelInviteList = function InteractionChannelInviteList(version,
|
|
@@ -63,7 +63,7 @@ InteractionChannelInviteList = function InteractionChannelInviteList(version,
|
|
|
63
63
|
* @memberof Twilio.FlexApi.V1.InteractionContext.InteractionChannelContext.InteractionChannelInviteList#
|
|
64
64
|
*
|
|
65
65
|
* @param {object} opts - Options for request
|
|
66
|
-
* @param {object} opts.routing - The routing
|
|
66
|
+
* @param {object} opts.routing - The Interaction's routing logic
|
|
67
67
|
* @param {function} [callback] - Callback to handle processed record
|
|
68
68
|
*
|
|
69
69
|
* @returns {Promise} Resolves to processed InteractionChannelInviteInstance
|
|
@@ -444,16 +444,17 @@ InteractionChannelInvitePage.prototype[util.inspect.custom] = function
|
|
|
444
444
|
*
|
|
445
445
|
* @constructor Twilio.FlexApi.V1.InteractionContext.InteractionChannelContext.InteractionChannelInviteInstance
|
|
446
446
|
*
|
|
447
|
-
* @property {string} sid - The
|
|
448
|
-
* @property {string} interactionSid - The
|
|
449
|
-
* @property {string} channelSid - The
|
|
450
|
-
* @property {object} routing -
|
|
447
|
+
* @property {string} sid - The unique string that identifies the resource
|
|
448
|
+
* @property {string} interactionSid - The Interaction SID for this Channel
|
|
449
|
+
* @property {string} channelSid - The Channel SID for this Invite
|
|
450
|
+
* @property {object} routing -
|
|
451
|
+
* A JSON object representing the routing rules for the Interaction Channel
|
|
451
452
|
* @property {string} url - The url
|
|
452
453
|
*
|
|
453
454
|
* @param {V1} version - Version of the resource
|
|
454
455
|
* @param {InteractionChannelInvitePayload} payload - The instance payload
|
|
455
|
-
* @param {sid} interactionSid - The
|
|
456
|
-
* @param {sid} channelSid - The
|
|
456
|
+
* @param {sid} interactionSid - The Interaction SID for this Channel
|
|
457
|
+
* @param {sid} channelSid - The Channel SID for this Invite
|
|
457
458
|
*/
|
|
458
459
|
/* jshint ignore:end */
|
|
459
460
|
InteractionChannelInviteInstance = function
|
|
@@ -22,15 +22,15 @@ type InteractionChannelType = 'voice'|'sms'|'email'|'web'|'whatsapp'|'chat';
|
|
|
22
22
|
* Initialize the InteractionChannelList
|
|
23
23
|
*
|
|
24
24
|
* @param version - Version of the resource
|
|
25
|
-
* @param interactionSid - The
|
|
25
|
+
* @param interactionSid - The unique string that identifies the resource
|
|
26
26
|
*/
|
|
27
27
|
declare function InteractionChannelList(version: V1, interactionSid: string): InteractionChannelListInstance;
|
|
28
28
|
|
|
29
29
|
/**
|
|
30
30
|
* Options to pass to update
|
|
31
31
|
*
|
|
32
|
-
* @property routing - The
|
|
33
|
-
* @property status - The Interaction
|
|
32
|
+
* @property routing - Optional. The state of associated tasks.
|
|
33
|
+
* @property status - Required. The Interaction channels's status
|
|
34
34
|
*/
|
|
35
35
|
interface InteractionChannelInstanceUpdateOptions {
|
|
36
36
|
routing?: object;
|
|
@@ -76,7 +76,7 @@ interface InteractionChannelListInstance {
|
|
|
76
76
|
/**
|
|
77
77
|
* Constructs a interaction_channel
|
|
78
78
|
*
|
|
79
|
-
* @param sid - The
|
|
79
|
+
* @param sid - The unique string that identifies the resource
|
|
80
80
|
*/
|
|
81
81
|
get(sid: string): InteractionChannelContext;
|
|
82
82
|
/**
|
|
@@ -230,8 +230,8 @@ declare class InteractionChannelContext {
|
|
|
230
230
|
* Initialize the InteractionChannelContext
|
|
231
231
|
*
|
|
232
232
|
* @param version - Version of the resource
|
|
233
|
-
* @param interactionSid - The
|
|
234
|
-
* @param sid - The
|
|
233
|
+
* @param interactionSid - The unique string that identifies the resource
|
|
234
|
+
* @param sid - The unique string that identifies the resource
|
|
235
235
|
*/
|
|
236
236
|
constructor(version: V1, interactionSid: string, sid: string);
|
|
237
237
|
|
|
@@ -263,8 +263,8 @@ declare class InteractionChannelInstance extends SerializableClass {
|
|
|
263
263
|
*
|
|
264
264
|
* @param version - Version of the resource
|
|
265
265
|
* @param payload - The instance payload
|
|
266
|
-
* @param interactionSid - The
|
|
267
|
-
* @param sid - The
|
|
266
|
+
* @param interactionSid - The unique string that identifies the resource
|
|
267
|
+
* @param sid - The unique string that identifies the resource
|
|
268
268
|
*/
|
|
269
269
|
constructor(version: V1, payload: InteractionChannelPayload, interactionSid: string, sid: string);
|
|
270
270
|
|
|
@@ -32,7 +32,7 @@ var InteractionChannelContext;
|
|
|
32
32
|
* @constructor Twilio.FlexApi.V1.InteractionContext.InteractionChannelList
|
|
33
33
|
*
|
|
34
34
|
* @param {Twilio.FlexApi.V1} version - Version of the resource
|
|
35
|
-
* @param {string} interactionSid - The
|
|
35
|
+
* @param {string} interactionSid - The unique string that identifies the resource
|
|
36
36
|
*/
|
|
37
37
|
/* jshint ignore:end */
|
|
38
38
|
InteractionChannelList = function InteractionChannelList(version,
|
|
@@ -307,7 +307,7 @@ InteractionChannelList = function InteractionChannelList(version,
|
|
|
307
307
|
* @function get
|
|
308
308
|
* @memberof Twilio.FlexApi.V1.InteractionContext.InteractionChannelList#
|
|
309
309
|
*
|
|
310
|
-
* @param {string} sid - The
|
|
310
|
+
* @param {string} sid - The unique string that identifies the resource
|
|
311
311
|
*
|
|
312
312
|
* @returns {Twilio.FlexApi.V1.InteractionContext.InteractionChannelContext}
|
|
313
313
|
*/
|
|
@@ -412,15 +412,16 @@ InteractionChannelPage.prototype[util.inspect.custom] = function inspect(depth,
|
|
|
412
412
|
* @constructor Twilio.FlexApi.V1.InteractionContext.InteractionChannelInstance
|
|
413
413
|
*
|
|
414
414
|
* @property {string} sid - The unique string that identifies the resource
|
|
415
|
-
* @property {string} interactionSid -
|
|
415
|
+
* @property {string} interactionSid -
|
|
416
|
+
* The unique string that identifies the resource
|
|
416
417
|
* @property {interaction_channel.type} type - The Interaction Channel's type.
|
|
417
418
|
* @property {string} url - The url
|
|
418
419
|
* @property {string} links - The links
|
|
419
420
|
*
|
|
420
421
|
* @param {V1} version - Version of the resource
|
|
421
422
|
* @param {InteractionChannelPayload} payload - The instance payload
|
|
422
|
-
* @param {sid} interactionSid - The
|
|
423
|
-
* @param {sid} sid - The
|
|
423
|
+
* @param {sid} interactionSid - The unique string that identifies the resource
|
|
424
|
+
* @param {sid} sid - The unique string that identifies the resource
|
|
424
425
|
*/
|
|
425
426
|
/* jshint ignore:end */
|
|
426
427
|
InteractionChannelInstance = function InteractionChannelInstance(version,
|
|
@@ -479,9 +480,8 @@ InteractionChannelInstance.prototype.fetch = function fetch(callback) {
|
|
|
479
480
|
*
|
|
480
481
|
* @param {object} opts - Options for request
|
|
481
482
|
* @param {interaction_channel.status} opts.status -
|
|
482
|
-
* The Interaction
|
|
483
|
-
* @param {object} [opts.routing] -
|
|
484
|
-
* The Interaction Channels's optional routing parameters
|
|
483
|
+
* Required. The Interaction channels's status
|
|
484
|
+
* @param {object} [opts.routing] - Optional. The state of associated tasks.
|
|
485
485
|
* @param {function} [callback] - Callback to handle processed record
|
|
486
486
|
*
|
|
487
487
|
* @returns {Promise} Resolves to processed InteractionChannelInstance
|
|
@@ -557,8 +557,8 @@ InteractionChannelInstance.prototype[util.inspect.custom] = function
|
|
|
557
557
|
* participants resource
|
|
558
558
|
*
|
|
559
559
|
* @param {V1} version - Version of the resource
|
|
560
|
-
* @param {sid} interactionSid - The
|
|
561
|
-
* @param {sid} sid - The
|
|
560
|
+
* @param {sid} interactionSid - The unique string that identifies the resource
|
|
561
|
+
* @param {sid} sid - The unique string that identifies the resource
|
|
562
562
|
*/
|
|
563
563
|
/* jshint ignore:end */
|
|
564
564
|
InteractionChannelContext = function InteractionChannelContext(version,
|
|
@@ -619,9 +619,8 @@ InteractionChannelContext.prototype.fetch = function fetch(callback) {
|
|
|
619
619
|
*
|
|
620
620
|
* @param {object} opts - Options for request
|
|
621
621
|
* @param {interaction_channel.status} opts.status -
|
|
622
|
-
* The Interaction
|
|
623
|
-
* @param {object} [opts.routing] -
|
|
624
|
-
* The Interaction Channels's optional routing parameters
|
|
622
|
+
* Required. The Interaction channels's status
|
|
623
|
+
* @param {object} [opts.routing] - Optional. The state of associated tasks.
|
|
625
624
|
* @param {function} [callback] - Callback to handle processed record
|
|
626
625
|
*
|
|
627
626
|
* @returns {Promise} Resolves to processed InteractionChannelInstance
|
|
@@ -212,7 +212,8 @@ InteractionPage.prototype[util.inspect.custom] = function inspect(depth,
|
|
|
212
212
|
*
|
|
213
213
|
* @property {string} sid - The unique string that identifies the resource
|
|
214
214
|
* @property {object} channel - The Interaction's channel
|
|
215
|
-
* @property {object} routing -
|
|
215
|
+
* @property {object} routing -
|
|
216
|
+
* A JSON Object representing the routing rules for the Interaction Channel
|
|
216
217
|
* @property {string} url - The url
|
|
217
218
|
* @property {string} links - The links
|
|
218
219
|
*
|
|
@@ -27,13 +27,19 @@ interface EsimProfileListInstance {
|
|
|
27
27
|
* @param sid - sid of instance
|
|
28
28
|
*/
|
|
29
29
|
(sid: string): EsimProfileContext;
|
|
30
|
+
/**
|
|
31
|
+
* create a EsimProfileInstance
|
|
32
|
+
*
|
|
33
|
+
* @param callback - Callback to handle processed record
|
|
34
|
+
*/
|
|
35
|
+
create(callback?: (error: Error | null, item: EsimProfileInstance) => any): Promise<EsimProfileInstance>;
|
|
30
36
|
/**
|
|
31
37
|
* create a EsimProfileInstance
|
|
32
38
|
*
|
|
33
39
|
* @param opts - Options for request
|
|
34
40
|
* @param callback - Callback to handle processed record
|
|
35
41
|
*/
|
|
36
|
-
create(opts
|
|
42
|
+
create(opts?: EsimProfileListInstanceCreateOptions, callback?: (error: Error | null, item: EsimProfileInstance) => any): Promise<EsimProfileInstance>;
|
|
37
43
|
/**
|
|
38
44
|
* Streams EsimProfileInstance records from the API.
|
|
39
45
|
*
|
|
@@ -152,7 +158,7 @@ interface EsimProfileListInstance {
|
|
|
152
158
|
interface EsimProfileListInstanceCreateOptions {
|
|
153
159
|
callbackMethod?: string;
|
|
154
160
|
callbackUrl?: string;
|
|
155
|
-
eid
|
|
161
|
+
eid?: string;
|
|
156
162
|
}
|
|
157
163
|
|
|
158
164
|
/**
|
|
@@ -60,31 +60,30 @@ EsimProfileList = function EsimProfileList(version) {
|
|
|
60
60
|
* @function create
|
|
61
61
|
* @memberof Twilio.Supersim.V1.EsimProfileList#
|
|
62
62
|
*
|
|
63
|
-
* @param {object} opts - Options for request
|
|
64
|
-
* @param {string} opts.eid -
|
|
65
|
-
* Identifier of the eUICC that will claim the eSIM Profile
|
|
63
|
+
* @param {object} [opts] - Options for request
|
|
66
64
|
* @param {string} [opts.callbackUrl] -
|
|
67
65
|
* The URL we should call after we have sent when the status of the eSIM Profile changes
|
|
68
66
|
* @param {string} [opts.callbackMethod] -
|
|
69
67
|
* The HTTP method we should use to call callback_url
|
|
68
|
+
* @param {string} [opts.eid] -
|
|
69
|
+
* Identifier of the eUICC that will claim the eSIM Profile
|
|
70
70
|
* @param {function} [callback] - Callback to handle processed record
|
|
71
71
|
*
|
|
72
72
|
* @returns {Promise} Resolves to processed EsimProfileInstance
|
|
73
73
|
*/
|
|
74
74
|
/* jshint ignore:end */
|
|
75
75
|
EsimProfileListInstance.create = function create(opts, callback) {
|
|
76
|
-
if (_.
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
if (_.isUndefined(opts['eid'])) {
|
|
80
|
-
throw new Error('Required parameter "opts[\'eid\']" missing.');
|
|
76
|
+
if (_.isFunction(opts)) {
|
|
77
|
+
callback = opts;
|
|
78
|
+
opts = {};
|
|
81
79
|
}
|
|
80
|
+
opts = opts || {};
|
|
82
81
|
|
|
83
82
|
var deferred = Q.defer();
|
|
84
83
|
var data = values.of({
|
|
85
|
-
'Eid': _.get(opts, 'eid'),
|
|
86
84
|
'CallbackUrl': _.get(opts, 'callbackUrl'),
|
|
87
|
-
'CallbackMethod': _.get(opts, 'callbackMethod')
|
|
85
|
+
'CallbackMethod': _.get(opts, 'callbackMethod'),
|
|
86
|
+
'Eid': _.get(opts, 'eid')
|
|
88
87
|
});
|
|
89
88
|
|
|
90
89
|
var promise = this._version.create({uri: this._uri, method: 'POST', data: data});
|
|
@@ -239,8 +239,10 @@ interface UsageRecordPayload extends UsageRecordResource, Page.TwilioResponsePay
|
|
|
239
239
|
|
|
240
240
|
interface UsageRecordResource {
|
|
241
241
|
account_sid: string;
|
|
242
|
+
billed_unit: string;
|
|
242
243
|
data_download: number;
|
|
243
244
|
data_total: number;
|
|
245
|
+
data_total_billed: number;
|
|
244
246
|
data_upload: number;
|
|
245
247
|
fleet_sid: string;
|
|
246
248
|
iso_country: string;
|
|
@@ -266,8 +268,10 @@ declare class UsageRecordInstance extends SerializableClass {
|
|
|
266
268
|
constructor(version: V1, payload: UsageRecordPayload);
|
|
267
269
|
|
|
268
270
|
accountSid: string;
|
|
271
|
+
billedUnit: string;
|
|
269
272
|
dataDownload: number;
|
|
270
273
|
dataTotal: number;
|
|
274
|
+
dataTotalBilled: number;
|
|
271
275
|
dataUpload: number;
|
|
272
276
|
fleetSid: string;
|
|
273
277
|
isoCountry: string;
|
|
@@ -468,6 +468,10 @@ UsageRecordPage.prototype[util.inspect.custom] = function inspect(depth,
|
|
|
468
468
|
* @property {number} dataDownload -
|
|
469
469
|
* Total data downloaded in bytes, aggregated by the query parameters.
|
|
470
470
|
* @property {number} dataTotal - Total of data_upload and data_download.
|
|
471
|
+
* @property {number} dataTotalBilled -
|
|
472
|
+
* Total amount in the `billed_unit` that was charged for the data uploaded or downloaded.
|
|
473
|
+
* @property {string} billedUnit -
|
|
474
|
+
* The currency in which the billed amounts are measured, specified in the 3 letter ISO 4127 format (e.g. `USD`, `EUR`, `JPY`).
|
|
471
475
|
*
|
|
472
476
|
* @param {V1} version - Version of the resource
|
|
473
477
|
* @param {UsageRecordPayload} payload - The instance payload
|
|
@@ -486,6 +490,8 @@ UsageRecordInstance = function UsageRecordInstance(version, payload) {
|
|
|
486
490
|
this.dataUpload = deserialize.integer(payload.data_upload); // jshint ignore:line
|
|
487
491
|
this.dataDownload = deserialize.integer(payload.data_download); // jshint ignore:line
|
|
488
492
|
this.dataTotal = deserialize.integer(payload.data_total); // jshint ignore:line
|
|
493
|
+
this.dataTotalBilled = deserialize.decimal(payload.data_total_billed); // jshint ignore:line
|
|
494
|
+
this.billedUnit = payload.billed_unit; // jshint ignore:line
|
|
489
495
|
|
|
490
496
|
// Context
|
|
491
497
|
this._context = undefined;
|
|
@@ -10,7 +10,7 @@ import Response = require('../../../../http/response');
|
|
|
10
10
|
import V2 = require('../../V2');
|
|
11
11
|
import { SerializableClass } from '../../../../interfaces';
|
|
12
12
|
|
|
13
|
-
type VerificationChannel = 'sms'|'call'|'email'|'whatsapp';
|
|
13
|
+
type VerificationChannel = 'sms'|'call'|'email'|'whatsapp'|'sna';
|
|
14
14
|
|
|
15
15
|
type VerificationStatus = 'canceled'|'approved';
|
|
16
16
|
|
|
@@ -104,6 +104,7 @@ interface VerificationResource {
|
|
|
104
104
|
send_code_attempts: object[];
|
|
105
105
|
service_sid: string;
|
|
106
106
|
sid: string;
|
|
107
|
+
sna: object;
|
|
107
108
|
status: string;
|
|
108
109
|
to: string;
|
|
109
110
|
url: string;
|
|
@@ -173,6 +174,7 @@ declare class VerificationInstance extends SerializableClass {
|
|
|
173
174
|
sendCodeAttempts: object[];
|
|
174
175
|
serviceSid: string;
|
|
175
176
|
sid: string;
|
|
177
|
+
sna: any;
|
|
176
178
|
status: string;
|
|
177
179
|
to: string;
|
|
178
180
|
/**
|
|
@@ -268,6 +268,8 @@ VerificationPage.prototype[util.inspect.custom] = function inspect(depth,
|
|
|
268
268
|
* The RFC 2822 date and time in GMT when the resource was created
|
|
269
269
|
* @property {Date} dateUpdated -
|
|
270
270
|
* The RFC 2822 date and time in GMT when the resource was last updated
|
|
271
|
+
* @property {object} sna -
|
|
272
|
+
* The set of fields used for a silent network auth (`sna`) verification
|
|
271
273
|
* @property {string} url - The absolute URL of the Verification resource
|
|
272
274
|
*
|
|
273
275
|
* @param {V2} version - Version of the resource
|
|
@@ -295,6 +297,7 @@ VerificationInstance = function VerificationInstance(version, payload,
|
|
|
295
297
|
this.sendCodeAttempts = payload.send_code_attempts; // jshint ignore:line
|
|
296
298
|
this.dateCreated = deserialize.iso8601DateTime(payload.date_created); // jshint ignore:line
|
|
297
299
|
this.dateUpdated = deserialize.iso8601DateTime(payload.date_updated); // jshint ignore:line
|
|
300
|
+
this.sna = payload.sna; // jshint ignore:line
|
|
298
301
|
this.url = payload.url; // jshint ignore:line
|
|
299
302
|
|
|
300
303
|
// Context
|
|
@@ -10,7 +10,7 @@ import Response = require('../../../../http/response');
|
|
|
10
10
|
import V2 = require('../../V2');
|
|
11
11
|
import { SerializableClass } from '../../../../interfaces';
|
|
12
12
|
|
|
13
|
-
type VerificationCheckChannel = 'sms'|'call'|'email'|'whatsapp';
|
|
13
|
+
type VerificationCheckChannel = 'sms'|'call'|'email'|'whatsapp'|'sna';
|
|
14
14
|
|
|
15
15
|
/**
|
|
16
16
|
* Initialize the VerificationCheckList
|
|
@@ -44,7 +44,7 @@ declare function ServiceList(version: V2): ServiceListInstance;
|
|
|
44
44
|
* @property psd2Enabled - Whether to pass PSD2 transaction parameters when starting a verification
|
|
45
45
|
* @property push.apnCredentialSid - Optional. Set APN Credential for this service.
|
|
46
46
|
* @property push.fcmCredentialSid - Optional. Set FCM Credential for this service.
|
|
47
|
-
* @property push.includeDate - Optional. Include the date in the Challenge's
|
|
47
|
+
* @property push.includeDate - Optional. Include the date in the Challenge's response. Default: false. **Deprecated** do not use this parameter.
|
|
48
48
|
* @property skipSmsToLandlines - Whether to skip sending SMS verifications to landlines
|
|
49
49
|
* @property totp.codeLength - Optional. Number of digits for generated TOTP codes
|
|
50
50
|
* @property totp.issuer - Optional. Set TOTP Issuer for this service.
|
|
@@ -209,7 +209,7 @@ interface ServiceListInstance {
|
|
|
209
209
|
* @property psd2Enabled - Whether to pass PSD2 transaction parameters when starting a verification
|
|
210
210
|
* @property push.apnCredentialSid - Optional. Set APN Credential for this service.
|
|
211
211
|
* @property push.fcmCredentialSid - Optional. Set FCM Credential for this service.
|
|
212
|
-
* @property push.includeDate - Optional. Include the date in the Challenge's
|
|
212
|
+
* @property push.includeDate - Optional. Include the date in the Challenge's response. Default: false. **Deprecated** do not use this parameter.
|
|
213
213
|
* @property skipSmsToLandlines - Whether to skip sending SMS verifications to landlines
|
|
214
214
|
* @property totp.codeLength - Optional. Number of digits for generated TOTP codes
|
|
215
215
|
* @property totp.issuer - Optional. Set TOTP Issuer for this service.
|
|
@@ -87,7 +87,7 @@ ServiceList = function ServiceList(version) {
|
|
|
87
87
|
* @param {boolean} [opts.customCodeEnabled] -
|
|
88
88
|
* Whether to allow sending verifications with a custom code.
|
|
89
89
|
* @param {boolean} [opts.push.includeDate] -
|
|
90
|
-
* Optional. Include the date in the Challenge's
|
|
90
|
+
* Optional. Include the date in the Challenge's response. Default: false. **Deprecated** do not use this parameter.
|
|
91
91
|
* @param {string} [opts.push.apnCredentialSid] -
|
|
92
92
|
* Optional. Set APN Credential for this service.
|
|
93
93
|
* @param {string} [opts.push.fcmCredentialSid] -
|
|
@@ -636,7 +636,7 @@ ServiceInstance.prototype.remove = function remove(callback) {
|
|
|
636
636
|
* @param {boolean} [opts.customCodeEnabled] -
|
|
637
637
|
* Whether to allow sending verifications with a custom code.
|
|
638
638
|
* @param {boolean} [opts.push.includeDate] -
|
|
639
|
-
* Optional. Include the date in the Challenge's
|
|
639
|
+
* Optional. Include the date in the Challenge's response. Default: false. **Deprecated** do not use this parameter.
|
|
640
640
|
* @param {string} [opts.push.apnCredentialSid] -
|
|
641
641
|
* Optional. Set APN Credential for this service.
|
|
642
642
|
* @param {string} [opts.push.fcmCredentialSid] -
|
|
@@ -915,7 +915,7 @@ ServiceContext.prototype.remove = function remove(callback) {
|
|
|
915
915
|
* @param {boolean} [opts.customCodeEnabled] -
|
|
916
916
|
* Whether to allow sending verifications with a custom code.
|
|
917
917
|
* @param {boolean} [opts.push.includeDate] -
|
|
918
|
-
* Optional. Include the date in the Challenge's
|
|
918
|
+
* Optional. Include the date in the Challenge's response. Default: false. **Deprecated** do not use this parameter.
|
|
919
919
|
* @param {string} [opts.push.apnCredentialSid] -
|
|
920
920
|
* Optional. Set APN Credential for this service.
|
|
921
921
|
* @param {string} [opts.push.fcmCredentialSid] -
|