@wix/auto_sdk_benefit-programs_transactions 1.0.21 → 1.0.23

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.
Files changed (134) hide show
  1. package/build/{internal/cjs/src/benefit-programs-v1-transaction-transactions.universal.d.ts → benefit-programs-v1-transaction-transactions.universal-DVO76Rkw.d.mts} +54 -100
  2. package/build/{cjs/src/benefit-programs-v1-transaction-transactions.universal.d.ts → benefit-programs-v1-transaction-transactions.universal-DVO76Rkw.d.ts} +54 -100
  3. package/build/index.d.mts +35 -0
  4. package/build/index.d.ts +35 -0
  5. package/build/index.js +327 -0
  6. package/build/index.js.map +1 -0
  7. package/build/index.mjs +297 -0
  8. package/build/index.mjs.map +1 -0
  9. package/build/internal/{es/src/benefit-programs-v1-transaction-transactions.universal.d.ts → benefit-programs-v1-transaction-transactions.universal-DVO76Rkw.d.mts} +54 -100
  10. package/build/{es/src/benefit-programs-v1-transaction-transactions.universal.d.ts → internal/benefit-programs-v1-transaction-transactions.universal-DVO76Rkw.d.ts} +54 -100
  11. package/build/internal/index.d.mts +35 -0
  12. package/build/internal/index.d.ts +35 -0
  13. package/build/internal/index.js +327 -0
  14. package/build/internal/index.js.map +1 -0
  15. package/build/internal/index.mjs +297 -0
  16. package/build/internal/index.mjs.map +1 -0
  17. package/build/internal/meta.d.mts +353 -0
  18. package/build/internal/meta.d.ts +353 -0
  19. package/build/internal/meta.js +224 -0
  20. package/build/internal/meta.js.map +1 -0
  21. package/build/internal/meta.mjs +196 -0
  22. package/build/internal/meta.mjs.map +1 -0
  23. package/build/meta.d.mts +353 -0
  24. package/build/meta.d.ts +353 -0
  25. package/build/meta.js +224 -0
  26. package/build/meta.js.map +1 -0
  27. package/build/meta.mjs +196 -0
  28. package/build/meta.mjs.map +1 -0
  29. package/package.json +13 -12
  30. package/build/cjs/index.d.ts +0 -1
  31. package/build/cjs/index.js +0 -18
  32. package/build/cjs/index.js.map +0 -1
  33. package/build/cjs/index.typings.d.ts +0 -1
  34. package/build/cjs/index.typings.js +0 -18
  35. package/build/cjs/index.typings.js.map +0 -1
  36. package/build/cjs/meta.d.ts +0 -1
  37. package/build/cjs/meta.js +0 -18
  38. package/build/cjs/meta.js.map +0 -1
  39. package/build/cjs/src/benefit-programs-v1-transaction-transactions.context.d.ts +0 -6
  40. package/build/cjs/src/benefit-programs-v1-transaction-transactions.context.js +0 -14
  41. package/build/cjs/src/benefit-programs-v1-transaction-transactions.context.js.map +0 -1
  42. package/build/cjs/src/benefit-programs-v1-transaction-transactions.http.d.ts +0 -17
  43. package/build/cjs/src/benefit-programs-v1-transaction-transactions.http.js +0 -172
  44. package/build/cjs/src/benefit-programs-v1-transaction-transactions.http.js.map +0 -1
  45. package/build/cjs/src/benefit-programs-v1-transaction-transactions.meta.d.ts +0 -16
  46. package/build/cjs/src/benefit-programs-v1-transaction-transactions.meta.js +0 -66
  47. package/build/cjs/src/benefit-programs-v1-transaction-transactions.meta.js.map +0 -1
  48. package/build/cjs/src/benefit-programs-v1-transaction-transactions.public.d.ts +0 -32
  49. package/build/cjs/src/benefit-programs-v1-transaction-transactions.public.js +0 -24
  50. package/build/cjs/src/benefit-programs-v1-transaction-transactions.public.js.map +0 -1
  51. package/build/cjs/src/benefit-programs-v1-transaction-transactions.types.d.ts +0 -602
  52. package/build/cjs/src/benefit-programs-v1-transaction-transactions.types.js +0 -48
  53. package/build/cjs/src/benefit-programs-v1-transaction-transactions.types.js.map +0 -1
  54. package/build/cjs/src/benefit-programs-v1-transaction-transactions.universal.js +0 -186
  55. package/build/cjs/src/benefit-programs-v1-transaction-transactions.universal.js.map +0 -1
  56. package/build/es/index.d.ts +0 -1
  57. package/build/es/index.js +0 -2
  58. package/build/es/index.js.map +0 -1
  59. package/build/es/index.typings.d.ts +0 -1
  60. package/build/es/index.typings.js +0 -2
  61. package/build/es/index.typings.js.map +0 -1
  62. package/build/es/meta.d.ts +0 -1
  63. package/build/es/meta.js +0 -2
  64. package/build/es/meta.js.map +0 -1
  65. package/build/es/package.json +0 -3
  66. package/build/es/src/benefit-programs-v1-transaction-transactions.context.d.ts +0 -6
  67. package/build/es/src/benefit-programs-v1-transaction-transactions.context.js +0 -6
  68. package/build/es/src/benefit-programs-v1-transaction-transactions.context.js.map +0 -1
  69. package/build/es/src/benefit-programs-v1-transaction-transactions.http.d.ts +0 -17
  70. package/build/es/src/benefit-programs-v1-transaction-transactions.http.js +0 -167
  71. package/build/es/src/benefit-programs-v1-transaction-transactions.http.js.map +0 -1
  72. package/build/es/src/benefit-programs-v1-transaction-transactions.meta.d.ts +0 -16
  73. package/build/es/src/benefit-programs-v1-transaction-transactions.meta.js +0 -38
  74. package/build/es/src/benefit-programs-v1-transaction-transactions.meta.js.map +0 -1
  75. package/build/es/src/benefit-programs-v1-transaction-transactions.public.d.ts +0 -32
  76. package/build/es/src/benefit-programs-v1-transaction-transactions.public.js +0 -14
  77. package/build/es/src/benefit-programs-v1-transaction-transactions.public.js.map +0 -1
  78. package/build/es/src/benefit-programs-v1-transaction-transactions.types.d.ts +0 -602
  79. package/build/es/src/benefit-programs-v1-transaction-transactions.types.js +0 -45
  80. package/build/es/src/benefit-programs-v1-transaction-transactions.types.js.map +0 -1
  81. package/build/es/src/benefit-programs-v1-transaction-transactions.universal.js +0 -158
  82. package/build/es/src/benefit-programs-v1-transaction-transactions.universal.js.map +0 -1
  83. package/build/internal/cjs/index.d.ts +0 -1
  84. package/build/internal/cjs/index.js +0 -18
  85. package/build/internal/cjs/index.js.map +0 -1
  86. package/build/internal/cjs/index.typings.d.ts +0 -1
  87. package/build/internal/cjs/index.typings.js +0 -18
  88. package/build/internal/cjs/index.typings.js.map +0 -1
  89. package/build/internal/cjs/meta.d.ts +0 -1
  90. package/build/internal/cjs/meta.js +0 -18
  91. package/build/internal/cjs/meta.js.map +0 -1
  92. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.context.d.ts +0 -6
  93. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.context.js +0 -14
  94. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.context.js.map +0 -1
  95. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.http.d.ts +0 -17
  96. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.http.js +0 -172
  97. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.http.js.map +0 -1
  98. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.meta.d.ts +0 -16
  99. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.meta.js +0 -66
  100. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.meta.js.map +0 -1
  101. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.public.d.ts +0 -32
  102. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.public.js +0 -24
  103. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.public.js.map +0 -1
  104. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.types.d.ts +0 -602
  105. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.types.js +0 -48
  106. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.types.js.map +0 -1
  107. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.universal.js +0 -186
  108. package/build/internal/cjs/src/benefit-programs-v1-transaction-transactions.universal.js.map +0 -1
  109. package/build/internal/es/index.d.ts +0 -1
  110. package/build/internal/es/index.js +0 -2
  111. package/build/internal/es/index.js.map +0 -1
  112. package/build/internal/es/index.typings.d.ts +0 -1
  113. package/build/internal/es/index.typings.js +0 -2
  114. package/build/internal/es/index.typings.js.map +0 -1
  115. package/build/internal/es/meta.d.ts +0 -1
  116. package/build/internal/es/meta.js +0 -2
  117. package/build/internal/es/meta.js.map +0 -1
  118. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.context.d.ts +0 -6
  119. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.context.js +0 -6
  120. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.context.js.map +0 -1
  121. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.http.d.ts +0 -17
  122. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.http.js +0 -167
  123. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.http.js.map +0 -1
  124. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.meta.d.ts +0 -16
  125. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.meta.js +0 -38
  126. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.meta.js.map +0 -1
  127. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.public.d.ts +0 -32
  128. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.public.js +0 -14
  129. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.public.js.map +0 -1
  130. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.types.d.ts +0 -602
  131. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.types.js +0 -45
  132. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.types.js.map +0 -1
  133. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.universal.js +0 -158
  134. package/build/internal/es/src/benefit-programs-v1-transaction-transactions.universal.js.map +0 -1
@@ -0,0 +1,353 @@
1
+ import { G as GetTransactionRequest$1, p as GetTransactionResponse$1, Q as QueryTransactionsRequest$1, u as QueryTransactionsResponse$1 } from './benefit-programs-v1-transaction-transactions.universal-DVO76Rkw.mjs';
2
+
3
+ interface Transaction {
4
+ /**
5
+ * Transaction ID.
6
+ * @format GUID
7
+ * @readonly
8
+ */
9
+ id?: string | null;
10
+ /**
11
+ * Revision number, which increments by 1 each time the transaction is updated.
12
+ * @readonly
13
+ */
14
+ revision?: string | null;
15
+ /**
16
+ * Date and time the transaction was created.
17
+ * @readonly
18
+ */
19
+ createdDate?: Date | null;
20
+ /**
21
+ * Date and time the transaction was updated.
22
+ * @readonly
23
+ */
24
+ updatedDate?: Date | null;
25
+ /**
26
+ * Pool associated with this transaction.
27
+ * @readonly
28
+ */
29
+ pool?: PoolInfo;
30
+ /**
31
+ * Amount the balance was adjusted in this transaction.
32
+ * @decimalValue options { gte:0, maxScale:4 }
33
+ */
34
+ amount?: string;
35
+ /** Where the credits came from. */
36
+ source?: BalanceTypeWithLiterals;
37
+ /** Where the credits went to. */
38
+ target?: BalanceTypeWithLiterals;
39
+ /**
40
+ * Unique identifier, generated by the client.
41
+ * Used to recognize repeated attempts to make the same request.
42
+ * @maxLength 200
43
+ * @readonly
44
+ */
45
+ idempotencyKey?: string;
46
+ /**
47
+ * ID of the related transaction. For example, if this transaction is a refund for a benefit redemption, the related transaction is the benefit redemption transaction.
48
+ * @format GUID
49
+ * @readonly
50
+ */
51
+ relatedTransactionId?: string | null;
52
+ /**
53
+ * Beneficiary of the pool associated with this transaction.
54
+ * @readonly
55
+ * @immutable
56
+ */
57
+ beneficiary?: CommonIdentificationData;
58
+ /**
59
+ * Identity that created the transaction.
60
+ * @readonly
61
+ * @immutable
62
+ */
63
+ instructingParty?: CommonIdentificationData;
64
+ /** Transaction status. */
65
+ status?: TransactionStatusWithLiterals;
66
+ /**
67
+ * Additional transaction details.
68
+ * @readonly
69
+ */
70
+ details?: TransactionDetails;
71
+ /**
72
+ * Custom field data for the transaction object.
73
+ *
74
+ * [Extended fields](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/schema-plugins/about-schema-plugin-extensions) must be configured in the app dashboard before they can be accessed with API calls.
75
+ */
76
+ extendedFields?: ExtendedFields;
77
+ }
78
+ interface PoolInfo {
79
+ /**
80
+ * Pool ID.
81
+ * @format GUID
82
+ * @readonly
83
+ */
84
+ id?: string;
85
+ /**
86
+ * ID of the pool definition the pool was created from.
87
+ * @format GUID
88
+ * @readonly
89
+ */
90
+ poolDefinitionId?: string | null;
91
+ /**
92
+ * ID of the program definition containing the pool definition the pool was created from.
93
+ * @format GUID
94
+ * @readonly
95
+ */
96
+ programDefinitionId?: string | null;
97
+ /**
98
+ * ID of the program that contains the pool.
99
+ * @format GUID
100
+ * @readonly
101
+ */
102
+ programId?: string | null;
103
+ /**
104
+ * Available credits.
105
+ * @decimalValue options { gte:0, maxScale:4 }
106
+ * @readonly
107
+ */
108
+ creditAmount?: string | null;
109
+ /**
110
+ * Namespace for your app or site's benefit programs. Namespaces allow you to distinguish between entities that you created and entities that other apps created.
111
+ * @minLength 1
112
+ * @maxLength 50
113
+ * @readonly
114
+ */
115
+ namespace?: string | null;
116
+ }
117
+ declare enum BalanceType {
118
+ UNDEFINED = "UNDEFINED",
119
+ /** In a pool's balance. */
120
+ AVAILABLE = "AVAILABLE",
121
+ /** Outside a pool's balance. */
122
+ EXTERNAL = "EXTERNAL"
123
+ }
124
+ /** @enumType */
125
+ type BalanceTypeWithLiterals = BalanceType | 'UNDEFINED' | 'AVAILABLE' | 'EXTERNAL';
126
+ interface CommonIdentificationData extends CommonIdentificationDataIdOneOf {
127
+ /**
128
+ * ID of a site visitor that hasn't logged in to the site.
129
+ * @format GUID
130
+ */
131
+ anonymousVisitorId?: string;
132
+ /**
133
+ * ID of a site member.
134
+ * @format GUID
135
+ */
136
+ memberId?: string;
137
+ /**
138
+ * ID of a Wix user.
139
+ * @format GUID
140
+ */
141
+ wixUserId?: string;
142
+ }
143
+ /** @oneof */
144
+ interface CommonIdentificationDataIdOneOf {
145
+ /**
146
+ * ID of a site visitor that hasn't logged in to the site.
147
+ * @format GUID
148
+ */
149
+ anonymousVisitorId?: string;
150
+ /**
151
+ * ID of a site member.
152
+ * @format GUID
153
+ */
154
+ memberId?: string;
155
+ /**
156
+ * ID of a Wix user.
157
+ * @format GUID
158
+ */
159
+ wixUserId?: string;
160
+ }
161
+ declare enum TransactionStatus {
162
+ UNDEFINED = "UNDEFINED",
163
+ /** Transaction is pending. This is the initial transaction status. */
164
+ PENDING = "PENDING",
165
+ /** Transaction completed successfully. */
166
+ COMPLETED = "COMPLETED",
167
+ /** Transaction failed. */
168
+ FAILED = "FAILED"
169
+ }
170
+ /** @enumType */
171
+ type TransactionStatusWithLiterals = TransactionStatus | 'UNDEFINED' | 'PENDING' | 'COMPLETED' | 'FAILED';
172
+ interface TransactionDetails {
173
+ /**
174
+ * Item associated with the transaction.
175
+ * @readonly
176
+ */
177
+ item?: Item;
178
+ /** Amount of items associated with the transaction. */
179
+ itemCount?: number | null;
180
+ /**
181
+ * Date and time the transaction was created.
182
+ * @readonly
183
+ */
184
+ effectiveDate?: Date | null;
185
+ /**
186
+ * Reason for the transaction. For example, `Redemption`.
187
+ * @readonly
188
+ * @maxLength 256
189
+ */
190
+ reason?: string | null;
191
+ }
192
+ interface Item {
193
+ /**
194
+ * Item ID.
195
+ * @format GUID
196
+ * @readonly
197
+ */
198
+ id?: string | null;
199
+ /**
200
+ * Item external ID.
201
+ * @format GUID
202
+ * @readonly
203
+ */
204
+ externalId?: string | null;
205
+ /**
206
+ * Item category.
207
+ * @maxLength 20
208
+ * @readonly
209
+ */
210
+ category?: string | null;
211
+ /**
212
+ * Item set ID.
213
+ * @format GUID
214
+ * @readonly
215
+ */
216
+ itemSetId?: string | null;
217
+ /**
218
+ * Item name.
219
+ * @maxLength 64
220
+ * @readonly
221
+ */
222
+ displayName?: string | null;
223
+ }
224
+ interface ExtendedFields {
225
+ /**
226
+ * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.
227
+ * The value of each key is structured according to the schema defined when the extended fields were configured.
228
+ *
229
+ * You can only access fields for which you have the appropriate permissions.
230
+ *
231
+ * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).
232
+ */
233
+ namespaces?: Record<string, Record<string, any>>;
234
+ }
235
+ interface GetTransactionRequest {
236
+ /**
237
+ * ID of the transaction to retrieve.
238
+ * @format GUID
239
+ */
240
+ transactionId: string;
241
+ }
242
+ interface GetTransactionResponse {
243
+ /** Retrieved transaction. */
244
+ transaction?: Transaction;
245
+ }
246
+ interface QueryTransactionsRequest {
247
+ /** Filter, sort, and paging to apply to the query. */
248
+ query: CursorQuery;
249
+ }
250
+ interface CursorQuery extends CursorQueryPagingMethodOneOf {
251
+ /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
252
+ cursorPaging?: CursorPaging;
253
+ /**
254
+ * Filter object.
255
+ * See [API Query Language](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language)
256
+ * for more information.
257
+ */
258
+ filter?: Record<string, any> | null;
259
+ /**
260
+ * List of sort objects.
261
+ * @maxSize 5
262
+ */
263
+ sort?: Sorting[];
264
+ }
265
+ /** @oneof */
266
+ interface CursorQueryPagingMethodOneOf {
267
+ /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
268
+ cursorPaging?: CursorPaging;
269
+ }
270
+ interface Sorting {
271
+ /**
272
+ * Field to sort by.
273
+ * @maxLength 512
274
+ */
275
+ fieldName?: string;
276
+ /**
277
+ * Sort order. Use `ASC` for ascending order or `DESC` for descending order.
278
+ *
279
+ * Default: `ASC`
280
+ */
281
+ order?: SortOrderWithLiterals;
282
+ }
283
+ declare enum SortOrder {
284
+ /** Ascending sort order. */
285
+ ASC = "ASC",
286
+ /** Descending sort order. */
287
+ DESC = "DESC"
288
+ }
289
+ /** @enumType */
290
+ type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC';
291
+ interface CursorPaging {
292
+ /**
293
+ * Maximum number of items to return.
294
+ * @max 100
295
+ */
296
+ limit?: number | null;
297
+ /**
298
+ * Pointer to the next or previous page in the list of results.
299
+ *
300
+ * Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.
301
+ * Not relevant for the first request.
302
+ * @maxLength 16000
303
+ */
304
+ cursor?: string | null;
305
+ }
306
+ interface QueryTransactionsResponse {
307
+ /** List of retrieved transactions. */
308
+ transactions?: Transaction[];
309
+ /** Metadata for paginated results. */
310
+ metadata?: CursorPagingMetadata;
311
+ }
312
+ interface CursorPagingMetadata {
313
+ /** Number of items returned in the response. */
314
+ count?: number | null;
315
+ /** Cursor strings that point to the next page, previous page, or both. */
316
+ cursors?: Cursors;
317
+ /**
318
+ * Whether there are more pages to retrieve following the current page.
319
+ *
320
+ * + `true`: Another page of results can be retrieved.
321
+ * + `false`: This is the last page.
322
+ */
323
+ hasNext?: boolean | null;
324
+ }
325
+ interface Cursors {
326
+ /**
327
+ * Cursor string pointing to the next page in the list of results.
328
+ * @maxLength 16000
329
+ */
330
+ next?: string | null;
331
+ /**
332
+ * Cursor pointing to the previous page in the list of results.
333
+ * @maxLength 16000
334
+ */
335
+ prev?: string | null;
336
+ }
337
+
338
+ type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
339
+ getUrl: (context: any) => string;
340
+ httpMethod: K;
341
+ path: string;
342
+ pathParams: M;
343
+ __requestType: T;
344
+ __originalRequestType: S;
345
+ __responseType: Q;
346
+ __originalResponseType: R;
347
+ };
348
+ declare function getTransaction(): __PublicMethodMetaInfo<'GET', {
349
+ transactionId: string;
350
+ }, GetTransactionRequest$1, GetTransactionRequest, GetTransactionResponse$1, GetTransactionResponse>;
351
+ declare function queryTransactions(): __PublicMethodMetaInfo<'POST', {}, QueryTransactionsRequest$1, QueryTransactionsRequest, QueryTransactionsResponse$1, QueryTransactionsResponse>;
352
+
353
+ export { type __PublicMethodMetaInfo, getTransaction, queryTransactions };
@@ -0,0 +1,353 @@
1
+ import { G as GetTransactionRequest$1, p as GetTransactionResponse$1, Q as QueryTransactionsRequest$1, u as QueryTransactionsResponse$1 } from './benefit-programs-v1-transaction-transactions.universal-DVO76Rkw.js';
2
+
3
+ interface Transaction {
4
+ /**
5
+ * Transaction ID.
6
+ * @format GUID
7
+ * @readonly
8
+ */
9
+ id?: string | null;
10
+ /**
11
+ * Revision number, which increments by 1 each time the transaction is updated.
12
+ * @readonly
13
+ */
14
+ revision?: string | null;
15
+ /**
16
+ * Date and time the transaction was created.
17
+ * @readonly
18
+ */
19
+ createdDate?: Date | null;
20
+ /**
21
+ * Date and time the transaction was updated.
22
+ * @readonly
23
+ */
24
+ updatedDate?: Date | null;
25
+ /**
26
+ * Pool associated with this transaction.
27
+ * @readonly
28
+ */
29
+ pool?: PoolInfo;
30
+ /**
31
+ * Amount the balance was adjusted in this transaction.
32
+ * @decimalValue options { gte:0, maxScale:4 }
33
+ */
34
+ amount?: string;
35
+ /** Where the credits came from. */
36
+ source?: BalanceTypeWithLiterals;
37
+ /** Where the credits went to. */
38
+ target?: BalanceTypeWithLiterals;
39
+ /**
40
+ * Unique identifier, generated by the client.
41
+ * Used to recognize repeated attempts to make the same request.
42
+ * @maxLength 200
43
+ * @readonly
44
+ */
45
+ idempotencyKey?: string;
46
+ /**
47
+ * ID of the related transaction. For example, if this transaction is a refund for a benefit redemption, the related transaction is the benefit redemption transaction.
48
+ * @format GUID
49
+ * @readonly
50
+ */
51
+ relatedTransactionId?: string | null;
52
+ /**
53
+ * Beneficiary of the pool associated with this transaction.
54
+ * @readonly
55
+ * @immutable
56
+ */
57
+ beneficiary?: CommonIdentificationData;
58
+ /**
59
+ * Identity that created the transaction.
60
+ * @readonly
61
+ * @immutable
62
+ */
63
+ instructingParty?: CommonIdentificationData;
64
+ /** Transaction status. */
65
+ status?: TransactionStatusWithLiterals;
66
+ /**
67
+ * Additional transaction details.
68
+ * @readonly
69
+ */
70
+ details?: TransactionDetails;
71
+ /**
72
+ * Custom field data for the transaction object.
73
+ *
74
+ * [Extended fields](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/schema-plugins/about-schema-plugin-extensions) must be configured in the app dashboard before they can be accessed with API calls.
75
+ */
76
+ extendedFields?: ExtendedFields;
77
+ }
78
+ interface PoolInfo {
79
+ /**
80
+ * Pool ID.
81
+ * @format GUID
82
+ * @readonly
83
+ */
84
+ id?: string;
85
+ /**
86
+ * ID of the pool definition the pool was created from.
87
+ * @format GUID
88
+ * @readonly
89
+ */
90
+ poolDefinitionId?: string | null;
91
+ /**
92
+ * ID of the program definition containing the pool definition the pool was created from.
93
+ * @format GUID
94
+ * @readonly
95
+ */
96
+ programDefinitionId?: string | null;
97
+ /**
98
+ * ID of the program that contains the pool.
99
+ * @format GUID
100
+ * @readonly
101
+ */
102
+ programId?: string | null;
103
+ /**
104
+ * Available credits.
105
+ * @decimalValue options { gte:0, maxScale:4 }
106
+ * @readonly
107
+ */
108
+ creditAmount?: string | null;
109
+ /**
110
+ * Namespace for your app or site's benefit programs. Namespaces allow you to distinguish between entities that you created and entities that other apps created.
111
+ * @minLength 1
112
+ * @maxLength 50
113
+ * @readonly
114
+ */
115
+ namespace?: string | null;
116
+ }
117
+ declare enum BalanceType {
118
+ UNDEFINED = "UNDEFINED",
119
+ /** In a pool's balance. */
120
+ AVAILABLE = "AVAILABLE",
121
+ /** Outside a pool's balance. */
122
+ EXTERNAL = "EXTERNAL"
123
+ }
124
+ /** @enumType */
125
+ type BalanceTypeWithLiterals = BalanceType | 'UNDEFINED' | 'AVAILABLE' | 'EXTERNAL';
126
+ interface CommonIdentificationData extends CommonIdentificationDataIdOneOf {
127
+ /**
128
+ * ID of a site visitor that hasn't logged in to the site.
129
+ * @format GUID
130
+ */
131
+ anonymousVisitorId?: string;
132
+ /**
133
+ * ID of a site member.
134
+ * @format GUID
135
+ */
136
+ memberId?: string;
137
+ /**
138
+ * ID of a Wix user.
139
+ * @format GUID
140
+ */
141
+ wixUserId?: string;
142
+ }
143
+ /** @oneof */
144
+ interface CommonIdentificationDataIdOneOf {
145
+ /**
146
+ * ID of a site visitor that hasn't logged in to the site.
147
+ * @format GUID
148
+ */
149
+ anonymousVisitorId?: string;
150
+ /**
151
+ * ID of a site member.
152
+ * @format GUID
153
+ */
154
+ memberId?: string;
155
+ /**
156
+ * ID of a Wix user.
157
+ * @format GUID
158
+ */
159
+ wixUserId?: string;
160
+ }
161
+ declare enum TransactionStatus {
162
+ UNDEFINED = "UNDEFINED",
163
+ /** Transaction is pending. This is the initial transaction status. */
164
+ PENDING = "PENDING",
165
+ /** Transaction completed successfully. */
166
+ COMPLETED = "COMPLETED",
167
+ /** Transaction failed. */
168
+ FAILED = "FAILED"
169
+ }
170
+ /** @enumType */
171
+ type TransactionStatusWithLiterals = TransactionStatus | 'UNDEFINED' | 'PENDING' | 'COMPLETED' | 'FAILED';
172
+ interface TransactionDetails {
173
+ /**
174
+ * Item associated with the transaction.
175
+ * @readonly
176
+ */
177
+ item?: Item;
178
+ /** Amount of items associated with the transaction. */
179
+ itemCount?: number | null;
180
+ /**
181
+ * Date and time the transaction was created.
182
+ * @readonly
183
+ */
184
+ effectiveDate?: Date | null;
185
+ /**
186
+ * Reason for the transaction. For example, `Redemption`.
187
+ * @readonly
188
+ * @maxLength 256
189
+ */
190
+ reason?: string | null;
191
+ }
192
+ interface Item {
193
+ /**
194
+ * Item ID.
195
+ * @format GUID
196
+ * @readonly
197
+ */
198
+ id?: string | null;
199
+ /**
200
+ * Item external ID.
201
+ * @format GUID
202
+ * @readonly
203
+ */
204
+ externalId?: string | null;
205
+ /**
206
+ * Item category.
207
+ * @maxLength 20
208
+ * @readonly
209
+ */
210
+ category?: string | null;
211
+ /**
212
+ * Item set ID.
213
+ * @format GUID
214
+ * @readonly
215
+ */
216
+ itemSetId?: string | null;
217
+ /**
218
+ * Item name.
219
+ * @maxLength 64
220
+ * @readonly
221
+ */
222
+ displayName?: string | null;
223
+ }
224
+ interface ExtendedFields {
225
+ /**
226
+ * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.
227
+ * The value of each key is structured according to the schema defined when the extended fields were configured.
228
+ *
229
+ * You can only access fields for which you have the appropriate permissions.
230
+ *
231
+ * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).
232
+ */
233
+ namespaces?: Record<string, Record<string, any>>;
234
+ }
235
+ interface GetTransactionRequest {
236
+ /**
237
+ * ID of the transaction to retrieve.
238
+ * @format GUID
239
+ */
240
+ transactionId: string;
241
+ }
242
+ interface GetTransactionResponse {
243
+ /** Retrieved transaction. */
244
+ transaction?: Transaction;
245
+ }
246
+ interface QueryTransactionsRequest {
247
+ /** Filter, sort, and paging to apply to the query. */
248
+ query: CursorQuery;
249
+ }
250
+ interface CursorQuery extends CursorQueryPagingMethodOneOf {
251
+ /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
252
+ cursorPaging?: CursorPaging;
253
+ /**
254
+ * Filter object.
255
+ * See [API Query Language](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language)
256
+ * for more information.
257
+ */
258
+ filter?: Record<string, any> | null;
259
+ /**
260
+ * List of sort objects.
261
+ * @maxSize 5
262
+ */
263
+ sort?: Sorting[];
264
+ }
265
+ /** @oneof */
266
+ interface CursorQueryPagingMethodOneOf {
267
+ /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
268
+ cursorPaging?: CursorPaging;
269
+ }
270
+ interface Sorting {
271
+ /**
272
+ * Field to sort by.
273
+ * @maxLength 512
274
+ */
275
+ fieldName?: string;
276
+ /**
277
+ * Sort order. Use `ASC` for ascending order or `DESC` for descending order.
278
+ *
279
+ * Default: `ASC`
280
+ */
281
+ order?: SortOrderWithLiterals;
282
+ }
283
+ declare enum SortOrder {
284
+ /** Ascending sort order. */
285
+ ASC = "ASC",
286
+ /** Descending sort order. */
287
+ DESC = "DESC"
288
+ }
289
+ /** @enumType */
290
+ type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC';
291
+ interface CursorPaging {
292
+ /**
293
+ * Maximum number of items to return.
294
+ * @max 100
295
+ */
296
+ limit?: number | null;
297
+ /**
298
+ * Pointer to the next or previous page in the list of results.
299
+ *
300
+ * Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.
301
+ * Not relevant for the first request.
302
+ * @maxLength 16000
303
+ */
304
+ cursor?: string | null;
305
+ }
306
+ interface QueryTransactionsResponse {
307
+ /** List of retrieved transactions. */
308
+ transactions?: Transaction[];
309
+ /** Metadata for paginated results. */
310
+ metadata?: CursorPagingMetadata;
311
+ }
312
+ interface CursorPagingMetadata {
313
+ /** Number of items returned in the response. */
314
+ count?: number | null;
315
+ /** Cursor strings that point to the next page, previous page, or both. */
316
+ cursors?: Cursors;
317
+ /**
318
+ * Whether there are more pages to retrieve following the current page.
319
+ *
320
+ * + `true`: Another page of results can be retrieved.
321
+ * + `false`: This is the last page.
322
+ */
323
+ hasNext?: boolean | null;
324
+ }
325
+ interface Cursors {
326
+ /**
327
+ * Cursor string pointing to the next page in the list of results.
328
+ * @maxLength 16000
329
+ */
330
+ next?: string | null;
331
+ /**
332
+ * Cursor pointing to the previous page in the list of results.
333
+ * @maxLength 16000
334
+ */
335
+ prev?: string | null;
336
+ }
337
+
338
+ type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
339
+ getUrl: (context: any) => string;
340
+ httpMethod: K;
341
+ path: string;
342
+ pathParams: M;
343
+ __requestType: T;
344
+ __originalRequestType: S;
345
+ __responseType: Q;
346
+ __originalResponseType: R;
347
+ };
348
+ declare function getTransaction(): __PublicMethodMetaInfo<'GET', {
349
+ transactionId: string;
350
+ }, GetTransactionRequest$1, GetTransactionRequest, GetTransactionResponse$1, GetTransactionResponse>;
351
+ declare function queryTransactions(): __PublicMethodMetaInfo<'POST', {}, QueryTransactionsRequest$1, QueryTransactionsRequest, QueryTransactionsResponse$1, QueryTransactionsResponse>;
352
+
353
+ export { type __PublicMethodMetaInfo, getTransaction, queryTransactions };