@wix/redirects 1.0.52 → 1.0.53
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/build/cjs/index.d.ts +2 -1
- package/build/cjs/index.js +2 -1
- package/build/cjs/index.js.map +1 -1
- package/build/es/index.d.ts +2 -1
- package/build/es/index.js +2 -1
- package/build/es/index.js.map +1 -1
- package/package.json +6 -5
- package/type-bundles/context.bundle.d.ts +778 -4
- package/type-bundles/index.bundle.d.ts +80 -52
- package/type-bundles/meta.bundle.d.ts +20 -16
package/build/cjs/index.d.ts
CHANGED
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
import * as redirects from '@wix/redirects_redirects';
|
|
2
|
+
export { redirects };
|
package/build/cjs/index.js
CHANGED
|
@@ -24,5 +24,6 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
26
|
exports.redirects = void 0;
|
|
27
|
-
|
|
27
|
+
const redirects = __importStar(require("@wix/redirects_redirects"));
|
|
28
|
+
exports.redirects = redirects;
|
|
28
29
|
//# sourceMappingURL=index.js.map
|
package/build/cjs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,oEAAsD;AAE7C,8BAAS"}
|
package/build/es/index.d.ts
CHANGED
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
import * as redirects from '@wix/redirects_redirects';
|
|
2
|
+
export { redirects };
|
package/build/es/index.js
CHANGED
package/build/es/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,SAAS,MAAM,0BAA0B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,SAAS,MAAM,0BAA0B,CAAC;AAEtD,OAAO,EAAE,SAAS,EAAE,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/redirects",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.53",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"registry": "https://registry.npmjs.org/",
|
|
6
6
|
"access": "public"
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"type-bundles"
|
|
19
19
|
],
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@wix/redirects_redirects": "1.0.
|
|
21
|
+
"@wix/redirects_redirects": "1.0.23"
|
|
22
22
|
},
|
|
23
23
|
"devDependencies": {
|
|
24
24
|
"glob": "^10.4.1",
|
|
@@ -27,8 +27,9 @@
|
|
|
27
27
|
"typescript": "^5.3.2"
|
|
28
28
|
},
|
|
29
29
|
"scripts": {
|
|
30
|
-
"build": "tsc -b tsconfig.json tsconfig.esm.json && npm run build:dts-bundles",
|
|
31
|
-
"build:dts-bundles": "test -f config/rollup-config.js && rollup --config config/rollup-config.js || echo 'Warning: config/rollup-config.js not found!'",
|
|
30
|
+
"build": "tsc -b tsconfig.json tsconfig.esm.json && npm run build:dts-bundles && npm run build:validate-dts",
|
|
31
|
+
"build:dts-bundles": "test -f config/rollup-config.js && NODE_OPTIONS=--max-old-space-size=8192 rollup --config config/rollup-config.js || echo 'Warning: config/rollup-config.js not found!'",
|
|
32
|
+
"build:validate-dts": "tsc type-bundles/*.d.ts --noEmit",
|
|
32
33
|
"test": ":"
|
|
33
34
|
},
|
|
34
35
|
"wix": {
|
|
@@ -42,5 +43,5 @@
|
|
|
42
43
|
"fqdn": ""
|
|
43
44
|
}
|
|
44
45
|
},
|
|
45
|
-
"falconPackageHash": "
|
|
46
|
+
"falconPackageHash": "fd81c4a453c534d1ad93b299f38d29fe5f837f4f8936464a029fa7e2"
|
|
46
47
|
}
|
|
@@ -42,17 +42,791 @@ declare global {
|
|
|
42
42
|
}
|
|
43
43
|
}
|
|
44
44
|
|
|
45
|
-
|
|
45
|
+
/** Information for redirecting a visitor from an external Wix Headless client site to a Wix page for Wix-managed functionality. */
|
|
46
|
+
interface RedirectSession {
|
|
47
|
+
/** ID of the redirect session created. */
|
|
48
|
+
_id?: string;
|
|
49
|
+
/**
|
|
50
|
+
* The full URL of the Wix page to redirect the visitor to. This URL includes query parameters informing Wix where to redirect the visitor back to on the Wix Headless client site.
|
|
51
|
+
* @readonly
|
|
52
|
+
*/
|
|
53
|
+
fullUrl?: string;
|
|
54
|
+
/** Details about the URL of the RedirectSession */
|
|
55
|
+
urlDetails?: URLDetails;
|
|
56
|
+
/**
|
|
57
|
+
* The session token to pass to the Wix page to maintain the visitor's identity.
|
|
58
|
+
* @readonly
|
|
59
|
+
*/
|
|
60
|
+
sessionToken?: string | null;
|
|
61
|
+
/**
|
|
62
|
+
* The short URL of the Wix page to redirect the visitor to. This URL includes query parameters informing Wix where to redirect the visitor back to on the Wix Headless client site.
|
|
63
|
+
* @readonly
|
|
64
|
+
*/
|
|
65
|
+
shortUrl?: string;
|
|
66
|
+
}
|
|
67
|
+
interface URLDetails {
|
|
68
|
+
/**
|
|
69
|
+
* The endpoint of the url (includes the base url and the path to the endpoint, without the query parameters)
|
|
70
|
+
* For example: `https://mysite.com/_api/oauth2/authorize`
|
|
71
|
+
* @readonly
|
|
72
|
+
*/
|
|
73
|
+
endpoint?: string;
|
|
74
|
+
/** The query parameters of the url */
|
|
75
|
+
searchParams?: Record<string, string>;
|
|
76
|
+
}
|
|
77
|
+
interface CreateRedirectSessionRequest extends CreateRedirectSessionRequestIntentOneOf {
|
|
78
|
+
/** Information required for generating a custom URL for a Wix Bookings checkout. */
|
|
79
|
+
bookingsCheckout?: RedirectSessionBookingsCheckoutParams;
|
|
80
|
+
/** Information required for generating a custom URL for a Wix eCommerce checkout. */
|
|
81
|
+
ecomCheckout?: RedirectSessionEcomCheckoutParams;
|
|
82
|
+
/** Information required for generating a custom URL for a Wix Events checkout. */
|
|
83
|
+
eventsCheckout?: RedirectSessionEventsCheckoutParams;
|
|
84
|
+
/** Information required for generating a custom URL for a Wix Paid Plans checkout. */
|
|
85
|
+
paidPlansCheckout?: RedirectSessionPaidPlansCheckoutParams;
|
|
86
|
+
/** Pass an empty object in this parameter to generate a URL for Wix login without first checking whether the visitor is authenticated. */
|
|
87
|
+
login?: RedirectSessionLoginParams;
|
|
88
|
+
/** Information required for generating a custom URL to log out from a Wix account. This process invalidates the visitor or member token and clears cookies associated with the Wix domain from their browser. */
|
|
89
|
+
logout?: RedirectSessionLogoutParams;
|
|
90
|
+
/** Information required for generating a custom URL for Wix authentication. */
|
|
91
|
+
auth?: RedirectSessionAuthParams;
|
|
92
|
+
/** Information required for generating a custom URL for a Wix stores product page. */
|
|
93
|
+
storesProduct?: RedirectSessionStoresProductParams;
|
|
94
|
+
/** Information required for generating a custom URL for Wix bookings book page. */
|
|
95
|
+
bookingsBook?: RedirectSessionBookingsBookParams;
|
|
96
|
+
/**
|
|
97
|
+
* Details of pages to redirect the visitor back to on the Wix Headless client site.
|
|
98
|
+
*
|
|
99
|
+
* **Note**: For an authentication redirect, don't pass a post-flow URL here. Instead, pass one in `options.auth.authRequest.redirectUri`.
|
|
100
|
+
*/
|
|
101
|
+
callbacks?: CallbackParams;
|
|
102
|
+
/** Optional preferences for customizing redirection to Wix pages. */
|
|
103
|
+
preferences?: RedirectSessionPreferences;
|
|
104
|
+
}
|
|
105
|
+
/** @oneof */
|
|
106
|
+
interface CreateRedirectSessionRequestIntentOneOf {
|
|
107
|
+
/** Information required for generating a custom URL for a Wix Bookings checkout. */
|
|
108
|
+
bookingsCheckout?: RedirectSessionBookingsCheckoutParams;
|
|
109
|
+
/** Information required for generating a custom URL for a Wix eCommerce checkout. */
|
|
110
|
+
ecomCheckout?: RedirectSessionEcomCheckoutParams;
|
|
111
|
+
/** Information required for generating a custom URL for a Wix Events checkout. */
|
|
112
|
+
eventsCheckout?: RedirectSessionEventsCheckoutParams;
|
|
113
|
+
/** Information required for generating a custom URL for a Wix Paid Plans checkout. */
|
|
114
|
+
paidPlansCheckout?: RedirectSessionPaidPlansCheckoutParams;
|
|
115
|
+
/** Pass an empty object in this parameter to generate a URL for Wix login without first checking whether the visitor is authenticated. */
|
|
116
|
+
login?: RedirectSessionLoginParams;
|
|
117
|
+
/** Information required for generating a custom URL to log out from a Wix account. This process invalidates the visitor or member token and clears cookies associated with the Wix domain from their browser. */
|
|
118
|
+
logout?: RedirectSessionLogoutParams;
|
|
119
|
+
/** Information required for generating a custom URL for Wix authentication. */
|
|
120
|
+
auth?: RedirectSessionAuthParams;
|
|
121
|
+
/** Information required for generating a custom URL for a Wix stores product page. */
|
|
122
|
+
storesProduct?: RedirectSessionStoresProductParams;
|
|
123
|
+
/** Information required for generating a custom URL for Wix bookings book page. */
|
|
124
|
+
bookingsBook?: RedirectSessionBookingsBookParams;
|
|
125
|
+
}
|
|
126
|
+
interface RedirectSessionBookingsCheckoutParams {
|
|
127
|
+
/**
|
|
128
|
+
* The timezone to use when presenting the selected slot to users, in [tz database](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones) format. For example, `America/Santiago`.
|
|
129
|
+
*
|
|
130
|
+
* Default: If you don't specify a timezone, the timezone in `slotAvailability.slot.timezone` is used.
|
|
131
|
+
*/
|
|
132
|
+
timezone?: string;
|
|
133
|
+
/** __Required.__ The calendar slot to check out. */
|
|
134
|
+
slotAvailability?: SlotAvailability;
|
|
135
|
+
}
|
|
136
|
+
interface SlotAvailability {
|
|
137
|
+
/**
|
|
138
|
+
* The slot for the corresponding session, when the session is either a single session
|
|
139
|
+
* or a specific session generated from a recurring session.
|
|
140
|
+
*/
|
|
141
|
+
slot?: Slot;
|
|
142
|
+
/**
|
|
143
|
+
* Whether the slot is bookable. Bookability is determined by checking a
|
|
144
|
+
* session's open slots and booking policies. Locks are not taken into
|
|
145
|
+
* account.
|
|
146
|
+
*/
|
|
147
|
+
bookable?: boolean;
|
|
148
|
+
/**
|
|
149
|
+
* Total number of spots for this slot.
|
|
150
|
+
* For example, if a session has a total of 10 spots and 3 spots are booked,
|
|
151
|
+
* `spotsTotal` is 10 and `openSpots` is 7.
|
|
152
|
+
*/
|
|
153
|
+
totalSpots?: number | null;
|
|
154
|
+
/** Number of open spots for this slot. */
|
|
155
|
+
openSpots?: number | null;
|
|
156
|
+
/** An object describing the slot's waitlist and its occupancy. */
|
|
157
|
+
waitingList?: WaitingList;
|
|
158
|
+
/** Booking policy violations for the slot. */
|
|
159
|
+
bookingPolicyViolations?: BookingPolicyViolations;
|
|
160
|
+
/**
|
|
161
|
+
* Indicates whether the slot is locked because a waitlist exists.
|
|
162
|
+
* When a slot frees up, the slot is offered to the next customer on the waitlist. Read-only.
|
|
163
|
+
*/
|
|
164
|
+
locked?: boolean | null;
|
|
165
|
+
isFromV2?: boolean;
|
|
166
|
+
}
|
|
167
|
+
interface Slot {
|
|
168
|
+
/**
|
|
169
|
+
* ID for the slot's corresponding session, when the session is either a single session
|
|
170
|
+
* or a specific session generated from a recurring session.
|
|
171
|
+
*/
|
|
172
|
+
sessionId?: string | null;
|
|
173
|
+
/** Service ID. */
|
|
174
|
+
serviceId?: string;
|
|
175
|
+
/** Schedule ID. */
|
|
176
|
+
scheduleId?: string;
|
|
177
|
+
/**
|
|
178
|
+
* The start time of this slot in [RFC 3339](https://www.rfc-editor.org/rfc/rfc3339)
|
|
179
|
+
* format.
|
|
180
|
+
*
|
|
181
|
+
* If `timezone` is specified,
|
|
182
|
+
* dates are based on the local date/time. This means that the timezone offset
|
|
183
|
+
* in the `startDate` is ignored.
|
|
184
|
+
*/
|
|
185
|
+
startDate?: string | null;
|
|
186
|
+
/**
|
|
187
|
+
* The end time of this slot in
|
|
188
|
+
* [RFC 3339](https://www.rfc-editor.org/rfc/rfc3339) format.
|
|
189
|
+
*
|
|
190
|
+
* If `timezone` is specified,
|
|
191
|
+
* dates are based on the local date/time. This means that the timezone offset
|
|
192
|
+
* in the `endDate` is ignored.
|
|
193
|
+
*/
|
|
194
|
+
endDate?: string | null;
|
|
195
|
+
/**
|
|
196
|
+
* The timezone for which slot availability is to be calculated.
|
|
197
|
+
*
|
|
198
|
+
* Learn more about [handling Daylight Savings Time (DST) for local time zones](https://dev.wix.com/api/sdk/bookings/availabilitycalendar/queryavailability#bookings_availabilitycalendar_queryavailability_handling-daylight-savings-time-dst-for-local-time-zones)
|
|
199
|
+
* when calculating availability.
|
|
200
|
+
*/
|
|
201
|
+
timezone?: string | null;
|
|
202
|
+
/**
|
|
203
|
+
* The resource required for this slot. Currently, the only supported resource
|
|
204
|
+
* is the relevant staff member for the slot.
|
|
205
|
+
*/
|
|
206
|
+
resource?: SlotResource;
|
|
207
|
+
/** Geographic location of the slot. */
|
|
208
|
+
location?: Location;
|
|
209
|
+
}
|
|
210
|
+
interface SlotResource {
|
|
211
|
+
/**
|
|
212
|
+
* Resource ID.
|
|
213
|
+
* @readonly
|
|
214
|
+
*/
|
|
215
|
+
_id?: string | null;
|
|
216
|
+
/** Resource name. Read only. */
|
|
217
|
+
name?: string | null;
|
|
218
|
+
}
|
|
219
|
+
interface Location {
|
|
220
|
+
/**
|
|
221
|
+
* Business location ID. Available only for locations that are business locations,
|
|
222
|
+
* meaning the `location_type` is `"OWNER_BUSINESS"`.
|
|
223
|
+
*/
|
|
224
|
+
_id?: string | null;
|
|
225
|
+
/** Location name. */
|
|
226
|
+
name?: string | null;
|
|
227
|
+
/** The full address of this location. */
|
|
228
|
+
formattedAddress?: string | null;
|
|
229
|
+
/**
|
|
230
|
+
* Location type.
|
|
231
|
+
*
|
|
232
|
+
* - `"OWNER_BUSINESS"`: The business address, as set in the site’s general settings.
|
|
233
|
+
* - `"OWNER_CUSTOM"`: The address as set when creating the service.
|
|
234
|
+
* - `"CUSTOM"`: The address as set for the individual session.
|
|
235
|
+
*/
|
|
236
|
+
locationType?: LocationType;
|
|
237
|
+
}
|
|
238
|
+
declare enum LocationType {
|
|
239
|
+
UNDEFINED = "UNDEFINED",
|
|
240
|
+
OWNER_BUSINESS = "OWNER_BUSINESS",
|
|
241
|
+
OWNER_CUSTOM = "OWNER_CUSTOM",
|
|
242
|
+
CUSTOM = "CUSTOM"
|
|
243
|
+
}
|
|
244
|
+
interface WaitingList {
|
|
245
|
+
/**
|
|
246
|
+
* Total number of spots and open spots for this waitlist.
|
|
247
|
+
* For example, a Yoga class with 10 waitlist spots and 3 registered
|
|
248
|
+
* on the waitlist has 10 `total_spots` and 7 `open_spots`.
|
|
249
|
+
*/
|
|
250
|
+
totalSpots?: number | null;
|
|
251
|
+
/** Number of open spots for this waitlist. */
|
|
252
|
+
openSpots?: number | null;
|
|
253
|
+
}
|
|
254
|
+
interface BookingPolicyViolations {
|
|
255
|
+
/** Bookings policy violation. Too early to book this slot. */
|
|
256
|
+
tooEarlyToBook?: boolean | null;
|
|
257
|
+
/** Bookings policy violation. Too late to book this slot. */
|
|
258
|
+
tooLateToBook?: boolean | null;
|
|
259
|
+
/** Bookings policy violation. Online booking is disabled for this slot. */
|
|
260
|
+
bookOnlineDisabled?: boolean | null;
|
|
261
|
+
}
|
|
262
|
+
interface NestedTimeSlot {
|
|
263
|
+
serviceId?: string;
|
|
264
|
+
start?: string;
|
|
265
|
+
end?: string;
|
|
266
|
+
resource?: SlotResource;
|
|
267
|
+
/** Schedule ID. */
|
|
268
|
+
scheduleId?: string;
|
|
269
|
+
}
|
|
270
|
+
interface RedirectSessionEcomCheckoutParams {
|
|
271
|
+
/** __Required.__ ID of the checkout to process. Use [`createCheckout()`](https://dev.wix.com/api/sdk/ecom/checkout/createcheckout) or [`createCheckoutFromCurrentCart()`](https://dev.wix.com/api/sdk/ecom/currentcart/createcheckoutfromcurrentcart) to create a checkout and obtain an ID. */
|
|
272
|
+
checkoutId?: string;
|
|
273
|
+
}
|
|
274
|
+
interface RedirectSessionEventsCheckoutParams {
|
|
275
|
+
/** __Required.__ ID of the temporary event reservation. Use [`createReservation()`](https://dev.wix.com/api/sdk/events/checkout/createreservation) to reserve a ticket temporarily and obtain a reservation ID. */
|
|
276
|
+
reservationId?: string;
|
|
277
|
+
/** __Required.__ URL-friendly event slug, generated from the event title of the event. For example, `my-event-4`. Use [`listEvents()`](https://dev.wix.com/api/sdk/events/wixevents/listevents) to obtain an event slug. */
|
|
278
|
+
eventSlug?: string;
|
|
279
|
+
}
|
|
280
|
+
interface RedirectSessionPaidPlansCheckoutParams {
|
|
281
|
+
/** __Required.__ ID of the paid plan selected. Use [`queryPublicPlans()`](https://dev.wix.com/api/sdk/pricing-plans/plans/querypublicplans) to obtain a paid plan ID. */
|
|
282
|
+
planId?: string;
|
|
283
|
+
/**
|
|
284
|
+
* For use when pricing plan selection is part of a checkout flow, only if the paid plan selection page is implemented on an external Wix Headless client site.
|
|
285
|
+
* In this case, a string is received by the external pricing plans page as a `checkoutData` query parameter. Pass this string back here when redirecting back to Wix for checkout.
|
|
286
|
+
*/
|
|
287
|
+
checkoutData?: string | null;
|
|
288
|
+
}
|
|
289
|
+
interface RedirectSessionLoginParams {
|
|
290
|
+
}
|
|
291
|
+
interface RedirectSessionLogoutParams {
|
|
292
|
+
/** __Required.__ ID of the OAuth app authorizing the client. */
|
|
293
|
+
clientId?: string;
|
|
294
|
+
}
|
|
295
|
+
interface RedirectSessionAuthParams {
|
|
296
|
+
/** __Required.__ The authorization request to send to the authorization server. */
|
|
297
|
+
authRequest?: AuthorizeRequest;
|
|
298
|
+
prompt?: Prompt;
|
|
299
|
+
}
|
|
300
|
+
/**
|
|
301
|
+
* AuthorizeRequest is sent by the client to the authorization server to initiate
|
|
302
|
+
* the authorization process.
|
|
303
|
+
*/
|
|
304
|
+
interface AuthorizeRequest {
|
|
305
|
+
/** ID of the Wix OAuth app requesting authorization. */
|
|
306
|
+
clientId?: string;
|
|
307
|
+
/**
|
|
308
|
+
* Desired authorization [grant type](https://auth0.com/docs/authenticate/protocols/oauth#grant-types).
|
|
309
|
+
*
|
|
310
|
+
* Supported values:
|
|
311
|
+
* + `code`: The endpoint returns an authorization code that can be used to obtain an access token.
|
|
312
|
+
*/
|
|
313
|
+
responseType?: string;
|
|
314
|
+
/** URI to redirect the browser to after authentication and authorization. The browser is redirected to this URI whether the authentication and authorization process is successful or not. */
|
|
315
|
+
redirectUri?: string | null;
|
|
316
|
+
/**
|
|
317
|
+
* Desired scope of access. If this field is left empty, only an access token is granted.
|
|
318
|
+
* To received a refresh token, pass `offline_access` as the value of this field.
|
|
319
|
+
*/
|
|
320
|
+
scope?: string | null;
|
|
321
|
+
/**
|
|
322
|
+
* A value used to confirm the state of an application before and after it makes an authorization
|
|
323
|
+
* request. If a value for this field is set in the request, it's added to the `redirectUri` when the browser
|
|
324
|
+
* is redirected there.
|
|
325
|
+
* Learn more about [using the state parameter](https://auth0.com/docs/secure/attack-protection/state-parameters).
|
|
326
|
+
*/
|
|
327
|
+
state?: string;
|
|
328
|
+
/**
|
|
329
|
+
* esired response format.
|
|
330
|
+
*
|
|
331
|
+
* Supported values:
|
|
332
|
+
* + `query`: The response parameters are encoded as query string parameters and added to the `redirectUri` when redirecting.
|
|
333
|
+
* + `fragment`: The response parameters are encoded as URI fragment parameters and added to the `redirectUri` when redirecting.
|
|
334
|
+
* + `web_message`: The response parameters are encoded as a JSON object and added to the body of a [web message response](https://datatracker.ietf.org/doc/html/draft-sakimura-oauth-wmrm-00).
|
|
335
|
+
*
|
|
336
|
+
* Default value: `query`
|
|
337
|
+
*/
|
|
338
|
+
responseMode?: string | null;
|
|
339
|
+
/**
|
|
340
|
+
* Code challenge to use for PKCE verification.
|
|
341
|
+
* This field is only used if `responseType` is set to `code`.
|
|
342
|
+
*/
|
|
343
|
+
codeChallenge?: string | null;
|
|
344
|
+
/**
|
|
345
|
+
* Code challenge method to use for PKCE verification.
|
|
346
|
+
* This field is only used if `responseType` is set to `code`.
|
|
347
|
+
*
|
|
348
|
+
* Supported values:
|
|
349
|
+
* + `S256`: The code challenge is transformed using SHA-256 encyption.
|
|
350
|
+
* + `S512`: The code challenge is transformed using SHA-512 encyption.
|
|
351
|
+
*/
|
|
352
|
+
codeChallengeMethod?: string | null;
|
|
353
|
+
/** Session token of the site visitor to authorize. */
|
|
354
|
+
sessionToken?: string | null;
|
|
355
|
+
}
|
|
356
|
+
/** Currently only `none` and `login` are supported. */
|
|
357
|
+
declare enum Prompt {
|
|
358
|
+
login = "login",
|
|
359
|
+
none = "none",
|
|
360
|
+
consent = "consent",
|
|
361
|
+
select_account = "select_account"
|
|
362
|
+
}
|
|
363
|
+
interface RedirectSessionMembersAccountParams {
|
|
364
|
+
/**
|
|
365
|
+
* The member account page to redirect to.
|
|
366
|
+
*
|
|
367
|
+
* Default: `ACCOUNT_INFO`
|
|
368
|
+
*/
|
|
369
|
+
section?: MembersAccountSection;
|
|
370
|
+
}
|
|
371
|
+
declare enum MembersAccountSection {
|
|
372
|
+
/** default - account info section in "my account" */
|
|
373
|
+
ACCOUNT_INFO = "ACCOUNT_INFO",
|
|
374
|
+
/** My Bookings section in "my account" */
|
|
375
|
+
BOOKINGS = "BOOKINGS",
|
|
376
|
+
/** My Orders section in "my account" */
|
|
377
|
+
ORDERS = "ORDERS",
|
|
378
|
+
/** Subscriptions section in "my account" */
|
|
379
|
+
SUBSCRIPTIONS = "SUBSCRIPTIONS",
|
|
380
|
+
/** Events section in "my account" */
|
|
381
|
+
EVENTS = "EVENTS"
|
|
382
|
+
}
|
|
383
|
+
interface RedirectSessionStoresProductParams {
|
|
384
|
+
/** *Required.** Slug of the product to navigate to. */
|
|
385
|
+
productSlug?: string;
|
|
386
|
+
}
|
|
387
|
+
interface RedirectSessionBookingsBookParams {
|
|
388
|
+
/** For use when filtering the bookings page by a specific resource. */
|
|
389
|
+
resourceId?: string;
|
|
390
|
+
}
|
|
391
|
+
interface CallbackParams {
|
|
392
|
+
/**
|
|
393
|
+
* The URL for a custom thank you page implemented on a site outside of Wix. The visitor is directed to this page after the Wix-managed process is completed.
|
|
394
|
+
* When redirecting to this URL, Wix passes different query parameters depending on the preceding transaction:
|
|
395
|
+
*
|
|
396
|
+
* After a pricing plans checkout:
|
|
397
|
+
* + `planOrderId`: ID of a pricing plan order.
|
|
398
|
+
*
|
|
399
|
+
* After an eCommerce checkout:
|
|
400
|
+
* + `orderId`: ID of an eCommerce order.
|
|
401
|
+
*
|
|
402
|
+
* After an Events checkout
|
|
403
|
+
* + `orderNumber`: Unique order number for the transaction.
|
|
404
|
+
* + `eventId`: ID of the event.
|
|
405
|
+
*
|
|
406
|
+
* If the process is abandoned or interrupted, the visitor is redirected to the URL specified in `postFlowUrl` instead.
|
|
407
|
+
*
|
|
408
|
+
* Default: If you don't pass a URL, the visitor is redirected to a Wix thank you page, and from there to the URL specified in `postFlowUrl`.
|
|
409
|
+
*/
|
|
410
|
+
thankYouPageUrl?: string | null;
|
|
411
|
+
/**
|
|
412
|
+
* The URL Wix should redirect the visitor to when the Wix-managed process is completed, abandoned, or interrupted.
|
|
413
|
+
*
|
|
414
|
+
* **Note**: For an authentication redirect, don't pass a URL here. Instead, pass one in `options.auth.authRequest.redirectUri`.
|
|
415
|
+
*/
|
|
416
|
+
postFlowUrl?: string | null;
|
|
417
|
+
/**
|
|
418
|
+
* The URL for a custom login page implemented outside of Wix.
|
|
419
|
+
*
|
|
420
|
+
* Default: If you don't pass a URL, a Wix login page is used.
|
|
421
|
+
*/
|
|
422
|
+
loginUrl?: string | null;
|
|
423
|
+
/**
|
|
424
|
+
* The URL for a custom bookings services page implemented outside of Wix.
|
|
425
|
+
*
|
|
426
|
+
* Default: If you don't pass a URL, a Wix bookings services page is used.
|
|
427
|
+
*/
|
|
428
|
+
bookingsServiceListUrl?: string | null;
|
|
429
|
+
/**
|
|
430
|
+
* The URL for a custom eCommerce cart page implemented outside of Wix.
|
|
431
|
+
*
|
|
432
|
+
* Default: If you don't pass a URL, a Wix cart page is used.
|
|
433
|
+
*/
|
|
434
|
+
cartPageUrl?: string | null;
|
|
435
|
+
/**
|
|
436
|
+
* The URL for a custom pricing plans page implemented outside of Wix. When redirecting to this URL, Wix passes the following query parameters:
|
|
437
|
+
* + `planIds`: IDs of the pricing plans on the custom page.
|
|
438
|
+
* + `checkoutData`: Pass this string back in `options.paidPlansCheckout.checkoutData` when redirecting back to Wix for checkout.
|
|
439
|
+
*
|
|
440
|
+
* Default: If you don't pass a URL, a Wix pricing plans page is used.
|
|
441
|
+
*/
|
|
442
|
+
planListUrl?: string | null;
|
|
443
|
+
}
|
|
444
|
+
interface RedirectSessionPreferences {
|
|
445
|
+
/**
|
|
446
|
+
* Whether to use a standard Wix template for Wix-managed pages the visitor is redirected to. Set to `false` only if your client site connects with a Wix site that has custom pages.
|
|
447
|
+
*
|
|
448
|
+
* Default: `true`
|
|
449
|
+
*/
|
|
450
|
+
useGenericWixPages?: boolean | null;
|
|
451
|
+
/**
|
|
452
|
+
* Whether to maintain the identity used in the redirect to wix (not relevant for "logout" and "auth" intents), or to use a new visitor identity.
|
|
453
|
+
*
|
|
454
|
+
* Default: `true`
|
|
455
|
+
*/
|
|
456
|
+
maintainIdentity?: boolean | null;
|
|
457
|
+
/**
|
|
458
|
+
* A map of additional query parameters to pass to the created Wix URL.
|
|
459
|
+
* Global query parameters to be passed to Wix, for example campaign parameters (UTM params).
|
|
460
|
+
*/
|
|
461
|
+
additionalQueryParameters?: Record<string, string>;
|
|
462
|
+
}
|
|
463
|
+
interface CustomMemberPaths {
|
|
464
|
+
/** Path of the account page in the site's members area. Required if `useGenericWixPages` is `false` and the account page path has been changed in the Wix editor. */
|
|
465
|
+
accountPagePath?: string | null;
|
|
466
|
+
/** Path of the member profile page in the site's members area. Required if `useGenericWixPages` is `false` and the member profile page path has been changed in the Wix editor. */
|
|
467
|
+
profilePagePath?: string | null;
|
|
468
|
+
}
|
|
469
|
+
interface CreateRedirectSessionResponse {
|
|
470
|
+
/** Details for redirecting the visitor to a Wix page. */
|
|
471
|
+
redirectSession?: RedirectSession;
|
|
472
|
+
}
|
|
473
|
+
interface CreateAnonymousRedirectSessionRequest extends CreateAnonymousRedirectSessionRequestIntentOneOf {
|
|
474
|
+
/** Information required for generating a custom URL for a Wix Bookings checkout. */
|
|
475
|
+
bookingsCheckout?: RedirectSessionBookingsCheckoutParams;
|
|
476
|
+
/** Information required for generating a custom URL for a Wix eCommerce checkout. */
|
|
477
|
+
ecomCheckout?: RedirectSessionEcomCheckoutParams;
|
|
478
|
+
/** Information required for generating a custom URL for a Wix Events checkout. */
|
|
479
|
+
eventsCheckout?: RedirectSessionEventsCheckoutParams;
|
|
480
|
+
/** Information required for generating a custom URL for a Wix Paid Plans checkout. */
|
|
481
|
+
paidPlansCheckout?: RedirectSessionPaidPlansCheckoutParams;
|
|
482
|
+
/** Information required for generating a custom URL for a Wix stores product page. */
|
|
483
|
+
storesProduct?: RedirectSessionStoresProductParams;
|
|
484
|
+
/** Information required for generating a custom URL for Wix bookings book page. */
|
|
485
|
+
bookingsBook?: RedirectSessionBookingsBookParams;
|
|
486
|
+
/** Optional preferences for customizing redirection to Wix pages. */
|
|
487
|
+
preferences?: RedirectSessionPreferences;
|
|
488
|
+
}
|
|
489
|
+
/** @oneof */
|
|
490
|
+
interface CreateAnonymousRedirectSessionRequestIntentOneOf {
|
|
491
|
+
/** Information required for generating a custom URL for a Wix Bookings checkout. */
|
|
492
|
+
bookingsCheckout?: RedirectSessionBookingsCheckoutParams;
|
|
493
|
+
/** Information required for generating a custom URL for a Wix eCommerce checkout. */
|
|
494
|
+
ecomCheckout?: RedirectSessionEcomCheckoutParams;
|
|
495
|
+
/** Information required for generating a custom URL for a Wix Events checkout. */
|
|
496
|
+
eventsCheckout?: RedirectSessionEventsCheckoutParams;
|
|
497
|
+
/** Information required for generating a custom URL for a Wix Paid Plans checkout. */
|
|
498
|
+
paidPlansCheckout?: RedirectSessionPaidPlansCheckoutParams;
|
|
499
|
+
/** Information required for generating a custom URL for a Wix stores product page. */
|
|
500
|
+
storesProduct?: RedirectSessionStoresProductParams;
|
|
501
|
+
/** Information required for generating a custom URL for Wix bookings book page. */
|
|
502
|
+
bookingsBook?: RedirectSessionBookingsBookParams;
|
|
503
|
+
}
|
|
504
|
+
interface CreateAnonymousRedirectSessionResponse {
|
|
505
|
+
/** Details for redirecting the visitor to a Wix page. */
|
|
506
|
+
redirectSession?: RedirectSession;
|
|
507
|
+
}
|
|
508
|
+
interface ValidateCallbackURLRequest {
|
|
509
|
+
/** An external URL to validate */
|
|
510
|
+
callbackUrl?: string;
|
|
511
|
+
/** The type of the callback URL */
|
|
512
|
+
callbackType?: CallbackType;
|
|
513
|
+
/** The oauth app id used in order to pull the allowed domains from, has to correspond to the same metasite as the site in context */
|
|
514
|
+
clientId?: string;
|
|
515
|
+
}
|
|
516
|
+
declare enum CallbackType {
|
|
517
|
+
/** Invalid value - default */
|
|
518
|
+
UNKNOWN = "UNKNOWN",
|
|
519
|
+
/** The callback URL is used for the logout flow */
|
|
520
|
+
LOGOUT = "LOGOUT",
|
|
521
|
+
/** The callback URL is used for a checkout flow */
|
|
522
|
+
CHECKOUT = "CHECKOUT",
|
|
523
|
+
/** The callback URL is used for the authorize flow */
|
|
524
|
+
AUTHORIZE = "AUTHORIZE"
|
|
525
|
+
}
|
|
526
|
+
interface ValidateCallbackURLResponse {
|
|
527
|
+
/** is the provided url allowed for the given client id */
|
|
528
|
+
isValid?: boolean;
|
|
529
|
+
}
|
|
530
|
+
interface SignInURLRequest {
|
|
531
|
+
/** The oauth app id used in order to pull the allowed domains from, has to correspond to the same metasite as the site in context */
|
|
532
|
+
clientId?: string;
|
|
533
|
+
}
|
|
534
|
+
interface SignInURLResponse {
|
|
535
|
+
/** The Wix URL details to redirect into */
|
|
536
|
+
redirectSession?: RedirectSession;
|
|
537
|
+
}
|
|
538
|
+
interface DomainEvent extends DomainEventBodyOneOf {
|
|
539
|
+
createdEvent?: EntityCreatedEvent;
|
|
540
|
+
updatedEvent?: EntityUpdatedEvent;
|
|
541
|
+
deletedEvent?: EntityDeletedEvent;
|
|
542
|
+
actionEvent?: ActionEvent;
|
|
543
|
+
/**
|
|
544
|
+
* Unique event ID.
|
|
545
|
+
* Allows clients to ignore duplicate webhooks.
|
|
546
|
+
*/
|
|
547
|
+
_id?: string;
|
|
548
|
+
/**
|
|
549
|
+
* Assumes actions are also always typed to an entity_type
|
|
550
|
+
* Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
|
|
551
|
+
*/
|
|
552
|
+
entityFqdn?: string;
|
|
553
|
+
/**
|
|
554
|
+
* This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
|
|
555
|
+
* This is although the created/updated/deleted notion is duplication of the oneof types
|
|
556
|
+
* Example: created/updated/deleted/started/completed/email_opened
|
|
557
|
+
*/
|
|
558
|
+
slug?: string;
|
|
559
|
+
/** ID of the entity associated with the event. */
|
|
560
|
+
entityId?: string;
|
|
561
|
+
/** Event timestamp. */
|
|
562
|
+
eventTime?: Date;
|
|
563
|
+
/**
|
|
564
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
|
565
|
+
* (for example, GDPR).
|
|
566
|
+
*/
|
|
567
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
568
|
+
/** If present, indicates the action that triggered the event. */
|
|
569
|
+
originatedFrom?: string | null;
|
|
570
|
+
/**
|
|
571
|
+
* A sequence number defining the order of updates to the underlying entity.
|
|
572
|
+
* For example, given that some entity was updated at 16:00 and than again at 16:01,
|
|
573
|
+
* it is guaranteed that the sequence number of the second update is strictly higher than the first.
|
|
574
|
+
* As the consumer, you can use this value to ensure that you handle messages in the correct order.
|
|
575
|
+
* To do so, you will need to persist this number on your end, and compare the sequence number from the
|
|
576
|
+
* message against the one you have stored. Given that the stored number is higher, you should ignore the message.
|
|
577
|
+
*/
|
|
578
|
+
entityEventSequence?: string | null;
|
|
579
|
+
}
|
|
580
|
+
/** @oneof */
|
|
581
|
+
interface DomainEventBodyOneOf {
|
|
582
|
+
createdEvent?: EntityCreatedEvent;
|
|
583
|
+
updatedEvent?: EntityUpdatedEvent;
|
|
584
|
+
deletedEvent?: EntityDeletedEvent;
|
|
585
|
+
actionEvent?: ActionEvent;
|
|
586
|
+
}
|
|
587
|
+
interface EntityCreatedEvent {
|
|
588
|
+
entity?: string;
|
|
589
|
+
}
|
|
590
|
+
interface RestoreInfo {
|
|
591
|
+
deletedDate?: Date;
|
|
592
|
+
}
|
|
593
|
+
interface EntityUpdatedEvent {
|
|
594
|
+
/**
|
|
595
|
+
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
596
|
+
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
597
|
+
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
598
|
+
*/
|
|
599
|
+
currentEntity?: string;
|
|
600
|
+
}
|
|
601
|
+
interface EntityDeletedEvent {
|
|
602
|
+
/** Entity that was deleted */
|
|
603
|
+
deletedEntity?: string | null;
|
|
604
|
+
}
|
|
605
|
+
interface ActionEvent {
|
|
606
|
+
body?: string;
|
|
607
|
+
}
|
|
608
|
+
interface MessageEnvelope {
|
|
609
|
+
/** App instance ID. */
|
|
610
|
+
instanceId?: string | null;
|
|
611
|
+
/** Event type. */
|
|
612
|
+
eventType?: string;
|
|
613
|
+
/** The identification type and identity data. */
|
|
614
|
+
identity?: IdentificationData;
|
|
615
|
+
/** Stringify payload. */
|
|
616
|
+
data?: string;
|
|
617
|
+
}
|
|
618
|
+
interface IdentificationData extends IdentificationDataIdOneOf {
|
|
619
|
+
/** ID of a site visitor that has not logged in to the site. */
|
|
620
|
+
anonymousVisitorId?: string;
|
|
621
|
+
/** ID of a site visitor that has logged in to the site. */
|
|
622
|
+
memberId?: string;
|
|
623
|
+
/** ID of a Wix user (site owner, contributor, etc.). */
|
|
624
|
+
wixUserId?: string;
|
|
625
|
+
/** ID of an app. */
|
|
626
|
+
appId?: string;
|
|
627
|
+
/** @readonly */
|
|
628
|
+
identityType?: WebhookIdentityType;
|
|
629
|
+
}
|
|
630
|
+
/** @oneof */
|
|
631
|
+
interface IdentificationDataIdOneOf {
|
|
632
|
+
/** ID of a site visitor that has not logged in to the site. */
|
|
633
|
+
anonymousVisitorId?: string;
|
|
634
|
+
/** ID of a site visitor that has logged in to the site. */
|
|
635
|
+
memberId?: string;
|
|
636
|
+
/** ID of a Wix user (site owner, contributor, etc.). */
|
|
637
|
+
wixUserId?: string;
|
|
638
|
+
/** ID of an app. */
|
|
639
|
+
appId?: string;
|
|
640
|
+
}
|
|
641
|
+
declare enum WebhookIdentityType {
|
|
642
|
+
UNKNOWN = "UNKNOWN",
|
|
643
|
+
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
|
644
|
+
MEMBER = "MEMBER",
|
|
645
|
+
WIX_USER = "WIX_USER",
|
|
646
|
+
APP = "APP"
|
|
647
|
+
}
|
|
648
|
+
interface URLDetailsNonNullableFields {
|
|
649
|
+
endpoint: string;
|
|
650
|
+
}
|
|
651
|
+
interface RedirectSessionNonNullableFields {
|
|
652
|
+
_id: string;
|
|
653
|
+
fullUrl: string;
|
|
654
|
+
urlDetails?: URLDetailsNonNullableFields;
|
|
655
|
+
shortUrl: string;
|
|
656
|
+
}
|
|
657
|
+
interface CreateRedirectSessionResponseNonNullableFields {
|
|
658
|
+
redirectSession?: RedirectSessionNonNullableFields;
|
|
659
|
+
}
|
|
660
|
+
interface BaseEventMetadata {
|
|
661
|
+
/** App instance ID. */
|
|
662
|
+
instanceId?: string | null;
|
|
663
|
+
/** Event type. */
|
|
664
|
+
eventType?: string;
|
|
665
|
+
/** The identification type and identity data. */
|
|
666
|
+
identity?: IdentificationData;
|
|
667
|
+
}
|
|
668
|
+
interface EventMetadata extends BaseEventMetadata {
|
|
669
|
+
/**
|
|
670
|
+
* Unique event ID.
|
|
671
|
+
* Allows clients to ignore duplicate webhooks.
|
|
672
|
+
*/
|
|
673
|
+
_id?: string;
|
|
674
|
+
/**
|
|
675
|
+
* Assumes actions are also always typed to an entity_type
|
|
676
|
+
* Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
|
|
677
|
+
*/
|
|
678
|
+
entityFqdn?: string;
|
|
679
|
+
/**
|
|
680
|
+
* This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
|
|
681
|
+
* This is although the created/updated/deleted notion is duplication of the oneof types
|
|
682
|
+
* Example: created/updated/deleted/started/completed/email_opened
|
|
683
|
+
*/
|
|
684
|
+
slug?: string;
|
|
685
|
+
/** ID of the entity associated with the event. */
|
|
686
|
+
entityId?: string;
|
|
687
|
+
/** Event timestamp. */
|
|
688
|
+
eventTime?: Date;
|
|
689
|
+
/**
|
|
690
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
|
691
|
+
* (for example, GDPR).
|
|
692
|
+
*/
|
|
693
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
694
|
+
/** If present, indicates the action that triggered the event. */
|
|
695
|
+
originatedFrom?: string | null;
|
|
696
|
+
/**
|
|
697
|
+
* A sequence number defining the order of updates to the underlying entity.
|
|
698
|
+
* For example, given that some entity was updated at 16:00 and than again at 16:01,
|
|
699
|
+
* it is guaranteed that the sequence number of the second update is strictly higher than the first.
|
|
700
|
+
* As the consumer, you can use this value to ensure that you handle messages in the correct order.
|
|
701
|
+
* To do so, you will need to persist this number on your end, and compare the sequence number from the
|
|
702
|
+
* message against the one you have stored. Given that the stored number is higher, you should ignore the message.
|
|
703
|
+
*/
|
|
704
|
+
entityEventSequence?: string | null;
|
|
705
|
+
}
|
|
706
|
+
interface RedirectSessionCreatedEnvelope {
|
|
707
|
+
entity: RedirectSession;
|
|
708
|
+
metadata: EventMetadata;
|
|
709
|
+
}
|
|
710
|
+
interface CreateRedirectSessionOptions extends CreateRedirectSessionRequestIntentOneOf {
|
|
711
|
+
/** Information required for generating a custom URL for a Wix Bookings checkout. */
|
|
712
|
+
bookingsCheckout?: RedirectSessionBookingsCheckoutParams;
|
|
713
|
+
/** Information required for generating a custom URL for a Wix eCommerce checkout. */
|
|
714
|
+
ecomCheckout?: RedirectSessionEcomCheckoutParams;
|
|
715
|
+
/** Information required for generating a custom URL for a Wix Events checkout. */
|
|
716
|
+
eventsCheckout?: RedirectSessionEventsCheckoutParams;
|
|
717
|
+
/** Information required for generating a custom URL for a Wix Paid Plans checkout. */
|
|
718
|
+
paidPlansCheckout?: RedirectSessionPaidPlansCheckoutParams;
|
|
719
|
+
/** Pass an empty object in this parameter to generate a URL for Wix login without first checking whether the visitor is authenticated. */
|
|
720
|
+
login?: RedirectSessionLoginParams;
|
|
721
|
+
/** Information required for generating a custom URL to log out from a Wix account. This process invalidates the visitor or member token and clears cookies associated with the Wix domain from their browser. */
|
|
722
|
+
logout?: RedirectSessionLogoutParams;
|
|
723
|
+
/** Information required for generating a custom URL for Wix authentication. */
|
|
724
|
+
auth?: RedirectSessionAuthParams;
|
|
725
|
+
/** Information required for generating a custom URL for a Wix stores product page. */
|
|
726
|
+
storesProduct?: RedirectSessionStoresProductParams;
|
|
727
|
+
/** Information required for generating a custom URL for Wix bookings book page. */
|
|
728
|
+
bookingsBook?: RedirectSessionBookingsBookParams;
|
|
729
|
+
/**
|
|
730
|
+
* Details of pages to redirect the visitor back to on the Wix Headless client site.
|
|
731
|
+
*
|
|
732
|
+
* **Note**: For an authentication redirect, don't pass a post-flow URL here. Instead, pass one in `options.auth.authRequest.redirectUri`.
|
|
733
|
+
*/
|
|
734
|
+
callbacks?: CallbackParams;
|
|
735
|
+
/** Optional preferences for customizing redirection to Wix pages. */
|
|
736
|
+
preferences?: RedirectSessionPreferences;
|
|
737
|
+
}
|
|
738
|
+
|
|
739
|
+
declare function createRedirectSession$1(httpClient: HttpClient): CreateRedirectSessionSignature;
|
|
740
|
+
interface CreateRedirectSessionSignature {
|
|
741
|
+
/**
|
|
742
|
+
* Creates a URL for redirecting a visitor from an external client site to a Wix page for Wix-managed functionality.
|
|
743
|
+
*
|
|
744
|
+
*
|
|
745
|
+
* The `createRedirectSession()` function enables your external Wix Headless client site, built on any platform, to integrate Wix-managed frontend functionality for specific processes.
|
|
746
|
+
* For example, your site can temporarily redirect a visitor to Wix for authentication, or for a checkout process for a bookings, eCommerce, events, or paid plans transaction.
|
|
747
|
+
*
|
|
748
|
+
* To initiate a redirect session:
|
|
749
|
+
*
|
|
750
|
+
* 1. Call `createRedirectSession()` with the details required for Wix to take care of one specific process (for example, authentication or a bookings checkout). Provide one or more callback URLs, so Wix can redirect the user back to your site as appropriate when the process is over.
|
|
751
|
+
* 1. Redirect your visitor to the URL provided in the response. This URL includes query parameters informing Wix where to redirect the visitor back to on your external site.
|
|
752
|
+
* 1. Make sure the pages at the callback URLs you provided take care of the next stages in your visitor flow.
|
|
753
|
+
* @param - Options for creating a redirect session.
|
|
754
|
+
*/
|
|
755
|
+
(options?: CreateRedirectSessionOptions | undefined): Promise<CreateRedirectSessionResponse & CreateRedirectSessionResponseNonNullableFields>;
|
|
756
|
+
}
|
|
757
|
+
declare const onRedirectSessionCreated$1: EventDefinition<RedirectSessionCreatedEnvelope, "wix.headless.v1.redirect_session_created">;
|
|
46
758
|
|
|
47
759
|
declare function createEventModule<T extends EventDefinition<any, string>>(eventDefinition: T): BuildEventDefinition<T> & T;
|
|
48
760
|
|
|
49
|
-
declare const createRedirectSession:
|
|
50
|
-
|
|
761
|
+
declare const createRedirectSession: BuildRESTFunction<typeof createRedirectSession$1> & typeof createRedirectSession$1;
|
|
762
|
+
|
|
763
|
+
type _publicOnRedirectSessionCreatedType = typeof onRedirectSessionCreated$1;
|
|
764
|
+
/** */
|
|
765
|
+
declare const onRedirectSessionCreated: ReturnType<typeof createEventModule<_publicOnRedirectSessionCreatedType>>;
|
|
51
766
|
|
|
767
|
+
type context_ActionEvent = ActionEvent;
|
|
768
|
+
type context_AuthorizeRequest = AuthorizeRequest;
|
|
769
|
+
type context_BaseEventMetadata = BaseEventMetadata;
|
|
770
|
+
type context_BookingPolicyViolations = BookingPolicyViolations;
|
|
771
|
+
type context_CallbackParams = CallbackParams;
|
|
772
|
+
type context_CallbackType = CallbackType;
|
|
773
|
+
declare const context_CallbackType: typeof CallbackType;
|
|
774
|
+
type context_CreateAnonymousRedirectSessionRequest = CreateAnonymousRedirectSessionRequest;
|
|
775
|
+
type context_CreateAnonymousRedirectSessionRequestIntentOneOf = CreateAnonymousRedirectSessionRequestIntentOneOf;
|
|
776
|
+
type context_CreateAnonymousRedirectSessionResponse = CreateAnonymousRedirectSessionResponse;
|
|
777
|
+
type context_CreateRedirectSessionOptions = CreateRedirectSessionOptions;
|
|
778
|
+
type context_CreateRedirectSessionRequest = CreateRedirectSessionRequest;
|
|
779
|
+
type context_CreateRedirectSessionRequestIntentOneOf = CreateRedirectSessionRequestIntentOneOf;
|
|
780
|
+
type context_CreateRedirectSessionResponse = CreateRedirectSessionResponse;
|
|
781
|
+
type context_CreateRedirectSessionResponseNonNullableFields = CreateRedirectSessionResponseNonNullableFields;
|
|
782
|
+
type context_CustomMemberPaths = CustomMemberPaths;
|
|
783
|
+
type context_DomainEvent = DomainEvent;
|
|
784
|
+
type context_DomainEventBodyOneOf = DomainEventBodyOneOf;
|
|
785
|
+
type context_EntityCreatedEvent = EntityCreatedEvent;
|
|
786
|
+
type context_EntityDeletedEvent = EntityDeletedEvent;
|
|
787
|
+
type context_EntityUpdatedEvent = EntityUpdatedEvent;
|
|
788
|
+
type context_EventMetadata = EventMetadata;
|
|
789
|
+
type context_IdentificationData = IdentificationData;
|
|
790
|
+
type context_IdentificationDataIdOneOf = IdentificationDataIdOneOf;
|
|
791
|
+
type context_Location = Location;
|
|
792
|
+
type context_LocationType = LocationType;
|
|
793
|
+
declare const context_LocationType: typeof LocationType;
|
|
794
|
+
type context_MembersAccountSection = MembersAccountSection;
|
|
795
|
+
declare const context_MembersAccountSection: typeof MembersAccountSection;
|
|
796
|
+
type context_MessageEnvelope = MessageEnvelope;
|
|
797
|
+
type context_NestedTimeSlot = NestedTimeSlot;
|
|
798
|
+
type context_Prompt = Prompt;
|
|
799
|
+
declare const context_Prompt: typeof Prompt;
|
|
800
|
+
type context_RedirectSession = RedirectSession;
|
|
801
|
+
type context_RedirectSessionAuthParams = RedirectSessionAuthParams;
|
|
802
|
+
type context_RedirectSessionBookingsBookParams = RedirectSessionBookingsBookParams;
|
|
803
|
+
type context_RedirectSessionBookingsCheckoutParams = RedirectSessionBookingsCheckoutParams;
|
|
804
|
+
type context_RedirectSessionCreatedEnvelope = RedirectSessionCreatedEnvelope;
|
|
805
|
+
type context_RedirectSessionEcomCheckoutParams = RedirectSessionEcomCheckoutParams;
|
|
806
|
+
type context_RedirectSessionEventsCheckoutParams = RedirectSessionEventsCheckoutParams;
|
|
807
|
+
type context_RedirectSessionLoginParams = RedirectSessionLoginParams;
|
|
808
|
+
type context_RedirectSessionLogoutParams = RedirectSessionLogoutParams;
|
|
809
|
+
type context_RedirectSessionMembersAccountParams = RedirectSessionMembersAccountParams;
|
|
810
|
+
type context_RedirectSessionPaidPlansCheckoutParams = RedirectSessionPaidPlansCheckoutParams;
|
|
811
|
+
type context_RedirectSessionPreferences = RedirectSessionPreferences;
|
|
812
|
+
type context_RedirectSessionStoresProductParams = RedirectSessionStoresProductParams;
|
|
813
|
+
type context_RestoreInfo = RestoreInfo;
|
|
814
|
+
type context_SignInURLRequest = SignInURLRequest;
|
|
815
|
+
type context_SignInURLResponse = SignInURLResponse;
|
|
816
|
+
type context_Slot = Slot;
|
|
817
|
+
type context_SlotAvailability = SlotAvailability;
|
|
818
|
+
type context_SlotResource = SlotResource;
|
|
819
|
+
type context_URLDetails = URLDetails;
|
|
820
|
+
type context_ValidateCallbackURLRequest = ValidateCallbackURLRequest;
|
|
821
|
+
type context_ValidateCallbackURLResponse = ValidateCallbackURLResponse;
|
|
822
|
+
type context_WaitingList = WaitingList;
|
|
823
|
+
type context_WebhookIdentityType = WebhookIdentityType;
|
|
824
|
+
declare const context_WebhookIdentityType: typeof WebhookIdentityType;
|
|
825
|
+
type context__publicOnRedirectSessionCreatedType = _publicOnRedirectSessionCreatedType;
|
|
52
826
|
declare const context_createRedirectSession: typeof createRedirectSession;
|
|
53
827
|
declare const context_onRedirectSessionCreated: typeof onRedirectSessionCreated;
|
|
54
828
|
declare namespace context {
|
|
55
|
-
export { context_createRedirectSession as createRedirectSession, context_onRedirectSessionCreated as onRedirectSessionCreated };
|
|
829
|
+
export { type context_ActionEvent as ActionEvent, type context_AuthorizeRequest as AuthorizeRequest, type context_BaseEventMetadata as BaseEventMetadata, type context_BookingPolicyViolations as BookingPolicyViolations, type context_CallbackParams as CallbackParams, context_CallbackType as CallbackType, type context_CreateAnonymousRedirectSessionRequest as CreateAnonymousRedirectSessionRequest, type context_CreateAnonymousRedirectSessionRequestIntentOneOf as CreateAnonymousRedirectSessionRequestIntentOneOf, type context_CreateAnonymousRedirectSessionResponse as CreateAnonymousRedirectSessionResponse, type context_CreateRedirectSessionOptions as CreateRedirectSessionOptions, type context_CreateRedirectSessionRequest as CreateRedirectSessionRequest, type context_CreateRedirectSessionRequestIntentOneOf as CreateRedirectSessionRequestIntentOneOf, type context_CreateRedirectSessionResponse as CreateRedirectSessionResponse, type context_CreateRedirectSessionResponseNonNullableFields as CreateRedirectSessionResponseNonNullableFields, type context_CustomMemberPaths as CustomMemberPaths, type context_DomainEvent as DomainEvent, type context_DomainEventBodyOneOf as DomainEventBodyOneOf, type context_EntityCreatedEvent as EntityCreatedEvent, type context_EntityDeletedEvent as EntityDeletedEvent, type context_EntityUpdatedEvent as EntityUpdatedEvent, type context_EventMetadata as EventMetadata, type context_IdentificationData as IdentificationData, type context_IdentificationDataIdOneOf as IdentificationDataIdOneOf, type context_Location as Location, context_LocationType as LocationType, context_MembersAccountSection as MembersAccountSection, type context_MessageEnvelope as MessageEnvelope, type context_NestedTimeSlot as NestedTimeSlot, context_Prompt as Prompt, type context_RedirectSession as RedirectSession, type context_RedirectSessionAuthParams as RedirectSessionAuthParams, type context_RedirectSessionBookingsBookParams as RedirectSessionBookingsBookParams, type context_RedirectSessionBookingsCheckoutParams as RedirectSessionBookingsCheckoutParams, type context_RedirectSessionCreatedEnvelope as RedirectSessionCreatedEnvelope, type context_RedirectSessionEcomCheckoutParams as RedirectSessionEcomCheckoutParams, type context_RedirectSessionEventsCheckoutParams as RedirectSessionEventsCheckoutParams, type context_RedirectSessionLoginParams as RedirectSessionLoginParams, type context_RedirectSessionLogoutParams as RedirectSessionLogoutParams, type context_RedirectSessionMembersAccountParams as RedirectSessionMembersAccountParams, type context_RedirectSessionPaidPlansCheckoutParams as RedirectSessionPaidPlansCheckoutParams, type context_RedirectSessionPreferences as RedirectSessionPreferences, type context_RedirectSessionStoresProductParams as RedirectSessionStoresProductParams, type context_RestoreInfo as RestoreInfo, type context_SignInURLRequest as SignInURLRequest, type context_SignInURLResponse as SignInURLResponse, type context_Slot as Slot, type context_SlotAvailability as SlotAvailability, type context_SlotResource as SlotResource, type context_URLDetails as URLDetails, type context_ValidateCallbackURLRequest as ValidateCallbackURLRequest, type context_ValidateCallbackURLResponse as ValidateCallbackURLResponse, type context_WaitingList as WaitingList, context_WebhookIdentityType as WebhookIdentityType, type context__publicOnRedirectSessionCreatedType as _publicOnRedirectSessionCreatedType, context_createRedirectSession as createRedirectSession, context_onRedirectSessionCreated as onRedirectSessionCreated, onRedirectSessionCreated$1 as publicOnRedirectSessionCreated };
|
|
56
830
|
}
|
|
57
831
|
|
|
58
832
|
export { context as redirects };
|
|
@@ -1,3 +1,47 @@
|
|
|
1
|
+
type RESTFunctionDescriptor<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient) => T;
|
|
2
|
+
interface HttpClient {
|
|
3
|
+
request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
|
|
4
|
+
fetchWithAuth: typeof fetch;
|
|
5
|
+
wixAPIFetch: (relativeUrl: string, options: RequestInit) => Promise<Response>;
|
|
6
|
+
}
|
|
7
|
+
type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
|
|
8
|
+
type HttpResponse<T = any> = {
|
|
9
|
+
data: T;
|
|
10
|
+
status: number;
|
|
11
|
+
statusText: string;
|
|
12
|
+
headers: any;
|
|
13
|
+
request?: any;
|
|
14
|
+
};
|
|
15
|
+
type RequestOptions<_TResponse = any, Data = any> = {
|
|
16
|
+
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
17
|
+
url: string;
|
|
18
|
+
data?: Data;
|
|
19
|
+
params?: URLSearchParams;
|
|
20
|
+
} & APIMetadata;
|
|
21
|
+
type APIMetadata = {
|
|
22
|
+
methodFqn?: string;
|
|
23
|
+
entityFqdn?: string;
|
|
24
|
+
packageName?: string;
|
|
25
|
+
};
|
|
26
|
+
type BuildRESTFunction<T extends RESTFunctionDescriptor> = T extends RESTFunctionDescriptor<infer U> ? U : never;
|
|
27
|
+
type EventDefinition<Payload = unknown, Type extends string = string> = {
|
|
28
|
+
__type: 'event-definition';
|
|
29
|
+
type: Type;
|
|
30
|
+
isDomainEvent?: boolean;
|
|
31
|
+
transformations?: (envelope: unknown) => Payload;
|
|
32
|
+
__payload: Payload;
|
|
33
|
+
};
|
|
34
|
+
declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
|
|
35
|
+
type EventHandler<T extends EventDefinition> = (payload: T['__payload']) => void | Promise<void>;
|
|
36
|
+
type BuildEventDefinition<T extends EventDefinition<any, string>> = (handler: EventHandler<T>) => void;
|
|
37
|
+
|
|
38
|
+
declare global {
|
|
39
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
40
|
+
interface SymbolConstructor {
|
|
41
|
+
readonly observable: symbol;
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
|
|
1
45
|
/** Information for redirecting a visitor from an external Wix Headless client site to a Wix page for Wix-managed functionality. */
|
|
2
46
|
interface RedirectSession {
|
|
3
47
|
/** ID of the redirect session created. */
|
|
@@ -601,15 +645,17 @@ declare enum WebhookIdentityType {
|
|
|
601
645
|
WIX_USER = "WIX_USER",
|
|
602
646
|
APP = "APP"
|
|
603
647
|
}
|
|
648
|
+
interface URLDetailsNonNullableFields {
|
|
649
|
+
endpoint: string;
|
|
650
|
+
}
|
|
651
|
+
interface RedirectSessionNonNullableFields {
|
|
652
|
+
_id: string;
|
|
653
|
+
fullUrl: string;
|
|
654
|
+
urlDetails?: URLDetailsNonNullableFields;
|
|
655
|
+
shortUrl: string;
|
|
656
|
+
}
|
|
604
657
|
interface CreateRedirectSessionResponseNonNullableFields {
|
|
605
|
-
redirectSession?:
|
|
606
|
-
_id: string;
|
|
607
|
-
fullUrl: string;
|
|
608
|
-
urlDetails?: {
|
|
609
|
-
endpoint: string;
|
|
610
|
-
};
|
|
611
|
-
shortUrl: string;
|
|
612
|
-
};
|
|
658
|
+
redirectSession?: RedirectSessionNonNullableFields;
|
|
613
659
|
}
|
|
614
660
|
interface BaseEventMetadata {
|
|
615
661
|
/** App instance ID. */
|
|
@@ -690,51 +736,33 @@ interface CreateRedirectSessionOptions extends CreateRedirectSessionRequestInten
|
|
|
690
736
|
preferences?: RedirectSessionPreferences;
|
|
691
737
|
}
|
|
692
738
|
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
739
|
+
declare function createRedirectSession$1(httpClient: HttpClient): CreateRedirectSessionSignature;
|
|
740
|
+
interface CreateRedirectSessionSignature {
|
|
741
|
+
/**
|
|
742
|
+
* Creates a URL for redirecting a visitor from an external client site to a Wix page for Wix-managed functionality.
|
|
743
|
+
*
|
|
744
|
+
*
|
|
745
|
+
* The `createRedirectSession()` function enables your external Wix Headless client site, built on any platform, to integrate Wix-managed frontend functionality for specific processes.
|
|
746
|
+
* For example, your site can temporarily redirect a visitor to Wix for authentication, or for a checkout process for a bookings, eCommerce, events, or paid plans transaction.
|
|
747
|
+
*
|
|
748
|
+
* To initiate a redirect session:
|
|
749
|
+
*
|
|
750
|
+
* 1. Call `createRedirectSession()` with the details required for Wix to take care of one specific process (for example, authentication or a bookings checkout). Provide one or more callback URLs, so Wix can redirect the user back to your site as appropriate when the process is over.
|
|
751
|
+
* 1. Redirect your visitor to the URL provided in the response. This URL includes query parameters informing Wix where to redirect the visitor back to on your external site.
|
|
752
|
+
* 1. Make sure the pages at the callback URLs you provided take care of the next stages in your visitor flow.
|
|
753
|
+
* @param - Options for creating a redirect session.
|
|
754
|
+
*/
|
|
755
|
+
(options?: CreateRedirectSessionOptions | undefined): Promise<CreateRedirectSessionResponse & CreateRedirectSessionResponseNonNullableFields>;
|
|
697
756
|
}
|
|
698
|
-
|
|
699
|
-
type HttpResponse<T = any> = {
|
|
700
|
-
data: T;
|
|
701
|
-
status: number;
|
|
702
|
-
statusText: string;
|
|
703
|
-
headers: any;
|
|
704
|
-
request?: any;
|
|
705
|
-
};
|
|
706
|
-
type RequestOptions<_TResponse = any, Data = any> = {
|
|
707
|
-
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
708
|
-
url: string;
|
|
709
|
-
data?: Data;
|
|
710
|
-
params?: URLSearchParams;
|
|
711
|
-
} & APIMetadata;
|
|
712
|
-
type APIMetadata = {
|
|
713
|
-
methodFqn?: string;
|
|
714
|
-
entityFqdn?: string;
|
|
715
|
-
packageName?: string;
|
|
716
|
-
};
|
|
717
|
-
type EventDefinition<Payload = unknown, Type extends string = string> = {
|
|
718
|
-
__type: 'event-definition';
|
|
719
|
-
type: Type;
|
|
720
|
-
isDomainEvent?: boolean;
|
|
721
|
-
transformations?: (envelope: unknown) => Payload;
|
|
722
|
-
__payload: Payload;
|
|
723
|
-
};
|
|
724
|
-
declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
|
|
757
|
+
declare const onRedirectSessionCreated$1: EventDefinition<RedirectSessionCreatedEnvelope, "wix.headless.v1.redirect_session_created">;
|
|
725
758
|
|
|
726
|
-
declare
|
|
727
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
728
|
-
interface SymbolConstructor {
|
|
729
|
-
readonly observable: symbol;
|
|
730
|
-
}
|
|
731
|
-
}
|
|
759
|
+
declare function createEventModule<T extends EventDefinition<any, string>>(eventDefinition: T): BuildEventDefinition<T> & T;
|
|
732
760
|
|
|
733
|
-
declare const
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
declare const onRedirectSessionCreated:
|
|
761
|
+
declare const createRedirectSession: BuildRESTFunction<typeof createRedirectSession$1> & typeof createRedirectSession$1;
|
|
762
|
+
|
|
763
|
+
type _publicOnRedirectSessionCreatedType = typeof onRedirectSessionCreated$1;
|
|
764
|
+
/** */
|
|
765
|
+
declare const onRedirectSessionCreated: ReturnType<typeof createEventModule<_publicOnRedirectSessionCreatedType>>;
|
|
738
766
|
|
|
739
767
|
type index_d_ActionEvent = ActionEvent;
|
|
740
768
|
type index_d_AuthorizeRequest = AuthorizeRequest;
|
|
@@ -794,11 +822,11 @@ type index_d_ValidateCallbackURLResponse = ValidateCallbackURLResponse;
|
|
|
794
822
|
type index_d_WaitingList = WaitingList;
|
|
795
823
|
type index_d_WebhookIdentityType = WebhookIdentityType;
|
|
796
824
|
declare const index_d_WebhookIdentityType: typeof WebhookIdentityType;
|
|
797
|
-
|
|
825
|
+
type index_d__publicOnRedirectSessionCreatedType = _publicOnRedirectSessionCreatedType;
|
|
798
826
|
declare const index_d_createRedirectSession: typeof createRedirectSession;
|
|
799
827
|
declare const index_d_onRedirectSessionCreated: typeof onRedirectSessionCreated;
|
|
800
828
|
declare namespace index_d {
|
|
801
|
-
export { type index_d_ActionEvent as ActionEvent, type index_d_AuthorizeRequest as AuthorizeRequest, type index_d_BaseEventMetadata as BaseEventMetadata, type index_d_BookingPolicyViolations as BookingPolicyViolations, type index_d_CallbackParams as CallbackParams, index_d_CallbackType as CallbackType, type index_d_CreateAnonymousRedirectSessionRequest as CreateAnonymousRedirectSessionRequest, type index_d_CreateAnonymousRedirectSessionRequestIntentOneOf as CreateAnonymousRedirectSessionRequestIntentOneOf, type index_d_CreateAnonymousRedirectSessionResponse as CreateAnonymousRedirectSessionResponse, type index_d_CreateRedirectSessionOptions as CreateRedirectSessionOptions, type index_d_CreateRedirectSessionRequest as CreateRedirectSessionRequest, type index_d_CreateRedirectSessionRequestIntentOneOf as CreateRedirectSessionRequestIntentOneOf, type index_d_CreateRedirectSessionResponse as CreateRedirectSessionResponse, type index_d_CreateRedirectSessionResponseNonNullableFields as CreateRedirectSessionResponseNonNullableFields, type index_d_CustomMemberPaths as CustomMemberPaths, type index_d_DomainEvent as DomainEvent, type index_d_DomainEventBodyOneOf as DomainEventBodyOneOf, type index_d_EntityCreatedEvent as EntityCreatedEvent, type index_d_EntityDeletedEvent as EntityDeletedEvent, type index_d_EntityUpdatedEvent as EntityUpdatedEvent, type index_d_EventMetadata as EventMetadata, type index_d_IdentificationData as IdentificationData, type index_d_IdentificationDataIdOneOf as IdentificationDataIdOneOf, type index_d_Location as Location, index_d_LocationType as LocationType, index_d_MembersAccountSection as MembersAccountSection, type index_d_MessageEnvelope as MessageEnvelope, type index_d_NestedTimeSlot as NestedTimeSlot, index_d_Prompt as Prompt, type index_d_RedirectSession as RedirectSession, type index_d_RedirectSessionAuthParams as RedirectSessionAuthParams, type index_d_RedirectSessionBookingsBookParams as RedirectSessionBookingsBookParams, type index_d_RedirectSessionBookingsCheckoutParams as RedirectSessionBookingsCheckoutParams, type index_d_RedirectSessionCreatedEnvelope as RedirectSessionCreatedEnvelope, type index_d_RedirectSessionEcomCheckoutParams as RedirectSessionEcomCheckoutParams, type index_d_RedirectSessionEventsCheckoutParams as RedirectSessionEventsCheckoutParams, type index_d_RedirectSessionLoginParams as RedirectSessionLoginParams, type index_d_RedirectSessionLogoutParams as RedirectSessionLogoutParams, type index_d_RedirectSessionMembersAccountParams as RedirectSessionMembersAccountParams, type index_d_RedirectSessionPaidPlansCheckoutParams as RedirectSessionPaidPlansCheckoutParams, type index_d_RedirectSessionPreferences as RedirectSessionPreferences, type index_d_RedirectSessionStoresProductParams as RedirectSessionStoresProductParams, type index_d_RestoreInfo as RestoreInfo, type index_d_SignInURLRequest as SignInURLRequest, type index_d_SignInURLResponse as SignInURLResponse, type index_d_Slot as Slot, type index_d_SlotAvailability as SlotAvailability, type index_d_SlotResource as SlotResource, type index_d_URLDetails as URLDetails, type index_d_ValidateCallbackURLRequest as ValidateCallbackURLRequest, type index_d_ValidateCallbackURLResponse as ValidateCallbackURLResponse, type index_d_WaitingList as WaitingList, index_d_WebhookIdentityType as WebhookIdentityType,
|
|
829
|
+
export { type index_d_ActionEvent as ActionEvent, type index_d_AuthorizeRequest as AuthorizeRequest, type index_d_BaseEventMetadata as BaseEventMetadata, type index_d_BookingPolicyViolations as BookingPolicyViolations, type index_d_CallbackParams as CallbackParams, index_d_CallbackType as CallbackType, type index_d_CreateAnonymousRedirectSessionRequest as CreateAnonymousRedirectSessionRequest, type index_d_CreateAnonymousRedirectSessionRequestIntentOneOf as CreateAnonymousRedirectSessionRequestIntentOneOf, type index_d_CreateAnonymousRedirectSessionResponse as CreateAnonymousRedirectSessionResponse, type index_d_CreateRedirectSessionOptions as CreateRedirectSessionOptions, type index_d_CreateRedirectSessionRequest as CreateRedirectSessionRequest, type index_d_CreateRedirectSessionRequestIntentOneOf as CreateRedirectSessionRequestIntentOneOf, type index_d_CreateRedirectSessionResponse as CreateRedirectSessionResponse, type index_d_CreateRedirectSessionResponseNonNullableFields as CreateRedirectSessionResponseNonNullableFields, type index_d_CustomMemberPaths as CustomMemberPaths, type index_d_DomainEvent as DomainEvent, type index_d_DomainEventBodyOneOf as DomainEventBodyOneOf, type index_d_EntityCreatedEvent as EntityCreatedEvent, type index_d_EntityDeletedEvent as EntityDeletedEvent, type index_d_EntityUpdatedEvent as EntityUpdatedEvent, type index_d_EventMetadata as EventMetadata, type index_d_IdentificationData as IdentificationData, type index_d_IdentificationDataIdOneOf as IdentificationDataIdOneOf, type index_d_Location as Location, index_d_LocationType as LocationType, index_d_MembersAccountSection as MembersAccountSection, type index_d_MessageEnvelope as MessageEnvelope, type index_d_NestedTimeSlot as NestedTimeSlot, index_d_Prompt as Prompt, type index_d_RedirectSession as RedirectSession, type index_d_RedirectSessionAuthParams as RedirectSessionAuthParams, type index_d_RedirectSessionBookingsBookParams as RedirectSessionBookingsBookParams, type index_d_RedirectSessionBookingsCheckoutParams as RedirectSessionBookingsCheckoutParams, type index_d_RedirectSessionCreatedEnvelope as RedirectSessionCreatedEnvelope, type index_d_RedirectSessionEcomCheckoutParams as RedirectSessionEcomCheckoutParams, type index_d_RedirectSessionEventsCheckoutParams as RedirectSessionEventsCheckoutParams, type index_d_RedirectSessionLoginParams as RedirectSessionLoginParams, type index_d_RedirectSessionLogoutParams as RedirectSessionLogoutParams, type index_d_RedirectSessionMembersAccountParams as RedirectSessionMembersAccountParams, type index_d_RedirectSessionPaidPlansCheckoutParams as RedirectSessionPaidPlansCheckoutParams, type index_d_RedirectSessionPreferences as RedirectSessionPreferences, type index_d_RedirectSessionStoresProductParams as RedirectSessionStoresProductParams, type index_d_RestoreInfo as RestoreInfo, type index_d_SignInURLRequest as SignInURLRequest, type index_d_SignInURLResponse as SignInURLResponse, type index_d_Slot as Slot, type index_d_SlotAvailability as SlotAvailability, type index_d_SlotResource as SlotResource, type index_d_URLDetails as URLDetails, type index_d_ValidateCallbackURLRequest as ValidateCallbackURLRequest, type index_d_ValidateCallbackURLResponse as ValidateCallbackURLResponse, type index_d_WaitingList as WaitingList, index_d_WebhookIdentityType as WebhookIdentityType, type index_d__publicOnRedirectSessionCreatedType as _publicOnRedirectSessionCreatedType, index_d_createRedirectSession as createRedirectSession, index_d_onRedirectSessionCreated as onRedirectSessionCreated, onRedirectSessionCreated$1 as publicOnRedirectSessionCreated };
|
|
802
830
|
}
|
|
803
831
|
|
|
804
832
|
export { index_d as redirects };
|
|
@@ -395,15 +395,17 @@ interface CreateRedirectSessionResponse$1 {
|
|
|
395
395
|
/** Details for redirecting the visitor to a Wix page. */
|
|
396
396
|
redirectSession?: RedirectSession$1;
|
|
397
397
|
}
|
|
398
|
+
interface URLDetailsNonNullableFields$1 {
|
|
399
|
+
endpoint: string;
|
|
400
|
+
}
|
|
401
|
+
interface RedirectSessionNonNullableFields$1 {
|
|
402
|
+
id: string;
|
|
403
|
+
fullUrl: string;
|
|
404
|
+
urlDetails?: URLDetailsNonNullableFields$1;
|
|
405
|
+
shortUrl: string;
|
|
406
|
+
}
|
|
398
407
|
interface CreateRedirectSessionResponseNonNullableFields$1 {
|
|
399
|
-
redirectSession?:
|
|
400
|
-
id: string;
|
|
401
|
-
fullUrl: string;
|
|
402
|
-
urlDetails?: {
|
|
403
|
-
endpoint: string;
|
|
404
|
-
};
|
|
405
|
-
shortUrl: string;
|
|
406
|
-
};
|
|
408
|
+
redirectSession?: RedirectSessionNonNullableFields$1;
|
|
407
409
|
}
|
|
408
410
|
|
|
409
411
|
/** Information for redirecting a visitor from an external Wix Headless client site to a Wix page for Wix-managed functionality. */
|
|
@@ -800,15 +802,17 @@ interface CreateRedirectSessionResponse {
|
|
|
800
802
|
/** Details for redirecting the visitor to a Wix page. */
|
|
801
803
|
redirectSession?: RedirectSession;
|
|
802
804
|
}
|
|
805
|
+
interface URLDetailsNonNullableFields {
|
|
806
|
+
endpoint: string;
|
|
807
|
+
}
|
|
808
|
+
interface RedirectSessionNonNullableFields {
|
|
809
|
+
_id: string;
|
|
810
|
+
fullUrl: string;
|
|
811
|
+
urlDetails?: URLDetailsNonNullableFields;
|
|
812
|
+
shortUrl: string;
|
|
813
|
+
}
|
|
803
814
|
interface CreateRedirectSessionResponseNonNullableFields {
|
|
804
|
-
redirectSession?:
|
|
805
|
-
_id: string;
|
|
806
|
-
fullUrl: string;
|
|
807
|
-
urlDetails?: {
|
|
808
|
-
endpoint: string;
|
|
809
|
-
};
|
|
810
|
-
shortUrl: string;
|
|
811
|
-
};
|
|
815
|
+
redirectSession?: RedirectSessionNonNullableFields;
|
|
812
816
|
}
|
|
813
817
|
|
|
814
818
|
type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
|