twilio 3.80.0 → 3.80.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. package/lib/rest/Microvisor.d.ts +28 -0
  2. package/lib/rest/Microvisor.js +62 -0
  3. package/lib/rest/Preview.d.ts +0 -6
  4. package/lib/rest/Preview.js +0 -28
  5. package/lib/rest/Routes.d.ts +30 -0
  6. package/lib/rest/Routes.js +71 -0
  7. package/lib/rest/Twilio.d.ts +4 -0
  8. package/lib/rest/Twilio.js +28 -0
  9. package/lib/rest/api/v2010/account/sip/ipAccessControlList/ipAddress.d.ts +2 -2
  10. package/lib/rest/api/v2010/account/sip/ipAccessControlList/ipAddress.js +4 -4
  11. package/lib/rest/microvisor/V1.d.ts +28 -0
  12. package/lib/rest/microvisor/V1.js +57 -0
  13. package/lib/rest/{preview/bulk_exports/export/day.d.ts → microvisor/v1/app.d.ts} +79 -69
  14. package/lib/rest/{preview/bulk_exports/export/day.js → microvisor/v1/app.js} +160 -122
  15. package/lib/rest/{preview/bulk_exports/export/exportCustomJob.d.ts → microvisor/v1/device.d.ts} +136 -84
  16. package/lib/rest/microvisor/v1/device.js +652 -0
  17. package/lib/rest/routes/V2.d.ts +31 -0
  18. package/lib/rest/routes/V2.js +69 -0
  19. package/lib/rest/routes/v2/phoneNumber.d.ts +193 -0
  20. package/lib/rest/routes/v2/phoneNumber.js +466 -0
  21. package/lib/rest/routes/v2/sipDomain.d.ts +205 -0
  22. package/lib/rest/routes/v2/sipDomain.js +447 -0
  23. package/lib/rest/routes/v2/trunk.d.ts +205 -0
  24. package/lib/rest/routes/v2/trunk.js +458 -0
  25. package/lib/rest/supersim/v1/fleet.d.ts +3 -1
  26. package/lib/rest/supersim/v1/fleet.js +8 -3
  27. package/package.json +1 -1
  28. package/lib/rest/preview/BulkExports.d.ts +0 -28
  29. package/lib/rest/preview/BulkExports.js +0 -59
  30. package/lib/rest/preview/bulk_exports/export/exportCustomJob.js +0 -540
  31. package/lib/rest/preview/bulk_exports/export/job.d.ts +0 -163
  32. package/lib/rest/preview/bulk_exports/export/job.js +0 -390
  33. package/lib/rest/preview/bulk_exports/export.d.ts +0 -153
  34. package/lib/rest/preview/bulk_exports/export.js +0 -402
  35. package/lib/rest/preview/bulk_exports/exportConfiguration.d.ts +0 -180
  36. package/lib/rest/preview/bulk_exports/exportConfiguration.js +0 -411
@@ -1,402 +0,0 @@
1
- 'use strict';
2
-
3
- /* jshint ignore:start */
4
- /**
5
- * This code was generated by
6
- * \ / _ _ _| _ _
7
- * | (_)\/(_)(_|\/| |(/_ v1.0.0
8
- * / /
9
- */
10
- /* jshint ignore:end */
11
-
12
- var Q = require('q'); /* jshint ignore:line */
13
- var _ = require('lodash'); /* jshint ignore:line */
14
- var util = require('util'); /* jshint ignore:line */
15
- var DayList = require('./export/day').DayList;
16
- var ExportCustomJobList = require(
17
- './export/exportCustomJob').ExportCustomJobList;
18
- var JobList = require('./export/job').JobList;
19
- var Page = require('../../../base/Page'); /* jshint ignore:line */
20
- var values = require('../../../base/values'); /* jshint ignore:line */
21
-
22
- var ExportList;
23
- var ExportPage;
24
- var ExportInstance;
25
- var ExportContext;
26
-
27
- /* jshint ignore:start */
28
- /**
29
- * Initialize the ExportList
30
- *
31
- * PLEASE NOTE that this class contains preview products that are subject to
32
- * change. Use them with caution. If you currently do not have developer preview
33
- * access, please contact help@twilio.com.
34
- *
35
- * @constructor Twilio.Preview.BulkExports.ExportList
36
- *
37
- * @param {Twilio.Preview.BulkExports} version - Version of the resource
38
- */
39
- /* jshint ignore:end */
40
- ExportList = function ExportList(version) {
41
- /* jshint ignore:start */
42
- /**
43
- * @function exports
44
- * @memberof Twilio.Preview.BulkExports#
45
- *
46
- * @param {string} sid - sid of instance
47
- *
48
- * @returns {Twilio.Preview.BulkExports.ExportContext}
49
- */
50
- /* jshint ignore:end */
51
- function ExportListInstance(sid) {
52
- return ExportListInstance.get(sid);
53
- }
54
-
55
- ExportListInstance._version = version;
56
- // Path Solution
57
- ExportListInstance._solution = {};
58
-
59
- // Components
60
- ExportListInstance._jobs = undefined;
61
-
62
- /* jshint ignore:start */
63
- /**
64
- * Constructs a export
65
- *
66
- * @function get
67
- * @memberof Twilio.Preview.BulkExports.ExportList#
68
- *
69
- * @param {string} resourceType -
70
- * The type of communication – Messages, Calls, Conferences, and Participants
71
- *
72
- * @returns {Twilio.Preview.BulkExports.ExportContext}
73
- */
74
- /* jshint ignore:end */
75
- ExportListInstance.get = function get(resourceType) {
76
- return new ExportContext(this._version, resourceType);
77
- };
78
-
79
- Object.defineProperty(ExportListInstance,
80
- 'jobs', {
81
- get: function jobs() {
82
- if (!this._jobs) {
83
- this._jobs = new JobList(this._version);
84
- }
85
-
86
- return this._jobs;
87
- }
88
- });
89
-
90
- /* jshint ignore:start */
91
- /**
92
- * Provide a user-friendly representation
93
- *
94
- * @function toJSON
95
- * @memberof Twilio.Preview.BulkExports.ExportList#
96
- *
97
- * @returns Object
98
- */
99
- /* jshint ignore:end */
100
- ExportListInstance.toJSON = function toJSON() {
101
- return this._solution;
102
- };
103
-
104
- ExportListInstance[util.inspect.custom] = function inspect(depth, options) {
105
- return util.inspect(this.toJSON(), options);
106
- };
107
-
108
- return ExportListInstance;
109
- };
110
-
111
-
112
- /* jshint ignore:start */
113
- /**
114
- * Initialize the ExportPage
115
- *
116
- * PLEASE NOTE that this class contains preview products that are subject to
117
- * change. Use them with caution. If you currently do not have developer preview
118
- * access, please contact help@twilio.com.
119
- *
120
- * @constructor Twilio.Preview.BulkExports.ExportPage
121
- *
122
- * @param {BulkExports} version - Version of the resource
123
- * @param {Response<string>} response - Response from the API
124
- * @param {ExportSolution} solution - Path solution
125
- *
126
- * @returns ExportPage
127
- */
128
- /* jshint ignore:end */
129
- ExportPage = function ExportPage(version, response, solution) {
130
- // Path Solution
131
- this._solution = solution;
132
-
133
- Page.prototype.constructor.call(this, version, response, this._solution);
134
- };
135
-
136
- _.extend(ExportPage.prototype, Page.prototype);
137
- ExportPage.prototype.constructor = ExportPage;
138
-
139
- /* jshint ignore:start */
140
- /**
141
- * Build an instance of ExportInstance
142
- *
143
- * @function getInstance
144
- * @memberof Twilio.Preview.BulkExports.ExportPage#
145
- *
146
- * @param {ExportPayload} payload - Payload response from the API
147
- *
148
- * @returns ExportInstance
149
- */
150
- /* jshint ignore:end */
151
- ExportPage.prototype.getInstance = function getInstance(payload) {
152
- return new ExportInstance(this._version, payload);
153
- };
154
-
155
- /* jshint ignore:start */
156
- /**
157
- * Provide a user-friendly representation
158
- *
159
- * @function toJSON
160
- * @memberof Twilio.Preview.BulkExports.ExportPage#
161
- *
162
- * @returns Object
163
- */
164
- /* jshint ignore:end */
165
- ExportPage.prototype.toJSON = function toJSON() {
166
- let clone = {};
167
- _.forOwn(this, function(value, key) {
168
- if (!_.startsWith(key, '_') && ! _.isFunction(value)) {
169
- clone[key] = value;
170
- }
171
- });
172
- return clone;
173
- };
174
-
175
- ExportPage.prototype[util.inspect.custom] = function inspect(depth, options) {
176
- return util.inspect(this.toJSON(), options);
177
- };
178
-
179
-
180
- /* jshint ignore:start */
181
- /**
182
- * Initialize the ExportContext
183
- *
184
- * PLEASE NOTE that this class contains preview products that are subject to
185
- * change. Use them with caution. If you currently do not have developer preview
186
- * access, please contact help@twilio.com.
187
- *
188
- * @constructor Twilio.Preview.BulkExports.ExportInstance
189
- *
190
- * @property {string} resourceType -
191
- * The type of communication – Messages, Calls, Conferences, and Participants
192
- * @property {string} url - The URL of this resource.
193
- * @property {string} links - Nested resource URLs.
194
- *
195
- * @param {BulkExports} version - Version of the resource
196
- * @param {ExportPayload} payload - The instance payload
197
- * @param {string} resourceType -
198
- * The type of communication – Messages, Calls, Conferences, and Participants
199
- */
200
- /* jshint ignore:end */
201
- ExportInstance = function ExportInstance(version, payload, resourceType) {
202
- this._version = version;
203
-
204
- // Marshaled Properties
205
- this.resourceType = payload.resource_type; // jshint ignore:line
206
- this.url = payload.url; // jshint ignore:line
207
- this.links = payload.links; // jshint ignore:line
208
-
209
- // Context
210
- this._context = undefined;
211
- this._solution = {resourceType: resourceType || this.resourceType, };
212
- };
213
-
214
- Object.defineProperty(ExportInstance.prototype,
215
- '_proxy', {
216
- get: function() {
217
- if (!this._context) {
218
- this._context = new ExportContext(this._version, this._solution.resourceType);
219
- }
220
-
221
- return this._context;
222
- }
223
- });
224
-
225
- /* jshint ignore:start */
226
- /**
227
- * fetch a ExportInstance
228
- *
229
- * @function fetch
230
- * @memberof Twilio.Preview.BulkExports.ExportInstance#
231
- *
232
- * @param {function} [callback] - Callback to handle processed record
233
- *
234
- * @returns {Promise} Resolves to processed ExportInstance
235
- */
236
- /* jshint ignore:end */
237
- ExportInstance.prototype.fetch = function fetch(callback) {
238
- return this._proxy.fetch(callback);
239
- };
240
-
241
- /* jshint ignore:start */
242
- /**
243
- * Access the days
244
- *
245
- * @function days
246
- * @memberof Twilio.Preview.BulkExports.ExportInstance#
247
- *
248
- * @returns {Twilio.Preview.BulkExports.ExportContext.DayList}
249
- */
250
- /* jshint ignore:end */
251
- ExportInstance.prototype.days = function days() {
252
- return this._proxy.days;
253
- };
254
-
255
- /* jshint ignore:start */
256
- /**
257
- * Access the exportCustomJobs
258
- *
259
- * @function exportCustomJobs
260
- * @memberof Twilio.Preview.BulkExports.ExportInstance#
261
- *
262
- * @returns {Twilio.Preview.BulkExports.ExportContext.ExportCustomJobList}
263
- */
264
- /* jshint ignore:end */
265
- ExportInstance.prototype.exportCustomJobs = function exportCustomJobs() {
266
- return this._proxy.exportCustomJobs;
267
- };
268
-
269
- /* jshint ignore:start */
270
- /**
271
- * Provide a user-friendly representation
272
- *
273
- * @function toJSON
274
- * @memberof Twilio.Preview.BulkExports.ExportInstance#
275
- *
276
- * @returns Object
277
- */
278
- /* jshint ignore:end */
279
- ExportInstance.prototype.toJSON = function toJSON() {
280
- let clone = {};
281
- _.forOwn(this, function(value, key) {
282
- if (!_.startsWith(key, '_') && ! _.isFunction(value)) {
283
- clone[key] = value;
284
- }
285
- });
286
- return clone;
287
- };
288
-
289
- ExportInstance.prototype[util.inspect.custom] = function inspect(depth, options)
290
- {
291
- return util.inspect(this.toJSON(), options);
292
- };
293
-
294
-
295
- /* jshint ignore:start */
296
- /**
297
- * Initialize the ExportContext
298
- *
299
- * PLEASE NOTE that this class contains preview products that are subject to
300
- * change. Use them with caution. If you currently do not have developer preview
301
- * access, please contact help@twilio.com.
302
- *
303
- * @constructor Twilio.Preview.BulkExports.ExportContext
304
- *
305
- * @property {Twilio.Preview.BulkExports.ExportContext.DayList} days -
306
- * days resource
307
- * @property {Twilio.Preview.BulkExports.ExportContext.ExportCustomJobList} exportCustomJobs -
308
- * exportCustomJobs resource
309
- *
310
- * @param {BulkExports} version - Version of the resource
311
- * @param {string} resourceType -
312
- * The type of communication – Messages, Calls, Conferences, and Participants
313
- */
314
- /* jshint ignore:end */
315
- ExportContext = function ExportContext(version, resourceType) {
316
- this._version = version;
317
-
318
- // Path Solution
319
- this._solution = {resourceType: resourceType, };
320
- this._uri = `/Exports/${resourceType}`;
321
-
322
- // Dependents
323
- this._days = undefined;
324
- this._exportCustomJobs = undefined;
325
- };
326
-
327
- /* jshint ignore:start */
328
- /**
329
- * fetch a ExportInstance
330
- *
331
- * @function fetch
332
- * @memberof Twilio.Preview.BulkExports.ExportContext#
333
- *
334
- * @param {function} [callback] - Callback to handle processed record
335
- *
336
- * @returns {Promise} Resolves to processed ExportInstance
337
- */
338
- /* jshint ignore:end */
339
- ExportContext.prototype.fetch = function fetch(callback) {
340
- var deferred = Q.defer();
341
- var promise = this._version.fetch({uri: this._uri, method: 'GET'});
342
-
343
- promise = promise.then(function(payload) {
344
- deferred.resolve(new ExportInstance(this._version, payload, this._solution.resourceType));
345
- }.bind(this));
346
-
347
- promise.catch(function(error) {
348
- deferred.reject(error);
349
- });
350
-
351
- if (_.isFunction(callback)) {
352
- deferred.promise.nodeify(callback);
353
- }
354
-
355
- return deferred.promise;
356
- };
357
-
358
- Object.defineProperty(ExportContext.prototype,
359
- 'days', {
360
- get: function() {
361
- if (!this._days) {
362
- this._days = new DayList(this._version, this._solution.resourceType);
363
- }
364
- return this._days;
365
- }
366
- });
367
-
368
- Object.defineProperty(ExportContext.prototype,
369
- 'exportCustomJobs', {
370
- get: function() {
371
- if (!this._exportCustomJobs) {
372
- this._exportCustomJobs = new ExportCustomJobList(this._version, this._solution.resourceType);
373
- }
374
- return this._exportCustomJobs;
375
- }
376
- });
377
-
378
- /* jshint ignore:start */
379
- /**
380
- * Provide a user-friendly representation
381
- *
382
- * @function toJSON
383
- * @memberof Twilio.Preview.BulkExports.ExportContext#
384
- *
385
- * @returns Object
386
- */
387
- /* jshint ignore:end */
388
- ExportContext.prototype.toJSON = function toJSON() {
389
- return this._solution;
390
- };
391
-
392
- ExportContext.prototype[util.inspect.custom] = function inspect(depth, options)
393
- {
394
- return util.inspect(this.toJSON(), options);
395
- };
396
-
397
- module.exports = {
398
- ExportList: ExportList,
399
- ExportPage: ExportPage,
400
- ExportInstance: ExportInstance,
401
- ExportContext: ExportContext
402
- };
@@ -1,180 +0,0 @@
1
- /**
2
- * This code was generated by
3
- * \ / _ _ _| _ _
4
- * | (_)\/(_)(_|\/| |(/_ v1.0.0
5
- * / /
6
- */
7
-
8
- import BulkExports = require('../BulkExports');
9
- import Page = require('../../../base/Page');
10
- import Response = require('../../../http/response');
11
- import { SerializableClass } from '../../../interfaces';
12
-
13
- /**
14
- * Initialize the ExportConfigurationList
15
- *
16
- * PLEASE NOTE that this class contains preview products that are subject to
17
- * change. Use them with caution. If you currently do not have developer preview
18
- * access, please contact help@twilio.com.
19
- *
20
- * @param version - Version of the resource
21
- */
22
- declare function ExportConfigurationList(version: BulkExports): ExportConfigurationListInstance;
23
-
24
- /**
25
- * Options to pass to update
26
- *
27
- * @property enabled - Whether files are automatically generated
28
- * @property webhookMethod - Whether to GET or POST to the webhook url
29
- * @property webhookUrl - URL targeted at export
30
- */
31
- interface ExportConfigurationInstanceUpdateOptions {
32
- enabled?: boolean;
33
- webhookMethod?: string;
34
- webhookUrl?: string;
35
- }
36
-
37
- interface ExportConfigurationListInstance {
38
- /**
39
- * @param sid - sid of instance
40
- */
41
- (sid: string): ExportConfigurationContext;
42
- /**
43
- * Constructs a export_configuration
44
- *
45
- * @param resourceType - The type of communication – Messages, Calls, Conferences, and Participants
46
- */
47
- get(resourceType: string): ExportConfigurationContext;
48
- /**
49
- * Provide a user-friendly representation
50
- */
51
- toJSON(): any;
52
- }
53
-
54
- interface ExportConfigurationPayload extends ExportConfigurationResource, Page.TwilioResponsePayload {
55
- }
56
-
57
- interface ExportConfigurationResource {
58
- enabled: boolean;
59
- resource_type: string;
60
- url: string;
61
- webhook_method: string;
62
- webhook_url: string;
63
- }
64
-
65
- interface ExportConfigurationSolution {
66
- }
67
-
68
-
69
- declare class ExportConfigurationContext {
70
- /**
71
- * Initialize the ExportConfigurationContext
72
- *
73
- * PLEASE NOTE that this class contains preview products that are subject to
74
- * change. Use them with caution. If you currently do not have developer preview
75
- * access, please contact help@twilio.com.
76
- *
77
- * @param version - Version of the resource
78
- * @param resourceType - The type of communication – Messages, Calls, Conferences, and Participants
79
- */
80
- constructor(version: BulkExports, resourceType: string);
81
-
82
- /**
83
- * fetch a ExportConfigurationInstance
84
- *
85
- * @param callback - Callback to handle processed record
86
- */
87
- fetch(callback?: (error: Error | null, items: ExportConfigurationInstance) => any): Promise<ExportConfigurationInstance>;
88
- /**
89
- * Provide a user-friendly representation
90
- */
91
- toJSON(): any;
92
- /**
93
- * update a ExportConfigurationInstance
94
- *
95
- * @param callback - Callback to handle processed record
96
- */
97
- update(callback?: (error: Error | null, items: ExportConfigurationInstance) => any): Promise<ExportConfigurationInstance>;
98
- /**
99
- * update a ExportConfigurationInstance
100
- *
101
- * @param opts - Options for request
102
- * @param callback - Callback to handle processed record
103
- */
104
- update(opts?: ExportConfigurationInstanceUpdateOptions, callback?: (error: Error | null, items: ExportConfigurationInstance) => any): Promise<ExportConfigurationInstance>;
105
- }
106
-
107
-
108
- declare class ExportConfigurationInstance extends SerializableClass {
109
- /**
110
- * Initialize the ExportConfigurationContext
111
- *
112
- * PLEASE NOTE that this class contains preview products that are subject to
113
- * change. Use them with caution. If you currently do not have developer preview
114
- * access, please contact help@twilio.com.
115
- *
116
- * @param version - Version of the resource
117
- * @param payload - The instance payload
118
- * @param resourceType - The type of communication – Messages, Calls, Conferences, and Participants
119
- */
120
- constructor(version: BulkExports, payload: ExportConfigurationPayload, resourceType: string);
121
-
122
- private _proxy: ExportConfigurationContext;
123
- enabled: boolean;
124
- /**
125
- * fetch a ExportConfigurationInstance
126
- *
127
- * @param callback - Callback to handle processed record
128
- */
129
- fetch(callback?: (error: Error | null, items: ExportConfigurationInstance) => any): Promise<ExportConfigurationInstance>;
130
- resourceType: string;
131
- /**
132
- * Provide a user-friendly representation
133
- */
134
- toJSON(): any;
135
- /**
136
- * update a ExportConfigurationInstance
137
- *
138
- * @param callback - Callback to handle processed record
139
- */
140
- update(callback?: (error: Error | null, items: ExportConfigurationInstance) => any): Promise<ExportConfigurationInstance>;
141
- /**
142
- * update a ExportConfigurationInstance
143
- *
144
- * @param opts - Options for request
145
- * @param callback - Callback to handle processed record
146
- */
147
- update(opts?: ExportConfigurationInstanceUpdateOptions, callback?: (error: Error | null, items: ExportConfigurationInstance) => any): Promise<ExportConfigurationInstance>;
148
- url: string;
149
- webhookMethod: string;
150
- webhookUrl: string;
151
- }
152
-
153
-
154
- declare class ExportConfigurationPage extends Page<BulkExports, ExportConfigurationPayload, ExportConfigurationResource, ExportConfigurationInstance> {
155
- /**
156
- * Initialize the ExportConfigurationPage
157
- *
158
- * PLEASE NOTE that this class contains preview products that are subject to
159
- * change. Use them with caution. If you currently do not have developer preview
160
- * access, please contact help@twilio.com.
161
- *
162
- * @param version - Version of the resource
163
- * @param response - Response from the API
164
- * @param solution - Path solution
165
- */
166
- constructor(version: BulkExports, response: Response<string>, solution: ExportConfigurationSolution);
167
-
168
- /**
169
- * Build an instance of ExportConfigurationInstance
170
- *
171
- * @param payload - Payload response from the API
172
- */
173
- getInstance(payload: ExportConfigurationPayload): ExportConfigurationInstance;
174
- /**
175
- * Provide a user-friendly representation
176
- */
177
- toJSON(): any;
178
- }
179
-
180
- export { ExportConfigurationContext, ExportConfigurationInstance, ExportConfigurationInstanceUpdateOptions, ExportConfigurationList, ExportConfigurationListInstance, ExportConfigurationPage, ExportConfigurationPayload, ExportConfigurationResource, ExportConfigurationSolution }