@wix/auto_sdk_benefit-programs_programs 1.0.1 → 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 +39 -66
- 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 +69 -117
- package/build/cjs/src/benefit-programs-v1-program-programs.universal.js +27 -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 +39 -66
- 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 +69 -117
- package/build/es/src/benefit-programs-v1-program-programs.universal.js +27 -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 +39 -66
- 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 +69 -117
- package/build/internal/cjs/src/benefit-programs-v1-program-programs.universal.js +27 -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 +39 -66
- 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 +69 -117
- package/build/internal/es/src/benefit-programs-v1-program-programs.universal.js +27 -37
- package/build/internal/es/src/benefit-programs-v1-program-programs.universal.js.map +1 -1
- package/package.json +2 -2
|
@@ -1,31 +1,23 @@
|
|
|
1
1
|
import { RequestOptionsFactory } from '@wix/sdk-types';
|
|
2
|
-
/** Creates active programs consisting of benefits derived from their underlying program definitions and pool definitions. */
|
|
3
|
-
export declare function provisionProgram(payload: object): RequestOptionsFactory<any>;
|
|
4
2
|
/**
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* Adjusts each pool in the program according to its unique credit configuration as specified in the pool definition.
|
|
3
|
+
* Creates a program for the specified beneficiary. Creating a program is also referred to as provisioning a program.
|
|
8
4
|
*
|
|
9
|
-
*
|
|
5
|
+
* You can provision a program from a program definition or a pool definition:
|
|
6
|
+
* - **Program definition**: The program has associated pools that are created from the pool definitions associated with the program definition.
|
|
7
|
+
* - **Pool definition**: The program has 1 associated pool that is created from the pool definition.
|
|
10
8
|
*/
|
|
11
|
-
export declare function
|
|
9
|
+
export declare function provisionProgram(payload: object): RequestOptionsFactory<any>;
|
|
12
10
|
/**
|
|
13
|
-
*
|
|
11
|
+
* Renews the specified program.
|
|
14
12
|
*
|
|
15
|
-
*
|
|
13
|
+
* Balances are handled for each pool in the program as defined in the pool's credit configuration.
|
|
16
14
|
*/
|
|
15
|
+
export declare function renewProgram(payload: object): RequestOptionsFactory<any>;
|
|
16
|
+
/** Pauses the specified program. Benefits in the program's pools can't be redeemed until the program is resumed. */
|
|
17
17
|
export declare function pauseProgram(payload: object): RequestOptionsFactory<any>;
|
|
18
|
-
/**
|
|
19
|
-
* Resumes the benefit pools within a program.
|
|
20
|
-
*
|
|
21
|
-
* Changes the program status to `ACTIVE`, allowing the redemption or reservation of benefits to continue.
|
|
22
|
-
*/
|
|
18
|
+
/** Resumes the specified program. Call this method for paused programs. */
|
|
23
19
|
export declare function resumeProgram(payload: object): RequestOptionsFactory<any>;
|
|
24
|
-
/**
|
|
25
|
-
* Prevents the benefit pools in the provided package from being redeemed or reserved.
|
|
26
|
-
*
|
|
27
|
-
* After ending a program, it can't be restarted.
|
|
28
|
-
*/
|
|
20
|
+
/** Ends the specified program. Benefits in the program's pools can't be redeemed until the program is resumed. */
|
|
29
21
|
export declare function endProgram(payload: object): RequestOptionsFactory<any>;
|
|
30
22
|
/**
|
|
31
23
|
* Updates a program.
|
|
@@ -42,14 +34,16 @@ export declare function getProgram(payload: object): RequestOptionsFactory<any>;
|
|
|
42
34
|
/**
|
|
43
35
|
* Creates a query to retrieve a list of programs.
|
|
44
36
|
*
|
|
45
|
-
* The
|
|
37
|
+
* The Query Programs method builds a query to retrieve a list of programs and returns a `ProgramsQueryBuilder` object.
|
|
38
|
+
*
|
|
39
|
+
* The returned object contains the query definition, which is used to run the query using the `find()` method.
|
|
46
40
|
*
|
|
47
|
-
*
|
|
41
|
+
* You can refine the query by chaining `ProgramsQueryBuilder` methods onto the query. `ProgramsQueryBuilder` methods enable you to filter, sort, and control the results that Query Programs returns.
|
|
48
42
|
*
|
|
49
|
-
*
|
|
43
|
+
* Query Programs has a default paging limit of 50, which you can override.
|
|
50
44
|
*
|
|
51
|
-
*
|
|
45
|
+
* For a full description of the item object, see the object returned for the `items` property in `ProgramsQueryResult`.
|
|
52
46
|
*/
|
|
53
47
|
export declare function queryPrograms(payload: object): RequestOptionsFactory<any>;
|
|
54
|
-
/** Retrieves a program
|
|
48
|
+
/** Retrieves a program with the specified external ID and namespace. */
|
|
55
49
|
export declare function getProgramByExternalIdAndNamespace(payload: object): RequestOptionsFactory<any>;
|
|
@@ -111,7 +111,13 @@ function resolveWixBenefitProgramsV1ProgramProgramServiceUrl(opts) {
|
|
|
111
111
|
return (0, rest_modules_2.resolveUrl)(Object.assign(opts, { domainToMappings }));
|
|
112
112
|
}
|
|
113
113
|
const PACKAGE_NAME = '@wix/auto_sdk_benefit-programs_programs';
|
|
114
|
-
/**
|
|
114
|
+
/**
|
|
115
|
+
* Creates a program for the specified beneficiary. Creating a program is also referred to as provisioning a program.
|
|
116
|
+
*
|
|
117
|
+
* You can provision a program from a program definition or a pool definition:
|
|
118
|
+
* - **Program definition**: The program has associated pools that are created from the pool definitions associated with the program definition.
|
|
119
|
+
* - **Pool definition**: The program has 1 associated pool that is created from the pool definition.
|
|
120
|
+
*/
|
|
115
121
|
function provisionProgram(payload) {
|
|
116
122
|
function __provisionProgram({ host }) {
|
|
117
123
|
const metadata = {
|
|
@@ -141,11 +147,9 @@ function provisionProgram(payload) {
|
|
|
141
147
|
}
|
|
142
148
|
exports.provisionProgram = provisionProgram;
|
|
143
149
|
/**
|
|
144
|
-
*
|
|
145
|
-
*
|
|
146
|
-
* Adjusts each pool in the program according to its unique credit configuration as specified in the pool definition.
|
|
150
|
+
* Renews the specified program.
|
|
147
151
|
*
|
|
148
|
-
*
|
|
152
|
+
* Balances are handled for each pool in the program as defined in the pool's credit configuration.
|
|
149
153
|
*/
|
|
150
154
|
function renewProgram(payload) {
|
|
151
155
|
function __renewProgram({ host }) {
|
|
@@ -166,11 +170,7 @@ function renewProgram(payload) {
|
|
|
166
170
|
return __renewProgram;
|
|
167
171
|
}
|
|
168
172
|
exports.renewProgram = renewProgram;
|
|
169
|
-
/**
|
|
170
|
-
* Pauses the benefit pools within a program.
|
|
171
|
-
*
|
|
172
|
-
* Changes the program status to `PAUSED`, preventing the redemption or reservation of benefits.
|
|
173
|
-
*/
|
|
173
|
+
/** Pauses the specified program. Benefits in the program's pools can't be redeemed until the program is resumed. */
|
|
174
174
|
function pauseProgram(payload) {
|
|
175
175
|
function __pauseProgram({ host }) {
|
|
176
176
|
const metadata = {
|
|
@@ -190,11 +190,7 @@ function pauseProgram(payload) {
|
|
|
190
190
|
return __pauseProgram;
|
|
191
191
|
}
|
|
192
192
|
exports.pauseProgram = pauseProgram;
|
|
193
|
-
/**
|
|
194
|
-
* Resumes the benefit pools within a program.
|
|
195
|
-
*
|
|
196
|
-
* Changes the program status to `ACTIVE`, allowing the redemption or reservation of benefits to continue.
|
|
197
|
-
*/
|
|
193
|
+
/** Resumes the specified program. Call this method for paused programs. */
|
|
198
194
|
function resumeProgram(payload) {
|
|
199
195
|
function __resumeProgram({ host }) {
|
|
200
196
|
const metadata = {
|
|
@@ -214,11 +210,7 @@ function resumeProgram(payload) {
|
|
|
214
210
|
return __resumeProgram;
|
|
215
211
|
}
|
|
216
212
|
exports.resumeProgram = resumeProgram;
|
|
217
|
-
/**
|
|
218
|
-
* Prevents the benefit pools in the provided package from being redeemed or reserved.
|
|
219
|
-
*
|
|
220
|
-
* After ending a program, it can't be restarted.
|
|
221
|
-
*/
|
|
213
|
+
/** Ends the specified program. Benefits in the program's pools can't be redeemed until the program is resumed. */
|
|
222
214
|
function endProgram(payload) {
|
|
223
215
|
function __endProgram({ host }) {
|
|
224
216
|
const metadata = {
|
|
@@ -320,13 +312,15 @@ exports.getProgram = getProgram;
|
|
|
320
312
|
/**
|
|
321
313
|
* Creates a query to retrieve a list of programs.
|
|
322
314
|
*
|
|
323
|
-
* The
|
|
315
|
+
* The Query Programs method builds a query to retrieve a list of programs and returns a `ProgramsQueryBuilder` object.
|
|
316
|
+
*
|
|
317
|
+
* The returned object contains the query definition, which is used to run the query using the `find()` method.
|
|
324
318
|
*
|
|
325
|
-
*
|
|
319
|
+
* You can refine the query by chaining `ProgramsQueryBuilder` methods onto the query. `ProgramsQueryBuilder` methods enable you to filter, sort, and control the results that Query Programs returns.
|
|
326
320
|
*
|
|
327
|
-
*
|
|
321
|
+
* Query Programs has a default paging limit of 50, which you can override.
|
|
328
322
|
*
|
|
329
|
-
*
|
|
323
|
+
* For a full description of the item object, see the object returned for the `items` property in `ProgramsQueryResult`.
|
|
330
324
|
*/
|
|
331
325
|
function queryPrograms(payload) {
|
|
332
326
|
function __queryPrograms({ host }) {
|
|
@@ -356,7 +350,7 @@ function queryPrograms(payload) {
|
|
|
356
350
|
return __queryPrograms;
|
|
357
351
|
}
|
|
358
352
|
exports.queryPrograms = queryPrograms;
|
|
359
|
-
/** Retrieves a program
|
|
353
|
+
/** Retrieves a program with the specified external ID and namespace. */
|
|
360
354
|
function getProgramByExternalIdAndNamespace(payload) {
|
|
361
355
|
function __getProgramByExternalIdAndNamespace({ host }) {
|
|
362
356
|
const metadata = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"benefit-programs-v1-program-programs.http.js","sourceRoot":"","sources":["../../../src/benefit-programs-v1-program-programs.http.ts"],"names":[],"mappings":";;;AAAA,gEAAkE;AAClE,0EAAkG;AAClG,0EAAkG;AAClG,4EAAmG;AACnG,sFAAkF;AAClF,gEAA2D;AAI3D,SAAS,mDAAmD,CAC1D,IAA8C;IAE9C,MAAM,gBAAgB,GAAG;QACvB,uBAAu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,QAAQ,EAAE,EAAE;aACb;YACD;gBACE,OAAO,EAAE,oCAAoC;gBAC7C,QAAQ,EAAE,cAAc;aACzB;SACF;QACD,iBAAiB,EAAE;YACjB;gBACE,OAAO,EAAE,iCAAiC;gBAC1C,QAAQ,EAAE,EAAE;aACb;YACD;gBACE,OAAO,EAAE,oCAAoC;gBAC7C,QAAQ,EAAE,cAAc;aACzB;SACF;KACF,CAAC;IAEF,OAAO,IAAA,yBAAU,EAAC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,EAAE,gBAAgB,EAAE,CAAC,CAAC,CAAC;AAC/D,CAAC;AAED,MAAM,YAAY,GAAG,yCAAyC,CAAC;AAE/D
|
|
1
|
+
{"version":3,"file":"benefit-programs-v1-program-programs.http.js","sourceRoot":"","sources":["../../../src/benefit-programs-v1-program-programs.http.ts"],"names":[],"mappings":";;;AAAA,gEAAkE;AAClE,0EAAkG;AAClG,0EAAkG;AAClG,4EAAmG;AACnG,sFAAkF;AAClF,gEAA2D;AAI3D,SAAS,mDAAmD,CAC1D,IAA8C;IAE9C,MAAM,gBAAgB,GAAG;QACvB,uBAAuB,EAAE;YACvB;gBACE,OAAO,EAAE,WAAW;gBACpB,QAAQ,EAAE,EAAE;aACb;SACF;QACD,oBAAoB,EAAE;YACpB;gBACE,OAAO,EAAE,iCAAiC;gBAC1C,QAAQ,EAAE,EAAE;aACb;YACD;gBACE,OAAO,EAAE,oCAAoC;gBAC7C,QAAQ,EAAE,cAAc;aACzB;SACF;QACD,oBAAoB,EAAE;YACpB;gBACE,OAAO,EAAE,iCAAiC;gBAC1C,QAAQ,EAAE,EAAE;aACb;SACF;QACD,CAAC,EAAE;YACD;gBACE,OAAO,EAAE,iCAAiC;gBAC1C,QAAQ,EAAE,EAAE;aACb;SACF;QACD,sBAAsB,EAAE;YACtB;gBACE,OAAO,EAAE,iCAAiC;gBAC1C,QAAQ,EAAE,EAAE;aACb;YACD;gBACE,OAAO,EAAE,oCAAoC;gBAC7C,QAAQ,EA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SAAS,EACP,mFAAmF;YACrF,WAAW,EAAE,YAAY;YACzB,GAAG,EAAE,mDAAmD,CAAC;gBACvD,SAAS,EAAE,2CAA2C;gBACtD,IAAI,EAAE,OAAO;gBACb,IAAI;aACL,CAAC;YACF,MAAM,EAAE,IAAA,gCAAiB,EAAC,OAAO,CAAC;YAClC,iBAAiB,EAAE,CAAC,OAAY,EAAE,EAAE,CAClC,IAAA,gCAAc,EAAC,OAAO,EAAE;gBACtB;oBACE,WAAW,EAAE,gDAAoC;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,oCAAoC,CAAC;AAC9C,CAAC;AAhCD,gFAgCC"}
|
|
@@ -6,23 +6,21 @@ export declare const __metadata: {
|
|
|
6
6
|
export declare function provisionProgram(httpClient: HttpClient): ProvisionProgramSignature;
|
|
7
7
|
interface ProvisionProgramSignature {
|
|
8
8
|
/**
|
|
9
|
-
* Creates
|
|
10
|
-
* @param - Used to locate the pool definition for creating its benefit pools within the program.
|
|
9
|
+
* Creates a program for the specified beneficiary. Creating a program is also referred to as provisioning a program.
|
|
11
10
|
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
11
|
+
* You can provision a program from a program definition or a pool definition:
|
|
12
|
+
* - **Program definition**: The program has associated pools that are created from the pool definitions associated with the program definition.
|
|
13
|
+
* - **Pool definition**: The program has 1 associated pool that is created from the pool definition.
|
|
14
|
+
* @param - The program definition or pool definition to use to provision the program.
|
|
15
15
|
*/
|
|
16
16
|
(poolDefinitionLookupId: PoolDefinitionLookupId, options?: ProvisionProgramOptions | undefined): Promise<ProvisionProgramResponse & ProvisionProgramResponseNonNullableFields>;
|
|
17
17
|
}
|
|
18
18
|
export declare function renewProgram(httpClient: HttpClient): RenewProgramSignature;
|
|
19
19
|
interface RenewProgramSignature {
|
|
20
20
|
/**
|
|
21
|
-
*
|
|
21
|
+
* Renews the specified program.
|
|
22
22
|
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
* Use this method to reset each benefit pool renewal cycle.
|
|
23
|
+
* Balances are handled for each pool in the program as defined in the pool's credit configuration.
|
|
26
24
|
* @param - ID of the program to renew.
|
|
27
25
|
*/
|
|
28
26
|
(programId: string): Promise<RenewProgramResponse & RenewProgramResponseNonNullableFields>;
|
|
@@ -30,9 +28,7 @@ interface RenewProgramSignature {
|
|
|
30
28
|
export declare function pauseProgram(httpClient: HttpClient): PauseProgramSignature;
|
|
31
29
|
interface PauseProgramSignature {
|
|
32
30
|
/**
|
|
33
|
-
* Pauses the
|
|
34
|
-
*
|
|
35
|
-
* Changes the program status to `PAUSED`, preventing the redemption or reservation of benefits.
|
|
31
|
+
* Pauses the specified program. Benefits in the program's pools can't be redeemed until the program is resumed.
|
|
36
32
|
* @param - ID of the program to pause.
|
|
37
33
|
*/
|
|
38
34
|
(programId: string): Promise<PauseProgramResponse & PauseProgramResponseNonNullableFields>;
|
|
@@ -40,9 +36,7 @@ interface PauseProgramSignature {
|
|
|
40
36
|
export declare function resumeProgram(httpClient: HttpClient): ResumeProgramSignature;
|
|
41
37
|
interface ResumeProgramSignature {
|
|
42
38
|
/**
|
|
43
|
-
* Resumes the
|
|
44
|
-
*
|
|
45
|
-
* Changes the program status to `ACTIVE`, allowing the redemption or reservation of benefits to continue.
|
|
39
|
+
* Resumes the specified program. Call this method for paused programs.
|
|
46
40
|
* @param - ID of program to resume.
|
|
47
41
|
*/
|
|
48
42
|
(programId: string): Promise<ResumeProgramResponse & ResumeProgramResponseNonNullableFields>;
|
|
@@ -50,10 +44,8 @@ interface ResumeProgramSignature {
|
|
|
50
44
|
export declare function endProgram(httpClient: HttpClient): EndProgramSignature;
|
|
51
45
|
interface EndProgramSignature {
|
|
52
46
|
/**
|
|
53
|
-
*
|
|
54
|
-
*
|
|
55
|
-
* After ending a program, it can't be restarted.
|
|
56
|
-
* @param - Package of pools
|
|
47
|
+
* Ends the specified program. Benefits in the program's pools can't be redeemed until the program is resumed.
|
|
48
|
+
* @param - ID of the program to end.
|
|
57
49
|
*/
|
|
58
50
|
(programId: string): Promise<EndProgramResponse & EndProgramResponseNonNullableFields>;
|
|
59
51
|
}
|
|
@@ -86,20 +78,22 @@ interface QueryProgramsSignature {
|
|
|
86
78
|
/**
|
|
87
79
|
* Creates a query to retrieve a list of programs.
|
|
88
80
|
*
|
|
89
|
-
* The
|
|
81
|
+
* The Query Programs method builds a query to retrieve a list of programs and returns a `ProgramsQueryBuilder` object.
|
|
82
|
+
*
|
|
83
|
+
* The returned object contains the query definition, which is used to run the query using the `find()` method.
|
|
90
84
|
*
|
|
91
|
-
*
|
|
85
|
+
* You can refine the query by chaining `ProgramsQueryBuilder` methods onto the query. `ProgramsQueryBuilder` methods enable you to filter, sort, and control the results that Query Programs returns.
|
|
92
86
|
*
|
|
93
|
-
*
|
|
87
|
+
* Query Programs has a default paging limit of 50, which you can override.
|
|
94
88
|
*
|
|
95
|
-
*
|
|
89
|
+
* For a full description of the item object, see the object returned for the `items` property in `ProgramsQueryResult`.
|
|
96
90
|
*/
|
|
97
91
|
(): ProgramsQueryBuilder;
|
|
98
92
|
}
|
|
99
93
|
export declare function getProgramByExternalIdAndNamespace(httpClient: HttpClient): GetProgramByExternalIdAndNamespaceSignature;
|
|
100
94
|
interface GetProgramByExternalIdAndNamespaceSignature {
|
|
101
95
|
/**
|
|
102
|
-
* Retrieves a program
|
|
96
|
+
* Retrieves a program with the specified external ID and namespace.
|
|
103
97
|
* @param - Application sub-module that is the source of the program creation.
|
|
104
98
|
*
|
|
105
99
|
* Use the namespace that was designated to the program definition.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"benefit-programs-v1-program-programs.public.js","sourceRoot":"","sources":["../../../src/benefit-programs-v1-program-programs.public.ts"],"names":[],"mappings":";;;AACA,2HA6B6D;AAEhD,QAAA,UAAU,GAAG,EAAE,YAAY,EAAE,uBAAuB,EAAE,CAAC;AAEpE,SAAgB,gBAAgB,CAC9B,UAAsB;IAEtB,OAAO,CACL,sBAA8C,EAC9C,OAAiC,EACjC,EAAE,CACF,IAAA,oEAAyB,EACvB,sBAAsB,EACtB,OAAO;IACP,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AAbD,4CAaC;AAmBD,SAAgB,YAAY,CAAC,UAAsB;IACjD,OAAO,CAAC,SAAiB,EAAE,EAAE,CAC3B,IAAA,gEAAqB,EACnB,SAAS;IACT,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AAPD,oCAOC;
|
|
1
|
+
{"version":3,"file":"benefit-programs-v1-program-programs.public.js","sourceRoot":"","sources":["../../../src/benefit-programs-v1-program-programs.public.ts"],"names":[],"mappings":";;;AACA,2HA6B6D;AAEhD,QAAA,UAAU,GAAG,EAAE,YAAY,EAAE,uBAAuB,EAAE,CAAC;AAEpE,SAAgB,gBAAgB,CAC9B,UAAsB;IAEtB,OAAO,CACL,sBAA8C,EAC9C,OAAiC,EACjC,EAAE,CACF,IAAA,oEAAyB,EACvB,sBAAsB,EACtB,OAAO;IACP,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AAbD,4CAaC;AAmBD,SAAgB,YAAY,CAAC,UAAsB;IACjD,OAAO,CAAC,SAAiB,EAAE,EAAE,CAC3B,IAAA,gEAAqB,EACnB,SAAS;IACT,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AAPD,oCAOC;AAcD,SAAgB,YAAY,CAAC,UAAsB;IACjD,OAAO,CAAC,SAAiB,EAAE,EAAE,CAC3B,IAAA,gEAAqB,EACnB,SAAS;IACT,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AAPD,oCAOC;AAYD,SAAgB,aAAa,CAAC,UAAsB;IAClD,OAAO,CAA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
*/
|
|
26
26
|
updatedDate?: Date | null;
|
|
27
27
|
/**
|
|
28
|
-
* ID of program definition
|
|
28
|
+
* ID of the associated program definition.
|
|
29
29
|
* @format GUID
|
|
30
30
|
* @readonly
|
|
31
31
|
* @immutable
|
|
@@ -37,7 +37,7 @@ export interface Program {
|
|
|
37
37
|
*/
|
|
38
38
|
status?: ProgramStatus;
|
|
39
39
|
/**
|
|
40
|
-
*
|
|
40
|
+
* Program beneficiary.
|
|
41
41
|
* @readonly
|
|
42
42
|
* @immutable
|
|
43
43
|
*/
|
|
@@ -45,12 +45,12 @@ export interface Program {
|
|
|
45
45
|
/**
|
|
46
46
|
* Program name.
|
|
47
47
|
*
|
|
48
|
-
*
|
|
48
|
+
* You may want to use the same name that's used in the associated program definition, if it exists.
|
|
49
49
|
* @maxLength 64
|
|
50
50
|
*/
|
|
51
51
|
displayName?: string | null;
|
|
52
52
|
/**
|
|
53
|
-
*
|
|
53
|
+
* Namespace for your app or site's benefit programs.
|
|
54
54
|
* @minLength 1
|
|
55
55
|
* @maxLength 50
|
|
56
56
|
* @immutable
|
|
@@ -59,63 +59,52 @@ export interface Program {
|
|
|
59
59
|
/**
|
|
60
60
|
* Custom field data for the program object.
|
|
61
61
|
*
|
|
62
|
-
* [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.
|
|
63
63
|
*/
|
|
64
64
|
extendedFields?: ExtendedFields;
|
|
65
65
|
/**
|
|
66
|
-
*
|
|
67
|
-
*
|
|
68
|
-
* Must be unique to every app's namespace.
|
|
66
|
+
* ID for the program defined by you. You can use `externalId` to filter queries.
|
|
69
67
|
* @format GUID
|
|
70
68
|
* @immutable
|
|
71
69
|
*/
|
|
72
70
|
externalId?: string | null;
|
|
73
71
|
/**
|
|
74
|
-
*
|
|
72
|
+
* Associated program definition information.
|
|
75
73
|
* @readonly
|
|
76
74
|
*/
|
|
77
75
|
programDefinition?: ProgramDefinitionInfo;
|
|
78
|
-
/**
|
|
79
|
-
* Intended status of a program after the completion of an action.
|
|
80
|
-
* @readonly
|
|
81
|
-
*/
|
|
82
|
-
targetStatus?: ProgramStatus;
|
|
83
76
|
}
|
|
84
77
|
export declare enum ProgramStatus {
|
|
85
78
|
/** Undefined program status. */
|
|
86
79
|
UNDEFINED = "UNDEFINED",
|
|
87
|
-
/**
|
|
80
|
+
/** Program is active. */
|
|
88
81
|
ACTIVE = "ACTIVE",
|
|
89
|
-
/**
|
|
82
|
+
/** Program is paused. It can be resumed. */
|
|
90
83
|
PAUSED = "PAUSED",
|
|
91
|
-
/**
|
|
92
|
-
* Inactive program.
|
|
93
|
-
*
|
|
94
|
-
* Benefits of a program with an `ENDED` status can't be redeemed or reserved.
|
|
95
|
-
*/
|
|
84
|
+
/** Program has ended. It can't be resumed. */
|
|
96
85
|
ENDED = "ENDED",
|
|
97
|
-
/**
|
|
86
|
+
/** Program is being activated for the first time. This status will be true for a negligible amount of time. */
|
|
98
87
|
PROVISIONING = "PROVISIONING",
|
|
99
|
-
/**
|
|
88
|
+
/** Program is being paused. This status will be true for a negligible amount of time. */
|
|
100
89
|
PAUSING = "PAUSING",
|
|
101
|
-
/**
|
|
90
|
+
/** Program is being re-activated after being paused. This status will be true for a negligible amount of time. */
|
|
102
91
|
RESUMING = "RESUMING",
|
|
103
|
-
/**
|
|
92
|
+
/** Program is being ended. This status will be true for a negligible amount of time. */
|
|
104
93
|
ENDING = "ENDING"
|
|
105
94
|
}
|
|
106
95
|
export interface CommonIdentificationData extends CommonIdentificationDataIdOneOf {
|
|
107
96
|
/**
|
|
108
|
-
* ID of a site visitor that
|
|
97
|
+
* ID of a site visitor that hasn't logged in to the site.
|
|
109
98
|
* @format GUID
|
|
110
99
|
*/
|
|
111
100
|
anonymousVisitorId?: string;
|
|
112
101
|
/**
|
|
113
|
-
* ID of a site
|
|
102
|
+
* ID of a site member.
|
|
114
103
|
* @format GUID
|
|
115
104
|
*/
|
|
116
105
|
memberId?: string;
|
|
117
106
|
/**
|
|
118
|
-
* ID of a Wix user
|
|
107
|
+
* ID of a Wix user.
|
|
119
108
|
* @format GUID
|
|
120
109
|
*/
|
|
121
110
|
wixUserId?: string;
|
|
@@ -123,17 +112,17 @@ export interface CommonIdentificationData extends CommonIdentificationDataIdOneO
|
|
|
123
112
|
/** @oneof */
|
|
124
113
|
export interface CommonIdentificationDataIdOneOf {
|
|
125
114
|
/**
|
|
126
|
-
* ID of a site visitor that
|
|
115
|
+
* ID of a site visitor that hasn't logged in to the site.
|
|
127
116
|
* @format GUID
|
|
128
117
|
*/
|
|
129
118
|
anonymousVisitorId?: string;
|
|
130
119
|
/**
|
|
131
|
-
* ID of a site
|
|
120
|
+
* ID of a site member.
|
|
132
121
|
* @format GUID
|
|
133
122
|
*/
|
|
134
123
|
memberId?: string;
|
|
135
124
|
/**
|
|
136
|
-
* ID of a Wix user
|
|
125
|
+
* ID of a Wix user.
|
|
137
126
|
* @format GUID
|
|
138
127
|
*/
|
|
139
128
|
wixUserId?: string;
|
|
@@ -161,15 +150,13 @@ export interface ExtendedFields {
|
|
|
161
150
|
}
|
|
162
151
|
export interface ProgramDefinitionInfo {
|
|
163
152
|
/**
|
|
164
|
-
*
|
|
153
|
+
* Program definition ID.
|
|
165
154
|
* @format GUID
|
|
166
155
|
* @readonly
|
|
167
156
|
*/
|
|
168
157
|
id?: string;
|
|
169
158
|
/**
|
|
170
|
-
*
|
|
171
|
-
*
|
|
172
|
-
* This identifies the source program definition in the external system.
|
|
159
|
+
* Program definition external ID.
|
|
173
160
|
* @format GUID
|
|
174
161
|
* @readonly
|
|
175
162
|
*/
|
|
@@ -197,30 +184,18 @@ export interface ProgramResumed {
|
|
|
197
184
|
}
|
|
198
185
|
/** In case pool_definition_id is provided should test if it's part of a package. If it is, reject the request */
|
|
199
186
|
export interface ProvisionProgramRequest {
|
|
200
|
-
/**
|
|
201
|
-
* Used to locate the pool definition for creating its benefit pools within the program.
|
|
202
|
-
*
|
|
203
|
-
* This object must contain either `programDefinitionId` or `poolDefinitionId`:
|
|
204
|
-
* + Use `programDefinitionId` for programs with multiple benefit pools.
|
|
205
|
-
* + Use `poolDefinitionId` for a program with just 1 benefit pool.
|
|
206
|
-
*/
|
|
187
|
+
/** The program definition or pool definition to use to provision the program. */
|
|
207
188
|
poolDefinitionLookupId: PoolDefinitionLookupId;
|
|
208
|
-
/**
|
|
209
|
-
* Identity of the individual that enrolled in the program, granting access to its associated benefits.
|
|
210
|
-
*
|
|
211
|
-
* 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.
|
|
212
|
-
*/
|
|
189
|
+
/** Program beneficiary. */
|
|
213
190
|
beneficiary: CommonIdentificationData;
|
|
214
191
|
/**
|
|
215
|
-
*
|
|
192
|
+
* Initial program status.
|
|
216
193
|
*
|
|
217
194
|
* Default: `ACTIVE`
|
|
218
195
|
*/
|
|
219
196
|
programStatus?: ProvisionProgramRequestProgramStatus;
|
|
220
197
|
/**
|
|
221
|
-
*
|
|
222
|
-
*
|
|
223
|
-
* Use the namespace that was designated to the program definition.
|
|
198
|
+
* Namespace for your app or site's benefit programs.
|
|
224
199
|
* @minLength 1
|
|
225
200
|
* @maxLength 50
|
|
226
201
|
*/
|
|
@@ -228,14 +203,12 @@ export interface ProvisionProgramRequest {
|
|
|
228
203
|
/**
|
|
229
204
|
* Program name.
|
|
230
205
|
*
|
|
231
|
-
*
|
|
206
|
+
* You may want to use the same name that's used in the associated program definition, if it exists.
|
|
232
207
|
* @maxLength 64
|
|
233
208
|
*/
|
|
234
209
|
displayName?: string | null;
|
|
235
210
|
/**
|
|
236
|
-
*
|
|
237
|
-
*
|
|
238
|
-
* Must be unique to every app owner's namespace.
|
|
211
|
+
* ID for the program defined by you. You can use `externalId` to filter queries.
|
|
239
212
|
* @format GUID
|
|
240
213
|
*/
|
|
241
214
|
externalProgramId: string;
|
|
@@ -266,14 +239,14 @@ export interface PoolDefinitionLookupIdIdOneOf {
|
|
|
266
239
|
programDefinitionId?: string;
|
|
267
240
|
}
|
|
268
241
|
export declare enum ProvisionProgramRequestProgramStatus {
|
|
269
|
-
/**
|
|
242
|
+
/** Program is active. */
|
|
270
243
|
ACTIVE = "ACTIVE",
|
|
271
|
-
/**
|
|
244
|
+
/** Program is paused. */
|
|
272
245
|
PAUSED = "PAUSED"
|
|
273
246
|
}
|
|
274
247
|
export interface ProvisionProgramResponse {
|
|
275
248
|
/**
|
|
276
|
-
* Job ID of the
|
|
249
|
+
* Job ID of the provisioning of the program.
|
|
277
250
|
* @format GUID
|
|
278
251
|
*/
|
|
279
252
|
jobId?: string;
|
|
@@ -302,7 +275,7 @@ export interface RenewProgramRequest {
|
|
|
302
275
|
}
|
|
303
276
|
export interface RenewProgramResponse {
|
|
304
277
|
/**
|
|
305
|
-
* Job ID of the
|
|
278
|
+
* Job ID of the program renewal.
|
|
306
279
|
* @format GUID
|
|
307
280
|
*/
|
|
308
281
|
jobId?: string;
|
|
@@ -316,7 +289,7 @@ export interface PauseProgramRequest {
|
|
|
316
289
|
}
|
|
317
290
|
export interface PauseProgramResponse {
|
|
318
291
|
/**
|
|
319
|
-
* Job ID of the
|
|
292
|
+
* Job ID of the pausing of the program.
|
|
320
293
|
* @format GUID
|
|
321
294
|
*/
|
|
322
295
|
jobId?: string;
|
|
@@ -336,21 +309,21 @@ export interface ResumeProgramRequest {
|
|
|
336
309
|
}
|
|
337
310
|
export interface ResumeProgramResponse {
|
|
338
311
|
/**
|
|
339
|
-
* Job ID of the
|
|
312
|
+
* Job ID of the resuming of the program.
|
|
340
313
|
* @format GUID
|
|
341
314
|
*/
|
|
342
315
|
jobId?: string;
|
|
343
316
|
}
|
|
344
317
|
export interface EndProgramRequest {
|
|
345
318
|
/**
|
|
346
|
-
*
|
|
319
|
+
* ID of the program to end.
|
|
347
320
|
* @format GUID
|
|
348
321
|
*/
|
|
349
322
|
programId: string;
|
|
350
323
|
}
|
|
351
324
|
export interface EndProgramResponse {
|
|
352
325
|
/**
|
|
353
|
-
* Job ID of the
|
|
326
|
+
* Job ID of the ending of the program.
|
|
354
327
|
* @format GUID
|
|
355
328
|
*/
|
|
356
329
|
jobId?: string;
|
|
@@ -407,7 +380,7 @@ export interface UpsertMigratedProgramResponse {
|
|
|
407
380
|
program?: Program;
|
|
408
381
|
}
|
|
409
382
|
export interface UpdateProgramRequest {
|
|
410
|
-
/** Program to
|
|
383
|
+
/** Program to update. */
|
|
411
384
|
program: Program;
|
|
412
385
|
}
|
|
413
386
|
export interface UpdateProgramResponse {
|
|
@@ -426,7 +399,7 @@ export interface GetProgramResponse {
|
|
|
426
399
|
program?: Program;
|
|
427
400
|
}
|
|
428
401
|
export interface QueryProgramsRequest {
|
|
429
|
-
/**
|
|
402
|
+
/** Filter, sort, and paging to apply to the query. */
|
|
430
403
|
query?: CursorQuery;
|
|
431
404
|
}
|
|
432
405
|
export interface CursorQuery extends CursorQueryPagingMethodOneOf {
|
|
@@ -484,7 +457,7 @@ export interface CursorPaging {
|
|
|
484
457
|
cursor?: string | null;
|
|
485
458
|
}
|
|
486
459
|
export interface QueryProgramsResponse {
|
|
487
|
-
/** List of programs. */
|
|
460
|
+
/** List of retrieved programs. */
|
|
488
461
|
programs?: Program[];
|
|
489
462
|
/** Metadata for the paginated results. */
|
|
490
463
|
metadata?: CursorPagingMetadata;
|
|
@@ -5,23 +5,19 @@ var ProgramStatus;
|
|
|
5
5
|
(function (ProgramStatus) {
|
|
6
6
|
/** Undefined program status. */
|
|
7
7
|
ProgramStatus["UNDEFINED"] = "UNDEFINED";
|
|
8
|
-
/**
|
|
8
|
+
/** Program is active. */
|
|
9
9
|
ProgramStatus["ACTIVE"] = "ACTIVE";
|
|
10
|
-
/**
|
|
10
|
+
/** Program is paused. It can be resumed. */
|
|
11
11
|
ProgramStatus["PAUSED"] = "PAUSED";
|
|
12
|
-
/**
|
|
13
|
-
* Inactive program.
|
|
14
|
-
*
|
|
15
|
-
* Benefits of a program with an `ENDED` status can't be redeemed or reserved.
|
|
16
|
-
*/
|
|
12
|
+
/** Program has ended. It can't be resumed. */
|
|
17
13
|
ProgramStatus["ENDED"] = "ENDED";
|
|
18
|
-
/**
|
|
14
|
+
/** Program is being activated for the first time. This status will be true for a negligible amount of time. */
|
|
19
15
|
ProgramStatus["PROVISIONING"] = "PROVISIONING";
|
|
20
|
-
/**
|
|
16
|
+
/** Program is being paused. This status will be true for a negligible amount of time. */
|
|
21
17
|
ProgramStatus["PAUSING"] = "PAUSING";
|
|
22
|
-
/**
|
|
18
|
+
/** Program is being re-activated after being paused. This status will be true for a negligible amount of time. */
|
|
23
19
|
ProgramStatus["RESUMING"] = "RESUMING";
|
|
24
|
-
/**
|
|
20
|
+
/** Program is being ended. This status will be true for a negligible amount of time. */
|
|
25
21
|
ProgramStatus["ENDING"] = "ENDING";
|
|
26
22
|
})(ProgramStatus || (exports.ProgramStatus = ProgramStatus = {}));
|
|
27
23
|
var IdentityType;
|
|
@@ -37,9 +33,9 @@ var IdentityType;
|
|
|
37
33
|
})(IdentityType || (exports.IdentityType = IdentityType = {}));
|
|
38
34
|
var ProvisionProgramRequestProgramStatus;
|
|
39
35
|
(function (ProvisionProgramRequestProgramStatus) {
|
|
40
|
-
/**
|
|
36
|
+
/** Program is active. */
|
|
41
37
|
ProvisionProgramRequestProgramStatus["ACTIVE"] = "ACTIVE";
|
|
42
|
-
/**
|
|
38
|
+
/** Program is paused. */
|
|
43
39
|
ProvisionProgramRequestProgramStatus["PAUSED"] = "PAUSED";
|
|
44
40
|
})(ProvisionProgramRequestProgramStatus || (exports.ProvisionProgramRequestProgramStatus = ProvisionProgramRequestProgramStatus = {}));
|
|
45
41
|
var OrderStatus;
|