@wix/auto_sdk_benefit-programs_balances 1.0.11 → 1.0.13

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/cjs/index.d.ts +1 -0
  2. package/build/cjs/index.js +18 -0
  3. package/build/cjs/index.js.map +1 -0
  4. package/build/cjs/index.typings.d.ts +1 -0
  5. package/build/cjs/index.typings.js +18 -0
  6. package/build/cjs/index.typings.js.map +1 -0
  7. package/build/cjs/meta.d.ts +1 -0
  8. package/build/cjs/meta.js +18 -0
  9. package/build/cjs/meta.js.map +1 -0
  10. package/build/cjs/src/benefit-programs-v1-balance-balances.context.d.ts +9 -0
  11. package/build/cjs/src/benefit-programs-v1-balance-balances.context.js +19 -0
  12. package/build/cjs/src/benefit-programs-v1-balance-balances.context.js.map +1 -0
  13. package/build/cjs/src/benefit-programs-v1-balance-balances.http.d.ts +34 -0
  14. package/build/cjs/src/benefit-programs-v1-balance-balances.http.js +296 -0
  15. package/build/cjs/src/benefit-programs-v1-balance-balances.http.js.map +1 -0
  16. package/build/cjs/src/benefit-programs-v1-balance-balances.meta.d.ts +23 -0
  17. package/build/cjs/src/benefit-programs-v1-balance-balances.meta.js +123 -0
  18. package/build/cjs/src/benefit-programs-v1-balance-balances.meta.js.map +1 -0
  19. package/build/cjs/src/benefit-programs-v1-balance-balances.public.d.ts +66 -0
  20. package/build/cjs/src/benefit-programs-v1-balance-balances.public.js +44 -0
  21. package/build/cjs/src/benefit-programs-v1-balance-balances.public.js.map +1 -0
  22. package/build/cjs/src/benefit-programs-v1-balance-balances.types.d.ts +719 -0
  23. package/build/cjs/src/benefit-programs-v1-balance-balances.types.js +63 -0
  24. package/build/cjs/src/benefit-programs-v1-balance-balances.types.js.map +1 -0
  25. package/build/{benefit-programs-v1-balance-balances.universal-qcbBfXdg.d.mts → cjs/src/benefit-programs-v1-balance-balances.universal.d.ts} +169 -66
  26. package/build/cjs/src/benefit-programs-v1-balance-balances.universal.js +345 -0
  27. package/build/cjs/src/benefit-programs-v1-balance-balances.universal.js.map +1 -0
  28. package/build/es/index.d.ts +1 -0
  29. package/build/es/index.js +2 -0
  30. package/build/es/index.js.map +1 -0
  31. package/build/es/index.typings.d.ts +1 -0
  32. package/build/es/index.typings.js +2 -0
  33. package/build/es/index.typings.js.map +1 -0
  34. package/build/es/meta.d.ts +1 -0
  35. package/build/es/meta.js +2 -0
  36. package/build/es/meta.js.map +1 -0
  37. package/build/es/package.json +3 -0
  38. package/build/es/src/benefit-programs-v1-balance-balances.context.d.ts +9 -0
  39. package/build/es/src/benefit-programs-v1-balance-balances.context.js +9 -0
  40. package/build/es/src/benefit-programs-v1-balance-balances.context.js.map +1 -0
  41. package/build/es/src/benefit-programs-v1-balance-balances.http.d.ts +34 -0
  42. package/build/es/src/benefit-programs-v1-balance-balances.http.js +288 -0
  43. package/build/es/src/benefit-programs-v1-balance-balances.http.js.map +1 -0
  44. package/build/es/src/benefit-programs-v1-balance-balances.meta.d.ts +23 -0
  45. package/build/es/src/benefit-programs-v1-balance-balances.meta.js +92 -0
  46. package/build/es/src/benefit-programs-v1-balance-balances.meta.js.map +1 -0
  47. package/build/es/src/benefit-programs-v1-balance-balances.public.d.ts +66 -0
  48. package/build/es/src/benefit-programs-v1-balance-balances.public.js +29 -0
  49. package/build/es/src/benefit-programs-v1-balance-balances.public.js.map +1 -0
  50. package/build/es/src/benefit-programs-v1-balance-balances.types.d.ts +719 -0
  51. package/build/es/src/benefit-programs-v1-balance-balances.types.js +60 -0
  52. package/build/es/src/benefit-programs-v1-balance-balances.types.js.map +1 -0
  53. package/build/{benefit-programs-v1-balance-balances.universal-qcbBfXdg.d.ts → es/src/benefit-programs-v1-balance-balances.universal.d.ts} +169 -66
  54. package/build/es/src/benefit-programs-v1-balance-balances.universal.js +314 -0
  55. package/build/es/src/benefit-programs-v1-balance-balances.universal.js.map +1 -0
  56. package/build/internal/cjs/index.d.ts +1 -0
  57. package/build/internal/cjs/index.js +18 -0
  58. package/build/internal/cjs/index.js.map +1 -0
  59. package/build/internal/cjs/index.typings.d.ts +1 -0
  60. package/build/internal/cjs/index.typings.js +18 -0
  61. package/build/internal/cjs/index.typings.js.map +1 -0
  62. package/build/internal/cjs/meta.d.ts +1 -0
  63. package/build/internal/cjs/meta.js +18 -0
  64. package/build/internal/cjs/meta.js.map +1 -0
  65. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.context.d.ts +9 -0
  66. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.context.js +19 -0
  67. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.context.js.map +1 -0
  68. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.http.d.ts +34 -0
  69. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.http.js +296 -0
  70. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.http.js.map +1 -0
  71. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.meta.d.ts +23 -0
  72. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.meta.js +123 -0
  73. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.meta.js.map +1 -0
  74. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.public.d.ts +66 -0
  75. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.public.js +44 -0
  76. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.public.js.map +1 -0
  77. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.types.d.ts +719 -0
  78. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.types.js +63 -0
  79. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.types.js.map +1 -0
  80. package/build/internal/{benefit-programs-v1-balance-balances.universal-qcbBfXdg.d.mts → cjs/src/benefit-programs-v1-balance-balances.universal.d.ts} +169 -66
  81. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.universal.js +345 -0
  82. package/build/internal/cjs/src/benefit-programs-v1-balance-balances.universal.js.map +1 -0
  83. package/build/internal/es/index.d.ts +1 -0
  84. package/build/internal/es/index.js +2 -0
  85. package/build/internal/es/index.js.map +1 -0
  86. package/build/internal/es/index.typings.d.ts +1 -0
  87. package/build/internal/es/index.typings.js +2 -0
  88. package/build/internal/es/index.typings.js.map +1 -0
  89. package/build/internal/es/meta.d.ts +1 -0
  90. package/build/internal/es/meta.js +2 -0
  91. package/build/internal/es/meta.js.map +1 -0
  92. package/build/internal/es/src/benefit-programs-v1-balance-balances.context.d.ts +9 -0
  93. package/build/internal/es/src/benefit-programs-v1-balance-balances.context.js +9 -0
  94. package/build/internal/es/src/benefit-programs-v1-balance-balances.context.js.map +1 -0
  95. package/build/internal/es/src/benefit-programs-v1-balance-balances.http.d.ts +34 -0
  96. package/build/internal/es/src/benefit-programs-v1-balance-balances.http.js +288 -0
  97. package/build/internal/es/src/benefit-programs-v1-balance-balances.http.js.map +1 -0
  98. package/build/internal/es/src/benefit-programs-v1-balance-balances.meta.d.ts +23 -0
  99. package/build/internal/es/src/benefit-programs-v1-balance-balances.meta.js +92 -0
  100. package/build/internal/es/src/benefit-programs-v1-balance-balances.meta.js.map +1 -0
  101. package/build/internal/es/src/benefit-programs-v1-balance-balances.public.d.ts +66 -0
  102. package/build/internal/es/src/benefit-programs-v1-balance-balances.public.js +29 -0
  103. package/build/internal/es/src/benefit-programs-v1-balance-balances.public.js.map +1 -0
  104. package/build/internal/es/src/benefit-programs-v1-balance-balances.types.d.ts +719 -0
  105. package/build/internal/es/src/benefit-programs-v1-balance-balances.types.js +60 -0
  106. package/build/internal/es/src/benefit-programs-v1-balance-balances.types.js.map +1 -0
  107. package/build/internal/{benefit-programs-v1-balance-balances.universal-qcbBfXdg.d.ts → es/src/benefit-programs-v1-balance-balances.universal.d.ts} +169 -66
  108. package/build/internal/es/src/benefit-programs-v1-balance-balances.universal.js +314 -0
  109. package/build/internal/es/src/benefit-programs-v1-balance-balances.universal.js.map +1 -0
  110. package/package.json +13 -14
  111. package/build/index.d.mts +0 -72
  112. package/build/index.d.ts +0 -72
  113. package/build/index.js +0 -573
  114. package/build/index.js.map +0 -1
  115. package/build/index.mjs +0 -538
  116. package/build/index.mjs.map +0 -1
  117. package/build/internal/index.d.mts +0 -72
  118. package/build/internal/index.d.ts +0 -72
  119. package/build/internal/index.js +0 -573
  120. package/build/internal/index.js.map +0 -1
  121. package/build/internal/index.mjs +0 -538
  122. package/build/internal/index.mjs.map +0 -1
  123. package/build/internal/meta.d.mts +0 -431
  124. package/build/internal/meta.d.ts +0 -431
  125. package/build/internal/meta.js +0 -391
  126. package/build/internal/meta.js.map +0 -1
  127. package/build/internal/meta.mjs +0 -360
  128. package/build/internal/meta.mjs.map +0 -1
  129. package/build/meta.d.mts +0 -431
  130. package/build/meta.d.ts +0 -431
  131. package/build/meta.js +0 -391
  132. package/build/meta.js.map +0 -1
  133. package/build/meta.mjs +0 -360
  134. package/build/meta.mjs.map +0 -1
@@ -0,0 +1,288 @@
1
+ import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';
2
+ import { transformSDKTimestampToRESTTimestamp } from '@wix/sdk-runtime/transformations/timestamp';
3
+ import { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';
4
+ import { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';
5
+ import { resolveUrl } from '@wix/sdk-runtime/rest-modules';
6
+ function resolveWixBenefitProgramsV1BalanceBalanceServiceUrl(opts) {
7
+ const domainToMappings = {
8
+ 'api._api_base_domain_': [
9
+ {
10
+ srcPath: '/pool-accounts',
11
+ destPath: '',
12
+ },
13
+ ],
14
+ _: [
15
+ {
16
+ srcPath: '/_api/benefit-programs-pool-accounts',
17
+ destPath: '',
18
+ },
19
+ ],
20
+ 'editor._base_domain_': [
21
+ {
22
+ srcPath: '/_api/benefit-programs-pool-accounts',
23
+ destPath: '',
24
+ },
25
+ {
26
+ srcPath: '/_api/benefit-programs/v1/balances',
27
+ destPath: '/v1/balances',
28
+ },
29
+ {
30
+ srcPath: '/_api/benefit-programs/v1/bulk/balances',
31
+ destPath: '/v1/bulk/balances',
32
+ },
33
+ ],
34
+ 'blocks._base_domain_': [
35
+ {
36
+ srcPath: '/_api/benefit-programs-pool-accounts',
37
+ destPath: '',
38
+ },
39
+ {
40
+ srcPath: '/_api/benefit-programs/v1/balances',
41
+ destPath: '/v1/balances',
42
+ },
43
+ {
44
+ srcPath: '/_api/benefit-programs/v1/bulk/balances',
45
+ destPath: '/v1/bulk/balances',
46
+ },
47
+ ],
48
+ 'create.editorx': [
49
+ {
50
+ srcPath: '/_api/benefit-programs-pool-accounts',
51
+ destPath: '',
52
+ },
53
+ {
54
+ srcPath: '/_api/benefit-programs/v1/balances',
55
+ destPath: '/v1/balances',
56
+ },
57
+ {
58
+ srcPath: '/_api/benefit-programs/v1/bulk/balances',
59
+ destPath: '/v1/bulk/balances',
60
+ },
61
+ ],
62
+ 'editor.wixapps.net': [
63
+ {
64
+ srcPath: '/_api/benefit-programs-pool-accounts',
65
+ destPath: '',
66
+ },
67
+ {
68
+ srcPath: '/_api/benefit-programs/v1/balances',
69
+ destPath: '/v1/balances',
70
+ },
71
+ {
72
+ srcPath: '/_api/benefit-programs/v1/bulk/balances',
73
+ destPath: '/v1/bulk/balances',
74
+ },
75
+ ],
76
+ 'manage._base_domain_': [
77
+ {
78
+ srcPath: '/_api/benefit-programs-pool-accounts',
79
+ destPath: '',
80
+ },
81
+ {
82
+ srcPath: '/_api/benefit-programs/v1/balances',
83
+ destPath: '/v1/balances',
84
+ },
85
+ {
86
+ srcPath: '/_api/benefit-programs/v1/bulk/balances',
87
+ destPath: '/v1/bulk/balances',
88
+ },
89
+ ],
90
+ 'www._base_domain_': [
91
+ {
92
+ srcPath: '/_api/benefit-programs-pool-accounts',
93
+ destPath: '',
94
+ },
95
+ {
96
+ srcPath: '/_api/benefit-programs/v1/balances',
97
+ destPath: '/v1/balances',
98
+ },
99
+ {
100
+ srcPath: '/_api/benefit-programs/v1/bulk/balances',
101
+ destPath: '/v1/bulk/balances',
102
+ },
103
+ ],
104
+ 'www.wixapis.com': [
105
+ {
106
+ srcPath: '/benefit-programs/v1/balances',
107
+ destPath: '/v1/balances',
108
+ },
109
+ {
110
+ srcPath: '/_api/benefit-programs/v1/bulk/balances',
111
+ destPath: '/v1/bulk/balances',
112
+ },
113
+ ],
114
+ '*.dev.wix-code.com': [
115
+ {
116
+ srcPath: '/_api/benefit-programs/v1/balances',
117
+ destPath: '/v1/balances',
118
+ },
119
+ {
120
+ srcPath: '/_api/benefit-programs/v1/bulk/balances',
121
+ destPath: '/v1/bulk/balances',
122
+ },
123
+ ],
124
+ };
125
+ return resolveUrl(Object.assign(opts, { domainToMappings }));
126
+ }
127
+ const PACKAGE_NAME = '@wix/auto_sdk_benefit-programs_balances';
128
+ /** Retrieves a balance. */
129
+ export function getBalance(payload) {
130
+ function __getBalance({ host }) {
131
+ const metadata = {
132
+ entityFqdn: 'wix.benefit_programs.v1.balance',
133
+ method: 'GET',
134
+ methodFqn: 'wix.benefit_programs.v1.balance.BalanceService.GetBalance',
135
+ packageName: PACKAGE_NAME,
136
+ url: resolveWixBenefitProgramsV1BalanceBalanceServiceUrl({
137
+ protoPath: '/v1/balances/{poolId}',
138
+ data: payload,
139
+ host,
140
+ }),
141
+ params: toURLSearchParams(payload),
142
+ transformResponse: (payload) => transformPaths(payload, [
143
+ {
144
+ transformFn: transformRESTTimestampToSDKTimestamp,
145
+ paths: [
146
+ { path: 'balance.createdDate' },
147
+ { path: 'balance.updatedDate' },
148
+ ],
149
+ },
150
+ ]),
151
+ };
152
+ return metadata;
153
+ }
154
+ return __getBalance;
155
+ }
156
+ /** Retrieves a list of balances. */
157
+ export function listBalances(payload) {
158
+ function __listBalances({ host }) {
159
+ const metadata = {
160
+ entityFqdn: 'wix.benefit_programs.v1.balance',
161
+ method: 'GET',
162
+ methodFqn: 'wix.benefit_programs.v1.balance.BalanceService.ListBalances',
163
+ packageName: PACKAGE_NAME,
164
+ url: resolveWixBenefitProgramsV1BalanceBalanceServiceUrl({
165
+ protoPath: '/v1/balances',
166
+ data: payload,
167
+ host,
168
+ }),
169
+ params: toURLSearchParams(payload),
170
+ transformResponse: (payload) => transformPaths(payload, [
171
+ {
172
+ transformFn: transformRESTTimestampToSDKTimestamp,
173
+ paths: [
174
+ { path: 'balances.createdDate' },
175
+ { path: 'balances.updatedDate' },
176
+ ],
177
+ },
178
+ ]),
179
+ };
180
+ return metadata;
181
+ }
182
+ return __listBalances;
183
+ }
184
+ /**
185
+ * Creates a query to retrieve a list of balances.
186
+ *
187
+ * The Query Balances method builds a query to retrieve a list of balances and returns a `BalancesQueryBuilder` object.
188
+ *
189
+ * The returned object contains the query definition, which is used to run the query using the `find()` method.
190
+ *
191
+ * You can refine the query by chaining `BalancesQueryBuilder` methods onto the query. `BalancesQueryBuilder` methods enable you to filter, sort, and control the results that Query Balances returns.
192
+ *
193
+ * Query Balances has a default paging limit of 50, which you can override.
194
+ *
195
+ * For a full description of the item object, see the object returned for the `items` property in `BalancesQueryResult`.
196
+ */
197
+ export function queryBalances(payload) {
198
+ function __queryBalances({ host }) {
199
+ const metadata = {
200
+ entityFqdn: 'wix.benefit_programs.v1.balance',
201
+ method: 'POST',
202
+ methodFqn: 'wix.benefit_programs.v1.balance.BalanceService.QueryBalances',
203
+ packageName: PACKAGE_NAME,
204
+ url: resolveWixBenefitProgramsV1BalanceBalanceServiceUrl({
205
+ protoPath: '/v1/balances/query',
206
+ data: payload,
207
+ host,
208
+ }),
209
+ data: payload,
210
+ transformResponse: (payload) => transformPaths(payload, [
211
+ {
212
+ transformFn: transformRESTTimestampToSDKTimestamp,
213
+ paths: [
214
+ { path: 'balances.createdDate' },
215
+ { path: 'balances.updatedDate' },
216
+ ],
217
+ },
218
+ ]),
219
+ };
220
+ return metadata;
221
+ }
222
+ return __queryBalances;
223
+ }
224
+ /**
225
+ * Changes the number of available credits in a balance.
226
+ *
227
+ * You can adjust or set the number of available credits.
228
+ */
229
+ export function changeBalance(payload) {
230
+ function __changeBalance({ host }) {
231
+ const serializedData = transformPaths(payload, [
232
+ {
233
+ transformFn: transformSDKTimestampToRESTTimestamp,
234
+ paths: [{ path: 'transactionDetails.effectiveDate' }],
235
+ },
236
+ ]);
237
+ const metadata = {
238
+ entityFqdn: 'wix.benefit_programs.v1.balance',
239
+ method: 'POST',
240
+ methodFqn: 'wix.benefit_programs.v1.balance.BalanceService.ChangeBalance',
241
+ packageName: PACKAGE_NAME,
242
+ url: resolveWixBenefitProgramsV1BalanceBalanceServiceUrl({
243
+ protoPath: '/v1/balances/{poolId}/change',
244
+ data: serializedData,
245
+ host,
246
+ }),
247
+ data: serializedData,
248
+ transformResponse: (payload) => transformPaths(payload, [
249
+ {
250
+ transformFn: transformRESTTimestampToSDKTimestamp,
251
+ paths: [
252
+ { path: 'balance.createdDate' },
253
+ { path: 'balance.updatedDate' },
254
+ ],
255
+ },
256
+ ]),
257
+ };
258
+ return metadata;
259
+ }
260
+ return __changeBalance;
261
+ }
262
+ /**
263
+ * Reverts a transaction created by calling Change Balance.
264
+ *
265
+ * For example, if a transaction increased a balance's available credits by 5,
266
+ * calling Revert Balance Change with the transaction's ID will decrease the balance's available credit by 5.
267
+ *
268
+ * > **Note:** If the Change Balance call set the balance, Revert Transaction reverts the amount the balance changed by, ensuring subsequent balance changes are still reflected after the reversion.
269
+ */
270
+ export function revertBalanceChange(payload) {
271
+ function __revertBalanceChange({ host }) {
272
+ const metadata = {
273
+ entityFqdn: 'wix.benefit_programs.v1.balance',
274
+ method: 'POST',
275
+ methodFqn: 'wix.benefit_programs.v1.balance.BalanceService.RevertBalanceChange',
276
+ packageName: PACKAGE_NAME,
277
+ url: resolveWixBenefitProgramsV1BalanceBalanceServiceUrl({
278
+ protoPath: '/v1/balances/changes/{transactionId}/revert',
279
+ data: payload,
280
+ host,
281
+ }),
282
+ data: payload,
283
+ };
284
+ return metadata;
285
+ }
286
+ return __revertBalanceChange;
287
+ }
288
+ //# sourceMappingURL=benefit-programs-v1-balance-balances.http.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"benefit-programs-v1-balance-balances.http.js","sourceRoot":"","sources":["../../../../src/benefit-programs-v1-balance-balances.http.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,+BAA+B,CAAC;AAClE,OAAO,EAAE,oCAAoC,EAAE,MAAM,4CAA4C,CAAC;AAClG,OAAO,EAAE,oCAAoC,EAAE,MAAM,4CAA4C,CAAC;AAClG,OAAO,EAAE,cAAc,EAAE,MAAM,kDAAkD,CAAC;AAClF,OAAO,EAAE,UAAU,EAAE,MAAM,+BAA+B,CAAC;AAI3D,SAAS,mDAAmD,CAC1D,IAA8C;IAE9C,MAAM,gBAAgB,GAAG;QACvB,uBAAuB,EAAE;YACvB;gBACE,OAAO,EAAE,gBAAgB;gBACzB,QAAQ,EAAE,EAAE;aACb;SACF;QACD,CAAC,EAAE;YACD;gBACE,OAAO,EAAE,sCAAsC;gBAC/C,QAAQ,EAAE,EAAE;aACb;SACF;QACD,sBAAsB,EAAE;YACtB;gBACE,OAAO,EAAE,sCAAsC;gBAC/C,QAAQ,EAAE,EAAE;aACb;YACD;gBACE,OAAO,EAAE,oCAAoC;gBAC7C,QAAQ,EAAE,cAAc;aACzB;YACD;gBACE,OAAO,EAAE,yCAAyC;gBAClD,QAAQ,EAAE,mBAAmB;aAC9B;SACF;QACD,sBAAsB,EAAE;YACtB;gBACE,OAAO,EAAE,sCAAsC;gBAC/C,QAAQ,EAAE,EAAE;aACb;YACD;gBACE,OAAO,EAAE,oCAAoC;gBAC7C,QAAQ,EAAE,cAAc;aACzB;YACD;gBACE,OAAO,EAAE,yCAAyC;gBAClD,QAAQ,EAAE,mBAAmB;aAC9B;SACF;QACD,gBAAgB,EAAE;YAChB;gBACE,OAAO,EAAE,sCAAsC;gBAC/C,QAAQ,EAAE,EAAE;aACb;YACD;gBACE,OAAO,EAAE,oCAAoC;gBAC7C,QAAQ,EAAE,cAAc;aACzB;YACD;gBACE,OAAO,EAAE,yCAAyC;gBAClD,QAAQ,EAAE,mBAAmB;aAC9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E,cAAc;YACpB,iBAAiB,EAAE,CAAC,OAAY,EAAE,EAAE,CAClC,cAAc,CAAC,OAAO,EAAE;gBACtB;oBACE,WAAW,EAAE,oCAAoC;oBACjD,KAAK,EAAE;wBACL,EAAE,IAAI,EAAE,qBAAqB,EAAE;wBAC/B,EAAE,IAAI,EAAE,qBAAqB,EAAE;qBAChC;iBACF;aACF,CAAC;SACL,CAAC;QAEF,OAAO,QAAQ,CAAC;IAClB,CAAC;IAED,OAAO,eAAe,CAAC;AACzB,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,UAAU,mBAAmB,CACjC,OAAe;IAEf,SAAS,qBAAqB,CAAC,EAAE,IAAI,EAAO;QAC1C,MAAM,QAAQ,GAAG;YACf,UAAU,EAAE,iCAAiC;YAC7C,MAAM,EAAE,MAAa;YACrB,SAAS,EACP,oEAAoE;YACtE,WAAW,EAAE,YAAY;YACzB,GAAG,EAAE,mDAAmD,CAAC;gBACvD,SAAS,EAAE,6CAA6C;gBACxD,IAAI,EAAE,OAAO;gBACb,IAAI;aACL,CAAC;YACF,IAAI,EAAE,OAAO;SACd,CAAC;QAEF,OAAO,QAAQ,CAAC;IAClB,CAAC;IAED,OAAO,qBAAqB,CAAC;AAC/B,CAAC"}
@@ -0,0 +1,23 @@
1
+ import * as ambassadorWixBenefitProgramsV1BalanceTypes from './benefit-programs-v1-balance-balances.types.js';
2
+ import * as ambassadorWixBenefitProgramsV1BalanceUniversalTypes from './benefit-programs-v1-balance-balances.universal.js';
3
+ export type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
4
+ getUrl: (context: any) => string;
5
+ httpMethod: K;
6
+ path: string;
7
+ pathParams: M;
8
+ __requestType: T;
9
+ __originalRequestType: S;
10
+ __responseType: Q;
11
+ __originalResponseType: R;
12
+ };
13
+ export declare function getBalance(): __PublicMethodMetaInfo<'GET', {
14
+ poolId: string;
15
+ }, ambassadorWixBenefitProgramsV1BalanceUniversalTypes.GetBalanceRequest, ambassadorWixBenefitProgramsV1BalanceTypes.GetBalanceRequest, ambassadorWixBenefitProgramsV1BalanceUniversalTypes.GetBalanceResponse, ambassadorWixBenefitProgramsV1BalanceTypes.GetBalanceResponse>;
16
+ export declare function listBalances(): __PublicMethodMetaInfo<'GET', {}, ambassadorWixBenefitProgramsV1BalanceUniversalTypes.ListBalancesRequest, ambassadorWixBenefitProgramsV1BalanceTypes.ListBalancesRequest, ambassadorWixBenefitProgramsV1BalanceUniversalTypes.ListBalancesResponse, ambassadorWixBenefitProgramsV1BalanceTypes.ListBalancesResponse>;
17
+ export declare function queryBalances(): __PublicMethodMetaInfo<'POST', {}, ambassadorWixBenefitProgramsV1BalanceUniversalTypes.QueryBalancesRequest, ambassadorWixBenefitProgramsV1BalanceTypes.QueryBalancesRequest, ambassadorWixBenefitProgramsV1BalanceUniversalTypes.QueryBalancesResponse, ambassadorWixBenefitProgramsV1BalanceTypes.QueryBalancesResponse>;
18
+ export declare function changeBalance(): __PublicMethodMetaInfo<'POST', {
19
+ poolId: string;
20
+ }, ambassadorWixBenefitProgramsV1BalanceUniversalTypes.BalanceChangeBalanceRequest, ambassadorWixBenefitProgramsV1BalanceTypes.BalanceChangeBalanceRequest, ambassadorWixBenefitProgramsV1BalanceUniversalTypes.ChangeBalanceResponse, ambassadorWixBenefitProgramsV1BalanceTypes.ChangeBalanceResponse>;
21
+ export declare function revertBalanceChange(): __PublicMethodMetaInfo<'POST', {
22
+ transactionId: string;
23
+ }, ambassadorWixBenefitProgramsV1BalanceUniversalTypes.RevertBalanceChangeRequest, ambassadorWixBenefitProgramsV1BalanceTypes.RevertBalanceChangeRequest, ambassadorWixBenefitProgramsV1BalanceUniversalTypes.RevertBalanceChangeResponse, ambassadorWixBenefitProgramsV1BalanceTypes.RevertBalanceChangeResponse>;
@@ -0,0 +1,92 @@
1
+ import * as ambassadorWixBenefitProgramsV1Balance from './benefit-programs-v1-balance-balances.http.js';
2
+ export function getBalance() {
3
+ const payload = { poolId: ':poolId' };
4
+ const getRequestOptions = ambassadorWixBenefitProgramsV1Balance.getBalance(payload);
5
+ const getUrl = (context) => {
6
+ const { url } = getRequestOptions(context);
7
+ return url;
8
+ };
9
+ return {
10
+ getUrl,
11
+ httpMethod: 'GET',
12
+ path: '/v1/balances/{poolId}',
13
+ pathParams: { poolId: 'poolId' },
14
+ __requestType: null,
15
+ __originalRequestType: null,
16
+ __responseType: null,
17
+ __originalResponseType: null,
18
+ };
19
+ }
20
+ export function listBalances() {
21
+ const payload = {};
22
+ const getRequestOptions = ambassadorWixBenefitProgramsV1Balance.listBalances(payload);
23
+ const getUrl = (context) => {
24
+ const { url } = getRequestOptions(context);
25
+ return url;
26
+ };
27
+ return {
28
+ getUrl,
29
+ httpMethod: 'GET',
30
+ path: '/v1/balances',
31
+ pathParams: {},
32
+ __requestType: null,
33
+ __originalRequestType: null,
34
+ __responseType: null,
35
+ __originalResponseType: null,
36
+ };
37
+ }
38
+ export function queryBalances() {
39
+ const payload = {};
40
+ const getRequestOptions = ambassadorWixBenefitProgramsV1Balance.queryBalances(payload);
41
+ const getUrl = (context) => {
42
+ const { url } = getRequestOptions(context);
43
+ return url;
44
+ };
45
+ return {
46
+ getUrl,
47
+ httpMethod: 'POST',
48
+ path: '/v1/balances/query',
49
+ pathParams: {},
50
+ __requestType: null,
51
+ __originalRequestType: null,
52
+ __responseType: null,
53
+ __originalResponseType: null,
54
+ };
55
+ }
56
+ export function changeBalance() {
57
+ const payload = { poolId: ':poolId' };
58
+ const getRequestOptions = ambassadorWixBenefitProgramsV1Balance.changeBalance(payload);
59
+ const getUrl = (context) => {
60
+ const { url } = getRequestOptions(context);
61
+ return url;
62
+ };
63
+ return {
64
+ getUrl,
65
+ httpMethod: 'POST',
66
+ path: '/v1/balances/{poolId}/change',
67
+ pathParams: { poolId: 'poolId' },
68
+ __requestType: null,
69
+ __originalRequestType: null,
70
+ __responseType: null,
71
+ __originalResponseType: null,
72
+ };
73
+ }
74
+ export function revertBalanceChange() {
75
+ const payload = { transactionId: ':transactionId' };
76
+ const getRequestOptions = ambassadorWixBenefitProgramsV1Balance.revertBalanceChange(payload);
77
+ const getUrl = (context) => {
78
+ const { url } = getRequestOptions(context);
79
+ return url;
80
+ };
81
+ return {
82
+ getUrl,
83
+ httpMethod: 'POST',
84
+ path: '/v1/balances/changes/{transactionId}/revert',
85
+ pathParams: { transactionId: 'transactionId' },
86
+ __requestType: null,
87
+ __originalRequestType: null,
88
+ __responseType: null,
89
+ __originalResponseType: null,
90
+ };
91
+ }
92
+ //# sourceMappingURL=benefit-programs-v1-balance-balances.meta.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"benefit-programs-v1-balance-balances.meta.js","sourceRoot":"","sources":["../../../../src/benefit-programs-v1-balance-balances.meta.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,qCAAqC,MAAM,gDAAgD,CAAC;AAsBxG,MAAM,UAAU,UAAU;IAQxB,MAAM,OAAO,GAAG,EAAE,MAAM,EAAE,SAAS,EAAS,CAAC;IAE7C,MAAM,iBAAiB,GACrB,qCAAqC,CAAC,UAAU,CAAC,OAAO,CAAC,CAAC;IAE5D,MAAM,MAAM,GAAG,CAAC,OAAY,EAAU,EAAE;QACtC,MAAM,EAAE,GAAG,EAAE,GAAG,iBAAiB,CAAC,OAAO,CAAC,CAAC;QAC3C,OAAO,GAAI,CAAC;IACd,CAAC,CAAC;IAEF,OAAO;QACL,MAAM;QACN,UAAU,EAAE,KAAK;QACjB,IAAI,EAAE,uBAAuB;QAC7B,UAAU,EAAE,EAAE,MAAM,EAAE,QAAQ,EAAE;QAChC,aAAa,EAAE,IAAW;QAC1B,qBAAqB,EAAE,IAAW;QAClC,cAAc,EAAE,IAAW;QAC3B,sBAAsB,EAAE,IAAW;KACpC,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,YAAY;IAQ1B,MAAM,OAAO,GAAG,EAAS,CAAC;IAE1B,MAAM,iBAAiB,GACrB,qCAAqC,CAAC,YAAY,CAAC,OAAO,CAA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AO;QACL,MAAM;QACN,UAAU,EAAE,MAAM;QAClB,IAAI,EAAE,8BAA8B;QACpC,UAAU,EAAE,EAAE,MAAM,EAAE,QAAQ,EAAE;QAChC,aAAa,EAAE,IAAW;QAC1B,qBAAqB,EAAE,IAAW;QAClC,cAAc,EAAE,IAAW;QAC3B,sBAAsB,EAAE,IAAW;KACpC,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,mBAAmB;IAQjC,MAAM,OAAO,GAAG,EAAE,aAAa,EAAE,gBAAgB,EAAS,CAAC;IAE3D,MAAM,iBAAiB,GACrB,qCAAqC,CAAC,mBAAmB,CAAC,OAAO,CAAC,CAAC;IAErE,MAAM,MAAM,GAAG,CAAC,OAAY,EAAU,EAAE;QACtC,MAAM,EAAE,GAAG,EAAE,GAAG,iBAAiB,CAAC,OAAO,CAAC,CAAC;QAC3C,OAAO,GAAI,CAAC;IACd,CAAC,CAAC;IAEF,OAAO;QACL,MAAM;QACN,UAAU,EAAE,MAAM;QAClB,IAAI,EAAE,6CAA6C;QACnD,UAAU,EAAE,EAAE,aAAa,EAAE,eAAe,EAAE;QAC9C,aAAa,EAAE,IAAW;QAC1B,qBAAqB,EAAE,IAAW;QAClC,cAAc,EAAE,IAAW;QAC3B,sBAAsB,EAAE,IAAW;KACpC,CAAC;AACJ,CAAC"}
@@ -0,0 +1,66 @@
1
+ import { HttpClient } from '@wix/sdk-types';
2
+ import { Balance, BalancesQueryBuilder, ChangeBalanceOptions, ChangeBalanceResponse, ListBalancesOptions, ListBalancesResponse, RevertBalanceChangeOptions, RevertBalanceChangeResponse } from './benefit-programs-v1-balance-balances.universal.js';
3
+ export declare const __metadata: {
4
+ PACKAGE_NAME: string;
5
+ };
6
+ export declare function getBalance(httpClient: HttpClient): GetBalanceSignature;
7
+ interface GetBalanceSignature {
8
+ /**
9
+ * Retrieves a balance.
10
+ * @param - ID of the pool associated with the balance to retrieve. This is also the ID of the balance.
11
+ * @returns Retrieved balance.
12
+ */
13
+ (poolId: string): Promise<Balance>;
14
+ }
15
+ export declare function listBalances(httpClient: HttpClient): ListBalancesSignature;
16
+ interface ListBalancesSignature {
17
+ /**
18
+ * Retrieves a list of balances.
19
+ */
20
+ (options?: ListBalancesOptions | undefined): Promise<ListBalancesResponse>;
21
+ }
22
+ export declare function queryBalances(httpClient: HttpClient): QueryBalancesSignature;
23
+ interface QueryBalancesSignature {
24
+ /**
25
+ * Creates a query to retrieve a list of balances.
26
+ *
27
+ * The Query Balances method builds a query to retrieve a list of balances and returns a `BalancesQueryBuilder` object.
28
+ *
29
+ * The returned object contains the query definition, which is used to run the query using the `find()` method.
30
+ *
31
+ * You can refine the query by chaining `BalancesQueryBuilder` methods onto the query. `BalancesQueryBuilder` methods enable you to filter, sort, and control the results that Query Balances returns.
32
+ *
33
+ * Query Balances has a default paging limit of 50, which you can override.
34
+ *
35
+ * For a full description of the item object, see the object returned for the `items` property in `BalancesQueryResult`.
36
+ */
37
+ (): BalancesQueryBuilder;
38
+ }
39
+ export declare function changeBalance(httpClient: HttpClient): ChangeBalanceSignature;
40
+ interface ChangeBalanceSignature {
41
+ /**
42
+ * Changes the number of available credits in a balance.
43
+ *
44
+ * You can adjust or set the number of available credits.
45
+ * @param - ID of the pool associated with the balance to change. This is also the ID of the balance.
46
+ * @param - Unique identifier, generated by the client.
47
+ * Used to recognize repeated attempts to make the same request.
48
+ */
49
+ (poolId: string, idempotencyKey: string, options?: ChangeBalanceOptions | undefined): Promise<ChangeBalanceResponse>;
50
+ }
51
+ export declare function revertBalanceChange(httpClient: HttpClient): RevertBalanceChangeSignature;
52
+ interface RevertBalanceChangeSignature {
53
+ /**
54
+ * Reverts a transaction created by calling Change Balance.
55
+ *
56
+ * For example, if a transaction increased a balance's available credits by 5,
57
+ * calling Revert Balance Change with the transaction's ID will decrease the balance's available credit by 5.
58
+ *
59
+ * > **Note:** If the Change Balance call set the balance, Revert Transaction reverts the amount the balance changed by, ensuring subsequent balance changes are still reflected after the reversion.
60
+ * @param - ID of the transaction associated with the balance change to revert.
61
+ * @param - Unique identifier, generated by the client.
62
+ * Used to recognize repeated attempts to make the same request.
63
+ */
64
+ (transactionId: string, idempotencyKey: string, options?: RevertBalanceChangeOptions | undefined): Promise<RevertBalanceChangeResponse>;
65
+ }
66
+ export { ActionEvent, AdjustOptions, ApplicationError, Balance, BalanceAmount, BalanceChangeBalanceRequest, BalanceChangeBalanceRequestOperationOneOf, BalanceExceededLimits, BalancesQueryBuilder, BalancesQueryResult, BulkActionMetadata, BulkChangeBalanceResult, BulkChangeBalancesRequest, BulkChangeBalancesResponse, ChangeAlreadyReverted, ChangeBalanceOptions, ChangeBalanceOptionsOperationOneOf, ChangeBalanceRequest, ChangeBalanceRequestOperationOneOf, ChangeBalanceRequestType, ChangeBalanceResponse, CommonIdentificationData, CommonIdentificationDataIdOneOf, CursorPaging, CursorPagingMetadata, CursorQuery, CursorQueryPagingMethodOneOf, Cursors, DomainEvent, DomainEventBodyOneOf, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, ExtendedFields, GetBalanceRequest, GetBalanceResponse, GetTransactionReversibilityRequest, GetTransactionReversibilityResponse, IdentificationData, IdentificationDataIdOneOf, IdentityType, Item, ItemMetadata, LimitRule, ListBalancesOptions, ListBalancesRequest, ListBalancesResponse, MessageEnvelope, NotEnoughBalance, PoolInfo, QueryBalancesRequest, QueryBalancesResponse, RestoreInfo, RevertBalanceChangeOptions, RevertBalanceChangeRequest, RevertBalanceChangeResponse, SetInitialOptions, SetOptions, SortOrder, Sorting, TransactionDetails, TransactionReversibility, Type, WebhookIdentityType, } from './benefit-programs-v1-balance-balances.universal.js';
@@ -0,0 +1,29 @@
1
+ import { changeBalance as universalChangeBalance, getBalance as universalGetBalance, listBalances as universalListBalances, queryBalances as universalQueryBalances, revertBalanceChange as universalRevertBalanceChange, } from './benefit-programs-v1-balance-balances.universal.js';
2
+ export const __metadata = { PACKAGE_NAME: '@wix/benefit-programs' };
3
+ export function getBalance(httpClient) {
4
+ return (poolId) => universalGetBalance(poolId,
5
+ // @ts-ignore
6
+ { httpClient });
7
+ }
8
+ export function listBalances(httpClient) {
9
+ return (options) => universalListBalances(options,
10
+ // @ts-ignore
11
+ { httpClient });
12
+ }
13
+ export function queryBalances(httpClient) {
14
+ return () => universalQueryBalances(
15
+ // @ts-ignore
16
+ { httpClient });
17
+ }
18
+ export function changeBalance(httpClient) {
19
+ return (poolId, idempotencyKey, options) => universalChangeBalance(poolId, idempotencyKey, options,
20
+ // @ts-ignore
21
+ { httpClient });
22
+ }
23
+ export function revertBalanceChange(httpClient) {
24
+ return (transactionId, idempotencyKey, options) => universalRevertBalanceChange(transactionId, idempotencyKey, options,
25
+ // @ts-ignore
26
+ { httpClient });
27
+ }
28
+ export { ChangeBalanceRequestType, IdentityType, LimitRule, SortOrder, TransactionReversibility, Type, WebhookIdentityType, } from './benefit-programs-v1-balance-balances.universal.js';
29
+ //# sourceMappingURL=benefit-programs-v1-balance-balances.public.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"benefit-programs-v1-balance-balances.public.js","sourceRoot":"","sources":["../../../../src/benefit-programs-v1-balance-balances.public.ts"],"names":[],"mappings":"AACA,OAAO,EASL,aAAa,IAAI,sBAAsB,EACvC,UAAU,IAAI,mBAAmB,EACjC,YAAY,IAAI,qBAAqB,EACrC,aAAa,IAAI,sBAAsB,EACvC,mBAAmB,IAAI,4BAA4B,GACpD,MAAM,qDAAqD,CAAC;AAE7D,MAAM,CAAC,MAAM,UAAU,GAAG,EAAE,YAAY,EAAE,uBAAuB,EAAE,CAAC;AAEpE,MAAM,UAAU,UAAU,CAAC,UAAsB;IAC/C,OAAO,CAAC,MAAc,EAAE,EAAE,CACxB,mBAAmB,CACjB,MAAM;IACN,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AAWD,MAAM,UAAU,YAAY,CAAC,UAAsB;IACjD,OAAO,CAAC,OAA6B,EAAE,EAAE,CACvC,qBAAqB,CACnB,OAAO;IACP,aAAa;IACb,EAAE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