twilio 5.6.0 → 5.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -0
- package/lib/base/BaseTwilio.d.ts +3 -0
- package/lib/base/BaseTwilio.js +4 -1
- package/lib/base/RequestClient.d.ts +36 -1
- package/lib/base/RequestClient.js +40 -0
- package/lib/base/ValidationClient.d.ts +10 -0
- package/lib/base/ValidationClient.js +2 -0
- package/lib/http/bearer_token/ApiTokenManager.d.ts +1 -1
- package/lib/http/bearer_token/ApiTokenManager.js +4 -4
- package/lib/http/bearer_token/OrgsTokenManager.d.ts +1 -1
- package/lib/http/bearer_token/OrgsTokenManager.js +4 -4
- package/lib/index.d.ts +3 -0
- package/lib/index.js +2 -0
- package/lib/jwt/validation/RequestCanonicalizer.d.ts +20 -0
- package/lib/jwt/validation/RequestCanonicalizer.js +97 -0
- package/lib/jwt/validation/ValidationToken.d.ts +45 -0
- package/lib/jwt/validation/ValidationToken.js +121 -0
- package/lib/rest/accounts/v1/bulkConsents.d.ts +1 -1
- package/lib/rest/api/v2010/account/address/dependentPhoneNumber.d.ts +10 -12
- package/lib/rest/api/v2010/account/address/dependentPhoneNumber.js +2 -2
- package/lib/rest/api/v2010/account/call/transcription.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/allTime.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/daily.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/lastMonth.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/monthly.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/thisMonth.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/today.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/yearly.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record/yesterday.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/record.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage/trigger.d.ts +1 -1
- package/lib/rest/api/v2010/account/usage.d.ts +1 -1
- package/lib/rest/content/v1/content/approvalFetch.d.ts +3 -3
- package/lib/rest/content/v1/content.d.ts +9 -6
- package/lib/rest/content/v1/contentAndApprovals.d.ts +9 -9
- package/lib/rest/content/v1/legacyContent.d.ts +6 -6
- package/lib/rest/events/v1/subscription.d.ts +0 -10
- package/lib/rest/events/v1/subscription.js +0 -6
- package/lib/rest/messaging/v1/brandRegistration/brandVetting.d.ts +0 -6
- package/lib/rest/messaging/v1/brandRegistration/brandVetting.js +0 -2
- package/lib/rest/messaging/v2/channelsSender.d.ts +2 -22
- package/lib/rest/messaging/v2/channelsSender.js +1 -7
- package/lib/rest/numbers/V1.d.ts +5 -5
- package/lib/rest/numbers/V1.js +6 -8
- package/lib/rest/numbers/v1/portingPortIn.d.ts +3 -3
- package/lib/rest/numbers/v1/{portingWebhookConfigurationFetch.d.ts → webhook.d.ts} +10 -10
- package/lib/rest/numbers/v1/{portingWebhookConfigurationFetch.js → webhook.js} +6 -6
- package/lib/rest/verify/v2/service.d.ts +1 -1
- package/lib/rest/verify/v2/verificationAttemptsSummary.d.ts +3 -3
- package/lib/twiml/VoiceResponse.d.ts +36 -16
- package/package.json +1 -1
|
@@ -16,6 +16,7 @@ export declare class CallToActionAction {
|
|
|
16
16
|
"url"?: string;
|
|
17
17
|
"phone"?: string;
|
|
18
18
|
"code"?: string;
|
|
19
|
+
"id"?: string;
|
|
19
20
|
}
|
|
20
21
|
export type CallToActionActionType = "URL" | "PHONE_NUMBER" | "COPY_CODE" | "VOICE_CALL" | "VOICE_CALL_REQUEST";
|
|
21
22
|
export declare class CardAction {
|
|
@@ -151,6 +152,8 @@ export declare class TwilioLocation {
|
|
|
151
152
|
"latitude": number;
|
|
152
153
|
"longitude": number;
|
|
153
154
|
"label"?: string;
|
|
155
|
+
"id"?: string;
|
|
156
|
+
"address"?: string;
|
|
154
157
|
}
|
|
155
158
|
/**
|
|
156
159
|
* twilio/media is used to send file attachments, or to send long text via MMS in the US and Canada. As such, the twilio/media type must contain at least ONE of text or media content.
|
|
@@ -313,8 +316,8 @@ interface ContentResource {
|
|
|
313
316
|
account_sid: string;
|
|
314
317
|
friendly_name: string;
|
|
315
318
|
language: string;
|
|
316
|
-
variables:
|
|
317
|
-
types:
|
|
319
|
+
variables: Record<string, object>;
|
|
320
|
+
types: Record<string, object>;
|
|
318
321
|
url: string;
|
|
319
322
|
links: Record<string, string>;
|
|
320
323
|
}
|
|
@@ -350,11 +353,11 @@ export declare class ContentInstance {
|
|
|
350
353
|
/**
|
|
351
354
|
* Defines the default placeholder values for variables included in the Content resource. e.g. {\"1\": \"Customer_Name\"}.
|
|
352
355
|
*/
|
|
353
|
-
variables:
|
|
356
|
+
variables: Record<string, object>;
|
|
354
357
|
/**
|
|
355
358
|
* The [Content types](https://www.twilio.com/docs/content-api/content-types-overview) (e.g. twilio/text) for this Content resource.
|
|
356
359
|
*/
|
|
357
|
-
types:
|
|
360
|
+
types: Record<string, object>;
|
|
358
361
|
/**
|
|
359
362
|
* The URL of the resource, relative to `https://content.twilio.com`.
|
|
360
363
|
*/
|
|
@@ -400,8 +403,8 @@ export declare class ContentInstance {
|
|
|
400
403
|
accountSid: string;
|
|
401
404
|
friendlyName: string;
|
|
402
405
|
language: string;
|
|
403
|
-
variables:
|
|
404
|
-
types:
|
|
406
|
+
variables: Record<string, object>;
|
|
407
|
+
types: Record<string, object>;
|
|
405
408
|
url: string;
|
|
406
409
|
links: Record<string, string>;
|
|
407
410
|
};
|
|
@@ -109,9 +109,9 @@ interface ContentAndApprovalsResource {
|
|
|
109
109
|
account_sid: string;
|
|
110
110
|
friendly_name: string;
|
|
111
111
|
language: string;
|
|
112
|
-
variables:
|
|
113
|
-
types:
|
|
114
|
-
approval_requests:
|
|
112
|
+
variables: Record<string, object>;
|
|
113
|
+
types: Record<string, object>;
|
|
114
|
+
approval_requests: Record<string, object>;
|
|
115
115
|
}
|
|
116
116
|
export declare class ContentAndApprovalsInstance {
|
|
117
117
|
protected _version: V1;
|
|
@@ -143,15 +143,15 @@ export declare class ContentAndApprovalsInstance {
|
|
|
143
143
|
/**
|
|
144
144
|
* Defines the default placeholder values for variables included in the Content resource. e.g. {\"1\": \"Customer_Name\"}.
|
|
145
145
|
*/
|
|
146
|
-
variables:
|
|
146
|
+
variables: Record<string, object>;
|
|
147
147
|
/**
|
|
148
148
|
* The [Content types](https://www.twilio.com/docs/content-api/content-types-overview) (e.g. twilio/text) for this Content resource.
|
|
149
149
|
*/
|
|
150
|
-
types:
|
|
150
|
+
types: Record<string, object>;
|
|
151
151
|
/**
|
|
152
152
|
* The submitted information and approval request status of the Content resource.
|
|
153
153
|
*/
|
|
154
|
-
approvalRequests:
|
|
154
|
+
approvalRequests: Record<string, object>;
|
|
155
155
|
/**
|
|
156
156
|
* Provide a user-friendly representation
|
|
157
157
|
*
|
|
@@ -164,9 +164,9 @@ export declare class ContentAndApprovalsInstance {
|
|
|
164
164
|
accountSid: string;
|
|
165
165
|
friendlyName: string;
|
|
166
166
|
language: string;
|
|
167
|
-
variables:
|
|
168
|
-
types:
|
|
169
|
-
approvalRequests:
|
|
167
|
+
variables: Record<string, object>;
|
|
168
|
+
types: Record<string, object>;
|
|
169
|
+
approvalRequests: Record<string, object>;
|
|
170
170
|
};
|
|
171
171
|
[inspect.custom](_depth: any, options: InspectOptions): string;
|
|
172
172
|
}
|
|
@@ -109,8 +109,8 @@ interface LegacyContentResource {
|
|
|
109
109
|
account_sid: string;
|
|
110
110
|
friendly_name: string;
|
|
111
111
|
language: string;
|
|
112
|
-
variables:
|
|
113
|
-
types:
|
|
112
|
+
variables: Record<string, object>;
|
|
113
|
+
types: Record<string, object>;
|
|
114
114
|
legacy_template_name: string;
|
|
115
115
|
legacy_body: string;
|
|
116
116
|
url: string;
|
|
@@ -145,11 +145,11 @@ export declare class LegacyContentInstance {
|
|
|
145
145
|
/**
|
|
146
146
|
* Defines the default placeholder values for variables included in the Content resource. e.g. {\"1\": \"Customer_Name\"}.
|
|
147
147
|
*/
|
|
148
|
-
variables:
|
|
148
|
+
variables: Record<string, object>;
|
|
149
149
|
/**
|
|
150
150
|
* The [Content types](https://www.twilio.com/docs/content-api/content-types-overview) (e.g. twilio/text) for this Content resource.
|
|
151
151
|
*/
|
|
152
|
-
types:
|
|
152
|
+
types: Record<string, object>;
|
|
153
153
|
/**
|
|
154
154
|
* The string name of the legacy content template associated with this Content resource, unique across all template names for its account. Only lowercase letters, numbers and underscores are allowed
|
|
155
155
|
*/
|
|
@@ -174,8 +174,8 @@ export declare class LegacyContentInstance {
|
|
|
174
174
|
accountSid: string;
|
|
175
175
|
friendlyName: string;
|
|
176
176
|
language: string;
|
|
177
|
-
variables:
|
|
178
|
-
types:
|
|
177
|
+
variables: Record<string, object>;
|
|
178
|
+
types: Record<string, object>;
|
|
179
179
|
legacyTemplateName: string;
|
|
180
180
|
legacyBody: string;
|
|
181
181
|
url: string;
|
|
@@ -12,8 +12,6 @@ export interface SubscriptionContextUpdateOptions {
|
|
|
12
12
|
description?: string;
|
|
13
13
|
/** The SID of the sink that events selected by this subscription should be sent to. Sink must be active for the subscription to be created. */
|
|
14
14
|
sinkSid?: string;
|
|
15
|
-
/** Receive events from all children accounts in the parent account subscription. */
|
|
16
|
-
receiveEventsFromSubaccounts?: boolean;
|
|
17
15
|
}
|
|
18
16
|
/**
|
|
19
17
|
* Options to pass to create a SubscriptionInstance
|
|
@@ -25,8 +23,6 @@ export interface SubscriptionListInstanceCreateOptions {
|
|
|
25
23
|
sinkSid: string;
|
|
26
24
|
/** An array of objects containing the subscribed Event Types */
|
|
27
25
|
types: Array<object>;
|
|
28
|
-
/** Receive events from all children accounts in the parent account subscription. */
|
|
29
|
-
receiveEventsFromSubaccounts?: boolean;
|
|
30
26
|
}
|
|
31
27
|
/**
|
|
32
28
|
* Options to pass to each
|
|
@@ -141,7 +137,6 @@ interface SubscriptionResource {
|
|
|
141
137
|
sink_sid: string;
|
|
142
138
|
url: string;
|
|
143
139
|
links: Record<string, string>;
|
|
144
|
-
receive_events_from_subaccounts: boolean;
|
|
145
140
|
}
|
|
146
141
|
export declare class SubscriptionInstance {
|
|
147
142
|
protected _version: V1;
|
|
@@ -180,10 +175,6 @@ export declare class SubscriptionInstance {
|
|
|
180
175
|
* Contains a dictionary of URL links to nested resources of this Subscription.
|
|
181
176
|
*/
|
|
182
177
|
links: Record<string, string>;
|
|
183
|
-
/**
|
|
184
|
-
* Receive events from all children accounts in the parent account subscription.
|
|
185
|
-
*/
|
|
186
|
-
receiveEventsFromSubaccounts: boolean;
|
|
187
178
|
private get _proxy();
|
|
188
179
|
/**
|
|
189
180
|
* Remove a SubscriptionInstance
|
|
@@ -236,7 +227,6 @@ export declare class SubscriptionInstance {
|
|
|
236
227
|
sinkSid: string;
|
|
237
228
|
url: string;
|
|
238
229
|
links: Record<string, string>;
|
|
239
|
-
receiveEventsFromSubaccounts: boolean;
|
|
240
230
|
};
|
|
241
231
|
[inspect.custom](_depth: any, options: InspectOptions): string;
|
|
242
232
|
}
|
|
@@ -75,8 +75,6 @@ class SubscriptionContextImpl {
|
|
|
75
75
|
data["Description"] = params["description"];
|
|
76
76
|
if (params["sinkSid"] !== undefined)
|
|
77
77
|
data["SinkSid"] = params["sinkSid"];
|
|
78
|
-
if (params["receiveEventsFromSubaccounts"] !== undefined)
|
|
79
|
-
data["ReceiveEventsFromSubaccounts"] = serialize.bool(params["receiveEventsFromSubaccounts"]);
|
|
80
78
|
const headers = {};
|
|
81
79
|
headers["Content-Type"] = "application/x-www-form-urlencoded";
|
|
82
80
|
headers["Accept"] = "application/json";
|
|
@@ -115,7 +113,6 @@ class SubscriptionInstance {
|
|
|
115
113
|
this.sinkSid = payload.sink_sid;
|
|
116
114
|
this.url = payload.url;
|
|
117
115
|
this.links = payload.links;
|
|
118
|
-
this.receiveEventsFromSubaccounts = payload.receive_events_from_subaccounts;
|
|
119
116
|
this._solution = { sid: sid || this.sid };
|
|
120
117
|
}
|
|
121
118
|
get _proxy() {
|
|
@@ -168,7 +165,6 @@ class SubscriptionInstance {
|
|
|
168
165
|
sinkSid: this.sinkSid,
|
|
169
166
|
url: this.url,
|
|
170
167
|
links: this.links,
|
|
171
|
-
receiveEventsFromSubaccounts: this.receiveEventsFromSubaccounts,
|
|
172
168
|
};
|
|
173
169
|
}
|
|
174
170
|
[util_1.inspect.custom](_depth, options) {
|
|
@@ -201,8 +197,6 @@ function SubscriptionListInstance(version) {
|
|
|
201
197
|
data["Description"] = params["description"];
|
|
202
198
|
data["SinkSid"] = params["sinkSid"];
|
|
203
199
|
data["Types"] = serialize.map(params["types"], (e) => e);
|
|
204
|
-
if (params["receiveEventsFromSubaccounts"] !== undefined)
|
|
205
|
-
data["ReceiveEventsFromSubaccounts"] = serialize.bool(params["receiveEventsFromSubaccounts"]);
|
|
206
200
|
const headers = {};
|
|
207
201
|
headers["Content-Type"] = "application/x-www-form-urlencoded";
|
|
208
202
|
headers["Accept"] = "application/json";
|
|
@@ -22,8 +22,6 @@ export interface BrandVettingListInstanceCreateOptions {
|
|
|
22
22
|
export interface BrandVettingListInstanceEachOptions {
|
|
23
23
|
/** The third-party provider of the vettings to read */
|
|
24
24
|
vettingProvider?: BrandVettingVettingProvider;
|
|
25
|
-
/** How many resources to return in each list page. The default is 50, and the maximum is 1000. */
|
|
26
|
-
pageSize?: number;
|
|
27
25
|
/** Function to process each record. If this and a positional callback are passed, this one will be used */
|
|
28
26
|
callback?: (item: BrandVettingInstance, done: (err?: Error) => void) => void;
|
|
29
27
|
/** Function to be called upon completion of streaming */
|
|
@@ -37,8 +35,6 @@ export interface BrandVettingListInstanceEachOptions {
|
|
|
37
35
|
export interface BrandVettingListInstanceOptions {
|
|
38
36
|
/** The third-party provider of the vettings to read */
|
|
39
37
|
vettingProvider?: BrandVettingVettingProvider;
|
|
40
|
-
/** How many resources to return in each list page. The default is 50, and the maximum is 1000. */
|
|
41
|
-
pageSize?: number;
|
|
42
38
|
/** Upper limit for the number of records to return. list() guarantees never to return more than limit. Default is no limit */
|
|
43
39
|
limit?: number;
|
|
44
40
|
}
|
|
@@ -48,8 +44,6 @@ export interface BrandVettingListInstanceOptions {
|
|
|
48
44
|
export interface BrandVettingListInstancePageOptions {
|
|
49
45
|
/** The third-party provider of the vettings to read */
|
|
50
46
|
vettingProvider?: BrandVettingVettingProvider;
|
|
51
|
-
/** How many resources to return in each list page. The default is 50, and the maximum is 1000. */
|
|
52
|
-
pageSize?: number;
|
|
53
47
|
/** Page Number, this value is simply for client state */
|
|
54
48
|
pageNumber?: number;
|
|
55
49
|
/** PageToken provided by the API */
|
|
@@ -165,8 +165,6 @@ function BrandVettingListInstance(version, brandSid) {
|
|
|
165
165
|
let data = {};
|
|
166
166
|
if (params["vettingProvider"] !== undefined)
|
|
167
167
|
data["VettingProvider"] = params["vettingProvider"];
|
|
168
|
-
if (params["pageSize"] !== undefined)
|
|
169
|
-
data["PageSize"] = params["pageSize"];
|
|
170
168
|
if (params.pageNumber !== undefined)
|
|
171
169
|
data["Page"] = params.pageNumber;
|
|
172
170
|
if (params.pageToken !== undefined)
|
|
@@ -65,7 +65,7 @@ export declare class MessagingV2ChannelsSenderProfile {
|
|
|
65
65
|
/**
|
|
66
66
|
* The emails of the sender.
|
|
67
67
|
*/
|
|
68
|
-
"emails"?:
|
|
68
|
+
"emails"?: any | null;
|
|
69
69
|
/**
|
|
70
70
|
* The logo URL of the sender.
|
|
71
71
|
*/
|
|
@@ -77,27 +77,7 @@ export declare class MessagingV2ChannelsSenderProfile {
|
|
|
77
77
|
/**
|
|
78
78
|
* The websites of the sender.
|
|
79
79
|
*/
|
|
80
|
-
"websites"?:
|
|
81
|
-
}
|
|
82
|
-
export declare class MessagingV2ChannelsSenderProfileEmails {
|
|
83
|
-
/**
|
|
84
|
-
* The email of the sender.
|
|
85
|
-
*/
|
|
86
|
-
"email"?: string | null;
|
|
87
|
-
/**
|
|
88
|
-
* The label of the sender.
|
|
89
|
-
*/
|
|
90
|
-
"label"?: string | null;
|
|
91
|
-
}
|
|
92
|
-
export declare class MessagingV2ChannelsSenderProfileWebsites {
|
|
93
|
-
/**
|
|
94
|
-
* The label of the sender.
|
|
95
|
-
*/
|
|
96
|
-
"label"?: string | null;
|
|
97
|
-
/**
|
|
98
|
-
* The website of the sender.
|
|
99
|
-
*/
|
|
100
|
-
"website"?: string | null;
|
|
80
|
+
"websites"?: any | null;
|
|
101
81
|
}
|
|
102
82
|
/**
|
|
103
83
|
* Sender specific additional properties, e.g., {\"quality_rating\": \"HIGH\", \"messaging_limit\": \"10K Customers/24hr\"}
|
|
@@ -16,7 +16,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
16
16
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
17
17
|
};
|
|
18
18
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
19
|
-
exports.ChannelsSenderPage = exports.ChannelsSenderListInstance = exports.ChannelsSenderInstance = exports.ChannelsSenderContextImpl = exports.MessagingV2ChannelsSenderWebhook = exports.MessagingV2ChannelsSenderRequestsUpdate = exports.MessagingV2ChannelsSenderRequestsCreate = exports.MessagingV2ChannelsSenderProperties = exports.
|
|
19
|
+
exports.ChannelsSenderPage = exports.ChannelsSenderListInstance = exports.ChannelsSenderInstance = exports.ChannelsSenderContextImpl = exports.MessagingV2ChannelsSenderWebhook = exports.MessagingV2ChannelsSenderRequestsUpdate = exports.MessagingV2ChannelsSenderRequestsCreate = exports.MessagingV2ChannelsSenderProperties = exports.MessagingV2ChannelsSenderProfile = exports.MessagingV2ChannelsSenderOfflineReasonsItems = exports.MessagingV2ChannelsSenderConfiguration = void 0;
|
|
20
20
|
const util_1 = require("util");
|
|
21
21
|
const Page_1 = __importDefault(require("../../../base/Page"));
|
|
22
22
|
const deserialize = require("../../../base/deserialize");
|
|
@@ -37,12 +37,6 @@ exports.MessagingV2ChannelsSenderOfflineReasonsItems = MessagingV2ChannelsSender
|
|
|
37
37
|
class MessagingV2ChannelsSenderProfile {
|
|
38
38
|
}
|
|
39
39
|
exports.MessagingV2ChannelsSenderProfile = MessagingV2ChannelsSenderProfile;
|
|
40
|
-
class MessagingV2ChannelsSenderProfileEmails {
|
|
41
|
-
}
|
|
42
|
-
exports.MessagingV2ChannelsSenderProfileEmails = MessagingV2ChannelsSenderProfileEmails;
|
|
43
|
-
class MessagingV2ChannelsSenderProfileWebsites {
|
|
44
|
-
}
|
|
45
|
-
exports.MessagingV2ChannelsSenderProfileWebsites = MessagingV2ChannelsSenderProfileWebsites;
|
|
46
40
|
/**
|
|
47
41
|
* Sender specific additional properties, e.g., {\"quality_rating\": \"HIGH\", \"messaging_limit\": \"10K Customers/24hr\"}
|
|
48
42
|
*/
|
package/lib/rest/numbers/V1.d.ts
CHANGED
|
@@ -7,8 +7,8 @@ import { PortingPortInPhoneNumberListInstance } from "./v1/portingPortInPhoneNum
|
|
|
7
7
|
import { PortingPortabilityListInstance } from "./v1/portingPortability";
|
|
8
8
|
import { PortingWebhookConfigurationListInstance } from "./v1/portingWebhookConfiguration";
|
|
9
9
|
import { PortingWebhookConfigurationDeleteListInstance } from "./v1/portingWebhookConfigurationDelete";
|
|
10
|
-
import { PortingWebhookConfigurationFetchListInstance } from "./v1/portingWebhookConfigurationFetch";
|
|
11
10
|
import { SigningRequestConfigurationListInstance } from "./v1/signingRequestConfiguration";
|
|
11
|
+
import { WebhookListInstance } from "./v1/webhook";
|
|
12
12
|
export default class V1 extends Version {
|
|
13
13
|
/**
|
|
14
14
|
* Initialize the V1 version of Numbers
|
|
@@ -30,10 +30,10 @@ export default class V1 extends Version {
|
|
|
30
30
|
protected _portingWebhookConfigurations?: PortingWebhookConfigurationListInstance;
|
|
31
31
|
/** portingWebhookConfigurationsDelete - { Twilio.Numbers.V1.PortingWebhookConfigurationDeleteListInstance } resource */
|
|
32
32
|
protected _portingWebhookConfigurationsDelete?: PortingWebhookConfigurationDeleteListInstance;
|
|
33
|
-
/** portingWebhookConfigurationFetch - { Twilio.Numbers.V1.PortingWebhookConfigurationFetchListInstance } resource */
|
|
34
|
-
protected _portingWebhookConfigurationFetch?: PortingWebhookConfigurationFetchListInstance;
|
|
35
33
|
/** signingRequestConfigurations - { Twilio.Numbers.V1.SigningRequestConfigurationListInstance } resource */
|
|
36
34
|
protected _signingRequestConfigurations?: SigningRequestConfigurationListInstance;
|
|
35
|
+
/** webhook - { Twilio.Numbers.V1.WebhookListInstance } resource */
|
|
36
|
+
protected _webhook?: WebhookListInstance;
|
|
37
37
|
/** Getter for bulkEligibilities resource */
|
|
38
38
|
get bulkEligibilities(): BulkEligibilityListInstance;
|
|
39
39
|
/** Getter for eligibilities resource */
|
|
@@ -48,8 +48,8 @@ export default class V1 extends Version {
|
|
|
48
48
|
get portingWebhookConfigurations(): PortingWebhookConfigurationListInstance;
|
|
49
49
|
/** Getter for portingWebhookConfigurationsDelete resource */
|
|
50
50
|
get portingWebhookConfigurationsDelete(): PortingWebhookConfigurationDeleteListInstance;
|
|
51
|
-
/** Getter for portingWebhookConfigurationFetch resource */
|
|
52
|
-
get portingWebhookConfigurationFetch(): PortingWebhookConfigurationFetchListInstance;
|
|
53
51
|
/** Getter for signingRequestConfigurations resource */
|
|
54
52
|
get signingRequestConfigurations(): SigningRequestConfigurationListInstance;
|
|
53
|
+
/** Getter for webhook resource */
|
|
54
|
+
get webhook(): WebhookListInstance;
|
|
55
55
|
}
|
package/lib/rest/numbers/V1.js
CHANGED
|
@@ -24,8 +24,8 @@ const portingPortInPhoneNumber_1 = require("./v1/portingPortInPhoneNumber");
|
|
|
24
24
|
const portingPortability_1 = require("./v1/portingPortability");
|
|
25
25
|
const portingWebhookConfiguration_1 = require("./v1/portingWebhookConfiguration");
|
|
26
26
|
const portingWebhookConfigurationDelete_1 = require("./v1/portingWebhookConfigurationDelete");
|
|
27
|
-
const portingWebhookConfigurationFetch_1 = require("./v1/portingWebhookConfigurationFetch");
|
|
28
27
|
const signingRequestConfiguration_1 = require("./v1/signingRequestConfiguration");
|
|
28
|
+
const webhook_1 = require("./v1/webhook");
|
|
29
29
|
class V1 extends Version_1.default {
|
|
30
30
|
/**
|
|
31
31
|
* Initialize the V1 version of Numbers
|
|
@@ -79,13 +79,6 @@ class V1 extends Version_1.default {
|
|
|
79
79
|
(0, portingWebhookConfigurationDelete_1.PortingWebhookConfigurationDeleteListInstance)(this);
|
|
80
80
|
return this._portingWebhookConfigurationsDelete;
|
|
81
81
|
}
|
|
82
|
-
/** Getter for portingWebhookConfigurationFetch resource */
|
|
83
|
-
get portingWebhookConfigurationFetch() {
|
|
84
|
-
this._portingWebhookConfigurationFetch =
|
|
85
|
-
this._portingWebhookConfigurationFetch ||
|
|
86
|
-
(0, portingWebhookConfigurationFetch_1.PortingWebhookConfigurationFetchListInstance)(this);
|
|
87
|
-
return this._portingWebhookConfigurationFetch;
|
|
88
|
-
}
|
|
89
82
|
/** Getter for signingRequestConfigurations resource */
|
|
90
83
|
get signingRequestConfigurations() {
|
|
91
84
|
this._signingRequestConfigurations =
|
|
@@ -93,5 +86,10 @@ class V1 extends Version_1.default {
|
|
|
93
86
|
(0, signingRequestConfiguration_1.SigningRequestConfigurationListInstance)(this);
|
|
94
87
|
return this._signingRequestConfigurations;
|
|
95
88
|
}
|
|
89
|
+
/** Getter for webhook resource */
|
|
90
|
+
get webhook() {
|
|
91
|
+
this._webhook = this._webhook || (0, webhook_1.WebhookListInstance)(this);
|
|
92
|
+
return this._webhook;
|
|
93
|
+
}
|
|
96
94
|
}
|
|
97
95
|
exports.default = V1;
|
|
@@ -85,15 +85,15 @@ export declare class PortingPortInInstance {
|
|
|
85
85
|
*/
|
|
86
86
|
notificationEmails: Array<string>;
|
|
87
87
|
/**
|
|
88
|
-
* Target date to port the number. We cannot guarantee that this date will be honored by the other carriers, please work with Ops to get a confirmation of the firm order commitment (FOC) date. Expected format is ISO Local Date, example: ‘2011-12-03`. This date must be at least 7 days in the future for US ports and 10 days in the future for Japanese ports.
|
|
88
|
+
* Target date to port the number. We cannot guarantee that this date will be honored by the other carriers, please work with Ops to get a confirmation of the firm order commitment (FOC) date. Expected format is ISO Local Date, example: ‘2011-12-03`. This date must be at least 7 days in the future for US ports and 10 days in the future for Japanese ports. We can\'t guarantee the exact date and time, as this depends on the losing carrier
|
|
89
89
|
*/
|
|
90
90
|
targetPortInDate: Date;
|
|
91
91
|
/**
|
|
92
|
-
* The earliest time that the port should occur on the target port in date. Expected format is ISO Offset Time, example: ‘10:15:00-08:00\'.
|
|
92
|
+
* The earliest time that the port should occur on the target port in date. Expected format is ISO Offset Time, example: ‘10:15:00-08:00\'. We can\'t guarantee the exact date and time, as this depends on the losing carrier
|
|
93
93
|
*/
|
|
94
94
|
targetPortInTimeRangeStart: string;
|
|
95
95
|
/**
|
|
96
|
-
* The latest time that the port should occur on the target port in date. Expected format is ISO Offset Time, example: ‘10:15:00-08:00\'.
|
|
96
|
+
* The latest time that the port should occur on the target port in date. Expected format is ISO Offset Time, example: ‘10:15:00-08:00\'. We can\'t guarantee the exact date and time, as this depends on the losing carrier
|
|
97
97
|
*/
|
|
98
98
|
targetPortInTimeRangeEnd: string;
|
|
99
99
|
/**
|
|
@@ -1,28 +1,28 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import { inspect, InspectOptions } from "util";
|
|
3
3
|
import V1 from "../V1";
|
|
4
|
-
export interface
|
|
4
|
+
export interface WebhookSolution {
|
|
5
5
|
}
|
|
6
|
-
export interface
|
|
6
|
+
export interface WebhookListInstance {
|
|
7
7
|
_version: V1;
|
|
8
|
-
_solution:
|
|
8
|
+
_solution: WebhookSolution;
|
|
9
9
|
_uri: string;
|
|
10
10
|
/**
|
|
11
|
-
* Fetch a
|
|
11
|
+
* Fetch a WebhookInstance
|
|
12
12
|
*
|
|
13
13
|
* @param callback - Callback to handle processed record
|
|
14
14
|
*
|
|
15
|
-
* @returns Resolves to processed
|
|
15
|
+
* @returns Resolves to processed WebhookInstance
|
|
16
16
|
*/
|
|
17
|
-
fetch(callback?: (error: Error | null, item?:
|
|
17
|
+
fetch(callback?: (error: Error | null, item?: WebhookInstance) => any): Promise<WebhookInstance>;
|
|
18
18
|
/**
|
|
19
19
|
* Provide a user-friendly representation
|
|
20
20
|
*/
|
|
21
21
|
toJSON(): any;
|
|
22
22
|
[inspect.custom](_depth: any, options: InspectOptions): any;
|
|
23
23
|
}
|
|
24
|
-
export declare function
|
|
25
|
-
interface
|
|
24
|
+
export declare function WebhookListInstance(version: V1): WebhookListInstance;
|
|
25
|
+
interface WebhookResource {
|
|
26
26
|
url: string;
|
|
27
27
|
port_in_target_url: string;
|
|
28
28
|
port_out_target_url: string;
|
|
@@ -30,9 +30,9 @@ interface PortingWebhookConfigurationFetchResource {
|
|
|
30
30
|
port_in_target_date_created: Date;
|
|
31
31
|
port_out_target_date_created: Date;
|
|
32
32
|
}
|
|
33
|
-
export declare class
|
|
33
|
+
export declare class WebhookInstance {
|
|
34
34
|
protected _version: V1;
|
|
35
|
-
constructor(_version: V1, payload:
|
|
35
|
+
constructor(_version: V1, payload: WebhookResource);
|
|
36
36
|
/**
|
|
37
37
|
* The URL of the webhook configuration request
|
|
38
38
|
*/
|
|
@@ -13,11 +13,11 @@
|
|
|
13
13
|
* Do not edit the class manually.
|
|
14
14
|
*/
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.
|
|
16
|
+
exports.WebhookInstance = exports.WebhookListInstance = void 0;
|
|
17
17
|
const util_1 = require("util");
|
|
18
18
|
const deserialize = require("../../../base/deserialize");
|
|
19
19
|
const serialize = require("../../../base/serialize");
|
|
20
|
-
function
|
|
20
|
+
function WebhookListInstance(version) {
|
|
21
21
|
const instance = {};
|
|
22
22
|
instance._version = version;
|
|
23
23
|
instance._solution = {};
|
|
@@ -30,7 +30,7 @@ function PortingWebhookConfigurationFetchListInstance(version) {
|
|
|
30
30
|
method: "get",
|
|
31
31
|
headers,
|
|
32
32
|
});
|
|
33
|
-
operationPromise = operationPromise.then((payload) => new
|
|
33
|
+
operationPromise = operationPromise.then((payload) => new WebhookInstance(operationVersion, payload));
|
|
34
34
|
operationPromise = instance._version.setPromiseCallback(operationPromise, callback);
|
|
35
35
|
return operationPromise;
|
|
36
36
|
};
|
|
@@ -42,8 +42,8 @@ function PortingWebhookConfigurationFetchListInstance(version) {
|
|
|
42
42
|
};
|
|
43
43
|
return instance;
|
|
44
44
|
}
|
|
45
|
-
exports.
|
|
46
|
-
class
|
|
45
|
+
exports.WebhookListInstance = WebhookListInstance;
|
|
46
|
+
class WebhookInstance {
|
|
47
47
|
constructor(_version, payload) {
|
|
48
48
|
this._version = _version;
|
|
49
49
|
this.url = payload.url;
|
|
@@ -72,4 +72,4 @@ class PortingWebhookConfigurationFetchInstance {
|
|
|
72
72
|
return (0, util_1.inspect)(this.toJSON(), options);
|
|
73
73
|
}
|
|
74
74
|
}
|
|
75
|
-
exports.
|
|
75
|
+
exports.WebhookInstance = WebhookInstance;
|
|
@@ -252,7 +252,7 @@ export declare class ServiceInstance {
|
|
|
252
252
|
*/
|
|
253
253
|
accountSid: string;
|
|
254
254
|
/**
|
|
255
|
-
* The name that appears in the body of your verification messages. It can be up to 30 characters long and can include letters, numbers, spaces, dashes, underscores. Phone numbers, special characters or links are NOT allowed. **This value should not contain PII.**
|
|
255
|
+
* The name that appears in the body of your verification messages. It can be up to 30 characters long and can include letters, numbers, spaces, dashes, underscores. Phone numbers, special characters or links are NOT allowed. It cannot contain more than 4 (consecutive or non-consecutive) digits. **This value should not contain PII.**
|
|
256
256
|
*/
|
|
257
257
|
friendlyName: string;
|
|
258
258
|
/**
|
|
@@ -63,7 +63,7 @@ interface VerificationAttemptsSummaryResource {
|
|
|
63
63
|
total_attempts: number;
|
|
64
64
|
total_converted: number;
|
|
65
65
|
total_unconverted: number;
|
|
66
|
-
conversion_rate_percentage:
|
|
66
|
+
conversion_rate_percentage: string;
|
|
67
67
|
url: string;
|
|
68
68
|
}
|
|
69
69
|
export declare class VerificationAttemptsSummaryInstance {
|
|
@@ -86,7 +86,7 @@ export declare class VerificationAttemptsSummaryInstance {
|
|
|
86
86
|
/**
|
|
87
87
|
* Percentage of the confirmed messages over the total, defined by (total_converted/total_attempts)*100.
|
|
88
88
|
*/
|
|
89
|
-
conversionRatePercentage:
|
|
89
|
+
conversionRatePercentage: string;
|
|
90
90
|
url: string;
|
|
91
91
|
private get _proxy();
|
|
92
92
|
/**
|
|
@@ -115,7 +115,7 @@ export declare class VerificationAttemptsSummaryInstance {
|
|
|
115
115
|
totalAttempts: number;
|
|
116
116
|
totalConverted: number;
|
|
117
117
|
totalUnconverted: number;
|
|
118
|
-
conversionRatePercentage:
|
|
118
|
+
conversionRatePercentage: string;
|
|
119
119
|
url: string;
|
|
120
120
|
};
|
|
121
121
|
[inspect.custom](_depth: any, options: InspectOptions): string;
|
|
@@ -1466,20 +1466,30 @@ declare namespace VoiceResponse {
|
|
|
1466
1466
|
* Attributes to pass to conversationRelay
|
|
1467
1467
|
*/
|
|
1468
1468
|
export interface ConversationRelayAttributes {
|
|
1469
|
-
/** debug -
|
|
1470
|
-
debug?:
|
|
1469
|
+
/** debug - Multiple debug options to be used for troubleshooting */
|
|
1470
|
+
debug?: string;
|
|
1471
1471
|
/** dtmfDetection - Whether DTMF tones should be detected and reported in speech transcription */
|
|
1472
1472
|
dtmfDetection?: boolean;
|
|
1473
|
-
/**
|
|
1474
|
-
|
|
1475
|
-
/**
|
|
1476
|
-
|
|
1473
|
+
/** elevenlabsTextNormalization - When using ElevenLabs as TTS provider, this parameter allows you to enable or disable its text normalization feature */
|
|
1474
|
+
elevenlabsTextNormalization?: string;
|
|
1475
|
+
/** hints - Phrases to help better accuracy in speech recognition of these pharases */
|
|
1476
|
+
hints?: string;
|
|
1477
|
+
/** intelligenceService - The Conversational Intelligence Service id or unique name to be used for the session */
|
|
1478
|
+
intelligenceService?: string;
|
|
1479
|
+
/** interruptSensitivity - Set the sensitivity of the interrupt feature for speech. The value can be low, medium, or high */
|
|
1480
|
+
interruptSensitivity?: string;
|
|
1481
|
+
/** interruptible - Whether and how the input from a caller, such as speaking or DTMF can interrupt the play of text-to-speech */
|
|
1482
|
+
interruptible?: string;
|
|
1477
1483
|
/** language - Language to be used for both text-to-speech and transcription */
|
|
1478
1484
|
language?: string;
|
|
1479
1485
|
/** partialPrompts - Whether partial prompts should be reported to WebSocket server before the caller finishes speaking */
|
|
1480
1486
|
partialPrompts?: boolean;
|
|
1487
|
+
/** preemptible - Whether subsequent text-to-speech or play media can interrupt the on-going play of text-to-speech or media */
|
|
1488
|
+
preemptible?: boolean;
|
|
1481
1489
|
/** profanityFilter - Whether profanities should be filtered out of the speech transcription */
|
|
1482
1490
|
profanityFilter?: boolean;
|
|
1491
|
+
/** reportInputDuringAgentSpeech - Whether prompts should be reported to WebSocket server when text-to-speech playing and interrupt is disabled */
|
|
1492
|
+
reportInputDuringAgentSpeech?: boolean;
|
|
1483
1493
|
/** speechModel - Speech model to be used for transcription */
|
|
1484
1494
|
speechModel?: string;
|
|
1485
1495
|
/** transcriptionLanguage - Language to be used for transcription */
|
|
@@ -1496,29 +1506,39 @@ declare namespace VoiceResponse {
|
|
|
1496
1506
|
voice?: string;
|
|
1497
1507
|
/** welcomeGreeting - The sentence to be played automatically when the session is connected */
|
|
1498
1508
|
welcomeGreeting?: string;
|
|
1499
|
-
/** welcomeGreetingInterruptible - Whether caller
|
|
1500
|
-
welcomeGreetingInterruptible?:
|
|
1509
|
+
/** welcomeGreetingInterruptible - "Whether and how the input from a caller, such as speaking or DTMF can interrupt the welcome greeting */
|
|
1510
|
+
welcomeGreetingInterruptible?: string;
|
|
1501
1511
|
}
|
|
1502
1512
|
/**
|
|
1503
1513
|
* Attributes to pass to assistant
|
|
1504
1514
|
*/
|
|
1505
1515
|
export interface AssistantAttributes {
|
|
1506
|
-
/** debug -
|
|
1507
|
-
debug?:
|
|
1516
|
+
/** debug - Multiple debug options to be used for troubleshooting */
|
|
1517
|
+
debug?: string;
|
|
1508
1518
|
/** dtmfDetection - Whether DTMF tones should be detected and reported in speech transcription */
|
|
1509
1519
|
dtmfDetection?: boolean;
|
|
1520
|
+
/** elevenlabsTextNormalization - When using ElevenLabs as TTS provider, this parameter allows you to enable or disable its text normalization feature */
|
|
1521
|
+
elevenlabsTextNormalization?: string;
|
|
1522
|
+
/** hints - Phrases to help better accuracy in speech recognition of these pharases */
|
|
1523
|
+
hints?: string;
|
|
1510
1524
|
/** id - The assistant ID of the AI Assistant */
|
|
1511
1525
|
id?: string;
|
|
1512
|
-
/**
|
|
1513
|
-
|
|
1514
|
-
/**
|
|
1515
|
-
|
|
1526
|
+
/** intelligenceService - The Conversational Intelligence Service id or unique name to be used for the session */
|
|
1527
|
+
intelligenceService?: string;
|
|
1528
|
+
/** interruptSensitivity - Set the sensitivity of the interrupt feature for speech. The value can be low, medium, or high */
|
|
1529
|
+
interruptSensitivity?: string;
|
|
1530
|
+
/** interruptible - Whether and how the input from a caller, such as speaking or DTMF can interrupt the play of text-to-speech */
|
|
1531
|
+
interruptible?: string;
|
|
1516
1532
|
/** language - Language to be used for both text-to-speech and transcription */
|
|
1517
1533
|
language?: string;
|
|
1518
1534
|
/** partialPrompts - Whether partial prompts should be reported to WebSocket server before the caller finishes speaking */
|
|
1519
1535
|
partialPrompts?: boolean;
|
|
1536
|
+
/** preemptible - Whether subsequent text-to-speech or play media can interrupt the on-going play of text-to-speech or media */
|
|
1537
|
+
preemptible?: boolean;
|
|
1520
1538
|
/** profanityFilter - Whether profanities should be filtered out of the speech transcription */
|
|
1521
1539
|
profanityFilter?: boolean;
|
|
1540
|
+
/** reportInputDuringAgentSpeech - Whether prompts should be reported to WebSocket server when text-to-speech playing and interrupt is disabled */
|
|
1541
|
+
reportInputDuringAgentSpeech?: boolean;
|
|
1522
1542
|
/** speechModel - Speech model to be used for transcription */
|
|
1523
1543
|
speechModel?: string;
|
|
1524
1544
|
/** transcriptionLanguage - Language to be used for transcription */
|
|
@@ -1533,8 +1553,8 @@ declare namespace VoiceResponse {
|
|
|
1533
1553
|
voice?: string;
|
|
1534
1554
|
/** welcomeGreeting - The sentence to be played automatically when the session is connected */
|
|
1535
1555
|
welcomeGreeting?: string;
|
|
1536
|
-
/** welcomeGreetingInterruptible - Whether caller
|
|
1537
|
-
welcomeGreetingInterruptible?:
|
|
1556
|
+
/** welcomeGreetingInterruptible - "Whether and how the input from a caller, such as speaking or DTMF can interrupt the welcome greeting */
|
|
1557
|
+
welcomeGreetingInterruptible?: string;
|
|
1538
1558
|
}
|
|
1539
1559
|
/**
|
|
1540
1560
|
* Attributes to pass to language
|