@wix/auto_sdk_payments_payouts 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/cjs/index.d.ts +44 -0
- package/build/cjs/index.js +397 -0
- package/build/cjs/index.js.map +1 -0
- package/build/cjs/index.typings.d.ts +633 -0
- package/build/cjs/index.typings.js +331 -0
- package/build/cjs/index.typings.js.map +1 -0
- package/build/cjs/meta.d.ts +522 -0
- package/build/cjs/meta.js +302 -0
- package/build/cjs/meta.js.map +1 -0
- package/build/cjs/schemas.d.ts +111 -0
- package/build/cjs/schemas.js +229 -0
- package/build/cjs/schemas.js.map +1 -0
- package/build/es/index.d.mts +44 -0
- package/build/es/index.mjs +366 -0
- package/build/es/index.mjs.map +1 -0
- package/build/es/index.typings.d.mts +633 -0
- package/build/es/index.typings.mjs +302 -0
- package/build/es/index.typings.mjs.map +1 -0
- package/build/es/meta.d.mts +522 -0
- package/build/es/meta.mjs +270 -0
- package/build/es/meta.mjs.map +1 -0
- package/build/es/package.json +3 -0
- package/build/es/schemas.d.mts +111 -0
- package/build/es/schemas.mjs +189 -0
- package/build/es/schemas.mjs.map +1 -0
- package/build/internal/cjs/index.d.ts +44 -0
- package/build/internal/cjs/index.js +397 -0
- package/build/internal/cjs/index.js.map +1 -0
- package/build/internal/cjs/index.typings.d.ts +633 -0
- package/build/internal/cjs/index.typings.js +331 -0
- package/build/internal/cjs/index.typings.js.map +1 -0
- package/build/internal/cjs/meta.d.ts +522 -0
- package/build/internal/cjs/meta.js +302 -0
- package/build/internal/cjs/meta.js.map +1 -0
- package/build/internal/cjs/schemas.d.ts +111 -0
- package/build/internal/cjs/schemas.js +229 -0
- package/build/internal/cjs/schemas.js.map +1 -0
- package/build/internal/es/index.d.mts +44 -0
- package/build/internal/es/index.mjs +366 -0
- package/build/internal/es/index.mjs.map +1 -0
- package/build/internal/es/index.typings.d.mts +633 -0
- package/build/internal/es/index.typings.mjs +302 -0
- package/build/internal/es/index.typings.mjs.map +1 -0
- package/build/internal/es/meta.d.mts +522 -0
- package/build/internal/es/meta.mjs +270 -0
- package/build/internal/es/meta.mjs.map +1 -0
- package/build/internal/es/schemas.d.mts +111 -0
- package/build/internal/es/schemas.mjs +189 -0
- package/build/internal/es/schemas.mjs.map +1 -0
- package/meta/package.json +3 -0
- package/package.json +61 -0
- package/schemas/package.json +3 -0
|
@@ -0,0 +1,522 @@
|
|
|
1
|
+
import { ListPayoutsRequest as ListPayoutsRequest$1, ListPayoutsResponse as ListPayoutsResponse$1, GetPayoutRequest as GetPayoutRequest$1, GetPayoutResponse as GetPayoutResponse$1 } from './index.typings.mjs';
|
|
2
|
+
import '@wix/sdk-types';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* A payout is one outgoing transfer of funds from a Wix Payments merchant account
|
|
6
|
+
* to the merchant's bank account. The entity carries the amount, lifecycle status,
|
|
7
|
+
* estimated arrival date, and (when applicable) failure information.
|
|
8
|
+
*/
|
|
9
|
+
interface Payout {
|
|
10
|
+
/**
|
|
11
|
+
* Unique identifier of the payout. Immutable.
|
|
12
|
+
* @format GUID
|
|
13
|
+
*/
|
|
14
|
+
id?: string;
|
|
15
|
+
/**
|
|
16
|
+
* ID of the Wix Payments account that owns this payout.
|
|
17
|
+
* @format GUID
|
|
18
|
+
*/
|
|
19
|
+
accountId?: string;
|
|
20
|
+
/**
|
|
21
|
+
* ID of the Wix Payments account profile this payout belongs to.
|
|
22
|
+
* A Wix Payments account has one or more profiles; each profile has its own
|
|
23
|
+
* balance and its own payouts. Most merchants have a single profile.
|
|
24
|
+
* @format GUID
|
|
25
|
+
*/
|
|
26
|
+
accountProfileId?: string;
|
|
27
|
+
/**
|
|
28
|
+
* Date the payout was created, in advance of the underlying transfer being
|
|
29
|
+
* initiated at the bank rail. Once initiated, the funds typically reach the
|
|
30
|
+
* merchant's bank account within 3-5 business days, depending on the receiving bank.
|
|
31
|
+
*/
|
|
32
|
+
createdDate?: Date | null;
|
|
33
|
+
/** Amount of funds transferred to the merchant's bank account. */
|
|
34
|
+
amount?: Money;
|
|
35
|
+
/**
|
|
36
|
+
* Lifecycle status of the payout. `SENT` means the bank rail accepted the transfer
|
|
37
|
+
* for delivery; `FAILED` means the receiving bank rejected the transfer. The rail
|
|
38
|
+
* does not provide a delivery acknowledgement, so `SENT` is not the same as
|
|
39
|
+
* "delivered to the merchant" — see the per-value documentation on `PayoutStatus`.
|
|
40
|
+
*/
|
|
41
|
+
status?: PayoutStatusWithLiterals;
|
|
42
|
+
/**
|
|
43
|
+
* Estimated date for when the funds should arrive at the merchant's bank, returned
|
|
44
|
+
* by the underlying bank rail when available. This is a prediction, not a guarantee —
|
|
45
|
+
* actual arrival depends on the receiving bank's processing and may be later.
|
|
46
|
+
* @format LOCAL_DATE
|
|
47
|
+
*/
|
|
48
|
+
estimatedArrivalDateV2?: string | null;
|
|
49
|
+
/**
|
|
50
|
+
* Set only when `status` is `FAILED`. Indicates why the bank rail rejected the transfer.
|
|
51
|
+
* The codes are a Wix Payments unified set; the original provider-specific reason is not exposed.
|
|
52
|
+
*/
|
|
53
|
+
failureReason?: PayoutFailureReason;
|
|
54
|
+
/**
|
|
55
|
+
* Reference returned by the bank rail (e.g. ACH trace number, SEPA reference) once
|
|
56
|
+
* the transfer is initiated. Use it for reconciliation against the merchant's bank
|
|
57
|
+
* statement. Empty when the rail has not yet returned a reference.
|
|
58
|
+
* @maxLength 500
|
|
59
|
+
*/
|
|
60
|
+
bankTransferReference?: string | null;
|
|
61
|
+
/**
|
|
62
|
+
* `true` if the payout's `amount` includes funds that originate from a Wix Capital
|
|
63
|
+
* advance the merchant has taken out. `false` if the amount is composed only of
|
|
64
|
+
* regular sales proceeds.
|
|
65
|
+
*/
|
|
66
|
+
cashAdvanceIncluded?: boolean;
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Money.
|
|
70
|
+
* Default format to use. Sufficiently compliant with majority of standards: w3c, ISO 4217, ISO 20022, ISO 8583:2003.
|
|
71
|
+
*/
|
|
72
|
+
interface Money {
|
|
73
|
+
/**
|
|
74
|
+
* Monetary amount. Decimal string with a period as a decimal separator (e.g., 3.99). Optionally, a single (-), to indicate that the amount is negative.
|
|
75
|
+
* @format DECIMAL_VALUE
|
|
76
|
+
*/
|
|
77
|
+
value?: string;
|
|
78
|
+
/**
|
|
79
|
+
* Currency code. Must be valid ISO 4217 currency code (e.g., USD).
|
|
80
|
+
* @format CURRENCY
|
|
81
|
+
*/
|
|
82
|
+
currency?: string;
|
|
83
|
+
/** Monetary amount. Decimal string in local format (e.g., 1 000,30). Optionally, a single (-), to indicate that the amount is negative. */
|
|
84
|
+
formattedValue?: string | null;
|
|
85
|
+
}
|
|
86
|
+
/** Lifecycle status of a payout. */
|
|
87
|
+
declare enum PayoutStatus {
|
|
88
|
+
/** Default value. Not returned by the API. */
|
|
89
|
+
UNKNOWN = "UNKNOWN",
|
|
90
|
+
/**
|
|
91
|
+
* The bank rail accepted the transfer. Funds are en route to the merchant's bank,
|
|
92
|
+
* but acceptance is not the same as delivery — a `SENT` payout can still flip to
|
|
93
|
+
* `FAILED` if the receiving bank rejects the transfer (the rail's return window
|
|
94
|
+
* is up to 60 days for ACH and up to 13 months for SEPA).
|
|
95
|
+
*/
|
|
96
|
+
SENT = "SENT",
|
|
97
|
+
/**
|
|
98
|
+
* The transfer was rejected by the receiving bank. See `failure_reason` for the cause;
|
|
99
|
+
* the funds remain in the merchant's Wix Payments balance.
|
|
100
|
+
*/
|
|
101
|
+
FAILED = "FAILED"
|
|
102
|
+
}
|
|
103
|
+
/** @enumType */
|
|
104
|
+
type PayoutStatusWithLiterals = PayoutStatus | 'UNKNOWN' | 'SENT' | 'FAILED';
|
|
105
|
+
/**
|
|
106
|
+
* Carries the reason a payout failed. Wraps the `PayoutFailureCode` enum to leave room
|
|
107
|
+
* for future fields (e.g. a human-readable message); new clients should still read
|
|
108
|
+
* `failure_reason.code` for the enum value.
|
|
109
|
+
*/
|
|
110
|
+
interface PayoutFailureReason {
|
|
111
|
+
/** Why the bank rail rejected the transfer. */
|
|
112
|
+
code?: PayoutFailureCodeWithLiterals;
|
|
113
|
+
}
|
|
114
|
+
/**
|
|
115
|
+
* Reasons a payout can fail. Values describe real-world bank-rail conditions and
|
|
116
|
+
* are mapped from the underlying provider into a Wix Payments unified vocabulary.
|
|
117
|
+
*/
|
|
118
|
+
declare enum PayoutFailureCode {
|
|
119
|
+
/**
|
|
120
|
+
* Generic failure with no more specific reason available from the bank rail.
|
|
121
|
+
* Note: this value is also returned when no failure reason is known — clients
|
|
122
|
+
* cannot distinguish "unknown" from "generic" using this code alone.
|
|
123
|
+
*/
|
|
124
|
+
GENERIC_PAYOUT_FAILURE = "GENERIC_PAYOUT_FAILURE",
|
|
125
|
+
/**
|
|
126
|
+
* The merchant's bank account is closed. The merchant must provide new bank
|
|
127
|
+
* account details before further payouts can succeed.
|
|
128
|
+
*/
|
|
129
|
+
ACCOUNT_CLOSED = "ACCOUNT_CLOSED",
|
|
130
|
+
/**
|
|
131
|
+
* The merchant's bank account is frozen (e.g. due to a hold placed by the bank).
|
|
132
|
+
* The merchant must resolve the hold with their bank before further payouts can succeed.
|
|
133
|
+
*/
|
|
134
|
+
ACCOUNT_FROZEN = "ACCOUNT_FROZEN",
|
|
135
|
+
/**
|
|
136
|
+
* The merchant's bank account is restricted from receiving the transfer
|
|
137
|
+
* (e.g. account type or status does not permit incoming credits).
|
|
138
|
+
*/
|
|
139
|
+
BANK_ACCOUNT_RESTRICTED = "BANK_ACCOUNT_RESTRICTED",
|
|
140
|
+
/**
|
|
141
|
+
* Ownership of the merchant's bank account changed and the rail no longer
|
|
142
|
+
* recognises the previously-recorded owner. New bank details are required.
|
|
143
|
+
*/
|
|
144
|
+
BANK_OWNERSHIP_CHANGED = "BANK_OWNERSHIP_CHANGED",
|
|
145
|
+
/**
|
|
146
|
+
* The receiving bank could not process the transfer for an unspecified reason.
|
|
147
|
+
* A subsequent payout attempt may succeed.
|
|
148
|
+
*/
|
|
149
|
+
COULD_NOT_PROCESS = "COULD_NOT_PROCESS",
|
|
150
|
+
/**
|
|
151
|
+
* The merchant's bank declined the debit authorisation associated with the transfer.
|
|
152
|
+
* The merchant must contact their bank to authorise Wix Payments payouts.
|
|
153
|
+
*/
|
|
154
|
+
DEBIT_NOT_AUTHORIZED = "DEBIT_NOT_AUTHORIZED",
|
|
155
|
+
/**
|
|
156
|
+
* The account holder name on file does not match what the receiving bank has on record.
|
|
157
|
+
* The merchant must correct the account holder name.
|
|
158
|
+
*/
|
|
159
|
+
INCORRECT_ACCOUNT_HOLDER_NAME = "INCORRECT_ACCOUNT_HOLDER_NAME",
|
|
160
|
+
/** The city in the bank account details is invalid for the receiving bank. */
|
|
161
|
+
INVALID_ACCOUNT_DETAILS_CITY = "INVALID_ACCOUNT_DETAILS_CITY",
|
|
162
|
+
/** The bank account number is invalid (wrong format or does not exist). */
|
|
163
|
+
INVALID_ACCOUNT_NUMBER = "INVALID_ACCOUNT_NUMBER",
|
|
164
|
+
/** The payout currency is not supported by the receiving bank account. */
|
|
165
|
+
INVALID_CURRENCY = "INVALID_CURRENCY",
|
|
166
|
+
/** The routing number (US) is invalid or does not match the receiving bank. */
|
|
167
|
+
INVALID_ROUTING_NUMBER = "INVALID_ROUTING_NUMBER",
|
|
168
|
+
/** The sort code (UK) is invalid or does not match the receiving bank. */
|
|
169
|
+
INVALID_SORT_CODE = "INVALID_SORT_CODE",
|
|
170
|
+
/**
|
|
171
|
+
* No bank account is on file for the merchant.
|
|
172
|
+
* The merchant must add bank details before payouts can succeed.
|
|
173
|
+
*/
|
|
174
|
+
NO_ACCOUNT = "NO_ACCOUNT",
|
|
175
|
+
/**
|
|
176
|
+
* A technical error at the bank rail prevented the transfer.
|
|
177
|
+
* A subsequent payout attempt may succeed.
|
|
178
|
+
*/
|
|
179
|
+
TECHNICAL_ERROR = "TECHNICAL_ERROR"
|
|
180
|
+
}
|
|
181
|
+
/** @enumType */
|
|
182
|
+
type PayoutFailureCodeWithLiterals = PayoutFailureCode | 'GENERIC_PAYOUT_FAILURE' | 'ACCOUNT_CLOSED' | 'ACCOUNT_FROZEN' | 'BANK_ACCOUNT_RESTRICTED' | 'BANK_OWNERSHIP_CHANGED' | 'COULD_NOT_PROCESS' | 'DEBIT_NOT_AUTHORIZED' | 'INCORRECT_ACCOUNT_HOLDER_NAME' | 'INVALID_ACCOUNT_DETAILS_CITY' | 'INVALID_ACCOUNT_NUMBER' | 'INVALID_CURRENCY' | 'INVALID_ROUTING_NUMBER' | 'INVALID_SORT_CODE' | 'NO_ACCOUNT' | 'TECHNICAL_ERROR';
|
|
183
|
+
interface ListPayoutsRequest {
|
|
184
|
+
/**
|
|
185
|
+
* ID of the Wix Payments account whose payouts to list.
|
|
186
|
+
* @format GUID
|
|
187
|
+
*/
|
|
188
|
+
accountId: string;
|
|
189
|
+
/**
|
|
190
|
+
* Optional. When omitted, payouts across all profiles of the account are returned.
|
|
191
|
+
* When set, only payouts belonging to the specified account profile are returned.
|
|
192
|
+
* @format GUID
|
|
193
|
+
*/
|
|
194
|
+
accountProfileId?: string | null;
|
|
195
|
+
/** Optional. Returns only payouts created before this timestamp. */
|
|
196
|
+
createdBefore?: Date | null;
|
|
197
|
+
/** Optional. Returns only payouts created after this timestamp. */
|
|
198
|
+
createdAfter?: Date | null;
|
|
199
|
+
/** Optional. Sorting. Only `created_date` is supported; requests sorting by any other field are rejected with INVALID_ARGUMENT. */
|
|
200
|
+
sort?: Sorting;
|
|
201
|
+
/** Optional paging. Offset-based. */
|
|
202
|
+
paging?: Paging;
|
|
203
|
+
}
|
|
204
|
+
interface Sorting {
|
|
205
|
+
/**
|
|
206
|
+
* Name of the field to sort by.
|
|
207
|
+
* @maxLength 512
|
|
208
|
+
*/
|
|
209
|
+
fieldName?: string;
|
|
210
|
+
/** Sort order. */
|
|
211
|
+
order?: SortOrderWithLiterals;
|
|
212
|
+
}
|
|
213
|
+
declare enum SortOrder {
|
|
214
|
+
ASC = "ASC",
|
|
215
|
+
DESC = "DESC"
|
|
216
|
+
}
|
|
217
|
+
/** @enumType */
|
|
218
|
+
type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC';
|
|
219
|
+
interface Paging {
|
|
220
|
+
/** Number of items to load. */
|
|
221
|
+
limit?: number | null;
|
|
222
|
+
/** Number of items to skip in the current sort order. */
|
|
223
|
+
offset?: number | null;
|
|
224
|
+
}
|
|
225
|
+
interface ListPayoutsResponse {
|
|
226
|
+
/** List of payouts. */
|
|
227
|
+
payouts?: Payout[];
|
|
228
|
+
/** Paging metadata. */
|
|
229
|
+
metadata?: PagingMetadata;
|
|
230
|
+
}
|
|
231
|
+
interface PagingMetadata {
|
|
232
|
+
/** Number of items returned in the response. */
|
|
233
|
+
count?: number | null;
|
|
234
|
+
/** Offset that was requested. */
|
|
235
|
+
offset?: number | null;
|
|
236
|
+
/** Total number of items that match the query. */
|
|
237
|
+
total?: number | null;
|
|
238
|
+
/** Flag that indicates the server failed to calculate the `total` field. */
|
|
239
|
+
tooManyToCount?: boolean | null;
|
|
240
|
+
}
|
|
241
|
+
interface CreatePayoutRequest {
|
|
242
|
+
/** Payout. */
|
|
243
|
+
payout?: Payout;
|
|
244
|
+
}
|
|
245
|
+
interface CreatePayoutResponse {
|
|
246
|
+
/** Payout. */
|
|
247
|
+
payout?: Payout;
|
|
248
|
+
}
|
|
249
|
+
interface GetPayoutRequest {
|
|
250
|
+
/**
|
|
251
|
+
* ID of the Wix Payments account the payout belongs to.
|
|
252
|
+
* @format GUID
|
|
253
|
+
*/
|
|
254
|
+
accountId: string;
|
|
255
|
+
/**
|
|
256
|
+
* ID of the payout to retrieve.
|
|
257
|
+
* @format GUID
|
|
258
|
+
*/
|
|
259
|
+
payoutId: string;
|
|
260
|
+
}
|
|
261
|
+
interface GetPayoutResponse {
|
|
262
|
+
/** Payout. */
|
|
263
|
+
payout?: Payout;
|
|
264
|
+
}
|
|
265
|
+
interface ListPayoutGroupsRequest {
|
|
266
|
+
/**
|
|
267
|
+
* Wix Payments account identifier.
|
|
268
|
+
* @format GUID
|
|
269
|
+
*/
|
|
270
|
+
accountId?: string;
|
|
271
|
+
/**
|
|
272
|
+
* Optional filter by payout date. Use it to return payouts before specific date.
|
|
273
|
+
* @format LOCAL_DATE
|
|
274
|
+
*/
|
|
275
|
+
payoutDateBefore?: string | null;
|
|
276
|
+
/**
|
|
277
|
+
* Optional filter by payout date. Use it to return payouts after specific date.
|
|
278
|
+
* @format LOCAL_DATE
|
|
279
|
+
*/
|
|
280
|
+
payoutDateAfter?: string | null;
|
|
281
|
+
/** Optional sorting. Supported fields: "payout_date". */
|
|
282
|
+
sort?: Sorting;
|
|
283
|
+
/** Optional paging. */
|
|
284
|
+
paging?: Paging;
|
|
285
|
+
}
|
|
286
|
+
interface ListPayoutGroupsResponse {
|
|
287
|
+
/** List of payout groups. */
|
|
288
|
+
groups?: PayoutGroup[];
|
|
289
|
+
/** Paging metadata. */
|
|
290
|
+
metadata?: PagingMetadata;
|
|
291
|
+
}
|
|
292
|
+
/** Payout group */
|
|
293
|
+
interface PayoutGroup {
|
|
294
|
+
/**
|
|
295
|
+
* Payout date.
|
|
296
|
+
* @format LOCAL_DATE
|
|
297
|
+
*/
|
|
298
|
+
payoutDate?: string;
|
|
299
|
+
/**
|
|
300
|
+
* Payout number within the same date, is absent if there's only one group
|
|
301
|
+
* @min 1
|
|
302
|
+
* @max 99
|
|
303
|
+
*/
|
|
304
|
+
payoutNumber?: number | null;
|
|
305
|
+
/** Payout group amount */
|
|
306
|
+
amount?: Money;
|
|
307
|
+
/**
|
|
308
|
+
* Payouts associated with the group
|
|
309
|
+
* @maxSize 10
|
|
310
|
+
*/
|
|
311
|
+
payouts?: Payout[];
|
|
312
|
+
}
|
|
313
|
+
interface GetPayoutGroupRequest {
|
|
314
|
+
/**
|
|
315
|
+
* Wix Payments account identifier.
|
|
316
|
+
* @format GUID
|
|
317
|
+
*/
|
|
318
|
+
accountId?: string;
|
|
319
|
+
/**
|
|
320
|
+
* Payout date.
|
|
321
|
+
* @format LOCAL_DATE
|
|
322
|
+
*/
|
|
323
|
+
payoutDate?: string;
|
|
324
|
+
/**
|
|
325
|
+
* Optional payout number within the same date
|
|
326
|
+
* @min 1
|
|
327
|
+
* @max 99
|
|
328
|
+
*/
|
|
329
|
+
payoutNumber?: number | null;
|
|
330
|
+
}
|
|
331
|
+
interface GetPayoutGroupResponse {
|
|
332
|
+
/** Payout group. */
|
|
333
|
+
group?: PayoutGroup;
|
|
334
|
+
}
|
|
335
|
+
interface GetPayoutGroupByPayoutIdRequest {
|
|
336
|
+
/**
|
|
337
|
+
* Wix Payments account identifier.
|
|
338
|
+
* @format GUID
|
|
339
|
+
*/
|
|
340
|
+
accountId?: string;
|
|
341
|
+
/**
|
|
342
|
+
* Payout identifier.
|
|
343
|
+
* @format GUID
|
|
344
|
+
*/
|
|
345
|
+
payoutId?: string;
|
|
346
|
+
}
|
|
347
|
+
interface GetPayoutGroupByPayoutIdResponse {
|
|
348
|
+
/** Payout group. */
|
|
349
|
+
group?: PayoutGroup;
|
|
350
|
+
}
|
|
351
|
+
interface DomainEvent extends DomainEventBodyOneOf {
|
|
352
|
+
createdEvent?: EntityCreatedEvent;
|
|
353
|
+
updatedEvent?: EntityUpdatedEvent;
|
|
354
|
+
deletedEvent?: EntityDeletedEvent;
|
|
355
|
+
actionEvent?: ActionEvent;
|
|
356
|
+
/** Event ID. With this ID you can easily spot duplicated events and ignore them. */
|
|
357
|
+
id?: string;
|
|
358
|
+
/**
|
|
359
|
+
* Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.
|
|
360
|
+
* For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
|
|
361
|
+
*/
|
|
362
|
+
entityFqdn?: string;
|
|
363
|
+
/**
|
|
364
|
+
* Event action name, placed at the top level to make it easier for users to dispatch messages.
|
|
365
|
+
* For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.
|
|
366
|
+
*/
|
|
367
|
+
slug?: string;
|
|
368
|
+
/** ID of the entity associated with the event. */
|
|
369
|
+
entityId?: string;
|
|
370
|
+
/** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */
|
|
371
|
+
eventTime?: Date | null;
|
|
372
|
+
/**
|
|
373
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
|
374
|
+
* (for example, GDPR).
|
|
375
|
+
*/
|
|
376
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
377
|
+
/** If present, indicates the action that triggered the event. */
|
|
378
|
+
originatedFrom?: string | null;
|
|
379
|
+
/**
|
|
380
|
+
* A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at 16:00 and then again at 16:01, the second update will always have a higher sequence number.
|
|
381
|
+
* You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.
|
|
382
|
+
*/
|
|
383
|
+
entityEventSequence?: string | null;
|
|
384
|
+
}
|
|
385
|
+
/** @oneof */
|
|
386
|
+
interface DomainEventBodyOneOf {
|
|
387
|
+
createdEvent?: EntityCreatedEvent;
|
|
388
|
+
updatedEvent?: EntityUpdatedEvent;
|
|
389
|
+
deletedEvent?: EntityDeletedEvent;
|
|
390
|
+
actionEvent?: ActionEvent;
|
|
391
|
+
}
|
|
392
|
+
interface EntityCreatedEvent {
|
|
393
|
+
entityAsJson?: string;
|
|
394
|
+
/** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */
|
|
395
|
+
restoreInfo?: RestoreInfo;
|
|
396
|
+
}
|
|
397
|
+
interface RestoreInfo {
|
|
398
|
+
deletedDate?: Date | null;
|
|
399
|
+
}
|
|
400
|
+
interface EntityUpdatedEvent {
|
|
401
|
+
/**
|
|
402
|
+
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
403
|
+
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
404
|
+
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
405
|
+
*/
|
|
406
|
+
currentEntityAsJson?: string;
|
|
407
|
+
}
|
|
408
|
+
interface EntityDeletedEvent {
|
|
409
|
+
/** Entity that was deleted. */
|
|
410
|
+
deletedEntityAsJson?: string | null;
|
|
411
|
+
}
|
|
412
|
+
interface ActionEvent {
|
|
413
|
+
bodyAsJson?: string;
|
|
414
|
+
}
|
|
415
|
+
interface MessageEnvelope {
|
|
416
|
+
/**
|
|
417
|
+
* App instance ID.
|
|
418
|
+
* @format GUID
|
|
419
|
+
*/
|
|
420
|
+
instanceId?: string | null;
|
|
421
|
+
/**
|
|
422
|
+
* Event type.
|
|
423
|
+
* @maxLength 150
|
|
424
|
+
*/
|
|
425
|
+
eventType?: string;
|
|
426
|
+
/** The identification type and identity data. */
|
|
427
|
+
identity?: IdentificationData;
|
|
428
|
+
/** Stringify payload. */
|
|
429
|
+
data?: string;
|
|
430
|
+
/** Details related to the account */
|
|
431
|
+
accountInfo?: AccountInfo;
|
|
432
|
+
}
|
|
433
|
+
interface IdentificationData extends IdentificationDataIdOneOf {
|
|
434
|
+
/**
|
|
435
|
+
* ID of a site visitor that has not logged in to the site.
|
|
436
|
+
* @format GUID
|
|
437
|
+
*/
|
|
438
|
+
anonymousVisitorId?: string;
|
|
439
|
+
/**
|
|
440
|
+
* ID of a site visitor that has logged in to the site.
|
|
441
|
+
* @format GUID
|
|
442
|
+
*/
|
|
443
|
+
memberId?: string;
|
|
444
|
+
/**
|
|
445
|
+
* ID of a Wix user (site owner, contributor, etc.).
|
|
446
|
+
* @format GUID
|
|
447
|
+
*/
|
|
448
|
+
wixUserId?: string;
|
|
449
|
+
/**
|
|
450
|
+
* ID of an app.
|
|
451
|
+
* @format GUID
|
|
452
|
+
*/
|
|
453
|
+
appId?: string;
|
|
454
|
+
/** @readonly */
|
|
455
|
+
identityType?: WebhookIdentityTypeWithLiterals;
|
|
456
|
+
}
|
|
457
|
+
/** @oneof */
|
|
458
|
+
interface IdentificationDataIdOneOf {
|
|
459
|
+
/**
|
|
460
|
+
* ID of a site visitor that has not logged in to the site.
|
|
461
|
+
* @format GUID
|
|
462
|
+
*/
|
|
463
|
+
anonymousVisitorId?: string;
|
|
464
|
+
/**
|
|
465
|
+
* ID of a site visitor that has logged in to the site.
|
|
466
|
+
* @format GUID
|
|
467
|
+
*/
|
|
468
|
+
memberId?: string;
|
|
469
|
+
/**
|
|
470
|
+
* ID of a Wix user (site owner, contributor, etc.).
|
|
471
|
+
* @format GUID
|
|
472
|
+
*/
|
|
473
|
+
wixUserId?: string;
|
|
474
|
+
/**
|
|
475
|
+
* ID of an app.
|
|
476
|
+
* @format GUID
|
|
477
|
+
*/
|
|
478
|
+
appId?: string;
|
|
479
|
+
}
|
|
480
|
+
declare enum WebhookIdentityType {
|
|
481
|
+
UNKNOWN = "UNKNOWN",
|
|
482
|
+
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
|
483
|
+
MEMBER = "MEMBER",
|
|
484
|
+
WIX_USER = "WIX_USER",
|
|
485
|
+
APP = "APP"
|
|
486
|
+
}
|
|
487
|
+
/** @enumType */
|
|
488
|
+
type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP';
|
|
489
|
+
interface AccountInfo {
|
|
490
|
+
/**
|
|
491
|
+
* ID of the Wix account associated with the event.
|
|
492
|
+
* @format GUID
|
|
493
|
+
*/
|
|
494
|
+
accountId?: string | null;
|
|
495
|
+
/**
|
|
496
|
+
* ID of the parent Wix account. Only included when accountId belongs to a child account.
|
|
497
|
+
* @format GUID
|
|
498
|
+
*/
|
|
499
|
+
parentAccountId?: string | null;
|
|
500
|
+
/**
|
|
501
|
+
* ID of the Wix site associated with the event. Only included when the event is tied to a specific site.
|
|
502
|
+
* @format GUID
|
|
503
|
+
*/
|
|
504
|
+
siteId?: string | null;
|
|
505
|
+
}
|
|
506
|
+
|
|
507
|
+
type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
|
|
508
|
+
getUrl: (context: any) => string;
|
|
509
|
+
httpMethod: K;
|
|
510
|
+
path: string;
|
|
511
|
+
pathParams: M;
|
|
512
|
+
__requestType: T;
|
|
513
|
+
__originalRequestType: S;
|
|
514
|
+
__responseType: Q;
|
|
515
|
+
__originalResponseType: R;
|
|
516
|
+
};
|
|
517
|
+
declare function listPayouts(): __PublicMethodMetaInfo<'GET', {}, ListPayoutsRequest$1, ListPayoutsRequest, ListPayoutsResponse$1, ListPayoutsResponse>;
|
|
518
|
+
declare function getPayout(): __PublicMethodMetaInfo<'GET', {
|
|
519
|
+
payoutId: string;
|
|
520
|
+
}, GetPayoutRequest$1, GetPayoutRequest, GetPayoutResponse$1, GetPayoutResponse>;
|
|
521
|
+
|
|
522
|
+
export { type AccountInfo as AccountInfoOriginal, type ActionEvent as ActionEventOriginal, type CreatePayoutRequest as CreatePayoutRequestOriginal, type CreatePayoutResponse as CreatePayoutResponseOriginal, type DomainEventBodyOneOf as DomainEventBodyOneOfOriginal, type DomainEvent as DomainEventOriginal, type EntityCreatedEvent as EntityCreatedEventOriginal, type EntityDeletedEvent as EntityDeletedEventOriginal, type EntityUpdatedEvent as EntityUpdatedEventOriginal, type GetPayoutGroupByPayoutIdRequest as GetPayoutGroupByPayoutIdRequestOriginal, type GetPayoutGroupByPayoutIdResponse as GetPayoutGroupByPayoutIdResponseOriginal, type GetPayoutGroupRequest as GetPayoutGroupRequestOriginal, type GetPayoutGroupResponse as GetPayoutGroupResponseOriginal, type GetPayoutRequest as GetPayoutRequestOriginal, type GetPayoutResponse as GetPayoutResponseOriginal, type IdentificationDataIdOneOf as IdentificationDataIdOneOfOriginal, type IdentificationData as IdentificationDataOriginal, type ListPayoutGroupsRequest as ListPayoutGroupsRequestOriginal, type ListPayoutGroupsResponse as ListPayoutGroupsResponseOriginal, type ListPayoutsRequest as ListPayoutsRequestOriginal, type ListPayoutsResponse as ListPayoutsResponseOriginal, type MessageEnvelope as MessageEnvelopeOriginal, type Money as MoneyOriginal, type PagingMetadata as PagingMetadataOriginal, type Paging as PagingOriginal, PayoutFailureCode as PayoutFailureCodeOriginal, type PayoutFailureCodeWithLiterals as PayoutFailureCodeWithLiteralsOriginal, type PayoutFailureReason as PayoutFailureReasonOriginal, type PayoutGroup as PayoutGroupOriginal, type Payout as PayoutOriginal, PayoutStatus as PayoutStatusOriginal, type PayoutStatusWithLiterals as PayoutStatusWithLiteralsOriginal, type RestoreInfo as RestoreInfoOriginal, SortOrder as SortOrderOriginal, type SortOrderWithLiterals as SortOrderWithLiteralsOriginal, type Sorting as SortingOriginal, WebhookIdentityType as WebhookIdentityTypeOriginal, type WebhookIdentityTypeWithLiterals as WebhookIdentityTypeWithLiteralsOriginal, type __PublicMethodMetaInfo, getPayout, listPayouts };
|