twilio 4.16.0 → 4.17.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/lib/rest/api/v2010/account/message/feedback.d.ts +4 -4
- package/lib/rest/api/v2010/account/message.d.ts +8 -0
- package/lib/rest/api/v2010/account/message.js +4 -0
- package/lib/rest/flexApi/v1/configuration.d.ts +6 -0
- package/lib/rest/flexApi/v1/configuration.js +2 -0
- package/lib/rest/messaging/v1/service.d.ts +3 -3
- package/lib/rest/numbers/v2/bulkHostedNumberOrder.d.ts +8 -14
- package/lib/rest/numbers/v2/bulkHostedNumberOrder.js +14 -16
- package/package.json +1 -1
|
@@ -53,20 +53,20 @@ export declare class FeedbackInstance {
|
|
|
53
53
|
protected _version: V2010;
|
|
54
54
|
constructor(_version: V2010, payload: FeedbackResource, accountSid: string, messageSid: string);
|
|
55
55
|
/**
|
|
56
|
-
* The SID of the [Account](https://www.twilio.com/docs/iam/api/account)
|
|
56
|
+
* The SID of the [Account](https://www.twilio.com/docs/iam/api/account) associated with this MessageFeedback resource.
|
|
57
57
|
*/
|
|
58
58
|
accountSid: string;
|
|
59
59
|
/**
|
|
60
|
-
* The SID of the Message resource
|
|
60
|
+
* The SID of the Message resource associated with this MessageFeedback resource.
|
|
61
61
|
*/
|
|
62
62
|
messageSid: string;
|
|
63
63
|
outcome: FeedbackOutcome;
|
|
64
64
|
/**
|
|
65
|
-
* The date and time in GMT
|
|
65
|
+
* The date and time in GMT when this MessageFeedback resource was created, specified in [RFC 2822](https://www.ietf.org/rfc/rfc2822.txt) format.
|
|
66
66
|
*/
|
|
67
67
|
dateCreated: Date;
|
|
68
68
|
/**
|
|
69
|
-
* The date and time in GMT
|
|
69
|
+
* The date and time in GMT when this MessageFeedback resource was last updated, specified in [RFC 2822](https://www.ietf.org/rfc/rfc2822.txt) format.
|
|
70
70
|
*/
|
|
71
71
|
dateUpdated: Date;
|
|
72
72
|
/**
|
|
@@ -59,6 +59,8 @@ export interface MessageListInstanceCreateOptions {
|
|
|
59
59
|
sendAsMms?: boolean;
|
|
60
60
|
/** For [Content Editor/API](https://www.twilio.com/docs/content) only: Key-value pairs of [Template variables](https://www.twilio.com/docs/content/using-variables-with-content-api) and their substitution values. `content_sid` parameter must also be provided. If values are not defined in the `content_variables` parameter, the [Template\\\'s default placeholder values](https://www.twilio.com/docs/content/content-api-resources#create-templates) are used. */
|
|
61
61
|
contentVariables?: string;
|
|
62
|
+
/** A string containing a JSON map of key value pairs of tags to be recorded as metadata for the message. The object may contain up to 10 tags. Keys and values can each be up to 128 characters in length. */
|
|
63
|
+
tags?: string;
|
|
62
64
|
/** */
|
|
63
65
|
riskCheck?: MessageRiskCheck;
|
|
64
66
|
/** The sender\\\'s Twilio phone number (in [E.164](https://en.wikipedia.org/wiki/E.164) format), [alphanumeric sender ID](https://www.twilio.com/docs/sms/send-messages#use-an-alphanumeric-sender-id), [Wireless SIM](https://www.twilio.com/docs/iot/wireless/programmable-wireless-send-machine-machine-sms-commands), [short code](https://www.twilio.com/docs/sms/api/short-code), or [channel address](https://www.twilio.com/docs/messaging/channels) (e.g., `whatsapp:+15554449999`). The value of the `from` parameter must be a sender that is hosted within Twilio and belong to the Account creating the Message. If you are using `messaging_service_sid`, this parameter can be empty (Twilio assigns a `from` value from the Messaging Service\\\'s Sender Pool) or you can provide a specific sender from your Sender Pool. */
|
|
@@ -225,6 +227,7 @@ interface MessageResource {
|
|
|
225
227
|
price_unit: string;
|
|
226
228
|
api_version: string;
|
|
227
229
|
subresource_uris: Record<string, string>;
|
|
230
|
+
tags: any;
|
|
228
231
|
}
|
|
229
232
|
export declare class MessageInstance {
|
|
230
233
|
protected _version: V2010;
|
|
@@ -305,6 +308,10 @@ export declare class MessageInstance {
|
|
|
305
308
|
* A list of related resources identified by their URIs relative to `https://api.twilio.com`
|
|
306
309
|
*/
|
|
307
310
|
subresourceUris: Record<string, string>;
|
|
311
|
+
/**
|
|
312
|
+
* A string containing a JSON map of key value pairs of tags to be recorded as metadata for the message.
|
|
313
|
+
*/
|
|
314
|
+
tags: any;
|
|
308
315
|
private get _proxy();
|
|
309
316
|
/**
|
|
310
317
|
* Remove a MessageInstance
|
|
@@ -373,6 +380,7 @@ export declare class MessageInstance {
|
|
|
373
380
|
priceUnit: string;
|
|
374
381
|
apiVersion: string;
|
|
375
382
|
subresourceUris: Record<string, string>;
|
|
383
|
+
tags: any;
|
|
376
384
|
};
|
|
377
385
|
[inspect.custom](_depth: any, options: InspectOptions): string;
|
|
378
386
|
}
|
|
@@ -129,6 +129,7 @@ class MessageInstance {
|
|
|
129
129
|
this.priceUnit = payload.price_unit;
|
|
130
130
|
this.apiVersion = payload.api_version;
|
|
131
131
|
this.subresourceUris = payload.subresource_uris;
|
|
132
|
+
this.tags = payload.tags;
|
|
132
133
|
this._solution = { accountSid, sid: sid || this.sid };
|
|
133
134
|
}
|
|
134
135
|
get _proxy() {
|
|
@@ -199,6 +200,7 @@ class MessageInstance {
|
|
|
199
200
|
priceUnit: this.priceUnit,
|
|
200
201
|
apiVersion: this.apiVersion,
|
|
201
202
|
subresourceUris: this.subresourceUris,
|
|
203
|
+
tags: this.tags,
|
|
202
204
|
};
|
|
203
205
|
}
|
|
204
206
|
[util_1.inspect.custom](_depth, options) {
|
|
@@ -258,6 +260,8 @@ function MessageListInstance(version, accountSid) {
|
|
|
258
260
|
data["SendAsMms"] = serialize.bool(params["sendAsMms"]);
|
|
259
261
|
if (params["contentVariables"] !== undefined)
|
|
260
262
|
data["ContentVariables"] = params["contentVariables"];
|
|
263
|
+
if (params["tags"] !== undefined)
|
|
264
|
+
data["Tags"] = params["tags"];
|
|
261
265
|
if (params["riskCheck"] !== undefined)
|
|
262
266
|
data["RiskCheck"] = params["riskCheck"];
|
|
263
267
|
if (params["from"] !== undefined)
|
|
@@ -95,6 +95,7 @@ interface ConfigurationResource {
|
|
|
95
95
|
channel_configs: Array<any>;
|
|
96
96
|
debugger_integration: any;
|
|
97
97
|
flex_ui_status_report: any;
|
|
98
|
+
agent_conv_end_methods: any;
|
|
98
99
|
}
|
|
99
100
|
export declare class ConfigurationInstance {
|
|
100
101
|
protected _version: V1;
|
|
@@ -278,6 +279,10 @@ export declare class ConfigurationInstance {
|
|
|
278
279
|
* Configurable parameters for Flex UI Status report.
|
|
279
280
|
*/
|
|
280
281
|
flexUiStatusReport: any;
|
|
282
|
+
/**
|
|
283
|
+
* Agent conversation end methods.
|
|
284
|
+
*/
|
|
285
|
+
agentConvEndMethods: any;
|
|
281
286
|
private get _proxy();
|
|
282
287
|
/**
|
|
283
288
|
* Fetch a ConfigurationInstance
|
|
@@ -347,6 +352,7 @@ export declare class ConfigurationInstance {
|
|
|
347
352
|
channelConfigs: any[];
|
|
348
353
|
debuggerIntegration: any;
|
|
349
354
|
flexUiStatusReport: any;
|
|
355
|
+
agentConvEndMethods: any;
|
|
350
356
|
};
|
|
351
357
|
[inspect.custom](_depth: any, options: InspectOptions): string;
|
|
352
358
|
}
|
|
@@ -107,6 +107,7 @@ class ConfigurationInstance {
|
|
|
107
107
|
this.channelConfigs = payload.channel_configs;
|
|
108
108
|
this.debuggerIntegration = payload.debugger_integration;
|
|
109
109
|
this.flexUiStatusReport = payload.flex_ui_status_report;
|
|
110
|
+
this.agentConvEndMethods = payload.agent_conv_end_methods;
|
|
110
111
|
this._solution = {};
|
|
111
112
|
}
|
|
112
113
|
get _proxy() {
|
|
@@ -169,6 +170,7 @@ class ConfigurationInstance {
|
|
|
169
170
|
channelConfigs: this.channelConfigs,
|
|
170
171
|
debuggerIntegration: this.debuggerIntegration,
|
|
171
172
|
flexUiStatusReport: this.flexUiStatusReport,
|
|
173
|
+
agentConvEndMethods: this.agentConvEndMethods,
|
|
172
174
|
};
|
|
173
175
|
}
|
|
174
176
|
[util_1.inspect.custom](_depth, options) {
|
|
@@ -34,7 +34,7 @@ export interface ServiceContextUpdateOptions {
|
|
|
34
34
|
smartEncoding?: boolean;
|
|
35
35
|
/** */
|
|
36
36
|
scanMessageContent?: ServiceScanMessageContent;
|
|
37
|
-
/**
|
|
37
|
+
/** [OBSOLETE] Former feature used to fallback to long code sender after certain short code message failures. */
|
|
38
38
|
fallbackToLongCode?: boolean;
|
|
39
39
|
/** Whether to enable [Area Code Geomatch](https://www.twilio.com/docs/messaging/services#area-code-geomatch) on the Service Instance. */
|
|
40
40
|
areaCodeGeomatch?: boolean;
|
|
@@ -71,7 +71,7 @@ export interface ServiceListInstanceCreateOptions {
|
|
|
71
71
|
smartEncoding?: boolean;
|
|
72
72
|
/** */
|
|
73
73
|
scanMessageContent?: ServiceScanMessageContent;
|
|
74
|
-
/**
|
|
74
|
+
/** [OBSOLETE] Former feature used to fallback to long code sender after certain short code message failures. */
|
|
75
75
|
fallbackToLongCode?: boolean;
|
|
76
76
|
/** Whether to enable [Area Code Geomatch](https://www.twilio.com/docs/messaging/services#area-code-geomatch) on the Service Instance. */
|
|
77
77
|
areaCodeGeomatch?: boolean;
|
|
@@ -281,7 +281,7 @@ export declare class ServiceInstance {
|
|
|
281
281
|
smartEncoding: boolean;
|
|
282
282
|
scanMessageContent: ServiceScanMessageContent;
|
|
283
283
|
/**
|
|
284
|
-
*
|
|
284
|
+
* [OBSOLETE] Former feature used to fallback to long code sender after certain short code message failures.
|
|
285
285
|
*/
|
|
286
286
|
fallbackToLongCode: boolean;
|
|
287
287
|
/**
|
|
@@ -34,13 +34,13 @@ export interface BulkHostedNumberOrderContext {
|
|
|
34
34
|
[inspect.custom](_depth: any, options: InspectOptions): any;
|
|
35
35
|
}
|
|
36
36
|
export interface BulkHostedNumberOrderContextSolution {
|
|
37
|
-
|
|
37
|
+
bulkHostingSid: string;
|
|
38
38
|
}
|
|
39
39
|
export declare class BulkHostedNumberOrderContextImpl implements BulkHostedNumberOrderContext {
|
|
40
40
|
protected _version: V2;
|
|
41
41
|
protected _solution: BulkHostedNumberOrderContextSolution;
|
|
42
42
|
protected _uri: string;
|
|
43
|
-
constructor(_version: V2,
|
|
43
|
+
constructor(_version: V2, bulkHostingSid: string);
|
|
44
44
|
fetch(params?: BulkHostedNumberOrderContextFetchOptions | ((error: Error | null, item?: BulkHostedNumberOrderInstance) => any), callback?: (error: Error | null, item?: BulkHostedNumberOrderInstance) => any): Promise<BulkHostedNumberOrderInstance>;
|
|
45
45
|
/**
|
|
46
46
|
* Provide a user-friendly representation
|
|
@@ -51,8 +51,7 @@ export declare class BulkHostedNumberOrderContextImpl implements BulkHostedNumbe
|
|
|
51
51
|
[inspect.custom](_depth: any, options: InspectOptions): string;
|
|
52
52
|
}
|
|
53
53
|
interface BulkHostedNumberOrderResource {
|
|
54
|
-
|
|
55
|
-
account_sid: string;
|
|
54
|
+
bulk_hosting_sid: string;
|
|
56
55
|
request_status: BulkHostedNumberOrderRequestStatus;
|
|
57
56
|
friendly_name: string;
|
|
58
57
|
notification_email: string;
|
|
@@ -66,15 +65,11 @@ export declare class BulkHostedNumberOrderInstance {
|
|
|
66
65
|
protected _version: V2;
|
|
67
66
|
protected _solution: BulkHostedNumberOrderContextSolution;
|
|
68
67
|
protected _context?: BulkHostedNumberOrderContext;
|
|
69
|
-
constructor(_version: V2, payload: BulkHostedNumberOrderResource,
|
|
68
|
+
constructor(_version: V2, payload: BulkHostedNumberOrderResource, bulkHostingSid?: string);
|
|
70
69
|
/**
|
|
71
70
|
* A 34 character string that uniquely identifies this BulkHostedNumberOrder.
|
|
72
71
|
*/
|
|
73
|
-
|
|
74
|
-
/**
|
|
75
|
-
* A 34 character string that uniquely identifies the account.
|
|
76
|
-
*/
|
|
77
|
-
accountSid: string;
|
|
72
|
+
bulkHostingSid: string;
|
|
78
73
|
requestStatus: BulkHostedNumberOrderRequestStatus;
|
|
79
74
|
/**
|
|
80
75
|
* A 128 character string that is a human-readable text that describes this resource.
|
|
@@ -128,8 +123,7 @@ export declare class BulkHostedNumberOrderInstance {
|
|
|
128
123
|
* @returns Object
|
|
129
124
|
*/
|
|
130
125
|
toJSON(): {
|
|
131
|
-
|
|
132
|
-
accountSid: string;
|
|
126
|
+
bulkHostingSid: string;
|
|
133
127
|
requestStatus: BulkHostedNumberOrderRequestStatus;
|
|
134
128
|
friendlyName: string;
|
|
135
129
|
notificationEmail: string;
|
|
@@ -147,8 +141,8 @@ export interface BulkHostedNumberOrderListInstance {
|
|
|
147
141
|
_version: V2;
|
|
148
142
|
_solution: BulkHostedNumberOrderSolution;
|
|
149
143
|
_uri: string;
|
|
150
|
-
(
|
|
151
|
-
get(
|
|
144
|
+
(bulkHostingSid: string): BulkHostedNumberOrderContext;
|
|
145
|
+
get(bulkHostingSid: string): BulkHostedNumberOrderContext;
|
|
152
146
|
/**
|
|
153
147
|
* Provide a user-friendly representation
|
|
154
148
|
*/
|
|
@@ -19,13 +19,13 @@ const deserialize = require("../../../base/deserialize");
|
|
|
19
19
|
const serialize = require("../../../base/serialize");
|
|
20
20
|
const utility_1 = require("../../../base/utility");
|
|
21
21
|
class BulkHostedNumberOrderContextImpl {
|
|
22
|
-
constructor(_version,
|
|
22
|
+
constructor(_version, bulkHostingSid) {
|
|
23
23
|
this._version = _version;
|
|
24
|
-
if (!(0, utility_1.isValidPathParam)(
|
|
25
|
-
throw new Error("Parameter '
|
|
24
|
+
if (!(0, utility_1.isValidPathParam)(bulkHostingSid)) {
|
|
25
|
+
throw new Error("Parameter 'bulkHostingSid' is not valid.");
|
|
26
26
|
}
|
|
27
|
-
this._solution = {
|
|
28
|
-
this._uri = `/HostedNumber/Orders/Bulk/${
|
|
27
|
+
this._solution = { bulkHostingSid };
|
|
28
|
+
this._uri = `/HostedNumber/Orders/Bulk/${bulkHostingSid}`;
|
|
29
29
|
}
|
|
30
30
|
fetch(params, callback) {
|
|
31
31
|
if (params instanceof Function) {
|
|
@@ -46,7 +46,7 @@ class BulkHostedNumberOrderContextImpl {
|
|
|
46
46
|
params: data,
|
|
47
47
|
headers,
|
|
48
48
|
});
|
|
49
|
-
operationPromise = operationPromise.then((payload) => new BulkHostedNumberOrderInstance(operationVersion, payload, instance._solution.
|
|
49
|
+
operationPromise = operationPromise.then((payload) => new BulkHostedNumberOrderInstance(operationVersion, payload, instance._solution.bulkHostingSid));
|
|
50
50
|
operationPromise = instance._version.setPromiseCallback(operationPromise, callback);
|
|
51
51
|
return operationPromise;
|
|
52
52
|
}
|
|
@@ -64,10 +64,9 @@ class BulkHostedNumberOrderContextImpl {
|
|
|
64
64
|
}
|
|
65
65
|
exports.BulkHostedNumberOrderContextImpl = BulkHostedNumberOrderContextImpl;
|
|
66
66
|
class BulkHostedNumberOrderInstance {
|
|
67
|
-
constructor(_version, payload,
|
|
67
|
+
constructor(_version, payload, bulkHostingSid) {
|
|
68
68
|
this._version = _version;
|
|
69
|
-
this.
|
|
70
|
-
this.accountSid = payload.account_sid;
|
|
69
|
+
this.bulkHostingSid = payload.bulk_hosting_sid;
|
|
71
70
|
this.requestStatus = payload.request_status;
|
|
72
71
|
this.friendlyName = payload.friendly_name;
|
|
73
72
|
this.notificationEmail = payload.notification_email;
|
|
@@ -76,12 +75,12 @@ class BulkHostedNumberOrderInstance {
|
|
|
76
75
|
this.url = payload.url;
|
|
77
76
|
this.totalCount = deserialize.integer(payload.total_count);
|
|
78
77
|
this.results = payload.results;
|
|
79
|
-
this._solution = {
|
|
78
|
+
this._solution = { bulkHostingSid: bulkHostingSid || this.bulkHostingSid };
|
|
80
79
|
}
|
|
81
80
|
get _proxy() {
|
|
82
81
|
this._context =
|
|
83
82
|
this._context ||
|
|
84
|
-
new BulkHostedNumberOrderContextImpl(this._version, this._solution.
|
|
83
|
+
new BulkHostedNumberOrderContextImpl(this._version, this._solution.bulkHostingSid);
|
|
85
84
|
return this._context;
|
|
86
85
|
}
|
|
87
86
|
fetch(params, callback) {
|
|
@@ -94,8 +93,7 @@ class BulkHostedNumberOrderInstance {
|
|
|
94
93
|
*/
|
|
95
94
|
toJSON() {
|
|
96
95
|
return {
|
|
97
|
-
|
|
98
|
-
accountSid: this.accountSid,
|
|
96
|
+
bulkHostingSid: this.bulkHostingSid,
|
|
99
97
|
requestStatus: this.requestStatus,
|
|
100
98
|
friendlyName: this.friendlyName,
|
|
101
99
|
notificationEmail: this.notificationEmail,
|
|
@@ -112,9 +110,9 @@ class BulkHostedNumberOrderInstance {
|
|
|
112
110
|
}
|
|
113
111
|
exports.BulkHostedNumberOrderInstance = BulkHostedNumberOrderInstance;
|
|
114
112
|
function BulkHostedNumberOrderListInstance(version) {
|
|
115
|
-
const instance = ((
|
|
116
|
-
instance.get = function get(
|
|
117
|
-
return new BulkHostedNumberOrderContextImpl(version,
|
|
113
|
+
const instance = ((bulkHostingSid) => instance.get(bulkHostingSid));
|
|
114
|
+
instance.get = function get(bulkHostingSid) {
|
|
115
|
+
return new BulkHostedNumberOrderContextImpl(version, bulkHostingSid);
|
|
118
116
|
};
|
|
119
117
|
instance._version = version;
|
|
120
118
|
instance._solution = {};
|