twilio 5.0.1 → 5.0.3
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/Twilio.d.ts +0 -5
- package/lib/rest/Twilio.js +0 -5
- package/lib/rest/api/v2010/account/call/payment.d.ts +1 -1
- package/lib/rest/api/v2010/account/call.d.ts +22 -22
- package/lib/rest/api/v2010/account/conference/participant.d.ts +6 -0
- package/lib/rest/api/v2010/account/conference/participant.js +2 -0
- package/lib/rest/api/v2010/account/conference.d.ts +22 -22
- package/lib/rest/content/v1/content/approvalCreate.d.ts +3 -3
- package/lib/rest/content/v1/content/approvalCreate.js +7 -7
- package/lib/rest/content/v1/content/approvalFetch.d.ts +5 -5
- package/lib/rest/content/v1/content/approvalFetch.js +14 -14
- package/lib/rest/conversations/v1/conversation.d.ts +6 -6
- package/lib/rest/conversations/v1/service/conversation.d.ts +6 -6
- package/lib/rest/flexApi/v1/plugin/pluginVersions.d.ts +4 -0
- package/lib/rest/flexApi/v1/plugin/pluginVersions.js +4 -0
- package/lib/rest/lookups/v2/phoneNumber.d.ts +9 -1
- package/lib/rest/lookups/v2/phoneNumber.js +4 -0
- package/lib/rest/messaging/v1/service.d.ts +6 -0
- package/lib/rest/messaging/v1/service.js +2 -0
- package/lib/rest/numbers/v1/portingPortInFetch.d.ts +6 -0
- package/lib/rest/numbers/v1/portingPortInFetch.js +2 -0
- package/lib/rest/oauth/v1/token.d.ts +8 -4
- package/lib/rest/oauth/v1/token.js +7 -6
- package/lib/rest/trusthub/v1/complianceRegistrationInquiries.d.ts +84 -10
- package/lib/rest/trusthub/v1/complianceRegistrationInquiries.js +92 -28
- package/lib/rest/trusthub/v1/trustProducts.d.ts +16 -16
- package/lib/rest/verify/v2/service.d.ts +11 -0
- package/lib/rest/verify/v2/service.js +10 -0
- package/lib/twiml/VoiceResponse.d.ts +3 -3
- package/package.json +1 -1
- package/lib/rest/Media.d.ts +0 -4
- package/lib/rest/Media.js +0 -8
- package/lib/rest/MediaBase.d.ts +0 -13
- package/lib/rest/MediaBase.js +0 -31
- package/lib/rest/media/V1.d.ts +0 -25
- package/lib/rest/media/V1.js +0 -51
- package/lib/rest/media/v1/mediaProcessor.d.ts +0 -317
- package/lib/rest/media/v1/mediaProcessor.js +0 -256
- package/lib/rest/media/v1/mediaRecording.d.ts +0 -309
- package/lib/rest/media/v1/mediaRecording.js +0 -226
- package/lib/rest/media/v1/playerStreamer/playbackGrant.d.ts +0 -151
- package/lib/rest/media/v1/playerStreamer/playbackGrant.js +0 -146
- package/lib/rest/media/v1/playerStreamer.d.ts +0 -327
- package/lib/rest/media/v1/playerStreamer.js +0 -264
|
@@ -77,9 +77,9 @@ export interface ConversationListInstanceCreateOptions {
|
|
|
77
77
|
* Options to pass to each
|
|
78
78
|
*/
|
|
79
79
|
export interface ConversationListInstanceEachOptions {
|
|
80
|
-
/**
|
|
80
|
+
/** Specifies the beginning of the date range for filtering Conversations based on their creation date. Conversations that were created on or after this date will be included in the results. The date must be in ISO8601 format, specifically starting at the beginning of the specified date (YYYY-MM-DDT00:00:00Z), for precise filtering. This parameter can be combined with other filters. If this filter is used, the returned list is sorted by latest conversation creation date in descending order. */
|
|
81
81
|
startDate?: string;
|
|
82
|
-
/**
|
|
82
|
+
/** Defines the end of the date range for filtering conversations by their creation date. Only conversations that were created on or before this date will appear in the results. The date must be in ISO8601 format, specifically capturing up to the end of the specified date (YYYY-MM-DDT23:59:59Z), to ensure that conversations from the entire end day are included. This parameter can be combined with other filters. If this filter is used, the returned list is sorted by latest conversation creation date in descending order. */
|
|
83
83
|
endDate?: string;
|
|
84
84
|
/** State for sorting and filtering list of Conversations. Can be `active`, `inactive` or `closed` */
|
|
85
85
|
state?: ConversationState;
|
|
@@ -96,9 +96,9 @@ export interface ConversationListInstanceEachOptions {
|
|
|
96
96
|
* Options to pass to list
|
|
97
97
|
*/
|
|
98
98
|
export interface ConversationListInstanceOptions {
|
|
99
|
-
/**
|
|
99
|
+
/** Specifies the beginning of the date range for filtering Conversations based on their creation date. Conversations that were created on or after this date will be included in the results. The date must be in ISO8601 format, specifically starting at the beginning of the specified date (YYYY-MM-DDT00:00:00Z), for precise filtering. This parameter can be combined with other filters. If this filter is used, the returned list is sorted by latest conversation creation date in descending order. */
|
|
100
100
|
startDate?: string;
|
|
101
|
-
/**
|
|
101
|
+
/** Defines the end of the date range for filtering conversations by their creation date. Only conversations that were created on or before this date will appear in the results. The date must be in ISO8601 format, specifically capturing up to the end of the specified date (YYYY-MM-DDT23:59:59Z), to ensure that conversations from the entire end day are included. This parameter can be combined with other filters. If this filter is used, the returned list is sorted by latest conversation creation date in descending order. */
|
|
102
102
|
endDate?: string;
|
|
103
103
|
/** State for sorting and filtering list of Conversations. Can be `active`, `inactive` or `closed` */
|
|
104
104
|
state?: ConversationState;
|
|
@@ -111,9 +111,9 @@ export interface ConversationListInstanceOptions {
|
|
|
111
111
|
* Options to pass to page
|
|
112
112
|
*/
|
|
113
113
|
export interface ConversationListInstancePageOptions {
|
|
114
|
-
/**
|
|
114
|
+
/** Specifies the beginning of the date range for filtering Conversations based on their creation date. Conversations that were created on or after this date will be included in the results. The date must be in ISO8601 format, specifically starting at the beginning of the specified date (YYYY-MM-DDT00:00:00Z), for precise filtering. This parameter can be combined with other filters. If this filter is used, the returned list is sorted by latest conversation creation date in descending order. */
|
|
115
115
|
startDate?: string;
|
|
116
|
-
/**
|
|
116
|
+
/** Defines the end of the date range for filtering conversations by their creation date. Only conversations that were created on or before this date will appear in the results. The date must be in ISO8601 format, specifically capturing up to the end of the specified date (YYYY-MM-DDT23:59:59Z), to ensure that conversations from the entire end day are included. This parameter can be combined with other filters. If this filter is used, the returned list is sorted by latest conversation creation date in descending order. */
|
|
117
117
|
endDate?: string;
|
|
118
118
|
/** State for sorting and filtering list of Conversations. Can be `active`, `inactive` or `closed` */
|
|
119
119
|
state?: ConversationState;
|
|
@@ -24,6 +24,10 @@ export interface PluginVersionsListInstanceCreateOptions {
|
|
|
24
24
|
changelog?: string;
|
|
25
25
|
/** Whether this Flex Plugin Version requires authorization. */
|
|
26
26
|
private?: boolean;
|
|
27
|
+
/** The version of Flex Plugins CLI used to create this plugin */
|
|
28
|
+
cliVersion?: string;
|
|
29
|
+
/** The validation status of the plugin, indicating whether it has been validated */
|
|
30
|
+
validateStatus?: string;
|
|
27
31
|
}
|
|
28
32
|
/**
|
|
29
33
|
* Options to pass to each
|
|
@@ -146,6 +146,10 @@ function PluginVersionsListInstance(version, pluginSid) {
|
|
|
146
146
|
data["Changelog"] = params["changelog"];
|
|
147
147
|
if (params["private"] !== undefined)
|
|
148
148
|
data["Private"] = serialize.bool(params["private"]);
|
|
149
|
+
if (params["cliVersion"] !== undefined)
|
|
150
|
+
data["CliVersion"] = params["cliVersion"];
|
|
151
|
+
if (params["validateStatus"] !== undefined)
|
|
152
|
+
data["ValidateStatus"] = params["validateStatus"];
|
|
149
153
|
const headers = {};
|
|
150
154
|
headers["Content-Type"] = "application/x-www-form-urlencoded";
|
|
151
155
|
if (params["flexMetadata"] !== undefined)
|
|
@@ -6,7 +6,7 @@ export type PhoneNumberValidationError = "TOO_SHORT" | "TOO_LONG" | "INVALID_BUT
|
|
|
6
6
|
* Options to pass to fetch a PhoneNumberInstance
|
|
7
7
|
*/
|
|
8
8
|
export interface PhoneNumberContextFetchOptions {
|
|
9
|
-
/** A comma-separated list of fields to return. Possible values are validation, caller_name, sim_swap, call_forwarding, line_status, line_type_intelligence, identity_match, reassigned_number, sms_pumping_risk, phone_number_quality_score. */
|
|
9
|
+
/** A comma-separated list of fields to return. Possible values are validation, caller_name, sim_swap, call_forwarding, line_status, line_type_intelligence, identity_match, reassigned_number, sms_pumping_risk, phone_number_quality_score, pre_fill. */
|
|
10
10
|
fields?: string;
|
|
11
11
|
/** The [country code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) used if the phone number provided is in national format. */
|
|
12
12
|
countryCode?: string;
|
|
@@ -32,6 +32,8 @@ export interface PhoneNumberContextFetchOptions {
|
|
|
32
32
|
dateOfBirth?: string;
|
|
33
33
|
/** The date you obtained consent to call or text the end-user of the phone number or a date on which you are reasonably certain that the end-user could still be reached at that number. This query parameter is only used (optionally) for reassigned_number package requests. */
|
|
34
34
|
lastVerifiedDate?: string;
|
|
35
|
+
/** The unique identifier associated with a verification process through verify API. This query parameter is only used (optionally) for pre_fill package requests. */
|
|
36
|
+
verificationSid?: string;
|
|
35
37
|
}
|
|
36
38
|
export interface PhoneNumberContext {
|
|
37
39
|
/**
|
|
@@ -90,6 +92,7 @@ interface PhoneNumberResource {
|
|
|
90
92
|
reassigned_number: any;
|
|
91
93
|
sms_pumping_risk: any;
|
|
92
94
|
phone_number_quality_score: any;
|
|
95
|
+
pre_fill: any;
|
|
93
96
|
url: string;
|
|
94
97
|
}
|
|
95
98
|
export declare class PhoneNumberInstance {
|
|
@@ -157,6 +160,10 @@ export declare class PhoneNumberInstance {
|
|
|
157
160
|
* An object that contains information of a mobile phone number quality score. Quality score will return a risk score about the phone number.
|
|
158
161
|
*/
|
|
159
162
|
phoneNumberQualityScore: any;
|
|
163
|
+
/**
|
|
164
|
+
* An object that contains pre fill information. pre_fill will return PII information associated with the phone number like first name, last name, address line, country code, state and postal code.
|
|
165
|
+
*/
|
|
166
|
+
preFill: any;
|
|
160
167
|
/**
|
|
161
168
|
* The absolute URL of the resource.
|
|
162
169
|
*/
|
|
@@ -200,6 +207,7 @@ export declare class PhoneNumberInstance {
|
|
|
200
207
|
reassignedNumber: any;
|
|
201
208
|
smsPumpingRisk: any;
|
|
202
209
|
phoneNumberQualityScore: any;
|
|
210
|
+
preFill: any;
|
|
203
211
|
url: string;
|
|
204
212
|
};
|
|
205
213
|
[inspect.custom](_depth: any, options: InspectOptions): string;
|
|
@@ -62,6 +62,8 @@ class PhoneNumberContextImpl {
|
|
|
62
62
|
data["DateOfBirth"] = params["dateOfBirth"];
|
|
63
63
|
if (params["lastVerifiedDate"] !== undefined)
|
|
64
64
|
data["LastVerifiedDate"] = params["lastVerifiedDate"];
|
|
65
|
+
if (params["verificationSid"] !== undefined)
|
|
66
|
+
data["VerificationSid"] = params["verificationSid"];
|
|
65
67
|
const headers = {};
|
|
66
68
|
const instance = this;
|
|
67
69
|
let operationVersion = instance._version, operationPromise = operationVersion.fetch({
|
|
@@ -105,6 +107,7 @@ class PhoneNumberInstance {
|
|
|
105
107
|
this.reassignedNumber = payload.reassigned_number;
|
|
106
108
|
this.smsPumpingRisk = payload.sms_pumping_risk;
|
|
107
109
|
this.phoneNumberQualityScore = payload.phone_number_quality_score;
|
|
110
|
+
this.preFill = payload.pre_fill;
|
|
108
111
|
this.url = payload.url;
|
|
109
112
|
this._solution = { phoneNumber: phoneNumber || this.phoneNumber };
|
|
110
113
|
}
|
|
@@ -139,6 +142,7 @@ class PhoneNumberInstance {
|
|
|
139
142
|
reassignedNumber: this.reassignedNumber,
|
|
140
143
|
smsPumpingRisk: this.smsPumpingRisk,
|
|
141
144
|
phoneNumberQualityScore: this.phoneNumberQualityScore,
|
|
145
|
+
preFill: this.preFill,
|
|
142
146
|
url: this.url,
|
|
143
147
|
};
|
|
144
148
|
}
|
|
@@ -221,6 +221,7 @@ interface ServiceResource {
|
|
|
221
221
|
usecase: string;
|
|
222
222
|
us_app_to_person_registered: boolean;
|
|
223
223
|
use_inbound_webhook_on_number: boolean;
|
|
224
|
+
sending_windows: any;
|
|
224
225
|
}
|
|
225
226
|
export declare class ServiceInstance {
|
|
226
227
|
protected _version: V1;
|
|
@@ -316,6 +317,10 @@ export declare class ServiceInstance {
|
|
|
316
317
|
* A boolean value that indicates either the webhook url configured on the phone number will be used or `inbound_request_url`/`fallback_url` url will be called when a message is received from the phone number. If this field is enabled then the webhook url defined on the phone number will override the `inbound_request_url`/`fallback_url` defined for the Messaging Service.
|
|
317
318
|
*/
|
|
318
319
|
useInboundWebhookOnNumber: boolean;
|
|
320
|
+
/**
|
|
321
|
+
* A list of Sending Windows, which indicate defined time ranges in which a message can be sent, in the UTC time zone. Each window is defined by two strings, labeled \"start_time\" and \"end_time\".
|
|
322
|
+
*/
|
|
323
|
+
sendingWindows: any;
|
|
319
324
|
private get _proxy();
|
|
320
325
|
/**
|
|
321
326
|
* Remove a ServiceInstance
|
|
@@ -403,6 +408,7 @@ export declare class ServiceInstance {
|
|
|
403
408
|
usecase: string;
|
|
404
409
|
usAppToPersonRegistered: boolean;
|
|
405
410
|
useInboundWebhookOnNumber: boolean;
|
|
411
|
+
sendingWindows: any;
|
|
406
412
|
};
|
|
407
413
|
[inspect.custom](_depth: any, options: InspectOptions): string;
|
|
408
414
|
}
|
|
@@ -185,6 +185,7 @@ class ServiceInstance {
|
|
|
185
185
|
this.usecase = payload.usecase;
|
|
186
186
|
this.usAppToPersonRegistered = payload.us_app_to_person_registered;
|
|
187
187
|
this.useInboundWebhookOnNumber = payload.use_inbound_webhook_on_number;
|
|
188
|
+
this.sendingWindows = payload.sending_windows;
|
|
188
189
|
this._solution = { sid: sid || this.sid };
|
|
189
190
|
}
|
|
190
191
|
get _proxy() {
|
|
@@ -282,6 +283,7 @@ class ServiceInstance {
|
|
|
282
283
|
usecase: this.usecase,
|
|
283
284
|
usAppToPersonRegistered: this.usAppToPersonRegistered,
|
|
284
285
|
useInboundWebhookOnNumber: this.useInboundWebhookOnNumber,
|
|
286
|
+
sendingWindows: this.sendingWindows,
|
|
285
287
|
};
|
|
286
288
|
}
|
|
287
289
|
[util_1.inspect.custom](_depth, options) {
|
|
@@ -41,6 +41,7 @@ interface PortingPortInFetchResource {
|
|
|
41
41
|
target_port_in_date: Date;
|
|
42
42
|
target_port_in_time_range_start: string;
|
|
43
43
|
target_port_in_time_range_end: string;
|
|
44
|
+
port_in_request_status: string;
|
|
44
45
|
losing_carrier_information: any;
|
|
45
46
|
phone_numbers: Array<any>;
|
|
46
47
|
documents: Array<string>;
|
|
@@ -78,6 +79,10 @@ export declare class PortingPortInFetchInstance {
|
|
|
78
79
|
* Maximum hour in the future needs to be established with the Ops team for validation.
|
|
79
80
|
*/
|
|
80
81
|
targetPortInTimeRangeEnd: string;
|
|
82
|
+
/**
|
|
83
|
+
* The status of the port in request. The possible values are: In progress, Completed, Expired, In review, Waiting for Signature, Action Required, and Canceled.
|
|
84
|
+
*/
|
|
85
|
+
portInRequestStatus: string;
|
|
81
86
|
/**
|
|
82
87
|
* The information for the losing carrier.
|
|
83
88
|
*/
|
|
@@ -112,6 +117,7 @@ export declare class PortingPortInFetchInstance {
|
|
|
112
117
|
targetPortInDate: Date;
|
|
113
118
|
targetPortInTimeRangeStart: string;
|
|
114
119
|
targetPortInTimeRangeEnd: string;
|
|
120
|
+
portInRequestStatus: string;
|
|
115
121
|
losingCarrierInformation: any;
|
|
116
122
|
phoneNumbers: any[];
|
|
117
123
|
documents: string[];
|
|
@@ -60,6 +60,7 @@ class PortingPortInFetchInstance {
|
|
|
60
60
|
this.targetPortInDate = deserialize.iso8601Date(payload.target_port_in_date);
|
|
61
61
|
this.targetPortInTimeRangeStart = payload.target_port_in_time_range_start;
|
|
62
62
|
this.targetPortInTimeRangeEnd = payload.target_port_in_time_range_end;
|
|
63
|
+
this.portInRequestStatus = payload.port_in_request_status;
|
|
63
64
|
this.losingCarrierInformation = payload.losing_carrier_information;
|
|
64
65
|
this.phoneNumbers = payload.phone_numbers;
|
|
65
66
|
this.documents = payload.documents;
|
|
@@ -97,6 +98,7 @@ class PortingPortInFetchInstance {
|
|
|
97
98
|
targetPortInDate: this.targetPortInDate,
|
|
98
99
|
targetPortInTimeRangeStart: this.targetPortInTimeRangeStart,
|
|
99
100
|
targetPortInTimeRangeEnd: this.targetPortInTimeRangeEnd,
|
|
101
|
+
portInRequestStatus: this.portInRequestStatus,
|
|
100
102
|
losingCarrierInformation: this.losingCarrierInformation,
|
|
101
103
|
phoneNumbers: this.phoneNumbers,
|
|
102
104
|
documents: this.documents,
|
|
@@ -10,13 +10,17 @@ export interface TokenListInstanceCreateOptions {
|
|
|
10
10
|
/** A 34 character string that uniquely identifies this OAuth App. */
|
|
11
11
|
clientId: string;
|
|
12
12
|
/** The credential for confidential OAuth App. */
|
|
13
|
-
clientSecret
|
|
13
|
+
clientSecret?: string;
|
|
14
14
|
/** JWT token related to the authorization code grant type. */
|
|
15
15
|
code?: string;
|
|
16
16
|
/** The redirect uri */
|
|
17
17
|
redirectUri?: string;
|
|
18
18
|
/** The targeted audience uri */
|
|
19
19
|
audience?: string;
|
|
20
|
+
/** JWT token related to refresh access token. */
|
|
21
|
+
refreshToken?: string;
|
|
22
|
+
/** The scope of token */
|
|
23
|
+
scope?: string;
|
|
20
24
|
}
|
|
21
25
|
export interface TokenSolution {
|
|
22
26
|
}
|
|
@@ -45,7 +49,7 @@ interface TokenResource {
|
|
|
45
49
|
refresh_token: string;
|
|
46
50
|
id_token: string;
|
|
47
51
|
token_type: string;
|
|
48
|
-
expires_in:
|
|
52
|
+
expires_in: number;
|
|
49
53
|
}
|
|
50
54
|
export declare class TokenInstance {
|
|
51
55
|
protected _version: V1;
|
|
@@ -66,7 +70,7 @@ export declare class TokenInstance {
|
|
|
66
70
|
* Token type
|
|
67
71
|
*/
|
|
68
72
|
tokenType: string;
|
|
69
|
-
expiresIn:
|
|
73
|
+
expiresIn: number;
|
|
70
74
|
/**
|
|
71
75
|
* Provide a user-friendly representation
|
|
72
76
|
*
|
|
@@ -77,7 +81,7 @@ export declare class TokenInstance {
|
|
|
77
81
|
refreshToken: string;
|
|
78
82
|
idToken: string;
|
|
79
83
|
tokenType: string;
|
|
80
|
-
expiresIn:
|
|
84
|
+
expiresIn: number;
|
|
81
85
|
};
|
|
82
86
|
[inspect.custom](_depth: any, options: InspectOptions): string;
|
|
83
87
|
}
|
|
@@ -32,20 +32,21 @@ function TokenListInstance(version) {
|
|
|
32
32
|
if (params["clientId"] === null || params["clientId"] === undefined) {
|
|
33
33
|
throw new Error("Required parameter \"params['clientId']\" missing.");
|
|
34
34
|
}
|
|
35
|
-
if (params["clientSecret"] === null ||
|
|
36
|
-
params["clientSecret"] === undefined) {
|
|
37
|
-
throw new Error("Required parameter \"params['clientSecret']\" missing.");
|
|
38
|
-
}
|
|
39
35
|
let data = {};
|
|
40
36
|
data["GrantType"] = params["grantType"];
|
|
41
37
|
data["ClientId"] = params["clientId"];
|
|
42
|
-
|
|
38
|
+
if (params["clientSecret"] !== undefined)
|
|
39
|
+
data["ClientSecret"] = params["clientSecret"];
|
|
43
40
|
if (params["code"] !== undefined)
|
|
44
41
|
data["Code"] = params["code"];
|
|
45
42
|
if (params["redirectUri"] !== undefined)
|
|
46
43
|
data["RedirectUri"] = params["redirectUri"];
|
|
47
44
|
if (params["audience"] !== undefined)
|
|
48
45
|
data["Audience"] = params["audience"];
|
|
46
|
+
if (params["refreshToken"] !== undefined)
|
|
47
|
+
data["RefreshToken"] = params["refreshToken"];
|
|
48
|
+
if (params["scope"] !== undefined)
|
|
49
|
+
data["Scope"] = params["scope"];
|
|
49
50
|
const headers = {};
|
|
50
51
|
headers["Content-Type"] = "application/x-www-form-urlencoded";
|
|
51
52
|
let operationVersion = version, operationPromise = operationVersion.create({
|
|
@@ -74,7 +75,7 @@ class TokenInstance {
|
|
|
74
75
|
this.refreshToken = payload.refresh_token;
|
|
75
76
|
this.idToken = payload.id_token;
|
|
76
77
|
this.tokenType = payload.token_type;
|
|
77
|
-
this.expiresIn =
|
|
78
|
+
this.expiresIn = payload.expires_in;
|
|
78
79
|
}
|
|
79
80
|
/**
|
|
80
81
|
* Provide a user-friendly representation
|
|
@@ -5,6 +5,15 @@ export type ComplianceRegistrationInquiriesBusinessIdentityType = "direct_custom
|
|
|
5
5
|
export type ComplianceRegistrationInquiriesBusinessRegistrationAuthority = "UK:CRN" | "US:EIN" | "CA:CBN" | "AU:ACN" | "Other";
|
|
6
6
|
export type ComplianceRegistrationInquiriesEndUserType = "Individual" | "Business";
|
|
7
7
|
export type ComplianceRegistrationInquiriesPhoneNumberType = "local" | "national" | "mobile" | "toll-free";
|
|
8
|
+
/**
|
|
9
|
+
* Options to pass to update a ComplianceRegistrationInquiriesInstance
|
|
10
|
+
*/
|
|
11
|
+
export interface ComplianceRegistrationInquiriesContextUpdateOptions {
|
|
12
|
+
/** Indicates if the inquiry is being started from an ISV embedded component. */
|
|
13
|
+
isIsvEmbed?: boolean;
|
|
14
|
+
/** Theme id for styling the inquiry form. */
|
|
15
|
+
themeSetId?: string;
|
|
16
|
+
}
|
|
8
17
|
/**
|
|
9
18
|
* Options to pass to create a ComplianceRegistrationInquiriesInstance
|
|
10
19
|
*/
|
|
@@ -85,29 +94,50 @@ export interface ComplianceRegistrationInquiriesListInstanceCreateOptions {
|
|
|
85
94
|
isvRegisteringForSelfOrTenant?: string;
|
|
86
95
|
/** The url we call to inform you of bundle changes. */
|
|
87
96
|
statusCallbackUrl?: string;
|
|
97
|
+
/** Theme id for styling the inquiry form. */
|
|
98
|
+
themeSetId?: string;
|
|
88
99
|
}
|
|
89
|
-
export interface
|
|
90
|
-
}
|
|
91
|
-
export interface ComplianceRegistrationInquiriesListInstance {
|
|
92
|
-
_version: V1;
|
|
93
|
-
_solution: ComplianceRegistrationInquiriesSolution;
|
|
94
|
-
_uri: string;
|
|
100
|
+
export interface ComplianceRegistrationInquiriesContext {
|
|
95
101
|
/**
|
|
96
|
-
*
|
|
102
|
+
* Update a ComplianceRegistrationInquiriesInstance
|
|
103
|
+
*
|
|
104
|
+
* @param callback - Callback to handle processed record
|
|
105
|
+
*
|
|
106
|
+
* @returns Resolves to processed ComplianceRegistrationInquiriesInstance
|
|
107
|
+
*/
|
|
108
|
+
update(callback?: (error: Error | null, item?: ComplianceRegistrationInquiriesInstance) => any): Promise<ComplianceRegistrationInquiriesInstance>;
|
|
109
|
+
/**
|
|
110
|
+
* Update a ComplianceRegistrationInquiriesInstance
|
|
97
111
|
*
|
|
98
112
|
* @param params - Parameter for request
|
|
99
113
|
* @param callback - Callback to handle processed record
|
|
100
114
|
*
|
|
101
115
|
* @returns Resolves to processed ComplianceRegistrationInquiriesInstance
|
|
102
116
|
*/
|
|
103
|
-
|
|
117
|
+
update(params: ComplianceRegistrationInquiriesContextUpdateOptions, callback?: (error: Error | null, item?: ComplianceRegistrationInquiriesInstance) => any): Promise<ComplianceRegistrationInquiriesInstance>;
|
|
104
118
|
/**
|
|
105
119
|
* Provide a user-friendly representation
|
|
106
120
|
*/
|
|
107
121
|
toJSON(): any;
|
|
108
122
|
[inspect.custom](_depth: any, options: InspectOptions): any;
|
|
109
123
|
}
|
|
110
|
-
export
|
|
124
|
+
export interface ComplianceRegistrationInquiriesContextSolution {
|
|
125
|
+
registrationId: string;
|
|
126
|
+
}
|
|
127
|
+
export declare class ComplianceRegistrationInquiriesContextImpl implements ComplianceRegistrationInquiriesContext {
|
|
128
|
+
protected _version: V1;
|
|
129
|
+
protected _solution: ComplianceRegistrationInquiriesContextSolution;
|
|
130
|
+
protected _uri: string;
|
|
131
|
+
constructor(_version: V1, registrationId: string);
|
|
132
|
+
update(params?: ComplianceRegistrationInquiriesContextUpdateOptions | ((error: Error | null, item?: ComplianceRegistrationInquiriesInstance) => any), callback?: (error: Error | null, item?: ComplianceRegistrationInquiriesInstance) => any): Promise<ComplianceRegistrationInquiriesInstance>;
|
|
133
|
+
/**
|
|
134
|
+
* Provide a user-friendly representation
|
|
135
|
+
*
|
|
136
|
+
* @returns Object
|
|
137
|
+
*/
|
|
138
|
+
toJSON(): ComplianceRegistrationInquiriesContextSolution;
|
|
139
|
+
[inspect.custom](_depth: any, options: InspectOptions): string;
|
|
140
|
+
}
|
|
111
141
|
interface ComplianceRegistrationInquiriesResource {
|
|
112
142
|
inquiry_id: string;
|
|
113
143
|
inquiry_session_token: string;
|
|
@@ -116,7 +146,9 @@ interface ComplianceRegistrationInquiriesResource {
|
|
|
116
146
|
}
|
|
117
147
|
export declare class ComplianceRegistrationInquiriesInstance {
|
|
118
148
|
protected _version: V1;
|
|
119
|
-
|
|
149
|
+
protected _solution: ComplianceRegistrationInquiriesContextSolution;
|
|
150
|
+
protected _context?: ComplianceRegistrationInquiriesContext;
|
|
151
|
+
constructor(_version: V1, payload: ComplianceRegistrationInquiriesResource, registrationId?: string);
|
|
120
152
|
/**
|
|
121
153
|
* The unique ID used to start an embedded compliance registration session.
|
|
122
154
|
*/
|
|
@@ -133,6 +165,24 @@ export declare class ComplianceRegistrationInquiriesInstance {
|
|
|
133
165
|
* The URL of this resource.
|
|
134
166
|
*/
|
|
135
167
|
url: string;
|
|
168
|
+
private get _proxy();
|
|
169
|
+
/**
|
|
170
|
+
* Update a ComplianceRegistrationInquiriesInstance
|
|
171
|
+
*
|
|
172
|
+
* @param callback - Callback to handle processed record
|
|
173
|
+
*
|
|
174
|
+
* @returns Resolves to processed ComplianceRegistrationInquiriesInstance
|
|
175
|
+
*/
|
|
176
|
+
update(callback?: (error: Error | null, item?: ComplianceRegistrationInquiriesInstance) => any): Promise<ComplianceRegistrationInquiriesInstance>;
|
|
177
|
+
/**
|
|
178
|
+
* Update a ComplianceRegistrationInquiriesInstance
|
|
179
|
+
*
|
|
180
|
+
* @param params - Parameter for request
|
|
181
|
+
* @param callback - Callback to handle processed record
|
|
182
|
+
*
|
|
183
|
+
* @returns Resolves to processed ComplianceRegistrationInquiriesInstance
|
|
184
|
+
*/
|
|
185
|
+
update(params: ComplianceRegistrationInquiriesContextUpdateOptions, callback?: (error: Error | null, item?: ComplianceRegistrationInquiriesInstance) => any): Promise<ComplianceRegistrationInquiriesInstance>;
|
|
136
186
|
/**
|
|
137
187
|
* Provide a user-friendly representation
|
|
138
188
|
*
|
|
@@ -146,4 +196,28 @@ export declare class ComplianceRegistrationInquiriesInstance {
|
|
|
146
196
|
};
|
|
147
197
|
[inspect.custom](_depth: any, options: InspectOptions): string;
|
|
148
198
|
}
|
|
199
|
+
export interface ComplianceRegistrationInquiriesSolution {
|
|
200
|
+
}
|
|
201
|
+
export interface ComplianceRegistrationInquiriesListInstance {
|
|
202
|
+
_version: V1;
|
|
203
|
+
_solution: ComplianceRegistrationInquiriesSolution;
|
|
204
|
+
_uri: string;
|
|
205
|
+
(registrationId: string): ComplianceRegistrationInquiriesContext;
|
|
206
|
+
get(registrationId: string): ComplianceRegistrationInquiriesContext;
|
|
207
|
+
/**
|
|
208
|
+
* Create a ComplianceRegistrationInquiriesInstance
|
|
209
|
+
*
|
|
210
|
+
* @param params - Parameter for request
|
|
211
|
+
* @param callback - Callback to handle processed record
|
|
212
|
+
*
|
|
213
|
+
* @returns Resolves to processed ComplianceRegistrationInquiriesInstance
|
|
214
|
+
*/
|
|
215
|
+
create(params: ComplianceRegistrationInquiriesListInstanceCreateOptions, callback?: (error: Error | null, item?: ComplianceRegistrationInquiriesInstance) => any): Promise<ComplianceRegistrationInquiriesInstance>;
|
|
216
|
+
/**
|
|
217
|
+
* Provide a user-friendly representation
|
|
218
|
+
*/
|
|
219
|
+
toJSON(): any;
|
|
220
|
+
[inspect.custom](_depth: any, options: InspectOptions): any;
|
|
221
|
+
}
|
|
222
|
+
export declare function ComplianceRegistrationInquiriesListInstance(version: V1): ComplianceRegistrationInquiriesListInstance;
|
|
149
223
|
export {};
|
|
@@ -13,12 +13,100 @@
|
|
|
13
13
|
* Do not edit the class manually.
|
|
14
14
|
*/
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.ComplianceRegistrationInquiriesInstance = exports.
|
|
16
|
+
exports.ComplianceRegistrationInquiriesListInstance = exports.ComplianceRegistrationInquiriesInstance = exports.ComplianceRegistrationInquiriesContextImpl = void 0;
|
|
17
17
|
const util_1 = require("util");
|
|
18
18
|
const deserialize = require("../../../base/deserialize");
|
|
19
19
|
const serialize = require("../../../base/serialize");
|
|
20
|
+
const utility_1 = require("../../../base/utility");
|
|
21
|
+
class ComplianceRegistrationInquiriesContextImpl {
|
|
22
|
+
constructor(_version, registrationId) {
|
|
23
|
+
this._version = _version;
|
|
24
|
+
if (!(0, utility_1.isValidPathParam)(registrationId)) {
|
|
25
|
+
throw new Error("Parameter 'registrationId' is not valid.");
|
|
26
|
+
}
|
|
27
|
+
this._solution = { registrationId };
|
|
28
|
+
this._uri = `/ComplianceInquiries/Registration/${registrationId}/RegulatoryCompliance/GB/Initialize`;
|
|
29
|
+
}
|
|
30
|
+
update(params, callback) {
|
|
31
|
+
if (params instanceof Function) {
|
|
32
|
+
callback = params;
|
|
33
|
+
params = {};
|
|
34
|
+
}
|
|
35
|
+
else {
|
|
36
|
+
params = params || {};
|
|
37
|
+
}
|
|
38
|
+
let data = {};
|
|
39
|
+
if (params["isIsvEmbed"] !== undefined)
|
|
40
|
+
data["IsIsvEmbed"] = serialize.bool(params["isIsvEmbed"]);
|
|
41
|
+
if (params["themeSetId"] !== undefined)
|
|
42
|
+
data["ThemeSetId"] = params["themeSetId"];
|
|
43
|
+
const headers = {};
|
|
44
|
+
headers["Content-Type"] = "application/x-www-form-urlencoded";
|
|
45
|
+
const instance = this;
|
|
46
|
+
let operationVersion = instance._version, operationPromise = operationVersion.update({
|
|
47
|
+
uri: instance._uri,
|
|
48
|
+
method: "post",
|
|
49
|
+
data,
|
|
50
|
+
headers,
|
|
51
|
+
});
|
|
52
|
+
operationPromise = operationPromise.then((payload) => new ComplianceRegistrationInquiriesInstance(operationVersion, payload, instance._solution.registrationId));
|
|
53
|
+
operationPromise = instance._version.setPromiseCallback(operationPromise, callback);
|
|
54
|
+
return operationPromise;
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* Provide a user-friendly representation
|
|
58
|
+
*
|
|
59
|
+
* @returns Object
|
|
60
|
+
*/
|
|
61
|
+
toJSON() {
|
|
62
|
+
return this._solution;
|
|
63
|
+
}
|
|
64
|
+
[util_1.inspect.custom](_depth, options) {
|
|
65
|
+
return (0, util_1.inspect)(this.toJSON(), options);
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
exports.ComplianceRegistrationInquiriesContextImpl = ComplianceRegistrationInquiriesContextImpl;
|
|
69
|
+
class ComplianceRegistrationInquiriesInstance {
|
|
70
|
+
constructor(_version, payload, registrationId) {
|
|
71
|
+
this._version = _version;
|
|
72
|
+
this.inquiryId = payload.inquiry_id;
|
|
73
|
+
this.inquirySessionToken = payload.inquiry_session_token;
|
|
74
|
+
this.registrationId = payload.registration_id;
|
|
75
|
+
this.url = payload.url;
|
|
76
|
+
this._solution = { registrationId: registrationId || this.registrationId };
|
|
77
|
+
}
|
|
78
|
+
get _proxy() {
|
|
79
|
+
this._context =
|
|
80
|
+
this._context ||
|
|
81
|
+
new ComplianceRegistrationInquiriesContextImpl(this._version, this._solution.registrationId);
|
|
82
|
+
return this._context;
|
|
83
|
+
}
|
|
84
|
+
update(params, callback) {
|
|
85
|
+
return this._proxy.update(params, callback);
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Provide a user-friendly representation
|
|
89
|
+
*
|
|
90
|
+
* @returns Object
|
|
91
|
+
*/
|
|
92
|
+
toJSON() {
|
|
93
|
+
return {
|
|
94
|
+
inquiryId: this.inquiryId,
|
|
95
|
+
inquirySessionToken: this.inquirySessionToken,
|
|
96
|
+
registrationId: this.registrationId,
|
|
97
|
+
url: this.url,
|
|
98
|
+
};
|
|
99
|
+
}
|
|
100
|
+
[util_1.inspect.custom](_depth, options) {
|
|
101
|
+
return (0, util_1.inspect)(this.toJSON(), options);
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
exports.ComplianceRegistrationInquiriesInstance = ComplianceRegistrationInquiriesInstance;
|
|
20
105
|
function ComplianceRegistrationInquiriesListInstance(version) {
|
|
21
|
-
const instance =
|
|
106
|
+
const instance = ((registrationId) => instance.get(registrationId));
|
|
107
|
+
instance.get = function get(registrationId) {
|
|
108
|
+
return new ComplianceRegistrationInquiriesContextImpl(version, registrationId);
|
|
109
|
+
};
|
|
22
110
|
instance._version = version;
|
|
23
111
|
instance._solution = {};
|
|
24
112
|
instance._uri = `/ComplianceInquiries/Registration/RegulatoryCompliance/GB/Initialize`;
|
|
@@ -118,6 +206,8 @@ function ComplianceRegistrationInquiriesListInstance(version) {
|
|
|
118
206
|
params["isvRegisteringForSelfOrTenant"];
|
|
119
207
|
if (params["statusCallbackUrl"] !== undefined)
|
|
120
208
|
data["StatusCallbackUrl"] = params["statusCallbackUrl"];
|
|
209
|
+
if (params["themeSetId"] !== undefined)
|
|
210
|
+
data["ThemeSetId"] = params["themeSetId"];
|
|
121
211
|
const headers = {};
|
|
122
212
|
headers["Content-Type"] = "application/x-www-form-urlencoded";
|
|
123
213
|
let operationVersion = version, operationPromise = operationVersion.create({
|
|
@@ -139,29 +229,3 @@ function ComplianceRegistrationInquiriesListInstance(version) {
|
|
|
139
229
|
return instance;
|
|
140
230
|
}
|
|
141
231
|
exports.ComplianceRegistrationInquiriesListInstance = ComplianceRegistrationInquiriesListInstance;
|
|
142
|
-
class ComplianceRegistrationInquiriesInstance {
|
|
143
|
-
constructor(_version, payload) {
|
|
144
|
-
this._version = _version;
|
|
145
|
-
this.inquiryId = payload.inquiry_id;
|
|
146
|
-
this.inquirySessionToken = payload.inquiry_session_token;
|
|
147
|
-
this.registrationId = payload.registration_id;
|
|
148
|
-
this.url = payload.url;
|
|
149
|
-
}
|
|
150
|
-
/**
|
|
151
|
-
* Provide a user-friendly representation
|
|
152
|
-
*
|
|
153
|
-
* @returns Object
|
|
154
|
-
*/
|
|
155
|
-
toJSON() {
|
|
156
|
-
return {
|
|
157
|
-
inquiryId: this.inquiryId,
|
|
158
|
-
inquirySessionToken: this.inquirySessionToken,
|
|
159
|
-
registrationId: this.registrationId,
|
|
160
|
-
url: this.url,
|
|
161
|
-
};
|
|
162
|
-
}
|
|
163
|
-
[util_1.inspect.custom](_depth, options) {
|
|
164
|
-
return (0, util_1.inspect)(this.toJSON(), options);
|
|
165
|
-
}
|
|
166
|
-
}
|
|
167
|
-
exports.ComplianceRegistrationInquiriesInstance = ComplianceRegistrationInquiriesInstance;
|