Skip to content

Commit

Permalink
[Librarian] Regenerated @ ee964c66599ebcd125eb411ba410bde1e62b3503
Browse files Browse the repository at this point in the history
  • Loading branch information
twilio-ci committed Mar 4, 2020
1 parent 5a65128 commit ec54ee2
Show file tree
Hide file tree
Showing 60 changed files with 5,805 additions and 662 deletions.
38 changes: 38 additions & 0 deletions CHANGES.md
@@ -1,6 +1,44 @@
twilio-node changelog
=====================

[2020-03-04] Version 3.40.0
---------------------------
**Library - Docs**
- [PR #541](https://github.com/twilio/twilio-node/pull/541): add url parameter documentation in twilio.webhook(). Thanks to [@fungiboletus](https://github.com/fungiboletus)!
- [PR #532](https://github.com/twilio/twilio-node/pull/532): guide for enabling lazy loading. Thanks to [@eshanholtz](https://github.com/eshanholtz)!

**Library - Fix**
- [PR #534](https://github.com/twilio/twilio-node/pull/534): proper indentation. Thanks to [@eshanholtz](https://github.com/eshanholtz)!

**Library - Feature**
- [PR #526](https://github.com/twilio/twilio-node/pull/526): Faster requiring using optional lazy loading. Thanks to [@wolfenrain](https://github.com/wolfenrain)!

**Authy**
- Added the `configuration` property to services to return the service level configurations
- Added optional parameter `Push` when creating a service to send the service level push factor configuration
- Remove FactorStrength support for Factors and Challenges **(breaking change)**

**Messaging**
- Correct the alpha sender capabilities property type **(breaking change)**

**Preview**
- Removed `/Devices` register Branded Calls endpoint, as per iOS sample app deprecation **(breaking change)**
- Removed `Twilio-Sandbox-Mode` request header from the Branded Calls endpoints, as not officially supported **(breaking change)**
- Removed `Verify` version from `preview` subdomain in favor to `verify` subdomain. **(breaking change)**

**Serverless**
- Add UI-Editable field to Services

**Supersim**
- Add `inactive` status for Super SIM which is an alias for `deactivated`

**Taskrouter**
- Adding value range to `priority` in task endpoint

**Verify**
- Fix `SendCodeAttempts` type. It's an array of objects instead of a unique object. **(breaking change)**


[2020-02-19] Version 3.39.5
---------------------------
**Api**
Expand Down
2 changes: 0 additions & 2 deletions lib/rest/Preview.d.ts
Expand Up @@ -23,7 +23,6 @@ import { BusinessListInstance } from './preview/trusted_comms/business';
import { CommandListInstance } from './preview/wireless/command';
import { CpsListInstance } from './preview/trusted_comms/cps';
import { CurrentCallListInstance } from './preview/trusted_comms/currentCall';
import { DeviceListInstance } from './preview/trusted_comms/device';
import { ExportConfigurationListInstance } from './preview/bulk_exports/exportConfiguration';
import { ExportListInstance } from './preview/bulk_exports/export';
import { FleetListInstance } from './preview/deployed_devices/fleet';
Expand Down Expand Up @@ -53,7 +52,6 @@ declare class Preview extends Domain {
readonly cps: CpsListInstance;
readonly currentCalls: CurrentCallListInstance;
readonly deployed_devices: DeployedDevices;
readonly devices: DeviceListInstance;
readonly exportConfiguration: ExportConfigurationListInstance;
readonly exports: ExportListInstance;
readonly fleets: FleetListInstance;
Expand Down
8 changes: 0 additions & 8 deletions lib/rest/Preview.js
Expand Up @@ -63,7 +63,6 @@ var Wireless = require('./preview/Wireless'); /* jshint ignore:line */
* @property {Twilio.Preview.TrustedComms.CpsList} cps - cps resource
* @property {Twilio.Preview.TrustedComms.CurrentCallList} currentCalls -
* currentCalls resource
* @property {Twilio.Preview.TrustedComms.DeviceList} devices - devices resource
* @property {Twilio.Preview.TrustedComms.PhoneCallList} phoneCalls -
* phoneCalls resource
*
Expand Down Expand Up @@ -263,13 +262,6 @@ Object.defineProperty(Preview.prototype,
}
});

Object.defineProperty(Preview.prototype,
'devices', {
get: function() {
return this.trusted_comms.devices;
}
});

Object.defineProperty(Preview.prototype,
'phoneCalls', {
get: function() {
Expand Down
32 changes: 32 additions & 0 deletions lib/rest/Supersim.d.ts
@@ -0,0 +1,32 @@
/**
* This code was generated by
* \ / _ _ _| _ _
* | (_)\/(_)(_|\/| |(/_ v1.0.0
* / /
*/

import Domain = require('../base/Domain');
import Twilio = require('./Twilio');
import V1 = require('./supersim/V1');
import { CommandListInstance } from './supersim/v1/command';
import { FleetListInstance } from './supersim/v1/fleet';
import { SimListInstance } from './supersim/v1/sim';
import { UsageRecordListInstance } from './supersim/v1/usageRecord';


declare class Supersim extends Domain {
/**
* Initialize supersim domain
*
* @param twilio - The twilio client
*/
constructor(twilio: Twilio);

readonly commands: CommandListInstance;
readonly fleets: FleetListInstance;
readonly sims: SimListInstance;
readonly usageRecords: UsageRecordListInstance;
readonly v1: V1;
}

export = Supersim;
79 changes: 79 additions & 0 deletions lib/rest/Supersim.js
@@ -0,0 +1,79 @@
'use strict';

/* jshint ignore:start */
/**
* This code was generated by
* \ / _ _ _| _ _
* | (_)\/(_)(_|\/| |(/_ v1.0.0
* / /
*/
/* jshint ignore:end */

var _ = require('lodash'); /* jshint ignore:line */
var Domain = require('../base/Domain'); /* jshint ignore:line */
var V1 = require('./supersim/V1'); /* jshint ignore:line */


/* jshint ignore:start */
/**
* Initialize supersim domain
*
* @constructor Twilio.Supersim
*
* @property {Twilio.Supersim.V1} v1 - v1 version
* @property {Twilio.Supersim.V1.CommandList} commands - commands resource
* @property {Twilio.Supersim.V1.FleetList} fleets - fleets resource
* @property {Twilio.Supersim.V1.SimList} sims - sims resource
* @property {Twilio.Supersim.V1.UsageRecordList} usageRecords -
* usageRecords resource
*
* @param {Twilio} twilio - The twilio client
*/
/* jshint ignore:end */
function Supersim(twilio) {
Domain.prototype.constructor.call(this, twilio, 'https://supersim.twilio.com');

// Versions
this._v1 = undefined;
}

_.extend(Supersim.prototype, Domain.prototype);
Supersim.prototype.constructor = Supersim;

Object.defineProperty(Supersim.prototype,
'v1', {
get: function() {
this._v1 = this._v1 || new V1(this);
return this._v1;
}
});

Object.defineProperty(Supersim.prototype,
'commands', {
get: function() {
return this.v1.commands;
}
});

Object.defineProperty(Supersim.prototype,
'fleets', {
get: function() {
return this.v1.fleets;
}
});

Object.defineProperty(Supersim.prototype,
'sims', {
get: function() {
return this.v1.sims;
}
});

Object.defineProperty(Supersim.prototype,
'usageRecords', {
get: function() {
return this.v1.usageRecords;
}
});

module.exports = Supersim;
2 changes: 2 additions & 0 deletions lib/rest/Twilio.d.ts
Expand Up @@ -26,6 +26,7 @@ import Proxy = require('./Proxy');
import RequestClient = require('../base/RequestClient');
import Serverless = require('./Serverless');
import Studio = require('./Studio');
import Supersim = require('./Supersim');
import Sync = require('./Sync');
import Taskrouter = require('./Taskrouter');
import Trunking = require('./Trunking');
Expand Down Expand Up @@ -92,6 +93,7 @@ declare class Twilio {
signingKeys: (typeof Api.prototype.account.signingKeys);
sip: (typeof Api.prototype.account.sip);
studio: Studio;
supersim: Supersim;
sync: Sync;
taskrouter: Taskrouter;
tokens: (typeof Api.prototype.account.tokens);
Expand Down
14 changes: 14 additions & 0 deletions lib/rest/Twilio.js
Expand Up @@ -48,6 +48,7 @@ var RestException = require('../base/RestException'); /* jshint ignore:line */
* @property {Twilio.Video} video - video domain
* @property {Twilio.Voice} voice - voice domain
* @property {Twilio.Wireless} wireless - wireless domain
* @property {Twilio.Supersim} supersim - supersim domain
* @property {Twilio.Api.V2010.AccountContext.AddressList} addresses -
* addresses resource
* @property {Twilio.Api.V2010.AccountContext.ApplicationList} applications -
Expand Down Expand Up @@ -161,6 +162,7 @@ function Twilio(username, password, opts) {
this._video = undefined;
this._voice = undefined;
this._wireless = undefined;
this._supersim = undefined;

if (!opts.lazyLoading) {
this.accounts;
Expand Down Expand Up @@ -190,6 +192,7 @@ function Twilio(username, password, opts) {
this.video;
this.voice;
this.wireless;
this.supersim;
}
}

Expand Down Expand Up @@ -596,6 +599,17 @@ Object.defineProperty(Twilio.prototype,
}
});

Object.defineProperty(Twilio.prototype,
'supersim', {
get: function() {
if (!this._supersim) {
var Supersim = require('./Supersim'); /* jshint ignore:line */
this._supersim = new Supersim(this);
}
return this._supersim;
}
});

Object.defineProperty(Twilio.prototype,
'addresses', {
get: function() {
Expand Down
4 changes: 4 additions & 0 deletions lib/rest/authy/v1/service.d.ts
Expand Up @@ -130,10 +130,12 @@ interface ServiceListInstance {
* Options to pass to create
*
* @property friendlyName - A human readable description of this resource.
* @property push - Optional service level push factors configuration
* @property twilioAuthySandboxMode - The Twilio-Authy-Sandbox-Mode HTTP request header
*/
interface ServiceListInstanceCreateOptions {
friendlyName: string;
push?: string;
twilioAuthySandboxMode?: string;
}

Expand Down Expand Up @@ -205,6 +207,7 @@ interface ServicePayload extends ServiceResource, Page.TwilioResponsePayload {

interface ServiceResource {
account_sid: string;
configuration: object;
date_created: Date;
date_updated: Date;
friendly_name: string;
Expand Down Expand Up @@ -275,6 +278,7 @@ declare class ServiceInstance extends SerializableClass {

private _proxy: ServiceContext;
accountSid: string;
configuration: object;
dateCreated: Date;
dateUpdated: Date;
/**
Expand Down
6 changes: 5 additions & 1 deletion lib/rest/authy/v1/service.js
Expand Up @@ -65,6 +65,7 @@ ServiceList = function ServiceList(version) {
* @param {object} opts - Options for request
* @param {string} opts.friendlyName -
* A human readable description of this resource.
* @param {string} [opts.push] - Optional service level push factors configuration
* @param {string} [opts.twilioAuthySandboxMode] -
* The Twilio-Authy-Sandbox-Mode HTTP request header
* @param {function} [callback] - Callback to handle processed record
Expand All @@ -81,7 +82,7 @@ ServiceList = function ServiceList(version) {
}

var deferred = Q.defer();
var data = values.of({'FriendlyName': _.get(opts, 'friendlyName')});
var data = values.of({'FriendlyName': _.get(opts, 'friendlyName'), 'Push': _.get(opts, 'push')});
var headers = values.of({'Twilio-Authy-Sandbox-Mode': _.get(opts, 'twilioAuthySandboxMode')});

var promise = this._version.create({uri: this._uri, method: 'POST', data: data, headers: headers});
Expand Down Expand Up @@ -475,6 +476,8 @@ ServicePage.prototype[util.inspect.custom] = function inspect(depth, options) {
* @property {Date} dateUpdated - The date this Service was updated
* @property {string} url - The URL of this resource.
* @property {string} links - Nested resource URLs.
* @property {object} configuration -
* The service level configuration of all the factor types.
*
* @param {V1} version - Version of the resource
* @param {ServicePayload} payload - The instance payload
Expand All @@ -492,6 +495,7 @@ ServiceInstance = function ServiceInstance(version, payload, sid) {
this.dateUpdated = deserialize.iso8601DateTime(payload.date_updated); // jshint ignore:line
this.url = payload.url; // jshint ignore:line
this.links = payload.links; // jshint ignore:line
this.configuration = payload.configuration; // jshint ignore:line

// Context
this._context = undefined;
Expand Down
6 changes: 1 addition & 5 deletions lib/rest/authy/v1/service/entity/factor.d.ts
Expand Up @@ -14,8 +14,6 @@ import { SerializableClass } from '../../../../../interfaces';

type FactorFactorStatuses = 'unverified'|'verified';

type FactorFactorStrengths = 'unknown'|'very_low'|'low'|'medium'|'high'|'very_high';

type FactorFactorTypes = 'app-push'|'sms'|'totp'|'push';

/**
Expand Down Expand Up @@ -220,7 +218,6 @@ interface FactorResource {
date_created: Date;
date_updated: Date;
entity_sid: string;
factor_strength: FactorFactorStrengths;
factor_type: FactorFactorTypes;
friendly_name: string;
identity: string;
Expand Down Expand Up @@ -306,7 +303,6 @@ declare class FactorInstance extends SerializableClass {
dateCreated: Date;
dateUpdated: Date;
entitySid: string;
factorStrength: FactorFactorStrengths;
factorType: FactorFactorTypes;
/**
* fetch a FactorInstance
Expand Down Expand Up @@ -369,4 +365,4 @@ declare class FactorPage extends Page<V1, FactorPayload, FactorResource, FactorI
toJSON(): any;
}

export { FactorContext, FactorFactorStatuses, FactorFactorStrengths, FactorFactorTypes, FactorInstance, FactorInstanceFetchOptions, FactorInstanceRemoveOptions, FactorInstanceUpdateOptions, FactorList, FactorListInstance, FactorListInstanceCreateOptions, FactorListInstanceEachOptions, FactorListInstanceOptions, FactorListInstancePageOptions, FactorPage, FactorPayload, FactorResource, FactorSolution }
export { FactorContext, FactorFactorStatuses, FactorFactorTypes, FactorInstance, FactorInstanceFetchOptions, FactorInstanceRemoveOptions, FactorInstanceUpdateOptions, FactorList, FactorListInstance, FactorListInstanceCreateOptions, FactorListInstanceEachOptions, FactorListInstanceOptions, FactorListInstancePageOptions, FactorPage, FactorPayload, FactorResource, FactorSolution }
2 changes: 0 additions & 2 deletions lib/rest/authy/v1/service/entity/factor.js
Expand Up @@ -502,7 +502,6 @@ FactorPage.prototype[util.inspect.custom] = function inspect(depth, options) {
* @property {string} friendlyName - A human readable description of this resource.
* @property {factor.factor_statuses} status - The Status of this Factor
* @property {factor.factor_types} factorType - The Type of this Factor
* @property {factor.factor_strengths} factorStrength - The Strength of this Factor
* @property {string} url - The URL of this resource.
* @property {string} links - Nested resource URLs.
*
Expand All @@ -528,7 +527,6 @@ FactorInstance = function FactorInstance(version, payload, serviceSid, identity,
this.friendlyName = payload.friendly_name; // jshint ignore:line
this.status = payload.status; // jshint ignore:line
this.factorType = payload.factor_type; // jshint ignore:line
this.factorStrength = payload.factor_strength; // jshint ignore:line
this.url = payload.url; // jshint ignore:line
this.links = payload.links; // jshint ignore:line

Expand Down
6 changes: 1 addition & 5 deletions lib/rest/authy/v1/service/entity/factor/challenge.d.ts
Expand Up @@ -15,8 +15,6 @@ type ChallengeChallengeReasons = 'none'|'not_needed'|'not_requested';

type ChallengeChallengeStatuses = 'pending'|'expired'|'approved'|'denied';

type ChallengeFactorStrengths = 'unknown'|'very_low'|'low'|'medium'|'high'|'very_high';

type ChallengeFactorTypes = 'app-push'|'sms'|'totp'|'push';

/**
Expand Down Expand Up @@ -113,7 +111,6 @@ interface ChallengeResource {
entity_sid: string;
expiration_date: Date;
factor_sid: string;
factor_strength: ChallengeFactorStrengths;
factor_type: ChallengeFactorTypes;
hidden_details: string;
identity: string;
Expand Down Expand Up @@ -201,7 +198,6 @@ declare class ChallengeInstance extends SerializableClass {
entitySid: string;
expirationDate: Date;
factorSid: string;
factorStrength: ChallengeFactorStrengths;
factorType: ChallengeFactorTypes;
/**
* fetch a ChallengeInstance
Expand Down Expand Up @@ -264,4 +260,4 @@ declare class ChallengePage extends Page<V1, ChallengePayload, ChallengeResource
toJSON(): any;
}

export { ChallengeChallengeReasons, ChallengeChallengeStatuses, ChallengeContext, ChallengeFactorStrengths, ChallengeFactorTypes, ChallengeInstance, ChallengeInstanceFetchOptions, ChallengeInstanceRemoveOptions, ChallengeInstanceUpdateOptions, ChallengeList, ChallengeListInstance, ChallengeListInstanceCreateOptions, ChallengePage, ChallengePayload, ChallengeResource, ChallengeSolution }
export { ChallengeChallengeReasons, ChallengeChallengeStatuses, ChallengeContext, ChallengeFactorTypes, ChallengeInstance, ChallengeInstanceFetchOptions, ChallengeInstanceRemoveOptions, ChallengeInstanceUpdateOptions, ChallengeList, ChallengeListInstance, ChallengeListInstanceCreateOptions, ChallengePage, ChallengePayload, ChallengeResource, ChallengeSolution }

0 comments on commit ec54ee2

Please sign in to comment.