@wix/auto_sdk_benefit-programs_programs 1.0.0 → 1.0.2
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/src/benefit-programs-v1-program-programs.http.d.ts +18 -24
- package/build/cjs/src/benefit-programs-v1-program-programs.http.js +19 -25
- package/build/cjs/src/benefit-programs-v1-program-programs.http.js.map +1 -1
- package/build/cjs/src/benefit-programs-v1-program-programs.public.d.ts +18 -24
- package/build/cjs/src/benefit-programs-v1-program-programs.public.js.map +1 -1
- package/build/cjs/src/benefit-programs-v1-program-programs.types.d.ts +215 -95
- package/build/cjs/src/benefit-programs-v1-program-programs.types.js +9 -13
- package/build/cjs/src/benefit-programs-v1-program-programs.types.js.map +1 -1
- package/build/cjs/src/benefit-programs-v1-program-programs.universal.d.ts +269 -146
- package/build/cjs/src/benefit-programs-v1-program-programs.universal.js +33 -37
- package/build/cjs/src/benefit-programs-v1-program-programs.universal.js.map +1 -1
- package/build/es/src/benefit-programs-v1-program-programs.http.d.ts +18 -24
- package/build/es/src/benefit-programs-v1-program-programs.http.js +19 -25
- package/build/es/src/benefit-programs-v1-program-programs.http.js.map +1 -1
- package/build/es/src/benefit-programs-v1-program-programs.public.d.ts +18 -24
- package/build/es/src/benefit-programs-v1-program-programs.public.js.map +1 -1
- package/build/es/src/benefit-programs-v1-program-programs.types.d.ts +215 -95
- package/build/es/src/benefit-programs-v1-program-programs.types.js +9 -13
- package/build/es/src/benefit-programs-v1-program-programs.types.js.map +1 -1
- package/build/es/src/benefit-programs-v1-program-programs.universal.d.ts +269 -146
- package/build/es/src/benefit-programs-v1-program-programs.universal.js +33 -37
- package/build/es/src/benefit-programs-v1-program-programs.universal.js.map +1 -1
- package/build/internal/cjs/src/benefit-programs-v1-program-programs.http.d.ts +18 -24
- package/build/internal/cjs/src/benefit-programs-v1-program-programs.http.js +19 -25
- package/build/internal/cjs/src/benefit-programs-v1-program-programs.http.js.map +1 -1
- package/build/internal/cjs/src/benefit-programs-v1-program-programs.public.d.ts +18 -24
- package/build/internal/cjs/src/benefit-programs-v1-program-programs.public.js.map +1 -1
- package/build/internal/cjs/src/benefit-programs-v1-program-programs.types.d.ts +215 -95
- package/build/internal/cjs/src/benefit-programs-v1-program-programs.types.js +9 -13
- package/build/internal/cjs/src/benefit-programs-v1-program-programs.types.js.map +1 -1
- package/build/internal/cjs/src/benefit-programs-v1-program-programs.universal.d.ts +269 -146
- package/build/internal/cjs/src/benefit-programs-v1-program-programs.universal.js +33 -37
- package/build/internal/cjs/src/benefit-programs-v1-program-programs.universal.js.map +1 -1
- package/build/internal/es/src/benefit-programs-v1-program-programs.http.d.ts +18 -24
- package/build/internal/es/src/benefit-programs-v1-program-programs.http.js +19 -25
- package/build/internal/es/src/benefit-programs-v1-program-programs.http.js.map +1 -1
- package/build/internal/es/src/benefit-programs-v1-program-programs.public.d.ts +18 -24
- package/build/internal/es/src/benefit-programs-v1-program-programs.public.js.map +1 -1
- package/build/internal/es/src/benefit-programs-v1-program-programs.types.d.ts +215 -95
- package/build/internal/es/src/benefit-programs-v1-program-programs.types.js +9 -13
- package/build/internal/es/src/benefit-programs-v1-program-programs.types.js.map +1 -1
- package/build/internal/es/src/benefit-programs-v1-program-programs.universal.d.ts +269 -146
- package/build/internal/es/src/benefit-programs-v1-program-programs.universal.js +33 -37
- package/build/internal/es/src/benefit-programs-v1-program-programs.universal.js.map +1 -1
- package/package.json +2 -2
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
export interface Program {
|
|
2
2
|
/**
|
|
3
3
|
* Program ID.
|
|
4
|
+
* @format GUID
|
|
4
5
|
* @readonly
|
|
6
|
+
* @immutable
|
|
5
7
|
*/
|
|
6
8
|
id?: string | null;
|
|
7
9
|
/**
|
|
@@ -23,8 +25,10 @@ export interface Program {
|
|
|
23
25
|
*/
|
|
24
26
|
updatedDate?: Date | null;
|
|
25
27
|
/**
|
|
26
|
-
* ID of program definition
|
|
28
|
+
* ID of the associated program definition.
|
|
29
|
+
* @format GUID
|
|
27
30
|
* @readonly
|
|
31
|
+
* @immutable
|
|
28
32
|
*/
|
|
29
33
|
programDefinitionId?: string | null;
|
|
30
34
|
/**
|
|
@@ -33,78 +37,94 @@ export interface Program {
|
|
|
33
37
|
*/
|
|
34
38
|
status?: ProgramStatus;
|
|
35
39
|
/**
|
|
36
|
-
*
|
|
40
|
+
* Program beneficiary.
|
|
37
41
|
* @readonly
|
|
42
|
+
* @immutable
|
|
38
43
|
*/
|
|
39
44
|
beneficiary?: CommonIdentificationData;
|
|
40
45
|
/**
|
|
41
46
|
* Program name.
|
|
42
47
|
*
|
|
43
|
-
*
|
|
48
|
+
* You may want to use the same name that's used in the associated program definition, if it exists.
|
|
49
|
+
* @maxLength 64
|
|
44
50
|
*/
|
|
45
51
|
displayName?: string | null;
|
|
46
|
-
/**
|
|
52
|
+
/**
|
|
53
|
+
* Namespace for your app or site's benefit programs.
|
|
54
|
+
* @minLength 1
|
|
55
|
+
* @maxLength 50
|
|
56
|
+
* @immutable
|
|
57
|
+
*/
|
|
47
58
|
namespace?: string | null;
|
|
48
59
|
/**
|
|
49
60
|
* Custom field data for the program object.
|
|
50
61
|
*
|
|
51
|
-
* [Extended fields](https://dev.wix.com/docs/
|
|
62
|
+
* [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.
|
|
52
63
|
*/
|
|
53
64
|
extendedFields?: ExtendedFields;
|
|
54
65
|
/**
|
|
55
|
-
*
|
|
56
|
-
*
|
|
57
|
-
*
|
|
66
|
+
* ID for the program defined by you. You can use `externalId` to filter queries.
|
|
67
|
+
* @format GUID
|
|
68
|
+
* @immutable
|
|
58
69
|
*/
|
|
59
70
|
externalId?: string | null;
|
|
60
71
|
/**
|
|
61
|
-
*
|
|
72
|
+
* Associated program definition information.
|
|
62
73
|
* @readonly
|
|
63
74
|
*/
|
|
64
75
|
programDefinition?: ProgramDefinitionInfo;
|
|
65
|
-
/**
|
|
66
|
-
* Intended status of a program after the completion of an action.
|
|
67
|
-
* @readonly
|
|
68
|
-
*/
|
|
69
|
-
targetStatus?: ProgramStatus;
|
|
70
76
|
}
|
|
71
77
|
export declare enum ProgramStatus {
|
|
72
78
|
/** Undefined program status. */
|
|
73
79
|
UNDEFINED = "UNDEFINED",
|
|
74
|
-
/**
|
|
80
|
+
/** Program is active. */
|
|
75
81
|
ACTIVE = "ACTIVE",
|
|
76
|
-
/**
|
|
82
|
+
/** Program is paused. It can be resumed. */
|
|
77
83
|
PAUSED = "PAUSED",
|
|
78
|
-
/**
|
|
79
|
-
* Inactive program.
|
|
80
|
-
*
|
|
81
|
-
* Benefits of a program with an `ENDED` status can't be redeemed or reserved.
|
|
82
|
-
*/
|
|
84
|
+
/** Program has ended. It can't be resumed. */
|
|
83
85
|
ENDED = "ENDED",
|
|
84
|
-
/**
|
|
86
|
+
/** Program is being activated for the first time. This status will be true for a negligible amount of time. */
|
|
85
87
|
PROVISIONING = "PROVISIONING",
|
|
86
|
-
/**
|
|
88
|
+
/** Program is being paused. This status will be true for a negligible amount of time. */
|
|
87
89
|
PAUSING = "PAUSING",
|
|
88
|
-
/**
|
|
90
|
+
/** Program is being re-activated after being paused. This status will be true for a negligible amount of time. */
|
|
89
91
|
RESUMING = "RESUMING",
|
|
90
|
-
/**
|
|
92
|
+
/** Program is being ended. This status will be true for a negligible amount of time. */
|
|
91
93
|
ENDING = "ENDING"
|
|
92
94
|
}
|
|
93
95
|
export interface CommonIdentificationData extends CommonIdentificationDataIdOneOf {
|
|
94
|
-
/**
|
|
96
|
+
/**
|
|
97
|
+
* ID of a site visitor that hasn't logged in to the site.
|
|
98
|
+
* @format GUID
|
|
99
|
+
*/
|
|
95
100
|
anonymousVisitorId?: string;
|
|
96
|
-
/**
|
|
101
|
+
/**
|
|
102
|
+
* ID of a site member.
|
|
103
|
+
* @format GUID
|
|
104
|
+
*/
|
|
97
105
|
memberId?: string;
|
|
98
|
-
/**
|
|
106
|
+
/**
|
|
107
|
+
* ID of a Wix user.
|
|
108
|
+
* @format GUID
|
|
109
|
+
*/
|
|
99
110
|
wixUserId?: string;
|
|
100
111
|
}
|
|
101
112
|
/** @oneof */
|
|
102
113
|
export interface CommonIdentificationDataIdOneOf {
|
|
103
|
-
/**
|
|
114
|
+
/**
|
|
115
|
+
* ID of a site visitor that hasn't logged in to the site.
|
|
116
|
+
* @format GUID
|
|
117
|
+
*/
|
|
104
118
|
anonymousVisitorId?: string;
|
|
105
|
-
/**
|
|
119
|
+
/**
|
|
120
|
+
* ID of a site member.
|
|
121
|
+
* @format GUID
|
|
122
|
+
*/
|
|
106
123
|
memberId?: string;
|
|
107
|
-
/**
|
|
124
|
+
/**
|
|
125
|
+
* ID of a Wix user.
|
|
126
|
+
* @format GUID
|
|
127
|
+
*/
|
|
108
128
|
wixUserId?: string;
|
|
109
129
|
}
|
|
110
130
|
export declare enum IdentityType {
|
|
@@ -130,14 +150,14 @@ export interface ExtendedFields {
|
|
|
130
150
|
}
|
|
131
151
|
export interface ProgramDefinitionInfo {
|
|
132
152
|
/**
|
|
133
|
-
*
|
|
153
|
+
* Program definition ID.
|
|
154
|
+
* @format GUID
|
|
134
155
|
* @readonly
|
|
135
156
|
*/
|
|
136
157
|
id?: string;
|
|
137
158
|
/**
|
|
138
|
-
*
|
|
139
|
-
*
|
|
140
|
-
* This identifies the source program definition in the external system.
|
|
159
|
+
* Program definition external ID.
|
|
160
|
+
* @format GUID
|
|
141
161
|
* @readonly
|
|
142
162
|
*/
|
|
143
163
|
externalId?: string | null;
|
|
@@ -164,91 +184,114 @@ export interface ProgramResumed {
|
|
|
164
184
|
}
|
|
165
185
|
/** In case pool_definition_id is provided should test if it's part of a package. If it is, reject the request */
|
|
166
186
|
export interface ProvisionProgramRequest {
|
|
167
|
-
/**
|
|
168
|
-
* Used to locate the pool definition for creating its benefit pools within the program.
|
|
169
|
-
*
|
|
170
|
-
* This object must contain either `programDefinitionId` or `poolDefinitionId`:
|
|
171
|
-
* + Use `programDefinitionId` for programs with multiple benefit pools.
|
|
172
|
-
* + Use `poolDefinitionId` for a program with just 1 benefit pool.
|
|
173
|
-
*/
|
|
187
|
+
/** The program definition or pool definition to use to provision the program. */
|
|
174
188
|
poolDefinitionLookupId: PoolDefinitionLookupId;
|
|
175
|
-
/**
|
|
176
|
-
* Identity of the individual that enrolled in the program, granting access to its associated benefits.
|
|
177
|
-
*
|
|
178
|
-
* The beneficiary's identity information is in their access token. To retrieve their identity, pass the access token from your frontend site to your backend, then call the Token Info ([SDK](https://dev.wix.com/docs/sdk/core-modules/essentials/auth#gettokeninfo)|[REST](https://dev.wix.com/docs/rest/app-management/oauth-2/token-info)) method. The returned `subjectType` and `subjectId` correspond to the identity type and ID of the beneficiary.
|
|
179
|
-
*/
|
|
189
|
+
/** Program beneficiary. */
|
|
180
190
|
beneficiary: CommonIdentificationData;
|
|
181
191
|
/**
|
|
182
|
-
*
|
|
192
|
+
* Initial program status.
|
|
183
193
|
*
|
|
184
194
|
* Default: `ACTIVE`
|
|
185
195
|
*/
|
|
186
196
|
programStatus?: ProvisionProgramRequestProgramStatus;
|
|
187
197
|
/**
|
|
188
|
-
*
|
|
189
|
-
*
|
|
190
|
-
*
|
|
198
|
+
* Namespace for your app or site's benefit programs.
|
|
199
|
+
* @minLength 1
|
|
200
|
+
* @maxLength 50
|
|
191
201
|
*/
|
|
192
202
|
namespace: string;
|
|
193
203
|
/**
|
|
194
204
|
* Program name.
|
|
195
205
|
*
|
|
196
|
-
*
|
|
206
|
+
* You may want to use the same name that's used in the associated program definition, if it exists.
|
|
207
|
+
* @maxLength 64
|
|
197
208
|
*/
|
|
198
209
|
displayName?: string | null;
|
|
199
210
|
/**
|
|
200
|
-
*
|
|
201
|
-
*
|
|
202
|
-
* Must be unique to every app owner's namespace.
|
|
211
|
+
* ID for the program defined by you. You can use `externalId` to filter queries.
|
|
212
|
+
* @format GUID
|
|
203
213
|
*/
|
|
204
214
|
externalProgramId: string;
|
|
205
215
|
}
|
|
206
216
|
export interface PoolDefinitionLookupId extends PoolDefinitionLookupIdIdOneOf {
|
|
207
|
-
/**
|
|
217
|
+
/**
|
|
218
|
+
* Pool definition ID.
|
|
219
|
+
* @format GUID
|
|
220
|
+
*/
|
|
208
221
|
poolDefinitionId?: string;
|
|
209
|
-
/**
|
|
222
|
+
/**
|
|
223
|
+
* Program definition ID.
|
|
224
|
+
* @format GUID
|
|
225
|
+
*/
|
|
210
226
|
programDefinitionId?: string;
|
|
211
227
|
}
|
|
212
228
|
/** @oneof */
|
|
213
229
|
export interface PoolDefinitionLookupIdIdOneOf {
|
|
214
|
-
/**
|
|
230
|
+
/**
|
|
231
|
+
* Pool definition ID.
|
|
232
|
+
* @format GUID
|
|
233
|
+
*/
|
|
215
234
|
poolDefinitionId?: string;
|
|
216
|
-
/**
|
|
235
|
+
/**
|
|
236
|
+
* Program definition ID.
|
|
237
|
+
* @format GUID
|
|
238
|
+
*/
|
|
217
239
|
programDefinitionId?: string;
|
|
218
240
|
}
|
|
219
241
|
export declare enum ProvisionProgramRequestProgramStatus {
|
|
220
|
-
/**
|
|
242
|
+
/** Program is active. */
|
|
221
243
|
ACTIVE = "ACTIVE",
|
|
222
|
-
/**
|
|
244
|
+
/** Program is paused. */
|
|
223
245
|
PAUSED = "PAUSED"
|
|
224
246
|
}
|
|
225
247
|
export interface ProvisionProgramResponse {
|
|
226
|
-
/**
|
|
248
|
+
/**
|
|
249
|
+
* Job ID of the provisioning of the program.
|
|
250
|
+
* @format GUID
|
|
251
|
+
*/
|
|
227
252
|
jobId?: string;
|
|
228
253
|
/** Provisioned program. */
|
|
229
254
|
program?: Program;
|
|
230
255
|
}
|
|
231
256
|
export interface ProgramAlreadyExists {
|
|
232
|
-
/**
|
|
257
|
+
/**
|
|
258
|
+
* Key of a program that already exists
|
|
259
|
+
* @format GUID
|
|
260
|
+
*/
|
|
233
261
|
externalProgramId?: string;
|
|
234
|
-
/**
|
|
262
|
+
/**
|
|
263
|
+
* Key of a program that already exists
|
|
264
|
+
* @format GUID
|
|
265
|
+
*/
|
|
235
266
|
namespace?: string;
|
|
236
267
|
}
|
|
237
268
|
/** Updates the pool credit amount according to the configuration. */
|
|
238
269
|
export interface RenewProgramRequest {
|
|
239
|
-
/**
|
|
270
|
+
/**
|
|
271
|
+
* ID of the program to renew.
|
|
272
|
+
* @format GUID
|
|
273
|
+
*/
|
|
240
274
|
programId: string;
|
|
241
275
|
}
|
|
242
276
|
export interface RenewProgramResponse {
|
|
243
|
-
/**
|
|
277
|
+
/**
|
|
278
|
+
* Job ID of the program renewal.
|
|
279
|
+
* @format GUID
|
|
280
|
+
*/
|
|
244
281
|
jobId?: string;
|
|
245
282
|
}
|
|
246
283
|
export interface PauseProgramRequest {
|
|
247
|
-
/**
|
|
284
|
+
/**
|
|
285
|
+
* ID of the program to pause.
|
|
286
|
+
* @format GUID
|
|
287
|
+
*/
|
|
248
288
|
programId: string;
|
|
249
289
|
}
|
|
250
290
|
export interface PauseProgramResponse {
|
|
251
|
-
/**
|
|
291
|
+
/**
|
|
292
|
+
* Job ID of the pausing of the program.
|
|
293
|
+
* @format GUID
|
|
294
|
+
*/
|
|
252
295
|
jobId?: string;
|
|
253
296
|
}
|
|
254
297
|
export interface ProgramStatusTransitionNotAllowed {
|
|
@@ -258,23 +301,38 @@ export interface ProgramStatusTransitionNotAllowed {
|
|
|
258
301
|
requestedStatus?: ProgramStatus;
|
|
259
302
|
}
|
|
260
303
|
export interface ResumeProgramRequest {
|
|
261
|
-
/**
|
|
304
|
+
/**
|
|
305
|
+
* ID of program to resume.
|
|
306
|
+
* @format GUID
|
|
307
|
+
*/
|
|
262
308
|
programId: string;
|
|
263
309
|
}
|
|
264
310
|
export interface ResumeProgramResponse {
|
|
265
|
-
/**
|
|
311
|
+
/**
|
|
312
|
+
* Job ID of the resuming of the program.
|
|
313
|
+
* @format GUID
|
|
314
|
+
*/
|
|
266
315
|
jobId?: string;
|
|
267
316
|
}
|
|
268
317
|
export interface EndProgramRequest {
|
|
269
|
-
/**
|
|
318
|
+
/**
|
|
319
|
+
* ID of the program to end.
|
|
320
|
+
* @format GUID
|
|
321
|
+
*/
|
|
270
322
|
programId: string;
|
|
271
323
|
}
|
|
272
324
|
export interface EndProgramResponse {
|
|
273
|
-
/**
|
|
325
|
+
/**
|
|
326
|
+
* Job ID of the ending of the program.
|
|
327
|
+
* @format GUID
|
|
328
|
+
*/
|
|
274
329
|
jobId?: string;
|
|
275
330
|
}
|
|
276
331
|
export interface UpdateProgramStatusRequest {
|
|
277
|
-
/**
|
|
332
|
+
/**
|
|
333
|
+
* Program to update
|
|
334
|
+
* @format GUID
|
|
335
|
+
*/
|
|
278
336
|
programId?: string;
|
|
279
337
|
/** Program revision */
|
|
280
338
|
programRevision?: string;
|
|
@@ -288,15 +346,27 @@ export interface UpdateProgramStatusResponse {
|
|
|
288
346
|
program?: Program;
|
|
289
347
|
}
|
|
290
348
|
export interface UpsertMigratedProgramRequest {
|
|
291
|
-
/**
|
|
349
|
+
/**
|
|
350
|
+
* Order id
|
|
351
|
+
* @format GUID
|
|
352
|
+
*/
|
|
292
353
|
orderId?: string;
|
|
293
|
-
/**
|
|
354
|
+
/**
|
|
355
|
+
* Plan id
|
|
356
|
+
* @format GUID
|
|
357
|
+
*/
|
|
294
358
|
planId?: string;
|
|
295
|
-
/**
|
|
359
|
+
/**
|
|
360
|
+
* Order member id
|
|
361
|
+
* @format GUID
|
|
362
|
+
*/
|
|
296
363
|
memberId?: string;
|
|
297
364
|
/** Order status */
|
|
298
365
|
status?: OrderStatus;
|
|
299
|
-
/**
|
|
366
|
+
/**
|
|
367
|
+
* Plan name
|
|
368
|
+
* @maxLength 64
|
|
369
|
+
*/
|
|
300
370
|
planName?: string;
|
|
301
371
|
}
|
|
302
372
|
export declare enum OrderStatus {
|
|
@@ -310,7 +380,7 @@ export interface UpsertMigratedProgramResponse {
|
|
|
310
380
|
program?: Program;
|
|
311
381
|
}
|
|
312
382
|
export interface UpdateProgramRequest {
|
|
313
|
-
/** Program to
|
|
383
|
+
/** Program to update. */
|
|
314
384
|
program: Program;
|
|
315
385
|
}
|
|
316
386
|
export interface UpdateProgramResponse {
|
|
@@ -318,7 +388,10 @@ export interface UpdateProgramResponse {
|
|
|
318
388
|
program?: Program;
|
|
319
389
|
}
|
|
320
390
|
export interface GetProgramRequest {
|
|
321
|
-
/**
|
|
391
|
+
/**
|
|
392
|
+
* ID of the program to retrieve.
|
|
393
|
+
* @format GUID
|
|
394
|
+
*/
|
|
322
395
|
programId: string;
|
|
323
396
|
}
|
|
324
397
|
export interface GetProgramResponse {
|
|
@@ -326,7 +399,7 @@ export interface GetProgramResponse {
|
|
|
326
399
|
program?: Program;
|
|
327
400
|
}
|
|
328
401
|
export interface QueryProgramsRequest {
|
|
329
|
-
/**
|
|
402
|
+
/** Filter, sort, and paging to apply to the query. */
|
|
330
403
|
query?: CursorQuery;
|
|
331
404
|
}
|
|
332
405
|
export interface CursorQuery extends CursorQueryPagingMethodOneOf {
|
|
@@ -344,6 +417,7 @@ export interface CursorQuery extends CursorQueryPagingMethodOneOf {
|
|
|
344
417
|
/**
|
|
345
418
|
* Sort object in the following format:
|
|
346
419
|
* `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]`
|
|
420
|
+
* @maxSize 5
|
|
347
421
|
*/
|
|
348
422
|
sort?: Sorting[];
|
|
349
423
|
}
|
|
@@ -353,7 +427,10 @@ export interface CursorQueryPagingMethodOneOf {
|
|
|
353
427
|
cursorPaging?: CursorPaging;
|
|
354
428
|
}
|
|
355
429
|
export interface Sorting {
|
|
356
|
-
/**
|
|
430
|
+
/**
|
|
431
|
+
* Name of the field to sort by.
|
|
432
|
+
* @maxLength 512
|
|
433
|
+
*/
|
|
357
434
|
fieldName?: string;
|
|
358
435
|
/** Sort order. */
|
|
359
436
|
order?: SortOrder;
|
|
@@ -365,18 +442,22 @@ export declare enum SortOrder {
|
|
|
365
442
|
DESC = "DESC"
|
|
366
443
|
}
|
|
367
444
|
export interface CursorPaging {
|
|
368
|
-
/**
|
|
445
|
+
/**
|
|
446
|
+
* Maximum number of items to return in the results.
|
|
447
|
+
* @max 100
|
|
448
|
+
*/
|
|
369
449
|
limit?: number | null;
|
|
370
450
|
/**
|
|
371
451
|
* Pointer to the next or previous page in the list of results.
|
|
372
452
|
*
|
|
373
453
|
* Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.
|
|
374
454
|
* Not relevant for the first request.
|
|
455
|
+
* @maxLength 16000
|
|
375
456
|
*/
|
|
376
457
|
cursor?: string | null;
|
|
377
458
|
}
|
|
378
459
|
export interface QueryProgramsResponse {
|
|
379
|
-
/** List of programs. */
|
|
460
|
+
/** List of retrieved programs. */
|
|
380
461
|
programs?: Program[];
|
|
381
462
|
/** Metadata for the paginated results. */
|
|
382
463
|
metadata?: CursorPagingMetadata;
|
|
@@ -395,9 +476,15 @@ export interface CursorPagingMetadata {
|
|
|
395
476
|
hasNext?: boolean | null;
|
|
396
477
|
}
|
|
397
478
|
export interface Cursors {
|
|
398
|
-
/**
|
|
479
|
+
/**
|
|
480
|
+
* Cursor string pointing to the next page in the list of results.
|
|
481
|
+
* @maxLength 16000
|
|
482
|
+
*/
|
|
399
483
|
next?: string | null;
|
|
400
|
-
/**
|
|
484
|
+
/**
|
|
485
|
+
* Cursor pointing to the previous page in the list of results.
|
|
486
|
+
* @maxLength 16000
|
|
487
|
+
*/
|
|
401
488
|
prev?: string | null;
|
|
402
489
|
}
|
|
403
490
|
export interface GetProgramByExternalIdAndNamespaceRequest {
|
|
@@ -405,12 +492,15 @@ export interface GetProgramByExternalIdAndNamespaceRequest {
|
|
|
405
492
|
* Application sub-module that is the source of the program creation.
|
|
406
493
|
*
|
|
407
494
|
* Use the namespace that was designated to the program definition.
|
|
495
|
+
* @minLength 1
|
|
496
|
+
* @maxLength 50
|
|
408
497
|
*/
|
|
409
498
|
namespace: string;
|
|
410
499
|
/**
|
|
411
500
|
* External program ID.
|
|
412
501
|
*
|
|
413
502
|
* Must be unique to every app's namespace.
|
|
503
|
+
* @format GUID
|
|
414
504
|
*/
|
|
415
505
|
externalId: string;
|
|
416
506
|
}
|
|
@@ -491,9 +581,15 @@ export interface ActionEvent {
|
|
|
491
581
|
bodyAsJson?: string;
|
|
492
582
|
}
|
|
493
583
|
export interface MessageEnvelope {
|
|
494
|
-
/**
|
|
584
|
+
/**
|
|
585
|
+
* App instance ID.
|
|
586
|
+
* @format GUID
|
|
587
|
+
*/
|
|
495
588
|
instanceId?: string | null;
|
|
496
|
-
/**
|
|
589
|
+
/**
|
|
590
|
+
* Event type.
|
|
591
|
+
* @maxLength 150
|
|
592
|
+
*/
|
|
497
593
|
eventType?: string;
|
|
498
594
|
/** The identification type and identity data. */
|
|
499
595
|
identity?: IdentificationData;
|
|
@@ -501,26 +597,50 @@ export interface MessageEnvelope {
|
|
|
501
597
|
data?: string;
|
|
502
598
|
}
|
|
503
599
|
export interface IdentificationData extends IdentificationDataIdOneOf {
|
|
504
|
-
/**
|
|
600
|
+
/**
|
|
601
|
+
* ID of a site visitor that has not logged in to the site.
|
|
602
|
+
* @format GUID
|
|
603
|
+
*/
|
|
505
604
|
anonymousVisitorId?: string;
|
|
506
|
-
/**
|
|
605
|
+
/**
|
|
606
|
+
* ID of a site visitor that has logged in to the site.
|
|
607
|
+
* @format GUID
|
|
608
|
+
*/
|
|
507
609
|
memberId?: string;
|
|
508
|
-
/**
|
|
610
|
+
/**
|
|
611
|
+
* ID of a Wix user (site owner, contributor, etc.).
|
|
612
|
+
* @format GUID
|
|
613
|
+
*/
|
|
509
614
|
wixUserId?: string;
|
|
510
|
-
/**
|
|
615
|
+
/**
|
|
616
|
+
* ID of an app.
|
|
617
|
+
* @format GUID
|
|
618
|
+
*/
|
|
511
619
|
appId?: string;
|
|
512
620
|
/** @readonly */
|
|
513
621
|
identityType?: WebhookIdentityType;
|
|
514
622
|
}
|
|
515
623
|
/** @oneof */
|
|
516
624
|
export interface IdentificationDataIdOneOf {
|
|
517
|
-
/**
|
|
625
|
+
/**
|
|
626
|
+
* ID of a site visitor that has not logged in to the site.
|
|
627
|
+
* @format GUID
|
|
628
|
+
*/
|
|
518
629
|
anonymousVisitorId?: string;
|
|
519
|
-
/**
|
|
630
|
+
/**
|
|
631
|
+
* ID of a site visitor that has logged in to the site.
|
|
632
|
+
* @format GUID
|
|
633
|
+
*/
|
|
520
634
|
memberId?: string;
|
|
521
|
-
/**
|
|
635
|
+
/**
|
|
636
|
+
* ID of a Wix user (site owner, contributor, etc.).
|
|
637
|
+
* @format GUID
|
|
638
|
+
*/
|
|
522
639
|
wixUserId?: string;
|
|
523
|
-
/**
|
|
640
|
+
/**
|
|
641
|
+
* ID of an app.
|
|
642
|
+
* @format GUID
|
|
643
|
+
*/
|
|
524
644
|
appId?: string;
|
|
525
645
|
}
|
|
526
646
|
export declare enum WebhookIdentityType {
|
|
@@ -2,23 +2,19 @@ export var ProgramStatus;
|
|
|
2
2
|
(function (ProgramStatus) {
|
|
3
3
|
/** Undefined program status. */
|
|
4
4
|
ProgramStatus["UNDEFINED"] = "UNDEFINED";
|
|
5
|
-
/**
|
|
5
|
+
/** Program is active. */
|
|
6
6
|
ProgramStatus["ACTIVE"] = "ACTIVE";
|
|
7
|
-
/**
|
|
7
|
+
/** Program is paused. It can be resumed. */
|
|
8
8
|
ProgramStatus["PAUSED"] = "PAUSED";
|
|
9
|
-
/**
|
|
10
|
-
* Inactive program.
|
|
11
|
-
*
|
|
12
|
-
* Benefits of a program with an `ENDED` status can't be redeemed or reserved.
|
|
13
|
-
*/
|
|
9
|
+
/** Program has ended. It can't be resumed. */
|
|
14
10
|
ProgramStatus["ENDED"] = "ENDED";
|
|
15
|
-
/**
|
|
11
|
+
/** Program is being activated for the first time. This status will be true for a negligible amount of time. */
|
|
16
12
|
ProgramStatus["PROVISIONING"] = "PROVISIONING";
|
|
17
|
-
/**
|
|
13
|
+
/** Program is being paused. This status will be true for a negligible amount of time. */
|
|
18
14
|
ProgramStatus["PAUSING"] = "PAUSING";
|
|
19
|
-
/**
|
|
15
|
+
/** Program is being re-activated after being paused. This status will be true for a negligible amount of time. */
|
|
20
16
|
ProgramStatus["RESUMING"] = "RESUMING";
|
|
21
|
-
/**
|
|
17
|
+
/** Program is being ended. This status will be true for a negligible amount of time. */
|
|
22
18
|
ProgramStatus["ENDING"] = "ENDING";
|
|
23
19
|
})(ProgramStatus || (ProgramStatus = {}));
|
|
24
20
|
export var IdentityType;
|
|
@@ -34,9 +30,9 @@ export var IdentityType;
|
|
|
34
30
|
})(IdentityType || (IdentityType = {}));
|
|
35
31
|
export var ProvisionProgramRequestProgramStatus;
|
|
36
32
|
(function (ProvisionProgramRequestProgramStatus) {
|
|
37
|
-
/**
|
|
33
|
+
/** Program is active. */
|
|
38
34
|
ProvisionProgramRequestProgramStatus["ACTIVE"] = "ACTIVE";
|
|
39
|
-
/**
|
|
35
|
+
/** Program is paused. */
|
|
40
36
|
ProvisionProgramRequestProgramStatus["PAUSED"] = "PAUSED";
|
|
41
37
|
})(ProvisionProgramRequestProgramStatus || (ProvisionProgramRequestProgramStatus = {}));
|
|
42
38
|
export var OrderStatus;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"benefit-programs-v1-program-programs.types.js","sourceRoot":"","sources":["../../../src/benefit-programs-v1-program-programs.types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"benefit-programs-v1-program-programs.types.js","sourceRoot":"","sources":["../../../src/benefit-programs-v1-program-programs.types.ts"],"names":[],"mappings":"AA6EA,MAAM,CAAN,IAAY,aAiBX;AAjBD,WAAY,aAAa;IACvB,gCAAgC;IAChC,wCAAuB,CAAA;IACvB,yBAAyB;IACzB,kCAAiB,CAAA;IACjB,4CAA4C;IAC5C,kCAAiB,CAAA;IACjB,8CAA8C;IAC9C,gCAAe,CAAA;IACf,+GAA+G;IAC/G,8CAA6B,CAAA;IAC7B,yFAAyF;IACzF,oCAAmB,CAAA;IACnB,kHAAkH;IAClH,sCAAqB,CAAA;IACrB,wFAAwF;IACxF,kCAAiB,CAAA;AACnB,CAAC,EAjBW,aAAa,KAAb,aAAa,QAiBxB;AAwCD,MAAM,CAAN,IAAY,YASX;AATD,WAAY,YAAY;IACtB,4CAA4C;IAC5C,mCAAmB,CAAA;IACnB,4CAA4C;IAC5C,uDAAuC,CAAA;IACvC,+BAA+B;IAC/B,iCAAiB,CAAA;IACjB,iEAAiE;IACjE,qCAAqB,CAAA;AACvB,CAAC,EATW,YAAY,KAAZ,YAAY,QASvB;AAiHD,MAAM,CAAN,IAAY,oCAKX;AALD,WAAY,oCAAoC;IAC9C,yBAAyB;IACzB,yDAAiB,CAAA;IACjB,yBAAyB;IACzB,yDAAiB,CAAA;AACnB,CAAC,EALW,oCAAoC,KAApC,oCAAoC,QAK/C;AA6ID,MAAM,CAAN,IAAY,WAKX;AALD,WAAY,WAAW;IACrB,kCAAmB,CAAA;IACnB,gCAAiB,CAAA;IACjB,gCAAiB,CAAA;IACjB,8BAAe,CAAA;AACjB,CAAC,EALW,WAAW,KAAX,WAAW,QAKtB;AAuED,MAAM,CAAN,IAAY,SAKX;AALD,WAAY,SAAS;IACnB,4BAA4B;IAC5B,wBAAW,CAAA;IACX,6BAA6B;IAC7B,0BAAa,CAAA;AACf,CAAC,EALW,SAAS,KAAT,SAAS,QAKpB;AA4ND,MAAM,CAAN,IAAY,mBAMX;AAND,WAAY,mBAAmB;IAC7B,0CAAmB,CAAA;IACnB,8DAAuC,CAAA;IACvC,wCAAiB,CAAA;IACjB,4CAAqB,CAAA;IACrB,kCAAW,CAAA;AACb,CAAC,EANW,mBAAmB,KAAnB,mBAAmB,QAM9B"}
|