@snagsolutions/sdk 0.1.0-alpha.18 → 0.1.0-alpha.180
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/CHANGELOG.md +1472 -0
- package/README.md +13 -23
- package/core.d.ts +19 -5
- package/core.d.ts.map +1 -1
- package/core.js +24 -17
- package/core.js.map +1 -1
- package/core.mjs +24 -17
- package/core.mjs.map +1 -1
- package/index.d.mts +7 -4
- package/index.d.ts +7 -4
- package/index.d.ts.map +1 -1
- package/index.js +8 -4
- package/index.js.map +1 -1
- package/index.mjs +8 -4
- package/index.mjs.map +1 -1
- package/package.json +4 -5
- package/resource.d.ts +1 -1
- package/resource.d.ts.map +1 -1
- package/resource.js.map +1 -1
- package/resource.mjs.map +1 -1
- package/resources/assets.d.ts +16 -2
- package/resources/assets.d.ts.map +1 -1
- package/resources/assets.js +8 -0
- package/resources/assets.js.map +1 -1
- package/resources/assets.mjs +8 -0
- package/resources/assets.mjs.map +1 -1
- package/resources/auctions/auctions.d.ts +285 -0
- package/resources/auctions/auctions.d.ts.map +1 -0
- package/resources/auctions/auctions.js +76 -0
- package/resources/auctions/auctions.js.map +1 -0
- package/resources/auctions/auctions.mjs +49 -0
- package/resources/auctions/auctions.mjs.map +1 -0
- package/resources/auctions/index.d.ts +3 -0
- package/resources/auctions/index.d.ts.map +1 -0
- package/resources/auctions/index.js +9 -0
- package/resources/auctions/index.js.map +1 -0
- package/resources/auctions/index.mjs +4 -0
- package/resources/auctions/index.mjs.map +1 -0
- package/resources/auctions/website-user-attributes/index.d.ts +3 -0
- package/resources/auctions/website-user-attributes/index.d.ts.map +1 -0
- package/resources/auctions/website-user-attributes/index.js +9 -0
- package/resources/auctions/website-user-attributes/index.js.map +1 -0
- package/resources/auctions/website-user-attributes/index.mjs +4 -0
- package/resources/auctions/website-user-attributes/index.mjs.map +1 -0
- package/resources/auctions/website-user-attributes/values.d.ts +122 -0
- package/resources/auctions/website-user-attributes/values.d.ts.map +1 -0
- package/resources/auctions/website-user-attributes/values.js +49 -0
- package/resources/auctions/website-user-attributes/values.js.map +1 -0
- package/resources/auctions/website-user-attributes/values.mjs +45 -0
- package/resources/auctions/website-user-attributes/values.mjs.map +1 -0
- package/resources/auctions/website-user-attributes/website-user-attributes.d.ts +132 -0
- package/resources/auctions/website-user-attributes/website-user-attributes.d.ts.map +1 -0
- package/resources/auctions/website-user-attributes/website-user-attributes.js +76 -0
- package/resources/auctions/website-user-attributes/website-user-attributes.js.map +1 -0
- package/resources/auctions/website-user-attributes/website-user-attributes.mjs +49 -0
- package/resources/auctions/website-user-attributes/website-user-attributes.mjs.map +1 -0
- package/resources/auctions/website-user-attributes.d.ts +2 -0
- package/resources/auctions/website-user-attributes.d.ts.map +1 -0
- package/resources/auctions/website-user-attributes.js +19 -0
- package/resources/auctions/website-user-attributes.js.map +1 -0
- package/resources/auctions/website-user-attributes.mjs +3 -0
- package/resources/auctions/website-user-attributes.mjs.map +1 -0
- package/resources/auctions.d.ts +1 -133
- package/resources/auctions.d.ts.map +1 -1
- package/resources/auctions.js +15 -22
- package/resources/auctions.js.map +1 -1
- package/resources/auctions.mjs +1 -20
- package/resources/auctions.mjs.map +1 -1
- package/resources/auth.d.ts +17 -4
- package/resources/auth.d.ts.map +1 -1
- package/resources/auth.js.map +1 -1
- package/resources/auth.mjs.map +1 -1
- package/resources/index.d.ts +2 -2
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +1 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +1 -1
- package/resources/index.mjs.map +1 -1
- package/resources/loyalty/account-streaks.d.ts +81 -0
- package/resources/loyalty/account-streaks.d.ts.map +1 -0
- package/resources/loyalty/account-streaks.js +24 -0
- package/resources/loyalty/account-streaks.js.map +1 -0
- package/resources/loyalty/account-streaks.mjs +20 -0
- package/resources/loyalty/account-streaks.mjs.map +1 -0
- package/resources/loyalty/accounts.d.ts +60 -16
- package/resources/loyalty/accounts.d.ts.map +1 -1
- package/resources/loyalty/accounts.js +14 -0
- package/resources/loyalty/accounts.js.map +1 -1
- package/resources/loyalty/accounts.mjs +14 -0
- package/resources/loyalty/accounts.mjs.map +1 -1
- package/resources/loyalty/badges.d.ts +504 -22
- package/resources/loyalty/badges.d.ts.map +1 -1
- package/resources/loyalty/badges.js +19 -1
- package/resources/loyalty/badges.js.map +1 -1
- package/resources/loyalty/badges.mjs +19 -1
- package/resources/loyalty/badges.mjs.map +1 -1
- package/resources/loyalty/currencies.d.ts +19 -0
- package/resources/loyalty/currencies.d.ts.map +1 -1
- package/resources/loyalty/currencies.js +19 -0
- package/resources/loyalty/currencies.js.map +1 -1
- package/resources/loyalty/currencies.mjs +19 -0
- package/resources/loyalty/currencies.mjs.map +1 -1
- package/resources/loyalty/index.d.ts +4 -4
- package/resources/loyalty/index.d.ts.map +1 -1
- package/resources/loyalty/index.js +5 -5
- package/resources/loyalty/index.js.map +1 -1
- package/resources/loyalty/index.mjs +3 -3
- package/resources/loyalty/index.mjs.map +1 -1
- package/resources/loyalty/loyalty.d.ts +11 -11
- package/resources/loyalty/loyalty.d.ts.map +1 -1
- package/resources/loyalty/loyalty.js +6 -6
- package/resources/loyalty/loyalty.js.map +1 -1
- package/resources/loyalty/loyalty.mjs +7 -7
- package/resources/loyalty/loyalty.mjs.map +1 -1
- package/resources/loyalty/multipliers.d.ts +39 -2
- package/resources/loyalty/multipliers.d.ts.map +1 -1
- package/resources/loyalty/multipliers.js +23 -0
- package/resources/loyalty/multipliers.js.map +1 -1
- package/resources/loyalty/multipliers.mjs +23 -0
- package/resources/loyalty/multipliers.mjs.map +1 -1
- package/resources/loyalty/questions-responses.d.ts +39 -0
- package/resources/loyalty/questions-responses.d.ts.map +1 -1
- package/resources/loyalty/questions-responses.js +9 -0
- package/resources/loyalty/questions-responses.js.map +1 -1
- package/resources/loyalty/questions-responses.mjs +9 -0
- package/resources/loyalty/questions-responses.mjs.map +1 -1
- package/resources/loyalty/questions.d.ts +37 -2
- package/resources/loyalty/questions.d.ts.map +1 -1
- package/resources/loyalty/questions.js +31 -0
- package/resources/loyalty/questions.js.map +1 -1
- package/resources/loyalty/questions.mjs +31 -0
- package/resources/loyalty/questions.mjs.map +1 -1
- package/resources/loyalty/rule-edits.d.ts +2630 -8
- package/resources/loyalty/rule-edits.d.ts.map +1 -1
- package/resources/loyalty/rule-edits.js +14 -0
- package/resources/loyalty/rule-edits.js.map +1 -1
- package/resources/loyalty/rule-edits.mjs +14 -0
- package/resources/loyalty/rule-edits.mjs.map +1 -1
- package/resources/loyalty/rule-groups.d.ts +279 -64
- package/resources/loyalty/rule-groups.d.ts.map +1 -1
- package/resources/loyalty/rule-groups.js +38 -2
- package/resources/loyalty/rule-groups.js.map +1 -1
- package/resources/loyalty/rule-groups.mjs +38 -2
- package/resources/loyalty/rule-groups.mjs.map +1 -1
- package/resources/loyalty/rules.d.ts +1902 -269
- package/resources/loyalty/rules.d.ts.map +1 -1
- package/resources/loyalty/rules.js +40 -9
- package/resources/loyalty/rules.js.map +1 -1
- package/resources/loyalty/rules.mjs +40 -9
- package/resources/loyalty/rules.mjs.map +1 -1
- package/resources/loyalty/transactions/index.d.ts +3 -0
- package/resources/loyalty/transactions/index.d.ts.map +1 -0
- package/resources/loyalty/transactions/index.js +9 -0
- package/resources/loyalty/transactions/index.js.map +1 -0
- package/resources/loyalty/transactions/index.mjs +4 -0
- package/resources/loyalty/transactions/index.mjs.map +1 -0
- package/resources/loyalty/transactions/rule-statuses.d.ts +120 -0
- package/resources/loyalty/transactions/rule-statuses.d.ts.map +1 -0
- package/resources/loyalty/transactions/rule-statuses.js +30 -0
- package/resources/loyalty/transactions/rule-statuses.js.map +1 -0
- package/resources/loyalty/transactions/rule-statuses.mjs +26 -0
- package/resources/loyalty/transactions/rule-statuses.mjs.map +1 -0
- package/resources/loyalty/transactions/transactions.d.ts +410 -0
- package/resources/loyalty/transactions/transactions.d.ts.map +1 -0
- package/resources/loyalty/transactions/transactions.js +76 -0
- package/resources/loyalty/transactions/transactions.js.map +1 -0
- package/resources/loyalty/transactions/transactions.mjs +49 -0
- package/resources/loyalty/transactions/transactions.mjs.map +1 -0
- package/resources/loyalty/transactions.d.ts +1 -247
- package/resources/loyalty/transactions.d.ts.map +1 -1
- package/resources/loyalty/transactions.js +15 -18
- package/resources/loyalty/transactions.js.map +1 -1
- package/resources/loyalty/transactions.mjs +1 -16
- package/resources/loyalty/transactions.mjs.map +1 -1
- package/resources/minting.d.ts +5 -5
- package/resources/minting.d.ts.map +1 -1
- package/resources/referral/referral.d.ts +11 -3
- package/resources/referral/referral.d.ts.map +1 -1
- package/resources/referral/referral.js +11 -5
- package/resources/referral/referral.js.map +1 -1
- package/resources/referral/referral.mjs +11 -5
- package/resources/referral/referral.mjs.map +1 -1
- package/resources/referral/users.d.ts +28 -1
- package/resources/referral/users.d.ts.map +1 -1
- package/resources/referral/users.js +14 -0
- package/resources/referral/users.js.map +1 -1
- package/resources/referral/users.mjs +14 -0
- package/resources/referral/users.mjs.map +1 -1
- package/resources/users/index.d.ts +1 -1
- package/resources/users/index.d.ts.map +1 -1
- package/resources/users/index.js.map +1 -1
- package/resources/users/index.mjs.map +1 -1
- package/resources/users/metadatas.d.ts +34 -3
- package/resources/users/metadatas.d.ts.map +1 -1
- package/resources/users/metadatas.js.map +1 -1
- package/resources/users/metadatas.mjs.map +1 -1
- package/resources/users/users.d.ts +159 -35
- package/resources/users/users.d.ts.map +1 -1
- package/resources/users/users.js +53 -1
- package/resources/users/users.js.map +1 -1
- package/resources/users/users.mjs +53 -1
- package/resources/users/users.mjs.map +1 -1
- package/resources/websites/website-collections.d.ts +22 -1
- package/resources/websites/website-collections.d.ts.map +1 -1
- package/resources/websites/website-collections.js +21 -0
- package/resources/websites/website-collections.js.map +1 -1
- package/resources/websites/website-collections.mjs +21 -0
- package/resources/websites/website-collections.mjs.map +1 -1
- package/resources/websites/website-user-roles.d.ts +23 -0
- package/resources/websites/website-user-roles.d.ts.map +1 -1
- package/resources/websites/website-user-roles.js +23 -0
- package/resources/websites/website-user-roles.js.map +1 -1
- package/resources/websites/website-user-roles.mjs +23 -0
- package/resources/websites/website-user-roles.mjs.map +1 -1
- package/resources/websites/websites.d.ts +12 -0
- package/resources/websites/websites.d.ts.map +1 -1
- package/resources/websites/websites.js +7 -0
- package/resources/websites/websites.js.map +1 -1
- package/resources/websites/websites.mjs +7 -0
- package/resources/websites/websites.mjs.map +1 -1
- package/src/core.ts +39 -16
- package/src/index.ts +29 -2
- package/src/resource.ts +1 -1
- package/src/resources/assets.ts +18 -3
- package/src/resources/auctions/auctions.ts +436 -0
- package/src/resources/auctions/index.ts +18 -0
- package/src/resources/auctions/website-user-attributes/index.ts +18 -0
- package/src/resources/auctions/website-user-attributes/values.ts +165 -0
- package/src/resources/auctions/website-user-attributes/website-user-attributes.ts +207 -0
- package/src/resources/auctions/website-user-attributes.ts +3 -0
- package/src/resources/auctions.ts +1 -207
- package/src/resources/auth.ts +21 -5
- package/src/resources/index.ts +11 -1
- package/src/resources/loyalty/account-streaks.ts +110 -0
- package/src/resources/loyalty/accounts.ts +65 -18
- package/src/resources/loyalty/badges.ts +607 -24
- package/src/resources/loyalty/currencies.ts +19 -0
- package/src/resources/loyalty/index.ts +19 -3
- package/src/resources/loyalty/loyalty.ts +39 -15
- package/src/resources/loyalty/multipliers.ts +43 -4
- package/src/resources/loyalty/questions-responses.ts +45 -0
- package/src/resources/loyalty/questions.ts +38 -2
- package/src/resources/loyalty/rule-edits.ts +3802 -100
- package/src/resources/loyalty/rule-groups.ts +483 -76
- package/src/resources/loyalty/rules.ts +2925 -310
- package/src/resources/loyalty/transactions/index.ts +18 -0
- package/src/resources/loyalty/transactions/rule-statuses.ts +178 -0
- package/src/resources/loyalty/transactions/transactions.ts +681 -0
- package/src/resources/loyalty/transactions.ts +1 -330
- package/src/resources/minting.ts +22 -5
- package/src/resources/referral/referral.ts +13 -11
- package/src/resources/referral/users.ts +33 -2
- package/src/resources/users/index.ts +4 -0
- package/src/resources/users/metadatas.ts +57 -3
- package/src/resources/users/users.ts +209 -38
- package/src/resources/websites/website-collections.ts +39 -1
- package/src/resources/websites/website-user-roles.ts +23 -0
- package/src/resources/websites/websites.ts +12 -0
- package/src/version.ts +1 -1
- package/version.d.ts +1 -1
- package/version.d.ts.map +1 -1
- package/version.js +1 -1
- package/version.js.map +1 -1
- package/version.mjs +1 -1
- package/version.mjs.map +1 -1
- package/resources/loyalty/rule-chains.d.ts +0 -34
- package/resources/loyalty/rule-chains.d.ts.map +0 -1
- package/resources/loyalty/rule-chains.js +0 -15
- package/resources/loyalty/rule-chains.js.map +0 -1
- package/resources/loyalty/rule-chains.mjs +0 -11
- package/resources/loyalty/rule-chains.mjs.map +0 -1
- package/src/resources/loyalty/rule-chains.ts +0 -45
|
@@ -6,7 +6,18 @@ import * as Core from '../../core';
|
|
|
6
6
|
|
|
7
7
|
export class Badges extends APIResource {
|
|
8
8
|
/**
|
|
9
|
-
* This endpoint allows you to configure a new badge
|
|
9
|
+
* This endpoint allows you to configure a new badge
|
|
10
|
+
*
|
|
11
|
+
* @example
|
|
12
|
+
* ```ts
|
|
13
|
+
* const badge = await client.loyalty.badges.create({
|
|
14
|
+
* conditions: [{}],
|
|
15
|
+
* imageUrl: 'https://example.com/image.png',
|
|
16
|
+
* name: 'Example Badge',
|
|
17
|
+
* organizationId: '123e4567-e89b-12d3-a456-426614174222',
|
|
18
|
+
* websiteId: '123e4567-e89b-12d3-a456-426614174111',
|
|
19
|
+
* });
|
|
20
|
+
* ```
|
|
10
21
|
*/
|
|
11
22
|
create(body: BadgeCreateParams, options?: Core.RequestOptions): Core.APIPromise<BadgeCreateResponse> {
|
|
12
23
|
return this._client.post('/api/loyalty/badges', { body, ...options });
|
|
@@ -14,6 +25,13 @@ export class Badges extends APIResource {
|
|
|
14
25
|
|
|
15
26
|
/**
|
|
16
27
|
* This endpoint allows you to update an existing badge.
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* ```ts
|
|
31
|
+
* const badge = await client.loyalty.badges.update(
|
|
32
|
+
* '123e4567-e89b-12d3-a456-426614174333',
|
|
33
|
+
* );
|
|
34
|
+
* ```
|
|
17
35
|
*/
|
|
18
36
|
update(
|
|
19
37
|
id: string,
|
|
@@ -34,6 +52,11 @@ export class Badges extends APIResource {
|
|
|
34
52
|
|
|
35
53
|
/**
|
|
36
54
|
* This endpoint allows you to fetch badge(s) data.
|
|
55
|
+
*
|
|
56
|
+
* @example
|
|
57
|
+
* ```ts
|
|
58
|
+
* const badges = await client.loyalty.badges.list();
|
|
59
|
+
* ```
|
|
37
60
|
*/
|
|
38
61
|
list(query?: BadgeListParams, options?: Core.RequestOptions): Core.APIPromise<BadgeListResponse>;
|
|
39
62
|
list(options?: Core.RequestOptions): Core.APIPromise<BadgeListResponse>;
|
|
@@ -49,6 +72,13 @@ export class Badges extends APIResource {
|
|
|
49
72
|
|
|
50
73
|
/**
|
|
51
74
|
* This endpoint allows you to delete a badge.
|
|
75
|
+
*
|
|
76
|
+
* @example
|
|
77
|
+
* ```ts
|
|
78
|
+
* const badge = await client.loyalty.badges.delete(
|
|
79
|
+
* '123e4567-e89b-12d3-a456-426614174333',
|
|
80
|
+
* );
|
|
81
|
+
* ```
|
|
52
82
|
*/
|
|
53
83
|
delete(id: string, options?: Core.RequestOptions): Core.APIPromise<BadgeDeleteResponse> {
|
|
54
84
|
return this._client.delete(`/api/loyalty/badges/${id}`, options);
|
|
@@ -56,6 +86,13 @@ export class Badges extends APIResource {
|
|
|
56
86
|
|
|
57
87
|
/**
|
|
58
88
|
* This endpoint allows you to revoke a badge from an account
|
|
89
|
+
*
|
|
90
|
+
* @example
|
|
91
|
+
* ```ts
|
|
92
|
+
* const response = await client.loyalty.badges.revoke(
|
|
93
|
+
* '123e4567-e89b-12d3-a456-426614174333',
|
|
94
|
+
* );
|
|
95
|
+
* ```
|
|
59
96
|
*/
|
|
60
97
|
revoke(
|
|
61
98
|
id: string,
|
|
@@ -76,6 +113,13 @@ export class Badges extends APIResource {
|
|
|
76
113
|
|
|
77
114
|
/**
|
|
78
115
|
* This endpoint allows you to reward a badge for an account
|
|
116
|
+
*
|
|
117
|
+
* @example
|
|
118
|
+
* ```ts
|
|
119
|
+
* const response = await client.loyalty.badges.reward(
|
|
120
|
+
* '123e4567-e89b-12d3-a456-426614174333',
|
|
121
|
+
* );
|
|
122
|
+
* ```
|
|
79
123
|
*/
|
|
80
124
|
reward(
|
|
81
125
|
id: string,
|
|
@@ -104,6 +148,11 @@ export interface BadgeCreateResponse {
|
|
|
104
148
|
*/
|
|
105
149
|
id: string;
|
|
106
150
|
|
|
151
|
+
/**
|
|
152
|
+
* The date and time the badge was created
|
|
153
|
+
*/
|
|
154
|
+
createdAt: string;
|
|
155
|
+
|
|
107
156
|
/**
|
|
108
157
|
* The description of the badge
|
|
109
158
|
*/
|
|
@@ -124,10 +173,25 @@ export interface BadgeCreateResponse {
|
|
|
124
173
|
*/
|
|
125
174
|
name: string;
|
|
126
175
|
|
|
176
|
+
/**
|
|
177
|
+
* The date and time the badge was updated
|
|
178
|
+
*/
|
|
179
|
+
updatedAt: string;
|
|
180
|
+
|
|
181
|
+
/**
|
|
182
|
+
* Array of data jobs associated with the badge
|
|
183
|
+
*/
|
|
184
|
+
dataJobs?: Array<BadgeCreateResponse.DataJob>;
|
|
185
|
+
|
|
127
186
|
/**
|
|
128
187
|
* Array of user badges
|
|
129
188
|
*/
|
|
130
|
-
|
|
189
|
+
loyaltyBadgeUsers?: Array<BadgeCreateResponse.LoyaltyBadgeUser>;
|
|
190
|
+
|
|
191
|
+
/**
|
|
192
|
+
* Array of loyalty rules associated with the badge
|
|
193
|
+
*/
|
|
194
|
+
loyaltyRules?: Array<BadgeCreateResponse.LoyaltyRule>;
|
|
131
195
|
}
|
|
132
196
|
|
|
133
197
|
export namespace BadgeCreateResponse {
|
|
@@ -148,7 +212,7 @@ export namespace BadgeCreateResponse {
|
|
|
148
212
|
association: Array<LoyaltyCondition.Association>;
|
|
149
213
|
|
|
150
214
|
/**
|
|
151
|
-
*
|
|
215
|
+
* URL of the CSV file
|
|
152
216
|
*/
|
|
153
217
|
csvUrl: string | null;
|
|
154
218
|
|
|
@@ -181,6 +245,11 @@ export namespace BadgeCreateResponse {
|
|
|
181
245
|
* The type of the condition
|
|
182
246
|
*/
|
|
183
247
|
type: 'rule' | 'rules' | 'points' | 'section' | 'level' | 'api' | 'badge' | 'badges' | 'csv';
|
|
248
|
+
|
|
249
|
+
/**
|
|
250
|
+
* Array of CSV files associated with the condition
|
|
251
|
+
*/
|
|
252
|
+
csvFiles?: Array<LoyaltyCondition.CsvFile>;
|
|
184
253
|
}
|
|
185
254
|
|
|
186
255
|
export namespace LoyaltyCondition {
|
|
@@ -257,6 +326,55 @@ export namespace BadgeCreateResponse {
|
|
|
257
326
|
name: string;
|
|
258
327
|
}
|
|
259
328
|
}
|
|
329
|
+
|
|
330
|
+
export interface CsvFile {
|
|
331
|
+
/**
|
|
332
|
+
* UUID of the CSV file (converted to lowercase)
|
|
333
|
+
*/
|
|
334
|
+
id: string;
|
|
335
|
+
|
|
336
|
+
/**
|
|
337
|
+
* The description of the CSV file
|
|
338
|
+
*/
|
|
339
|
+
description: string | null;
|
|
340
|
+
|
|
341
|
+
/**
|
|
342
|
+
* The name of the CSV file
|
|
343
|
+
*/
|
|
344
|
+
name: string | null;
|
|
345
|
+
|
|
346
|
+
/**
|
|
347
|
+
* The URL of the CSV file
|
|
348
|
+
*/
|
|
349
|
+
url: string | null;
|
|
350
|
+
}
|
|
351
|
+
}
|
|
352
|
+
|
|
353
|
+
export interface DataJob {
|
|
354
|
+
/**
|
|
355
|
+
* UUID of the data job (converted to lowercase)
|
|
356
|
+
*/
|
|
357
|
+
id: string;
|
|
358
|
+
|
|
359
|
+
/**
|
|
360
|
+
* The date and time the data job was created
|
|
361
|
+
*/
|
|
362
|
+
createdAt: string;
|
|
363
|
+
|
|
364
|
+
/**
|
|
365
|
+
* The status of the data job
|
|
366
|
+
*/
|
|
367
|
+
status: 'pending' | 'complete' | 'failed';
|
|
368
|
+
|
|
369
|
+
/**
|
|
370
|
+
* The date and time the data job was updated
|
|
371
|
+
*/
|
|
372
|
+
updatedAt: string;
|
|
373
|
+
|
|
374
|
+
/**
|
|
375
|
+
* The message associated with the data job
|
|
376
|
+
*/
|
|
377
|
+
message?: string | null;
|
|
260
378
|
}
|
|
261
379
|
|
|
262
380
|
export interface LoyaltyBadgeUser {
|
|
@@ -265,6 +383,11 @@ export namespace BadgeCreateResponse {
|
|
|
265
383
|
*/
|
|
266
384
|
id: string;
|
|
267
385
|
|
|
386
|
+
/**
|
|
387
|
+
* The date and time the user badge was created
|
|
388
|
+
*/
|
|
389
|
+
createdAt: string;
|
|
390
|
+
|
|
268
391
|
/**
|
|
269
392
|
* UUID of the badge (converted to lowercase)
|
|
270
393
|
*/
|
|
@@ -280,6 +403,11 @@ export namespace BadgeCreateResponse {
|
|
|
280
403
|
*/
|
|
281
404
|
status: 'active' | 'inactive' | 'revoked';
|
|
282
405
|
|
|
406
|
+
/**
|
|
407
|
+
* The date and time the user badge was updated
|
|
408
|
+
*/
|
|
409
|
+
updatedAt: string;
|
|
410
|
+
|
|
283
411
|
/**
|
|
284
412
|
* UUID of the user (converted to lowercase)
|
|
285
413
|
*/
|
|
@@ -290,10 +418,49 @@ export namespace BadgeCreateResponse {
|
|
|
290
418
|
*/
|
|
291
419
|
websiteId: string;
|
|
292
420
|
|
|
421
|
+
/**
|
|
422
|
+
* Whether the user has dismissed the badge in the UI
|
|
423
|
+
*/
|
|
424
|
+
dismissedInUi?: boolean;
|
|
425
|
+
|
|
293
426
|
/**
|
|
294
427
|
* Array of progress for the badge
|
|
295
428
|
*/
|
|
296
429
|
progress?: unknown;
|
|
430
|
+
|
|
431
|
+
/**
|
|
432
|
+
* User associated with the user badge
|
|
433
|
+
*/
|
|
434
|
+
user?: LoyaltyBadgeUser.User;
|
|
435
|
+
}
|
|
436
|
+
|
|
437
|
+
export namespace LoyaltyBadgeUser {
|
|
438
|
+
/**
|
|
439
|
+
* User associated with the user badge
|
|
440
|
+
*/
|
|
441
|
+
export interface User {
|
|
442
|
+
/**
|
|
443
|
+
* UUID of the user (converted to lowercase)
|
|
444
|
+
*/
|
|
445
|
+
id: string;
|
|
446
|
+
|
|
447
|
+
/**
|
|
448
|
+
* Wallet address of the user
|
|
449
|
+
*/
|
|
450
|
+
walletAddress: string;
|
|
451
|
+
}
|
|
452
|
+
}
|
|
453
|
+
|
|
454
|
+
export interface LoyaltyRule {
|
|
455
|
+
/**
|
|
456
|
+
* UUID of the loyalty rule (converted to lowercase)
|
|
457
|
+
*/
|
|
458
|
+
id: string;
|
|
459
|
+
|
|
460
|
+
/**
|
|
461
|
+
* The name of the loyalty rule
|
|
462
|
+
*/
|
|
463
|
+
name: string;
|
|
297
464
|
}
|
|
298
465
|
}
|
|
299
466
|
|
|
@@ -306,6 +473,11 @@ export interface BadgeUpdateResponse {
|
|
|
306
473
|
*/
|
|
307
474
|
id: string;
|
|
308
475
|
|
|
476
|
+
/**
|
|
477
|
+
* The date and time the badge was created
|
|
478
|
+
*/
|
|
479
|
+
createdAt: string;
|
|
480
|
+
|
|
309
481
|
/**
|
|
310
482
|
* The description of the badge
|
|
311
483
|
*/
|
|
@@ -326,10 +498,25 @@ export interface BadgeUpdateResponse {
|
|
|
326
498
|
*/
|
|
327
499
|
name: string;
|
|
328
500
|
|
|
501
|
+
/**
|
|
502
|
+
* The date and time the badge was updated
|
|
503
|
+
*/
|
|
504
|
+
updatedAt: string;
|
|
505
|
+
|
|
506
|
+
/**
|
|
507
|
+
* Array of data jobs associated with the badge
|
|
508
|
+
*/
|
|
509
|
+
dataJobs?: Array<BadgeUpdateResponse.DataJob>;
|
|
510
|
+
|
|
329
511
|
/**
|
|
330
512
|
* Array of user badges
|
|
331
513
|
*/
|
|
332
|
-
|
|
514
|
+
loyaltyBadgeUsers?: Array<BadgeUpdateResponse.LoyaltyBadgeUser>;
|
|
515
|
+
|
|
516
|
+
/**
|
|
517
|
+
* Array of loyalty rules associated with the badge
|
|
518
|
+
*/
|
|
519
|
+
loyaltyRules?: Array<BadgeUpdateResponse.LoyaltyRule>;
|
|
333
520
|
}
|
|
334
521
|
|
|
335
522
|
export namespace BadgeUpdateResponse {
|
|
@@ -350,7 +537,7 @@ export namespace BadgeUpdateResponse {
|
|
|
350
537
|
association: Array<LoyaltyCondition.Association>;
|
|
351
538
|
|
|
352
539
|
/**
|
|
353
|
-
*
|
|
540
|
+
* URL of the CSV file
|
|
354
541
|
*/
|
|
355
542
|
csvUrl: string | null;
|
|
356
543
|
|
|
@@ -383,6 +570,11 @@ export namespace BadgeUpdateResponse {
|
|
|
383
570
|
* The type of the condition
|
|
384
571
|
*/
|
|
385
572
|
type: 'rule' | 'rules' | 'points' | 'section' | 'level' | 'api' | 'badge' | 'badges' | 'csv';
|
|
573
|
+
|
|
574
|
+
/**
|
|
575
|
+
* Array of CSV files associated with the condition
|
|
576
|
+
*/
|
|
577
|
+
csvFiles?: Array<LoyaltyCondition.CsvFile>;
|
|
386
578
|
}
|
|
387
579
|
|
|
388
580
|
export namespace LoyaltyCondition {
|
|
@@ -459,6 +651,55 @@ export namespace BadgeUpdateResponse {
|
|
|
459
651
|
name: string;
|
|
460
652
|
}
|
|
461
653
|
}
|
|
654
|
+
|
|
655
|
+
export interface CsvFile {
|
|
656
|
+
/**
|
|
657
|
+
* UUID of the CSV file (converted to lowercase)
|
|
658
|
+
*/
|
|
659
|
+
id: string;
|
|
660
|
+
|
|
661
|
+
/**
|
|
662
|
+
* The description of the CSV file
|
|
663
|
+
*/
|
|
664
|
+
description: string | null;
|
|
665
|
+
|
|
666
|
+
/**
|
|
667
|
+
* The name of the CSV file
|
|
668
|
+
*/
|
|
669
|
+
name: string | null;
|
|
670
|
+
|
|
671
|
+
/**
|
|
672
|
+
* The URL of the CSV file
|
|
673
|
+
*/
|
|
674
|
+
url: string | null;
|
|
675
|
+
}
|
|
676
|
+
}
|
|
677
|
+
|
|
678
|
+
export interface DataJob {
|
|
679
|
+
/**
|
|
680
|
+
* UUID of the data job (converted to lowercase)
|
|
681
|
+
*/
|
|
682
|
+
id: string;
|
|
683
|
+
|
|
684
|
+
/**
|
|
685
|
+
* The date and time the data job was created
|
|
686
|
+
*/
|
|
687
|
+
createdAt: string;
|
|
688
|
+
|
|
689
|
+
/**
|
|
690
|
+
* The status of the data job
|
|
691
|
+
*/
|
|
692
|
+
status: 'pending' | 'complete' | 'failed';
|
|
693
|
+
|
|
694
|
+
/**
|
|
695
|
+
* The date and time the data job was updated
|
|
696
|
+
*/
|
|
697
|
+
updatedAt: string;
|
|
698
|
+
|
|
699
|
+
/**
|
|
700
|
+
* The message associated with the data job
|
|
701
|
+
*/
|
|
702
|
+
message?: string | null;
|
|
462
703
|
}
|
|
463
704
|
|
|
464
705
|
export interface LoyaltyBadgeUser {
|
|
@@ -467,6 +708,11 @@ export namespace BadgeUpdateResponse {
|
|
|
467
708
|
*/
|
|
468
709
|
id: string;
|
|
469
710
|
|
|
711
|
+
/**
|
|
712
|
+
* The date and time the user badge was created
|
|
713
|
+
*/
|
|
714
|
+
createdAt: string;
|
|
715
|
+
|
|
470
716
|
/**
|
|
471
717
|
* UUID of the badge (converted to lowercase)
|
|
472
718
|
*/
|
|
@@ -482,6 +728,11 @@ export namespace BadgeUpdateResponse {
|
|
|
482
728
|
*/
|
|
483
729
|
status: 'active' | 'inactive' | 'revoked';
|
|
484
730
|
|
|
731
|
+
/**
|
|
732
|
+
* The date and time the user badge was updated
|
|
733
|
+
*/
|
|
734
|
+
updatedAt: string;
|
|
735
|
+
|
|
485
736
|
/**
|
|
486
737
|
* UUID of the user (converted to lowercase)
|
|
487
738
|
*/
|
|
@@ -492,10 +743,49 @@ export namespace BadgeUpdateResponse {
|
|
|
492
743
|
*/
|
|
493
744
|
websiteId: string;
|
|
494
745
|
|
|
746
|
+
/**
|
|
747
|
+
* Whether the user has dismissed the badge in the UI
|
|
748
|
+
*/
|
|
749
|
+
dismissedInUi?: boolean;
|
|
750
|
+
|
|
495
751
|
/**
|
|
496
752
|
* Array of progress for the badge
|
|
497
753
|
*/
|
|
498
754
|
progress?: unknown;
|
|
755
|
+
|
|
756
|
+
/**
|
|
757
|
+
* User associated with the user badge
|
|
758
|
+
*/
|
|
759
|
+
user?: LoyaltyBadgeUser.User;
|
|
760
|
+
}
|
|
761
|
+
|
|
762
|
+
export namespace LoyaltyBadgeUser {
|
|
763
|
+
/**
|
|
764
|
+
* User associated with the user badge
|
|
765
|
+
*/
|
|
766
|
+
export interface User {
|
|
767
|
+
/**
|
|
768
|
+
* UUID of the user (converted to lowercase)
|
|
769
|
+
*/
|
|
770
|
+
id: string;
|
|
771
|
+
|
|
772
|
+
/**
|
|
773
|
+
* Wallet address of the user
|
|
774
|
+
*/
|
|
775
|
+
walletAddress: string;
|
|
776
|
+
}
|
|
777
|
+
}
|
|
778
|
+
|
|
779
|
+
export interface LoyaltyRule {
|
|
780
|
+
/**
|
|
781
|
+
* UUID of the loyalty rule (converted to lowercase)
|
|
782
|
+
*/
|
|
783
|
+
id: string;
|
|
784
|
+
|
|
785
|
+
/**
|
|
786
|
+
* The name of the loyalty rule
|
|
787
|
+
*/
|
|
788
|
+
name: string;
|
|
499
789
|
}
|
|
500
790
|
}
|
|
501
791
|
|
|
@@ -508,6 +798,11 @@ export interface BadgeListResponse {
|
|
|
508
798
|
*/
|
|
509
799
|
id: string;
|
|
510
800
|
|
|
801
|
+
/**
|
|
802
|
+
* The date and time the badge was created
|
|
803
|
+
*/
|
|
804
|
+
createdAt: string;
|
|
805
|
+
|
|
511
806
|
/**
|
|
512
807
|
* The description of the badge
|
|
513
808
|
*/
|
|
@@ -528,10 +823,25 @@ export interface BadgeListResponse {
|
|
|
528
823
|
*/
|
|
529
824
|
name: string;
|
|
530
825
|
|
|
826
|
+
/**
|
|
827
|
+
* The date and time the badge was updated
|
|
828
|
+
*/
|
|
829
|
+
updatedAt: string;
|
|
830
|
+
|
|
831
|
+
/**
|
|
832
|
+
* Array of data jobs associated with the badge
|
|
833
|
+
*/
|
|
834
|
+
dataJobs?: Array<BadgeListResponse.DataJob>;
|
|
835
|
+
|
|
531
836
|
/**
|
|
532
837
|
* Array of user badges
|
|
533
838
|
*/
|
|
534
|
-
|
|
839
|
+
loyaltyBadgeUsers?: Array<BadgeListResponse.LoyaltyBadgeUser>;
|
|
840
|
+
|
|
841
|
+
/**
|
|
842
|
+
* Array of loyalty rules associated with the badge
|
|
843
|
+
*/
|
|
844
|
+
loyaltyRules?: Array<BadgeListResponse.LoyaltyRule>;
|
|
535
845
|
}
|
|
536
846
|
|
|
537
847
|
export namespace BadgeListResponse {
|
|
@@ -552,7 +862,7 @@ export namespace BadgeListResponse {
|
|
|
552
862
|
association: Array<LoyaltyCondition.Association>;
|
|
553
863
|
|
|
554
864
|
/**
|
|
555
|
-
*
|
|
865
|
+
* URL of the CSV file
|
|
556
866
|
*/
|
|
557
867
|
csvUrl: string | null;
|
|
558
868
|
|
|
@@ -585,6 +895,11 @@ export namespace BadgeListResponse {
|
|
|
585
895
|
* The type of the condition
|
|
586
896
|
*/
|
|
587
897
|
type: 'rule' | 'rules' | 'points' | 'section' | 'level' | 'api' | 'badge' | 'badges' | 'csv';
|
|
898
|
+
|
|
899
|
+
/**
|
|
900
|
+
* Array of CSV files associated with the condition
|
|
901
|
+
*/
|
|
902
|
+
csvFiles?: Array<LoyaltyCondition.CsvFile>;
|
|
588
903
|
}
|
|
589
904
|
|
|
590
905
|
export namespace LoyaltyCondition {
|
|
@@ -661,6 +976,55 @@ export namespace BadgeListResponse {
|
|
|
661
976
|
name: string;
|
|
662
977
|
}
|
|
663
978
|
}
|
|
979
|
+
|
|
980
|
+
export interface CsvFile {
|
|
981
|
+
/**
|
|
982
|
+
* UUID of the CSV file (converted to lowercase)
|
|
983
|
+
*/
|
|
984
|
+
id: string;
|
|
985
|
+
|
|
986
|
+
/**
|
|
987
|
+
* The description of the CSV file
|
|
988
|
+
*/
|
|
989
|
+
description: string | null;
|
|
990
|
+
|
|
991
|
+
/**
|
|
992
|
+
* The name of the CSV file
|
|
993
|
+
*/
|
|
994
|
+
name: string | null;
|
|
995
|
+
|
|
996
|
+
/**
|
|
997
|
+
* The URL of the CSV file
|
|
998
|
+
*/
|
|
999
|
+
url: string | null;
|
|
1000
|
+
}
|
|
1001
|
+
}
|
|
1002
|
+
|
|
1003
|
+
export interface DataJob {
|
|
1004
|
+
/**
|
|
1005
|
+
* UUID of the data job (converted to lowercase)
|
|
1006
|
+
*/
|
|
1007
|
+
id: string;
|
|
1008
|
+
|
|
1009
|
+
/**
|
|
1010
|
+
* The date and time the data job was created
|
|
1011
|
+
*/
|
|
1012
|
+
createdAt: string;
|
|
1013
|
+
|
|
1014
|
+
/**
|
|
1015
|
+
* The status of the data job
|
|
1016
|
+
*/
|
|
1017
|
+
status: 'pending' | 'complete' | 'failed';
|
|
1018
|
+
|
|
1019
|
+
/**
|
|
1020
|
+
* The date and time the data job was updated
|
|
1021
|
+
*/
|
|
1022
|
+
updatedAt: string;
|
|
1023
|
+
|
|
1024
|
+
/**
|
|
1025
|
+
* The message associated with the data job
|
|
1026
|
+
*/
|
|
1027
|
+
message?: string | null;
|
|
664
1028
|
}
|
|
665
1029
|
|
|
666
1030
|
export interface LoyaltyBadgeUser {
|
|
@@ -669,6 +1033,11 @@ export namespace BadgeListResponse {
|
|
|
669
1033
|
*/
|
|
670
1034
|
id: string;
|
|
671
1035
|
|
|
1036
|
+
/**
|
|
1037
|
+
* The date and time the user badge was created
|
|
1038
|
+
*/
|
|
1039
|
+
createdAt: string;
|
|
1040
|
+
|
|
672
1041
|
/**
|
|
673
1042
|
* UUID of the badge (converted to lowercase)
|
|
674
1043
|
*/
|
|
@@ -684,6 +1053,11 @@ export namespace BadgeListResponse {
|
|
|
684
1053
|
*/
|
|
685
1054
|
status: 'active' | 'inactive' | 'revoked';
|
|
686
1055
|
|
|
1056
|
+
/**
|
|
1057
|
+
* The date and time the user badge was updated
|
|
1058
|
+
*/
|
|
1059
|
+
updatedAt: string;
|
|
1060
|
+
|
|
687
1061
|
/**
|
|
688
1062
|
* UUID of the user (converted to lowercase)
|
|
689
1063
|
*/
|
|
@@ -694,10 +1068,49 @@ export namespace BadgeListResponse {
|
|
|
694
1068
|
*/
|
|
695
1069
|
websiteId: string;
|
|
696
1070
|
|
|
1071
|
+
/**
|
|
1072
|
+
* Whether the user has dismissed the badge in the UI
|
|
1073
|
+
*/
|
|
1074
|
+
dismissedInUi?: boolean;
|
|
1075
|
+
|
|
697
1076
|
/**
|
|
698
1077
|
* Array of progress for the badge
|
|
699
1078
|
*/
|
|
700
1079
|
progress?: unknown;
|
|
1080
|
+
|
|
1081
|
+
/**
|
|
1082
|
+
* User associated with the user badge
|
|
1083
|
+
*/
|
|
1084
|
+
user?: LoyaltyBadgeUser.User;
|
|
1085
|
+
}
|
|
1086
|
+
|
|
1087
|
+
export namespace LoyaltyBadgeUser {
|
|
1088
|
+
/**
|
|
1089
|
+
* User associated with the user badge
|
|
1090
|
+
*/
|
|
1091
|
+
export interface User {
|
|
1092
|
+
/**
|
|
1093
|
+
* UUID of the user (converted to lowercase)
|
|
1094
|
+
*/
|
|
1095
|
+
id: string;
|
|
1096
|
+
|
|
1097
|
+
/**
|
|
1098
|
+
* Wallet address of the user
|
|
1099
|
+
*/
|
|
1100
|
+
walletAddress: string;
|
|
1101
|
+
}
|
|
1102
|
+
}
|
|
1103
|
+
|
|
1104
|
+
export interface LoyaltyRule {
|
|
1105
|
+
/**
|
|
1106
|
+
* UUID of the loyalty rule (converted to lowercase)
|
|
1107
|
+
*/
|
|
1108
|
+
id: string;
|
|
1109
|
+
|
|
1110
|
+
/**
|
|
1111
|
+
* The name of the loyalty rule
|
|
1112
|
+
*/
|
|
1113
|
+
name: string;
|
|
701
1114
|
}
|
|
702
1115
|
}
|
|
703
1116
|
|
|
@@ -710,6 +1123,11 @@ export interface BadgeDeleteResponse {
|
|
|
710
1123
|
*/
|
|
711
1124
|
id: string;
|
|
712
1125
|
|
|
1126
|
+
/**
|
|
1127
|
+
* The date and time the badge was created
|
|
1128
|
+
*/
|
|
1129
|
+
createdAt: string;
|
|
1130
|
+
|
|
713
1131
|
/**
|
|
714
1132
|
* The description of the badge
|
|
715
1133
|
*/
|
|
@@ -730,10 +1148,25 @@ export interface BadgeDeleteResponse {
|
|
|
730
1148
|
*/
|
|
731
1149
|
name: string;
|
|
732
1150
|
|
|
1151
|
+
/**
|
|
1152
|
+
* The date and time the badge was updated
|
|
1153
|
+
*/
|
|
1154
|
+
updatedAt: string;
|
|
1155
|
+
|
|
1156
|
+
/**
|
|
1157
|
+
* Array of data jobs associated with the badge
|
|
1158
|
+
*/
|
|
1159
|
+
dataJobs?: Array<BadgeDeleteResponse.DataJob>;
|
|
1160
|
+
|
|
733
1161
|
/**
|
|
734
1162
|
* Array of user badges
|
|
735
1163
|
*/
|
|
736
|
-
|
|
1164
|
+
loyaltyBadgeUsers?: Array<BadgeDeleteResponse.LoyaltyBadgeUser>;
|
|
1165
|
+
|
|
1166
|
+
/**
|
|
1167
|
+
* Array of loyalty rules associated with the badge
|
|
1168
|
+
*/
|
|
1169
|
+
loyaltyRules?: Array<BadgeDeleteResponse.LoyaltyRule>;
|
|
737
1170
|
}
|
|
738
1171
|
|
|
739
1172
|
export namespace BadgeDeleteResponse {
|
|
@@ -754,7 +1187,7 @@ export namespace BadgeDeleteResponse {
|
|
|
754
1187
|
association: Array<LoyaltyCondition.Association>;
|
|
755
1188
|
|
|
756
1189
|
/**
|
|
757
|
-
*
|
|
1190
|
+
* URL of the CSV file
|
|
758
1191
|
*/
|
|
759
1192
|
csvUrl: string | null;
|
|
760
1193
|
|
|
@@ -787,6 +1220,11 @@ export namespace BadgeDeleteResponse {
|
|
|
787
1220
|
* The type of the condition
|
|
788
1221
|
*/
|
|
789
1222
|
type: 'rule' | 'rules' | 'points' | 'section' | 'level' | 'api' | 'badge' | 'badges' | 'csv';
|
|
1223
|
+
|
|
1224
|
+
/**
|
|
1225
|
+
* Array of CSV files associated with the condition
|
|
1226
|
+
*/
|
|
1227
|
+
csvFiles?: Array<LoyaltyCondition.CsvFile>;
|
|
790
1228
|
}
|
|
791
1229
|
|
|
792
1230
|
export namespace LoyaltyCondition {
|
|
@@ -863,6 +1301,55 @@ export namespace BadgeDeleteResponse {
|
|
|
863
1301
|
name: string;
|
|
864
1302
|
}
|
|
865
1303
|
}
|
|
1304
|
+
|
|
1305
|
+
export interface CsvFile {
|
|
1306
|
+
/**
|
|
1307
|
+
* UUID of the CSV file (converted to lowercase)
|
|
1308
|
+
*/
|
|
1309
|
+
id: string;
|
|
1310
|
+
|
|
1311
|
+
/**
|
|
1312
|
+
* The description of the CSV file
|
|
1313
|
+
*/
|
|
1314
|
+
description: string | null;
|
|
1315
|
+
|
|
1316
|
+
/**
|
|
1317
|
+
* The name of the CSV file
|
|
1318
|
+
*/
|
|
1319
|
+
name: string | null;
|
|
1320
|
+
|
|
1321
|
+
/**
|
|
1322
|
+
* The URL of the CSV file
|
|
1323
|
+
*/
|
|
1324
|
+
url: string | null;
|
|
1325
|
+
}
|
|
1326
|
+
}
|
|
1327
|
+
|
|
1328
|
+
export interface DataJob {
|
|
1329
|
+
/**
|
|
1330
|
+
* UUID of the data job (converted to lowercase)
|
|
1331
|
+
*/
|
|
1332
|
+
id: string;
|
|
1333
|
+
|
|
1334
|
+
/**
|
|
1335
|
+
* The date and time the data job was created
|
|
1336
|
+
*/
|
|
1337
|
+
createdAt: string;
|
|
1338
|
+
|
|
1339
|
+
/**
|
|
1340
|
+
* The status of the data job
|
|
1341
|
+
*/
|
|
1342
|
+
status: 'pending' | 'complete' | 'failed';
|
|
1343
|
+
|
|
1344
|
+
/**
|
|
1345
|
+
* The date and time the data job was updated
|
|
1346
|
+
*/
|
|
1347
|
+
updatedAt: string;
|
|
1348
|
+
|
|
1349
|
+
/**
|
|
1350
|
+
* The message associated with the data job
|
|
1351
|
+
*/
|
|
1352
|
+
message?: string | null;
|
|
866
1353
|
}
|
|
867
1354
|
|
|
868
1355
|
export interface LoyaltyBadgeUser {
|
|
@@ -871,6 +1358,11 @@ export namespace BadgeDeleteResponse {
|
|
|
871
1358
|
*/
|
|
872
1359
|
id: string;
|
|
873
1360
|
|
|
1361
|
+
/**
|
|
1362
|
+
* The date and time the user badge was created
|
|
1363
|
+
*/
|
|
1364
|
+
createdAt: string;
|
|
1365
|
+
|
|
874
1366
|
/**
|
|
875
1367
|
* UUID of the badge (converted to lowercase)
|
|
876
1368
|
*/
|
|
@@ -886,6 +1378,11 @@ export namespace BadgeDeleteResponse {
|
|
|
886
1378
|
*/
|
|
887
1379
|
status: 'active' | 'inactive' | 'revoked';
|
|
888
1380
|
|
|
1381
|
+
/**
|
|
1382
|
+
* The date and time the user badge was updated
|
|
1383
|
+
*/
|
|
1384
|
+
updatedAt: string;
|
|
1385
|
+
|
|
889
1386
|
/**
|
|
890
1387
|
* UUID of the user (converted to lowercase)
|
|
891
1388
|
*/
|
|
@@ -896,10 +1393,49 @@ export namespace BadgeDeleteResponse {
|
|
|
896
1393
|
*/
|
|
897
1394
|
websiteId: string;
|
|
898
1395
|
|
|
1396
|
+
/**
|
|
1397
|
+
* Whether the user has dismissed the badge in the UI
|
|
1398
|
+
*/
|
|
1399
|
+
dismissedInUi?: boolean;
|
|
1400
|
+
|
|
899
1401
|
/**
|
|
900
1402
|
* Array of progress for the badge
|
|
901
1403
|
*/
|
|
902
1404
|
progress?: unknown;
|
|
1405
|
+
|
|
1406
|
+
/**
|
|
1407
|
+
* User associated with the user badge
|
|
1408
|
+
*/
|
|
1409
|
+
user?: LoyaltyBadgeUser.User;
|
|
1410
|
+
}
|
|
1411
|
+
|
|
1412
|
+
export namespace LoyaltyBadgeUser {
|
|
1413
|
+
/**
|
|
1414
|
+
* User associated with the user badge
|
|
1415
|
+
*/
|
|
1416
|
+
export interface User {
|
|
1417
|
+
/**
|
|
1418
|
+
* UUID of the user (converted to lowercase)
|
|
1419
|
+
*/
|
|
1420
|
+
id: string;
|
|
1421
|
+
|
|
1422
|
+
/**
|
|
1423
|
+
* Wallet address of the user
|
|
1424
|
+
*/
|
|
1425
|
+
walletAddress: string;
|
|
1426
|
+
}
|
|
1427
|
+
}
|
|
1428
|
+
|
|
1429
|
+
export interface LoyaltyRule {
|
|
1430
|
+
/**
|
|
1431
|
+
* UUID of the loyalty rule (converted to lowercase)
|
|
1432
|
+
*/
|
|
1433
|
+
id: string;
|
|
1434
|
+
|
|
1435
|
+
/**
|
|
1436
|
+
* The name of the loyalty rule
|
|
1437
|
+
*/
|
|
1438
|
+
name: string;
|
|
903
1439
|
}
|
|
904
1440
|
}
|
|
905
1441
|
|
|
@@ -952,6 +1488,11 @@ export namespace BadgeRewardResponse {
|
|
|
952
1488
|
}
|
|
953
1489
|
|
|
954
1490
|
export interface BadgeCreateParams {
|
|
1491
|
+
/**
|
|
1492
|
+
* Array of conditions for the badge
|
|
1493
|
+
*/
|
|
1494
|
+
conditions: Array<BadgeCreateParams.Condition>;
|
|
1495
|
+
|
|
955
1496
|
/**
|
|
956
1497
|
* The URL of the badge image
|
|
957
1498
|
*/
|
|
@@ -967,16 +1508,13 @@ export interface BadgeCreateParams {
|
|
|
967
1508
|
*/
|
|
968
1509
|
organizationId: string;
|
|
969
1510
|
|
|
970
|
-
/**
|
|
971
|
-
* Array of rules for the badge
|
|
972
|
-
*/
|
|
973
|
-
rules: Array<BadgeCreateParams.Rule>;
|
|
974
|
-
|
|
975
1511
|
/**
|
|
976
1512
|
* UUID of the website (optional, converted to lowercase)
|
|
977
1513
|
*/
|
|
978
1514
|
websiteId: string;
|
|
979
1515
|
|
|
1516
|
+
csvFiles?: Array<BadgeCreateParams.CsvFile>;
|
|
1517
|
+
|
|
980
1518
|
/**
|
|
981
1519
|
* The description of the badge
|
|
982
1520
|
*/
|
|
@@ -984,12 +1522,7 @@ export interface BadgeCreateParams {
|
|
|
984
1522
|
}
|
|
985
1523
|
|
|
986
1524
|
export namespace BadgeCreateParams {
|
|
987
|
-
export interface
|
|
988
|
-
/**
|
|
989
|
-
* The type of rule
|
|
990
|
-
*/
|
|
991
|
-
type: 'rule' | 'rules' | 'points' | 'section' | 'level' | 'api' | 'badge' | 'badges' | 'csv';
|
|
992
|
-
|
|
1525
|
+
export interface Condition {
|
|
993
1526
|
/**
|
|
994
1527
|
* The amount of the rule
|
|
995
1528
|
*/
|
|
@@ -1023,7 +1556,7 @@ export namespace BadgeCreateParams {
|
|
|
1023
1556
|
/**
|
|
1024
1557
|
* UUID of the loyalty rule chain (optional, converted to lowercase)
|
|
1025
1558
|
*/
|
|
1026
|
-
loyaltyRuleChainId?: string;
|
|
1559
|
+
loyaltyRuleChainId?: string | null;
|
|
1027
1560
|
|
|
1028
1561
|
/**
|
|
1029
1562
|
* Array of UUIDs of the rule group (optional, converted to lowercase)
|
|
@@ -1044,10 +1577,25 @@ export namespace BadgeCreateParams {
|
|
|
1044
1577
|
* The number of rules that need to be fulfilled to satisfy the condition
|
|
1045
1578
|
*/
|
|
1046
1579
|
requiredCount?: number | null;
|
|
1580
|
+
|
|
1581
|
+
/**
|
|
1582
|
+
* The type of rule
|
|
1583
|
+
*/
|
|
1584
|
+
type?: 'rule' | 'rules' | 'points' | 'section' | 'level' | 'api' | 'badge' | 'badges' | 'csv';
|
|
1585
|
+
}
|
|
1586
|
+
|
|
1587
|
+
export interface CsvFile {
|
|
1588
|
+
src: string;
|
|
1589
|
+
|
|
1590
|
+
description?: string;
|
|
1591
|
+
|
|
1592
|
+
name?: string;
|
|
1047
1593
|
}
|
|
1048
1594
|
}
|
|
1049
1595
|
|
|
1050
1596
|
export interface BadgeUpdateParams {
|
|
1597
|
+
csvFiles?: Array<BadgeUpdateParams.CsvFile>;
|
|
1598
|
+
|
|
1051
1599
|
/**
|
|
1052
1600
|
* The description of the badge
|
|
1053
1601
|
*/
|
|
@@ -1064,11 +1612,21 @@ export interface BadgeUpdateParams {
|
|
|
1064
1612
|
name?: string;
|
|
1065
1613
|
}
|
|
1066
1614
|
|
|
1615
|
+
export namespace BadgeUpdateParams {
|
|
1616
|
+
export interface CsvFile {
|
|
1617
|
+
src: string;
|
|
1618
|
+
|
|
1619
|
+
description?: string;
|
|
1620
|
+
|
|
1621
|
+
name?: string;
|
|
1622
|
+
}
|
|
1623
|
+
}
|
|
1624
|
+
|
|
1067
1625
|
export interface BadgeListParams {
|
|
1068
1626
|
/**
|
|
1069
1627
|
* Array of badge IDs (converted to lowercase) to fetch
|
|
1070
1628
|
*/
|
|
1071
|
-
badgeIds?: Array<string>;
|
|
1629
|
+
badgeIds?: string | Array<string>;
|
|
1072
1630
|
|
|
1073
1631
|
/**
|
|
1074
1632
|
* Include deleted badges in the response
|
|
@@ -1091,9 +1649,24 @@ export interface BadgeListParams {
|
|
|
1091
1649
|
startingAfter?: string;
|
|
1092
1650
|
|
|
1093
1651
|
/**
|
|
1094
|
-
*
|
|
1652
|
+
* External identifier of the user group
|
|
1095
1653
|
*/
|
|
1096
|
-
|
|
1654
|
+
userGroupExternalIdentifier?: string;
|
|
1655
|
+
|
|
1656
|
+
/**
|
|
1657
|
+
* UUID of the user group
|
|
1658
|
+
*/
|
|
1659
|
+
userGroupId?: string;
|
|
1660
|
+
|
|
1661
|
+
/**
|
|
1662
|
+
* UUID of the user, or array of UUID.
|
|
1663
|
+
*/
|
|
1664
|
+
userId?: string | Array<string>;
|
|
1665
|
+
|
|
1666
|
+
/**
|
|
1667
|
+
* Wallet Address of the user, or array of wallet addresses.
|
|
1668
|
+
*/
|
|
1669
|
+
walletAddress?: string | Array<string>;
|
|
1097
1670
|
|
|
1098
1671
|
/**
|
|
1099
1672
|
* UUID of the website (optional, converted to lowercase)
|
|
@@ -1102,6 +1675,11 @@ export interface BadgeListParams {
|
|
|
1102
1675
|
}
|
|
1103
1676
|
|
|
1104
1677
|
export interface BadgeRevokeParams {
|
|
1678
|
+
/**
|
|
1679
|
+
* Status of the badge
|
|
1680
|
+
*/
|
|
1681
|
+
status?: 'active' | 'inactive' | 'revoked';
|
|
1682
|
+
|
|
1105
1683
|
/**
|
|
1106
1684
|
* UUID of the user (converted to lowercase)
|
|
1107
1685
|
*/
|
|
@@ -1114,6 +1692,11 @@ export interface BadgeRevokeParams {
|
|
|
1114
1692
|
}
|
|
1115
1693
|
|
|
1116
1694
|
export interface BadgeRewardParams {
|
|
1695
|
+
/**
|
|
1696
|
+
* Status of the badge
|
|
1697
|
+
*/
|
|
1698
|
+
status?: 'active' | 'inactive' | 'revoked';
|
|
1699
|
+
|
|
1117
1700
|
/**
|
|
1118
1701
|
* UUID of the user (converted to lowercase)
|
|
1119
1702
|
*/
|