twilio 3.69.0 → 3.70.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (32) hide show
  1. package/CHANGES.md +21 -0
  2. package/lib/jwt/AccessToken.d.ts +16 -0
  3. package/lib/jwt/AccessToken.js +20 -0
  4. package/lib/rest/Media.d.ts +28 -0
  5. package/lib/rest/Media.js +64 -0
  6. package/lib/rest/Twilio.d.ts +2 -0
  7. package/lib/rest/Twilio.js +14 -0
  8. package/lib/rest/api/v2010/account/incomingPhoneNumber/local.d.ts +5 -1
  9. package/lib/rest/api/v2010/account/incomingPhoneNumber/local.js +3 -0
  10. package/lib/rest/api/v2010/account/incomingPhoneNumber/mobile.d.ts +5 -1
  11. package/lib/rest/api/v2010/account/incomingPhoneNumber/mobile.js +3 -0
  12. package/lib/rest/api/v2010/account/incomingPhoneNumber/tollFree.d.ts +5 -1
  13. package/lib/rest/api/v2010/account/incomingPhoneNumber/tollFree.js +3 -0
  14. package/lib/rest/api/v2010/account/incomingPhoneNumber.d.ts +5 -1
  15. package/lib/rest/api/v2010/account/incomingPhoneNumber.js +3 -0
  16. package/lib/rest/media/V1.d.ts +28 -0
  17. package/lib/rest/media/V1.js +59 -0
  18. package/lib/rest/media/v1/mediaProcessor.d.ts +355 -0
  19. package/lib/rest/media/v1/mediaProcessor.js +702 -0
  20. package/lib/rest/media/v1/playerStreamer/playbackGrant.d.ts +162 -0
  21. package/lib/rest/media/v1/playerStreamer/playbackGrant.js +384 -0
  22. package/lib/rest/media/v1/playerStreamer.d.ts +366 -0
  23. package/lib/rest/media/v1/playerStreamer.js +729 -0
  24. package/lib/rest/messaging/v1/brandRegistration/brandVetting.d.ts +286 -0
  25. package/lib/rest/messaging/v1/brandRegistration/brandVetting.js +521 -0
  26. package/lib/rest/messaging/v1/brandRegistration.d.ts +14 -1
  27. package/lib/rest/messaging/v1/brandRegistration.js +36 -0
  28. package/lib/rest/messaging/v1/service.d.ts +8 -0
  29. package/lib/rest/messaging/v1/service.js +14 -0
  30. package/lib/rest/video/v1/room.d.ts +4 -0
  31. package/lib/rest/video/v1/room.js +7 -1
  32. package/package.json +2 -2
@@ -0,0 +1,521 @@
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 Page = require('../../../../base/Page'); /* jshint ignore:line */
16
+ var deserialize = require(
17
+ '../../../../base/deserialize'); /* jshint ignore:line */
18
+ var values = require('../../../../base/values'); /* jshint ignore:line */
19
+
20
+ var BrandVettingList;
21
+ var BrandVettingPage;
22
+ var BrandVettingInstance;
23
+
24
+ /* jshint ignore:start */
25
+ /**
26
+ * Initialize the BrandVettingList
27
+ *
28
+ * PLEASE NOTE that this class contains beta products that are subject to change.
29
+ * Use them with caution.
30
+ *
31
+ * @constructor Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingList
32
+ *
33
+ * @param {Twilio.Messaging.V1} version - Version of the resource
34
+ * @param {string} brandSid - A2P BrandRegistration Sid
35
+ */
36
+ /* jshint ignore:end */
37
+ BrandVettingList = function BrandVettingList(version, brandSid) {
38
+ /* jshint ignore:start */
39
+ /**
40
+ * @function brandVettings
41
+ * @memberof Twilio.Messaging.V1.BrandRegistrationContext#
42
+ *
43
+ * @param {string} sid - sid of instance
44
+ *
45
+ * @returns {Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingContext}
46
+ */
47
+ /* jshint ignore:end */
48
+ function BrandVettingListInstance(sid) {
49
+ return BrandVettingListInstance.get(sid);
50
+ }
51
+
52
+ BrandVettingListInstance._version = version;
53
+ // Path Solution
54
+ BrandVettingListInstance._solution = {brandSid: brandSid};
55
+ BrandVettingListInstance._uri = `/a2p/BrandRegistrations/${brandSid}/Vettings`;
56
+ /* jshint ignore:start */
57
+ /**
58
+ * create a BrandVettingInstance
59
+ *
60
+ * @function create
61
+ * @memberof Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingList#
62
+ *
63
+ * @param {object} opts - Options for request
64
+ * @param {brand_vetting.vetting_provider} opts.vettingProvider -
65
+ * Third-party provider of the vettings to create
66
+ * @param {string} [opts.vettingId] - The unique ID of the vetting
67
+ * @param {function} [callback] - Callback to handle processed record
68
+ *
69
+ * @returns {Promise} Resolves to processed BrandVettingInstance
70
+ */
71
+ /* jshint ignore:end */
72
+ BrandVettingListInstance.create = function create(opts, callback) {
73
+ if (_.isUndefined(opts)) {
74
+ throw new Error('Required parameter "opts" missing.');
75
+ }
76
+ if (_.isUndefined(opts.vettingProvider)) {
77
+ throw new Error('Required parameter "opts.vettingProvider" missing.');
78
+ }
79
+
80
+ var deferred = Q.defer();
81
+ var data = values.of({
82
+ 'VettingProvider': _.get(opts, 'vettingProvider'),
83
+ 'VettingId': _.get(opts, 'vettingId')
84
+ });
85
+
86
+ var promise = this._version.create({uri: this._uri, method: 'POST', data: data});
87
+
88
+ promise = promise.then(function(payload) {
89
+ deferred.resolve(new BrandVettingInstance(this._version, payload));
90
+ }.bind(this));
91
+
92
+ promise.catch(function(error) {
93
+ deferred.reject(error);
94
+ });
95
+
96
+ if (_.isFunction(callback)) {
97
+ deferred.promise.nodeify(callback);
98
+ }
99
+
100
+ return deferred.promise;
101
+ };
102
+
103
+ /* jshint ignore:start */
104
+ /**
105
+ * Streams BrandVettingInstance records from the API.
106
+ *
107
+ * This operation lazily loads records as efficiently as possible until the limit
108
+ * is reached.
109
+ *
110
+ * The results are passed into the callback function, so this operation is memory
111
+ * efficient.
112
+ *
113
+ * If a function is passed as the first argument, it will be used as the callback
114
+ * function.
115
+ *
116
+ * @function each
117
+ * @memberof Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingList#
118
+ *
119
+ * @param {object} [opts] - Options for request
120
+ * @param {brand_vetting.vetting_provider} [opts.vettingProvider] -
121
+ * Third-party provider of the vettings to create
122
+ * @param {number} [opts.limit] -
123
+ * Upper limit for the number of records to return.
124
+ * each() guarantees never to return more than limit.
125
+ * Default is no limit
126
+ * @param {number} [opts.pageSize] -
127
+ * Number of records to fetch per request,
128
+ * when not set will use the default value of 50 records.
129
+ * If no pageSize is defined but a limit is defined,
130
+ * each() will attempt to read the limit with the most efficient
131
+ * page size, i.e. min(limit, 1000)
132
+ * @param {Function} [opts.callback] -
133
+ * Function to process each record. If this and a positional
134
+ * callback are passed, this one will be used
135
+ * @param {Function} [opts.done] -
136
+ * Function to be called upon completion of streaming
137
+ * @param {Function} [callback] - Function to process each record
138
+ */
139
+ /* jshint ignore:end */
140
+ BrandVettingListInstance.each = function each(opts, callback) {
141
+ if (_.isFunction(opts)) {
142
+ callback = opts;
143
+ opts = {};
144
+ }
145
+ opts = opts || {};
146
+ if (opts.callback) {
147
+ callback = opts.callback;
148
+ }
149
+ if (_.isUndefined(callback)) {
150
+ throw new Error('Callback function must be provided');
151
+ }
152
+
153
+ var done = false;
154
+ var currentPage = 1;
155
+ var currentResource = 0;
156
+ var limits = this._version.readLimits({
157
+ limit: opts.limit,
158
+ pageSize: opts.pageSize
159
+ });
160
+
161
+ function onComplete(error) {
162
+ done = true;
163
+ if (_.isFunction(opts.done)) {
164
+ opts.done(error);
165
+ }
166
+ }
167
+
168
+ function fetchNextPage(fn) {
169
+ var promise = fn();
170
+ if (_.isUndefined(promise)) {
171
+ onComplete();
172
+ return;
173
+ }
174
+
175
+ promise.then(function(page) {
176
+ _.each(page.instances, function(instance) {
177
+ if (done || (!_.isUndefined(opts.limit) && currentResource >= opts.limit)) {
178
+ done = true;
179
+ return false;
180
+ }
181
+
182
+ currentResource++;
183
+ callback(instance, onComplete);
184
+ });
185
+
186
+ if (!done) {
187
+ currentPage++;
188
+ fetchNextPage(_.bind(page.nextPage, page));
189
+ }
190
+ });
191
+
192
+ promise.catch(onComplete);
193
+ }
194
+
195
+ fetchNextPage(_.bind(this.page, this, _.merge(opts, limits)));
196
+ };
197
+
198
+ /* jshint ignore:start */
199
+ /**
200
+ * Lists BrandVettingInstance records from the API as a list.
201
+ *
202
+ * If a function is passed as the first argument, it will be used as the callback
203
+ * function.
204
+ *
205
+ * @function list
206
+ * @memberof Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingList#
207
+ *
208
+ * @param {object} [opts] - Options for request
209
+ * @param {brand_vetting.vetting_provider} [opts.vettingProvider] -
210
+ * Third-party provider of the vettings to create
211
+ * @param {number} [opts.limit] -
212
+ * Upper limit for the number of records to return.
213
+ * list() guarantees never to return more than limit.
214
+ * Default is no limit
215
+ * @param {number} [opts.pageSize] -
216
+ * Number of records to fetch per request,
217
+ * when not set will use the default value of 50 records.
218
+ * If no page_size is defined but a limit is defined,
219
+ * list() will attempt to read the limit with the most
220
+ * efficient page size, i.e. min(limit, 1000)
221
+ * @param {function} [callback] - Callback to handle list of records
222
+ *
223
+ * @returns {Promise} Resolves to a list of records
224
+ */
225
+ /* jshint ignore:end */
226
+ BrandVettingListInstance.list = function list(opts, callback) {
227
+ if (_.isFunction(opts)) {
228
+ callback = opts;
229
+ opts = {};
230
+ }
231
+ opts = opts || {};
232
+ var deferred = Q.defer();
233
+ var allResources = [];
234
+ opts.callback = function(resource, done) {
235
+ allResources.push(resource);
236
+
237
+ if (!_.isUndefined(opts.limit) && allResources.length === opts.limit) {
238
+ done();
239
+ }
240
+ };
241
+
242
+ opts.done = function(error) {
243
+ if (_.isUndefined(error)) {
244
+ deferred.resolve(allResources);
245
+ } else {
246
+ deferred.reject(error);
247
+ }
248
+ };
249
+
250
+ if (_.isFunction(callback)) {
251
+ deferred.promise.nodeify(callback);
252
+ }
253
+
254
+ this.each(opts);
255
+ return deferred.promise;
256
+ };
257
+
258
+ /* jshint ignore:start */
259
+ /**
260
+ * Retrieve a single page of BrandVettingInstance records from the API.
261
+ *
262
+ * The request is executed immediately.
263
+ *
264
+ * If a function is passed as the first argument, it will be used as the callback
265
+ * function.
266
+ *
267
+ * @function page
268
+ * @memberof Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingList#
269
+ *
270
+ * @param {object} [opts] - Options for request
271
+ * @param {brand_vetting.vetting_provider} [opts.vettingProvider] -
272
+ * Third-party provider of the vettings to create
273
+ * @param {string} [opts.pageToken] - PageToken provided by the API
274
+ * @param {number} [opts.pageNumber] -
275
+ * Page Number, this value is simply for client state
276
+ * @param {number} [opts.pageSize] - Number of records to return, defaults to 50
277
+ * @param {function} [callback] - Callback to handle list of records
278
+ *
279
+ * @returns {Promise} Resolves to a list of records
280
+ */
281
+ /* jshint ignore:end */
282
+ BrandVettingListInstance.page = function page(opts, callback) {
283
+ if (_.isFunction(opts)) {
284
+ callback = opts;
285
+ opts = {};
286
+ }
287
+ opts = opts || {};
288
+
289
+ var deferred = Q.defer();
290
+ var data = values.of({
291
+ 'VettingProvider': _.get(opts, 'vettingProvider'),
292
+ 'PageToken': opts.pageToken,
293
+ 'Page': opts.pageNumber,
294
+ 'PageSize': opts.pageSize
295
+ });
296
+
297
+ var promise = this._version.page({uri: this._uri, method: 'GET', params: data});
298
+
299
+ promise = promise.then(function(payload) {
300
+ deferred.resolve(new BrandVettingPage(this._version, payload, this._solution));
301
+ }.bind(this));
302
+
303
+ promise.catch(function(error) {
304
+ deferred.reject(error);
305
+ });
306
+
307
+ if (_.isFunction(callback)) {
308
+ deferred.promise.nodeify(callback);
309
+ }
310
+
311
+ return deferred.promise;
312
+ };
313
+
314
+ /* jshint ignore:start */
315
+ /**
316
+ * Retrieve a single target page of BrandVettingInstance records from the API.
317
+ *
318
+ * The request is executed immediately.
319
+ *
320
+ * If a function is passed as the first argument, it will be used as the callback
321
+ * function.
322
+ *
323
+ * @function getPage
324
+ * @memberof Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingList#
325
+ *
326
+ * @param {string} [targetUrl] - API-generated URL for the requested results page
327
+ * @param {function} [callback] - Callback to handle list of records
328
+ *
329
+ * @returns {Promise} Resolves to a list of records
330
+ */
331
+ /* jshint ignore:end */
332
+ BrandVettingListInstance.getPage = function getPage(targetUrl, callback) {
333
+ var deferred = Q.defer();
334
+
335
+ var promise = this._version._domain.twilio.request({method: 'GET', uri: targetUrl});
336
+
337
+ promise = promise.then(function(payload) {
338
+ deferred.resolve(new BrandVettingPage(this._version, payload, this._solution));
339
+ }.bind(this));
340
+
341
+ promise.catch(function(error) {
342
+ deferred.reject(error);
343
+ });
344
+
345
+ if (_.isFunction(callback)) {
346
+ deferred.promise.nodeify(callback);
347
+ }
348
+
349
+ return deferred.promise;
350
+ };
351
+
352
+ /* jshint ignore:start */
353
+ /**
354
+ * Provide a user-friendly representation
355
+ *
356
+ * @function toJSON
357
+ * @memberof Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingList#
358
+ *
359
+ * @returns Object
360
+ */
361
+ /* jshint ignore:end */
362
+ BrandVettingListInstance.toJSON = function toJSON() {
363
+ return this._solution;
364
+ };
365
+
366
+ BrandVettingListInstance[util.inspect.custom] = function inspect(depth, options)
367
+ {
368
+ return util.inspect(this.toJSON(), options);
369
+ };
370
+
371
+ return BrandVettingListInstance;
372
+ };
373
+
374
+
375
+ /* jshint ignore:start */
376
+ /**
377
+ * Initialize the BrandVettingPage
378
+ *
379
+ * PLEASE NOTE that this class contains beta products that are subject to change.
380
+ * Use them with caution.
381
+ *
382
+ * @constructor Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingPage
383
+ *
384
+ * @param {V1} version - Version of the resource
385
+ * @param {Response<string>} response - Response from the API
386
+ * @param {BrandVettingSolution} solution - Path solution
387
+ *
388
+ * @returns BrandVettingPage
389
+ */
390
+ /* jshint ignore:end */
391
+ BrandVettingPage = function BrandVettingPage(version, response, solution) {
392
+ // Path Solution
393
+ this._solution = solution;
394
+
395
+ Page.prototype.constructor.call(this, version, response, this._solution);
396
+ };
397
+
398
+ _.extend(BrandVettingPage.prototype, Page.prototype);
399
+ BrandVettingPage.prototype.constructor = BrandVettingPage;
400
+
401
+ /* jshint ignore:start */
402
+ /**
403
+ * Build an instance of BrandVettingInstance
404
+ *
405
+ * @function getInstance
406
+ * @memberof Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingPage#
407
+ *
408
+ * @param {BrandVettingPayload} payload - Payload response from the API
409
+ *
410
+ * @returns BrandVettingInstance
411
+ */
412
+ /* jshint ignore:end */
413
+ BrandVettingPage.prototype.getInstance = function getInstance(payload) {
414
+ return new BrandVettingInstance(this._version, payload, this._solution.brandSid);
415
+ };
416
+
417
+ /* jshint ignore:start */
418
+ /**
419
+ * Provide a user-friendly representation
420
+ *
421
+ * @function toJSON
422
+ * @memberof Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingPage#
423
+ *
424
+ * @returns Object
425
+ */
426
+ /* jshint ignore:end */
427
+ BrandVettingPage.prototype.toJSON = function toJSON() {
428
+ let clone = {};
429
+ _.forOwn(this, function(value, key) {
430
+ if (!_.startsWith(key, '_') && ! _.isFunction(value)) {
431
+ clone[key] = value;
432
+ }
433
+ });
434
+ return clone;
435
+ };
436
+
437
+ BrandVettingPage.prototype[util.inspect.custom] = function inspect(depth,
438
+ options) {
439
+ return util.inspect(this.toJSON(), options);
440
+ };
441
+
442
+
443
+ /* jshint ignore:start */
444
+ /**
445
+ * Initialize the BrandVettingContext
446
+ *
447
+ * PLEASE NOTE that this class contains beta products that are subject to change.
448
+ * Use them with caution.
449
+ *
450
+ * @constructor Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingInstance
451
+ *
452
+ * @property {string} accountSid - The SID of the Account that created the vetting
453
+ * @property {string} brandSid - A2P BrandRegistration Sid
454
+ * @property {string} brandVettingSid - SID for third-party vetting record
455
+ * @property {Date} dateUpdated -
456
+ * The ISO 8601 date and time in GMT when the resource was last updated
457
+ * @property {Date} dateCreated -
458
+ * The ISO 8601 date and time in GMT when the resource was created
459
+ * @property {string} vettingId - The unique ID of the vetting
460
+ * @property {string} vettingClass - The type of vetting
461
+ * @property {string} vettingStatus - Status of vetting attempt
462
+ * @property {brand_vetting.vetting_provider} vettingProvider -
463
+ * Third-party provider that has conducted the vetting
464
+ * @property {string} url - The absolute URL of the Brand Vetting
465
+ *
466
+ * @param {V1} version - Version of the resource
467
+ * @param {BrandVettingPayload} payload - The instance payload
468
+ * @param {sid} brandSid - A2P BrandRegistration Sid
469
+ */
470
+ /* jshint ignore:end */
471
+ BrandVettingInstance = function BrandVettingInstance(version, payload, brandSid)
472
+ {
473
+ this._version = version;
474
+
475
+ // Marshaled Properties
476
+ this.accountSid = payload.account_sid; // jshint ignore:line
477
+ this.brandSid = payload.brand_sid; // jshint ignore:line
478
+ this.brandVettingSid = payload.brand_vetting_sid; // jshint ignore:line
479
+ this.dateUpdated = deserialize.iso8601DateTime(payload.date_updated); // jshint ignore:line
480
+ this.dateCreated = deserialize.iso8601DateTime(payload.date_created); // jshint ignore:line
481
+ this.vettingId = payload.vetting_id; // jshint ignore:line
482
+ this.vettingClass = payload.vetting_class; // jshint ignore:line
483
+ this.vettingStatus = payload.vetting_status; // jshint ignore:line
484
+ this.vettingProvider = payload.vetting_provider; // jshint ignore:line
485
+ this.url = payload.url; // jshint ignore:line
486
+
487
+ // Context
488
+ this._context = undefined;
489
+ this._solution = {brandSid: brandSid, };
490
+ };
491
+
492
+ /* jshint ignore:start */
493
+ /**
494
+ * Provide a user-friendly representation
495
+ *
496
+ * @function toJSON
497
+ * @memberof Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingInstance#
498
+ *
499
+ * @returns Object
500
+ */
501
+ /* jshint ignore:end */
502
+ BrandVettingInstance.prototype.toJSON = function toJSON() {
503
+ let clone = {};
504
+ _.forOwn(this, function(value, key) {
505
+ if (!_.startsWith(key, '_') && ! _.isFunction(value)) {
506
+ clone[key] = value;
507
+ }
508
+ });
509
+ return clone;
510
+ };
511
+
512
+ BrandVettingInstance.prototype[util.inspect.custom] = function inspect(depth,
513
+ options) {
514
+ return util.inspect(this.toJSON(), options);
515
+ };
516
+
517
+ module.exports = {
518
+ BrandVettingList: BrandVettingList,
519
+ BrandVettingPage: BrandVettingPage,
520
+ BrandVettingInstance: BrandVettingInstance
521
+ };
@@ -8,8 +8,12 @@
8
8
  import Page = require('../../../base/Page');
9
9
  import Response = require('../../../http/response');
10
10
  import V1 = require('../V1');
11
+ import { BrandVettingList } from './brandRegistration/brandVetting';
12
+ import { BrandVettingListInstance } from './brandRegistration/brandVetting';
11
13
  import { SerializableClass } from '../../../interfaces';
12
14
 
15
+ type BrandRegistrationBrandFeedback = 'TAX_ID'|'STOCK_SYMBOL'|'NONPROFIT'|'GOVERNMENT_ENTITY'|'OTHERS';
16
+
13
17
  type BrandRegistrationIdentityStatus = 'SELF_DECLARED'|'UNVERIFIED'|'VERIFIED'|'VETTED_VERIFIED';
14
18
 
15
19
  type BrandRegistrationStatus = 'PENDING'|'APPROVED'|'FAILED';
@@ -224,6 +228,7 @@ interface BrandRegistrationPayload extends BrandRegistrationResource, Page.Twili
224
228
  interface BrandRegistrationResource {
225
229
  a2p_profile_bundle_sid: string;
226
230
  account_sid: string;
231
+ brand_feedback: BrandRegistrationBrandFeedback[];
227
232
  brand_score: number;
228
233
  brand_type: string;
229
234
  customer_profile_bundle_sid: string;
@@ -231,6 +236,7 @@ interface BrandRegistrationResource {
231
236
  date_updated: Date;
232
237
  failure_reason: string;
233
238
  identity_status: BrandRegistrationIdentityStatus;
239
+ links: string;
234
240
  mock: boolean;
235
241
  russell_3000: boolean;
236
242
  sid: string;
@@ -257,6 +263,7 @@ declare class BrandRegistrationContext {
257
263
  */
258
264
  constructor(version: V1, sid: string);
259
265
 
266
+ brandVettings: BrandVettingListInstance;
260
267
  /**
261
268
  * fetch a BrandRegistrationInstance
262
269
  *
@@ -286,8 +293,13 @@ declare class BrandRegistrationInstance extends SerializableClass {
286
293
  private _proxy: BrandRegistrationContext;
287
294
  a2PProfileBundleSid: string;
288
295
  accountSid: string;
296
+ brandFeedback: BrandRegistrationBrandFeedback[];
289
297
  brandScore: number;
290
298
  brandType: string;
299
+ /**
300
+ * Access the brandVettings
301
+ */
302
+ brandVettings(): BrandVettingListInstance;
291
303
  customerProfileBundleSid: string;
292
304
  dateCreated: Date;
293
305
  dateUpdated: Date;
@@ -299,6 +311,7 @@ declare class BrandRegistrationInstance extends SerializableClass {
299
311
  */
300
312
  fetch(callback?: (error: Error | null, items: BrandRegistrationInstance) => any): Promise<BrandRegistrationInstance>;
301
313
  identityStatus: BrandRegistrationIdentityStatus;
314
+ links: string;
302
315
  mock: boolean;
303
316
  russell3000: boolean;
304
317
  sid: string;
@@ -339,4 +352,4 @@ declare class BrandRegistrationPage extends Page<V1, BrandRegistrationPayload, B
339
352
  toJSON(): any;
340
353
  }
341
354
 
342
- export { BrandRegistrationContext, BrandRegistrationIdentityStatus, BrandRegistrationInstance, BrandRegistrationList, BrandRegistrationListInstance, BrandRegistrationListInstanceCreateOptions, BrandRegistrationListInstanceEachOptions, BrandRegistrationListInstanceOptions, BrandRegistrationListInstancePageOptions, BrandRegistrationPage, BrandRegistrationPayload, BrandRegistrationResource, BrandRegistrationSolution, BrandRegistrationStatus }
355
+ export { BrandRegistrationBrandFeedback, BrandRegistrationContext, BrandRegistrationIdentityStatus, BrandRegistrationInstance, BrandRegistrationList, BrandRegistrationListInstance, BrandRegistrationListInstanceCreateOptions, BrandRegistrationListInstanceEachOptions, BrandRegistrationListInstanceOptions, BrandRegistrationListInstancePageOptions, BrandRegistrationPage, BrandRegistrationPayload, BrandRegistrationResource, BrandRegistrationSolution, BrandRegistrationStatus }
@@ -12,6 +12,8 @@
12
12
  var Q = require('q'); /* jshint ignore:line */
13
13
  var _ = require('lodash'); /* jshint ignore:line */
14
14
  var util = require('util'); /* jshint ignore:line */
15
+ var BrandVettingList = require(
16
+ './brandRegistration/brandVetting').BrandVettingList;
15
17
  var Page = require('../../../base/Page'); /* jshint ignore:line */
16
18
  var deserialize = require(
17
19
  '../../../base/deserialize'); /* jshint ignore:line */
@@ -485,12 +487,14 @@ BrandRegistrationPage.prototype[util.inspect.custom] = function inspect(depth,
485
487
  * @property {string} failureReason - A reason why brand registration has failed
486
488
  * @property {string} url - The absolute URL of the Brand Registration
487
489
  * @property {number} brandScore - Brand score
490
+ * @property {brand_registration.brand_feedback} brandFeedback - Brand feedback
488
491
  * @property {brand_registration.identity_status} identityStatus - Identity Status
489
492
  * @property {boolean} russell3000 - Russell 3000
490
493
  * @property {string} taxExemptStatus - Tax Exempt Status
491
494
  * @property {boolean} skipAutomaticSecVet - Skip Automatic Secondary Vetting
492
495
  * @property {boolean} mock -
493
496
  * A boolean that specifies whether brand should be a mock or not. If true, brand will be registered as a mock brand. Defaults to false if no value is provided.
497
+ * @property {string} links - The links
494
498
  *
495
499
  * @param {V1} version - Version of the resource
496
500
  * @param {BrandRegistrationPayload} payload - The instance payload
@@ -514,11 +518,13 @@ BrandRegistrationInstance = function BrandRegistrationInstance(version, payload,
514
518
  this.failureReason = payload.failure_reason; // jshint ignore:line
515
519
  this.url = payload.url; // jshint ignore:line
516
520
  this.brandScore = deserialize.integer(payload.brand_score); // jshint ignore:line
521
+ this.brandFeedback = payload.brand_feedback; // jshint ignore:line
517
522
  this.identityStatus = payload.identity_status; // jshint ignore:line
518
523
  this.russell3000 = payload.russell_3000; // jshint ignore:line
519
524
  this.taxExemptStatus = payload.tax_exempt_status; // jshint ignore:line
520
525
  this.skipAutomaticSecVet = payload.skip_automatic_sec_vet; // jshint ignore:line
521
526
  this.mock = payload.mock; // jshint ignore:line
527
+ this.links = payload.links; // jshint ignore:line
522
528
 
523
529
  // Context
524
530
  this._context = undefined;
@@ -552,6 +558,20 @@ BrandRegistrationInstance.prototype.fetch = function fetch(callback) {
552
558
  return this._proxy.fetch(callback);
553
559
  };
554
560
 
561
+ /* jshint ignore:start */
562
+ /**
563
+ * Access the brandVettings
564
+ *
565
+ * @function brandVettings
566
+ * @memberof Twilio.Messaging.V1.BrandRegistrationInstance#
567
+ *
568
+ * @returns {Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingList}
569
+ */
570
+ /* jshint ignore:end */
571
+ BrandRegistrationInstance.prototype.brandVettings = function brandVettings() {
572
+ return this._proxy.brandVettings;
573
+ };
574
+
555
575
  /* jshint ignore:start */
556
576
  /**
557
577
  * Provide a user-friendly representation
@@ -587,6 +607,9 @@ BrandRegistrationInstance.prototype[util.inspect.custom] = function
587
607
  *
588
608
  * @constructor Twilio.Messaging.V1.BrandRegistrationContext
589
609
  *
610
+ * @property {Twilio.Messaging.V1.BrandRegistrationContext.BrandVettingList} brandVettings -
611
+ * brandVettings resource
612
+ *
590
613
  * @param {V1} version - Version of the resource
591
614
  * @param {sid} sid - The SID that identifies the resource to fetch
592
615
  */
@@ -597,6 +620,9 @@ BrandRegistrationContext = function BrandRegistrationContext(version, sid) {
597
620
  // Path Solution
598
621
  this._solution = {sid: sid, };
599
622
  this._uri = `/a2p/BrandRegistrations/${sid}`;
623
+
624
+ // Dependents
625
+ this._brandVettings = undefined;
600
626
  };
601
627
 
602
628
  /* jshint ignore:start */
@@ -630,6 +656,16 @@ BrandRegistrationContext.prototype.fetch = function fetch(callback) {
630
656
  return deferred.promise;
631
657
  };
632
658
 
659
+ Object.defineProperty(BrandRegistrationContext.prototype,
660
+ 'brandVettings', {
661
+ get: function() {
662
+ if (!this._brandVettings) {
663
+ this._brandVettings = new BrandVettingList(this._version, this._solution.sid);
664
+ }
665
+ return this._brandVettings;
666
+ }
667
+ });
668
+
633
669
  /* jshint ignore:start */
634
670
  /**
635
671
  * Provide a user-friendly representation