@snagsolutions/sdk 0.1.0-alpha.23 → 0.1.0-alpha.231

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (328) hide show
  1. package/CHANGELOG.md +13 -254
  2. package/LICENSE +1 -1
  3. package/README.md +15 -23
  4. package/core.d.ts +19 -5
  5. package/core.d.ts.map +1 -1
  6. package/core.js +29 -17
  7. package/core.js.map +1 -1
  8. package/core.mjs +29 -17
  9. package/core.mjs.map +1 -1
  10. package/index.d.mts +14 -8
  11. package/index.d.ts +14 -8
  12. package/index.d.ts.map +1 -1
  13. package/index.js +12 -5
  14. package/index.js.map +1 -1
  15. package/index.mjs +13 -6
  16. package/index.mjs.map +1 -1
  17. package/package.json +4 -5
  18. package/resource.d.ts +1 -1
  19. package/resource.d.ts.map +1 -1
  20. package/resource.js.map +1 -1
  21. package/resource.mjs.map +1 -1
  22. package/resources/assets.d.ts +16 -2
  23. package/resources/assets.d.ts.map +1 -1
  24. package/resources/assets.js +8 -0
  25. package/resources/assets.js.map +1 -1
  26. package/resources/assets.mjs +8 -0
  27. package/resources/assets.mjs.map +1 -1
  28. package/resources/auctions/auctions.d.ts +368 -0
  29. package/resources/auctions/auctions.d.ts.map +1 -0
  30. package/resources/auctions/auctions.js +72 -0
  31. package/resources/auctions/auctions.js.map +1 -0
  32. package/resources/auctions/auctions.mjs +45 -0
  33. package/resources/auctions/auctions.mjs.map +1 -0
  34. package/resources/auctions/index.d.ts +3 -0
  35. package/resources/auctions/index.d.ts.map +1 -0
  36. package/resources/auctions/index.js +9 -0
  37. package/resources/auctions/index.js.map +1 -0
  38. package/resources/auctions/index.mjs +4 -0
  39. package/resources/auctions/index.mjs.map +1 -0
  40. package/resources/auctions/website-user-attributes/index.d.ts +3 -0
  41. package/resources/auctions/website-user-attributes/index.d.ts.map +1 -0
  42. package/resources/auctions/website-user-attributes/index.js +9 -0
  43. package/resources/auctions/website-user-attributes/index.js.map +1 -0
  44. package/resources/auctions/website-user-attributes/index.mjs +4 -0
  45. package/resources/auctions/website-user-attributes/index.mjs.map +1 -0
  46. package/resources/auctions/website-user-attributes/values.d.ts +126 -0
  47. package/resources/auctions/website-user-attributes/values.d.ts.map +1 -0
  48. package/resources/auctions/website-user-attributes/values.js +49 -0
  49. package/resources/auctions/website-user-attributes/values.js.map +1 -0
  50. package/resources/auctions/website-user-attributes/values.mjs +45 -0
  51. package/resources/auctions/website-user-attributes/values.mjs.map +1 -0
  52. package/resources/auctions/website-user-attributes/website-user-attributes.d.ts +136 -0
  53. package/resources/auctions/website-user-attributes/website-user-attributes.d.ts.map +1 -0
  54. package/resources/auctions/website-user-attributes/website-user-attributes.js +76 -0
  55. package/resources/auctions/website-user-attributes/website-user-attributes.js.map +1 -0
  56. package/resources/auctions/website-user-attributes/website-user-attributes.mjs +49 -0
  57. package/resources/auctions/website-user-attributes/website-user-attributes.mjs.map +1 -0
  58. package/resources/auctions/website-user-attributes.d.ts +2 -0
  59. package/resources/auctions/website-user-attributes.d.ts.map +1 -0
  60. package/resources/auctions/website-user-attributes.js +19 -0
  61. package/resources/auctions/website-user-attributes.js.map +1 -0
  62. package/resources/auctions/website-user-attributes.mjs +3 -0
  63. package/resources/auctions/website-user-attributes.mjs.map +1 -0
  64. package/resources/auctions.d.ts +1 -133
  65. package/resources/auctions.d.ts.map +1 -1
  66. package/resources/auctions.js +15 -22
  67. package/resources/auctions.js.map +1 -1
  68. package/resources/auctions.mjs +1 -20
  69. package/resources/auctions.mjs.map +1 -1
  70. package/resources/auth.d.ts +66 -6
  71. package/resources/auth.d.ts.map +1 -1
  72. package/resources/auth.js +6 -0
  73. package/resources/auth.js.map +1 -1
  74. package/resources/auth.mjs +6 -0
  75. package/resources/auth.mjs.map +1 -1
  76. package/resources/index.d.ts +5 -4
  77. package/resources/index.d.ts.map +1 -1
  78. package/resources/index.js +5 -3
  79. package/resources/index.js.map +1 -1
  80. package/resources/index.mjs +4 -3
  81. package/resources/index.mjs.map +1 -1
  82. package/resources/loyalty/account-streaks.d.ts +96 -0
  83. package/resources/loyalty/account-streaks.d.ts.map +1 -0
  84. package/resources/loyalty/account-streaks.js +24 -0
  85. package/resources/loyalty/account-streaks.js.map +1 -0
  86. package/resources/loyalty/account-streaks.mjs +20 -0
  87. package/resources/loyalty/account-streaks.mjs.map +1 -0
  88. package/resources/loyalty/accounts.d.ts +60 -16
  89. package/resources/loyalty/accounts.d.ts.map +1 -1
  90. package/resources/loyalty/accounts.js +14 -0
  91. package/resources/loyalty/accounts.js.map +1 -1
  92. package/resources/loyalty/accounts.mjs +14 -0
  93. package/resources/loyalty/accounts.mjs.map +1 -1
  94. package/resources/loyalty/badges.d.ts +666 -135
  95. package/resources/loyalty/badges.d.ts.map +1 -1
  96. package/resources/loyalty/badges.js +19 -1
  97. package/resources/loyalty/badges.js.map +1 -1
  98. package/resources/loyalty/badges.mjs +19 -1
  99. package/resources/loyalty/badges.mjs.map +1 -1
  100. package/resources/loyalty/currencies.d.ts +19 -0
  101. package/resources/loyalty/currencies.d.ts.map +1 -1
  102. package/resources/loyalty/currencies.js +19 -0
  103. package/resources/loyalty/currencies.js.map +1 -1
  104. package/resources/loyalty/currencies.mjs +19 -0
  105. package/resources/loyalty/currencies.mjs.map +1 -1
  106. package/resources/loyalty/index.d.ts +3 -3
  107. package/resources/loyalty/index.d.ts.map +1 -1
  108. package/resources/loyalty/index.js +5 -5
  109. package/resources/loyalty/index.js.map +1 -1
  110. package/resources/loyalty/index.mjs +2 -2
  111. package/resources/loyalty/index.mjs.map +1 -1
  112. package/resources/loyalty/loyalty.d.ts +9 -9
  113. package/resources/loyalty/loyalty.d.ts.map +1 -1
  114. package/resources/loyalty/loyalty.js +6 -6
  115. package/resources/loyalty/loyalty.js.map +1 -1
  116. package/resources/loyalty/loyalty.mjs +6 -6
  117. package/resources/loyalty/loyalty.mjs.map +1 -1
  118. package/resources/loyalty/multipliers.d.ts +39 -2
  119. package/resources/loyalty/multipliers.d.ts.map +1 -1
  120. package/resources/loyalty/multipliers.js +23 -0
  121. package/resources/loyalty/multipliers.js.map +1 -1
  122. package/resources/loyalty/multipliers.mjs +23 -0
  123. package/resources/loyalty/multipliers.mjs.map +1 -1
  124. package/resources/loyalty/questions-responses.d.ts +55 -4
  125. package/resources/loyalty/questions-responses.d.ts.map +1 -1
  126. package/resources/loyalty/questions-responses.js +9 -0
  127. package/resources/loyalty/questions-responses.js.map +1 -1
  128. package/resources/loyalty/questions-responses.mjs +9 -0
  129. package/resources/loyalty/questions-responses.mjs.map +1 -1
  130. package/resources/loyalty/questions.d.ts +60 -6
  131. package/resources/loyalty/questions.d.ts.map +1 -1
  132. package/resources/loyalty/questions.js +39 -0
  133. package/resources/loyalty/questions.js.map +1 -1
  134. package/resources/loyalty/questions.mjs +39 -0
  135. package/resources/loyalty/questions.mjs.map +1 -1
  136. package/resources/loyalty/rule-edits.d.ts +2842 -8
  137. package/resources/loyalty/rule-edits.d.ts.map +1 -1
  138. package/resources/loyalty/rule-edits.js +14 -0
  139. package/resources/loyalty/rule-edits.js.map +1 -1
  140. package/resources/loyalty/rule-edits.mjs +14 -0
  141. package/resources/loyalty/rule-edits.mjs.map +1 -1
  142. package/resources/loyalty/rule-groups.d.ts +279 -56
  143. package/resources/loyalty/rule-groups.d.ts.map +1 -1
  144. package/resources/loyalty/rule-groups.js +18 -0
  145. package/resources/loyalty/rule-groups.js.map +1 -1
  146. package/resources/loyalty/rule-groups.mjs +18 -0
  147. package/resources/loyalty/rule-groups.mjs.map +1 -1
  148. package/resources/loyalty/rules.d.ts +2299 -365
  149. package/resources/loyalty/rules.d.ts.map +1 -1
  150. package/resources/loyalty/rules.js +40 -9
  151. package/resources/loyalty/rules.js.map +1 -1
  152. package/resources/loyalty/rules.mjs +40 -9
  153. package/resources/loyalty/rules.mjs.map +1 -1
  154. package/resources/loyalty/transactions/index.d.ts +4 -0
  155. package/resources/loyalty/transactions/index.d.ts.map +1 -0
  156. package/resources/loyalty/transactions/index.js +11 -0
  157. package/resources/loyalty/transactions/index.js.map +1 -0
  158. package/resources/loyalty/transactions/index.mjs +5 -0
  159. package/resources/loyalty/transactions/index.mjs.map +1 -0
  160. package/resources/loyalty/transactions/posts.d.ts +145 -0
  161. package/resources/loyalty/transactions/posts.d.ts.map +1 -0
  162. package/resources/loyalty/transactions/posts.js +32 -0
  163. package/resources/loyalty/transactions/posts.js.map +1 -0
  164. package/resources/loyalty/transactions/posts.mjs +28 -0
  165. package/resources/loyalty/transactions/posts.mjs.map +1 -0
  166. package/resources/loyalty/transactions/rule-statuses.d.ts +121 -0
  167. package/resources/loyalty/transactions/rule-statuses.d.ts.map +1 -0
  168. package/resources/loyalty/transactions/rule-statuses.js +30 -0
  169. package/resources/loyalty/transactions/rule-statuses.js.map +1 -0
  170. package/resources/loyalty/transactions/rule-statuses.mjs +26 -0
  171. package/resources/loyalty/transactions/rule-statuses.mjs.map +1 -0
  172. package/resources/loyalty/transactions/transactions.d.ts +564 -0
  173. package/resources/loyalty/transactions/transactions.d.ts.map +1 -0
  174. package/resources/loyalty/transactions/transactions.js +110 -0
  175. package/resources/loyalty/transactions/transactions.js.map +1 -0
  176. package/resources/loyalty/transactions/transactions.mjs +83 -0
  177. package/resources/loyalty/transactions/transactions.mjs.map +1 -0
  178. package/resources/loyalty/transactions.d.ts +1 -248
  179. package/resources/loyalty/transactions.d.ts.map +1 -1
  180. package/resources/loyalty/transactions.js +15 -18
  181. package/resources/loyalty/transactions.js.map +1 -1
  182. package/resources/loyalty/transactions.mjs +1 -16
  183. package/resources/loyalty/transactions.mjs.map +1 -1
  184. package/resources/minting/allowlist.d.ts +84 -0
  185. package/resources/minting/allowlist.d.ts.map +1 -0
  186. package/resources/minting/allowlist.js +42 -0
  187. package/resources/minting/allowlist.js.map +1 -0
  188. package/resources/minting/allowlist.mjs +38 -0
  189. package/resources/minting/allowlist.mjs.map +1 -0
  190. package/resources/minting/contracts.d.ts +165 -0
  191. package/resources/minting/contracts.d.ts.map +1 -0
  192. package/resources/minting/contracts.js +30 -0
  193. package/resources/minting/contracts.js.map +1 -0
  194. package/resources/minting/contracts.mjs +26 -0
  195. package/resources/minting/contracts.mjs.map +1 -0
  196. package/resources/minting/index.d.ts +5 -0
  197. package/resources/minting/index.d.ts.map +1 -0
  198. package/resources/minting/index.js +13 -0
  199. package/resources/minting/index.js.map +1 -0
  200. package/resources/minting/index.mjs +6 -0
  201. package/resources/minting/index.mjs.map +1 -0
  202. package/resources/minting/minting.d.ts +142 -0
  203. package/resources/minting/minting.d.ts.map +1 -0
  204. package/resources/minting/minting.js +79 -0
  205. package/resources/minting/minting.js.map +1 -0
  206. package/resources/minting/minting.mjs +52 -0
  207. package/resources/minting/minting.mjs.map +1 -0
  208. package/resources/minting/status.d.ts +44 -0
  209. package/resources/minting/status.d.ts.map +1 -0
  210. package/resources/minting/status.js +33 -0
  211. package/resources/minting/status.js.map +1 -0
  212. package/resources/minting/status.mjs +29 -0
  213. package/resources/minting/status.mjs.map +1 -0
  214. package/resources/minting.d.ts +1 -94
  215. package/resources/minting.d.ts.map +1 -1
  216. package/resources/minting.js +15 -11
  217. package/resources/minting.js.map +1 -1
  218. package/resources/minting.mjs +1 -9
  219. package/resources/minting.mjs.map +1 -1
  220. package/resources/referral/referral.d.ts +12 -3
  221. package/resources/referral/referral.d.ts.map +1 -1
  222. package/resources/referral/referral.js +11 -5
  223. package/resources/referral/referral.js.map +1 -1
  224. package/resources/referral/referral.mjs +11 -5
  225. package/resources/referral/referral.mjs.map +1 -1
  226. package/resources/referral/users.d.ts +30 -3
  227. package/resources/referral/users.d.ts.map +1 -1
  228. package/resources/referral/users.js +12 -4
  229. package/resources/referral/users.js.map +1 -1
  230. package/resources/referral/users.mjs +12 -4
  231. package/resources/referral/users.mjs.map +1 -1
  232. package/resources/token-claims.d.ts +160 -0
  233. package/resources/token-claims.d.ts.map +1 -0
  234. package/resources/token-claims.js +46 -0
  235. package/resources/token-claims.js.map +1 -0
  236. package/resources/token-claims.mjs +42 -0
  237. package/resources/token-claims.mjs.map +1 -0
  238. package/resources/users/index.d.ts +1 -1
  239. package/resources/users/index.d.ts.map +1 -1
  240. package/resources/users/index.js.map +1 -1
  241. package/resources/users/index.mjs.map +1 -1
  242. package/resources/users/metadatas.d.ts +36 -3
  243. package/resources/users/metadatas.d.ts.map +1 -1
  244. package/resources/users/metadatas.js.map +1 -1
  245. package/resources/users/metadatas.mjs.map +1 -1
  246. package/resources/users/users.d.ts +196 -35
  247. package/resources/users/users.d.ts.map +1 -1
  248. package/resources/users/users.js +58 -1
  249. package/resources/users/users.js.map +1 -1
  250. package/resources/users/users.mjs +58 -1
  251. package/resources/users/users.mjs.map +1 -1
  252. package/resources/websites/website-collections.d.ts +22 -1
  253. package/resources/websites/website-collections.d.ts.map +1 -1
  254. package/resources/websites/website-collections.js +21 -0
  255. package/resources/websites/website-collections.js.map +1 -1
  256. package/resources/websites/website-collections.mjs +21 -0
  257. package/resources/websites/website-collections.mjs.map +1 -1
  258. package/resources/websites/website-user-roles.d.ts +24 -1
  259. package/resources/websites/website-user-roles.d.ts.map +1 -1
  260. package/resources/websites/website-user-roles.js +23 -0
  261. package/resources/websites/website-user-roles.js.map +1 -1
  262. package/resources/websites/website-user-roles.mjs +23 -0
  263. package/resources/websites/website-user-roles.mjs.map +1 -1
  264. package/resources/websites/websites.d.ts +118 -0
  265. package/resources/websites/websites.d.ts.map +1 -1
  266. package/resources/websites/websites.js +7 -0
  267. package/resources/websites/websites.js.map +1 -1
  268. package/resources/websites/websites.mjs +7 -0
  269. package/resources/websites/websites.mjs.map +1 -1
  270. package/src/core.ts +45 -16
  271. package/src/index.ts +82 -4
  272. package/src/resource.ts +1 -1
  273. package/src/resources/assets.ts +18 -3
  274. package/src/resources/auctions/auctions.ts +561 -0
  275. package/src/resources/auctions/index.ts +19 -0
  276. package/src/resources/auctions/website-user-attributes/index.ts +18 -0
  277. package/src/resources/auctions/website-user-attributes/values.ts +170 -0
  278. package/src/resources/auctions/website-user-attributes/website-user-attributes.ts +212 -0
  279. package/src/resources/auctions/website-user-attributes.ts +3 -0
  280. package/src/resources/auctions.ts +1 -207
  281. package/src/resources/auth.ts +121 -6
  282. package/src/resources/index.ts +41 -3
  283. package/src/resources/loyalty/account-streaks.ts +128 -0
  284. package/src/resources/loyalty/accounts.ts +65 -18
  285. package/src/resources/loyalty/badges.ts +790 -146
  286. package/src/resources/loyalty/currencies.ts +19 -0
  287. package/src/resources/loyalty/index.ts +13 -2
  288. package/src/resources/loyalty/loyalty.ts +30 -12
  289. package/src/resources/loyalty/multipliers.ts +43 -4
  290. package/src/resources/loyalty/questions-responses.ts +64 -4
  291. package/src/resources/loyalty/questions.ts +64 -6
  292. package/src/resources/loyalty/rule-edits.ts +4118 -100
  293. package/src/resources/loyalty/rule-groups.ts +454 -64
  294. package/src/resources/loyalty/rules.ts +3499 -372
  295. package/src/resources/loyalty/transactions/index.ts +29 -0
  296. package/src/resources/loyalty/transactions/posts.ts +221 -0
  297. package/src/resources/loyalty/transactions/rule-statuses.ts +179 -0
  298. package/src/resources/loyalty/transactions/transactions.ts +914 -0
  299. package/src/resources/loyalty/transactions.ts +1 -440
  300. package/src/resources/minting/allowlist.ts +116 -0
  301. package/src/resources/minting/contracts.ts +408 -0
  302. package/src/resources/minting/index.ts +29 -0
  303. package/src/resources/minting/minting.ts +277 -0
  304. package/src/resources/minting/status.ts +70 -0
  305. package/src/resources/minting.ts +1 -157
  306. package/src/resources/referral/referral.ts +15 -11
  307. package/src/resources/referral/users.ts +45 -5
  308. package/src/resources/token-claims.ts +307 -0
  309. package/src/resources/users/index.ts +4 -0
  310. package/src/resources/users/metadatas.ts +61 -3
  311. package/src/resources/users/users.ts +264 -38
  312. package/src/resources/websites/website-collections.ts +41 -1
  313. package/src/resources/websites/website-user-roles.ts +26 -1
  314. package/src/resources/websites/websites.ts +142 -0
  315. package/src/version.ts +1 -1
  316. package/version.d.ts +1 -1
  317. package/version.d.ts.map +1 -1
  318. package/version.js +1 -1
  319. package/version.js.map +1 -1
  320. package/version.mjs +1 -1
  321. package/version.mjs.map +1 -1
  322. package/resources/loyalty/rule-chains.d.ts +0 -34
  323. package/resources/loyalty/rule-chains.d.ts.map +0 -1
  324. package/resources/loyalty/rule-chains.js +0 -15
  325. package/resources/loyalty/rule-chains.js.map +0 -1
  326. package/resources/loyalty/rule-chains.mjs +0 -11
  327. package/resources/loyalty/rule-chains.mjs.map +0 -1
  328. package/src/resources/loyalty/rule-chains.ts +0 -45
@@ -3,10 +3,24 @@ import * as Core from "../../core.js";
3
3
  export declare class RuleEdits extends APIResource {
4
4
  /**
5
5
  * Retrieve configured loyalty rule edits with optional pagination and filters
6
+ *
7
+ * @example
8
+ * ```ts
9
+ * const ruleEdits = await client.loyalty.ruleEdits.list({
10
+ * loyaltyRuleId: true,
11
+ * });
12
+ * ```
6
13
  */
7
14
  list(query: RuleEditListParams, options?: Core.RequestOptions): Core.APIPromise<RuleEditListResponse>;
8
15
  /**
9
16
  * Restore a loyalty rule from a rule edit
17
+ *
18
+ * @example
19
+ * ```ts
20
+ * const response = await client.loyalty.ruleEdits.restore(
21
+ * '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
22
+ * );
23
+ * ```
10
24
  */
11
25
  restore(id: string, body?: RuleEditRestoreParams | null | undefined, options?: Core.RequestOptions): Core.APIPromise<RuleEditRestoreResponse>;
12
26
  }
@@ -69,7 +83,7 @@ export declare namespace RuleEditListResponse {
69
83
  /**
70
84
  * Amount associated with the loyalty rule
71
85
  */
72
- amount: number;
86
+ amount: number | null;
73
87
  /**
74
88
  * Timestamp when the loyalty rule was created
75
89
  */
@@ -78,14 +92,34 @@ export declare namespace RuleEditListResponse {
78
92
  * Timestamp when the loyalty rule was deleted (if applicable)
79
93
  */
80
94
  deletedAt: string | null;
95
+ /**
96
+ * Description of the loyalty rule
97
+ */
98
+ description: string;
99
+ /**
100
+ * End time of the loyalty rule
101
+ */
102
+ endTime: string | null;
81
103
  /**
82
104
  * Frequency of the loyalty rule
83
105
  */
84
106
  frequency: string;
107
+ /**
108
+ * Name of the loyalty rule
109
+ */
110
+ name: string;
85
111
  /**
86
112
  * Unique identifier for the organization
87
113
  */
88
114
  organizationId: string;
115
+ /**
116
+ * Type of the reward
117
+ */
118
+ rewardType: 'points' | 'multiplier' | 'badge';
119
+ /**
120
+ * Start time of the loyalty rule
121
+ */
122
+ startTime: string | null;
89
123
  /**
90
124
  * Type of the loyalty rule
91
125
  */
@@ -102,10 +136,695 @@ export declare namespace RuleEditListResponse {
102
136
  * Optional address of the collection
103
137
  */
104
138
  collectionAddress?: string;
139
+ /**
140
+ * URL of the media associated with the loyalty rule
141
+ */
142
+ mediaUrl?: string | null;
105
143
  /**
106
144
  * Optional metadata for the loyalty rule
107
145
  */
108
- metadata?: Record<string, unknown>;
146
+ metadata?: {
147
+ [key: string]: Data.Metadata;
148
+ };
149
+ }
150
+ namespace Data {
151
+ interface Metadata {
152
+ /**
153
+ * Flag indicating if the rule allows multiple redemptions. Applies to Enter a Code
154
+ * only.
155
+ */
156
+ allowMultipleRedemptions?: boolean;
157
+ /**
158
+ * Array of loyalty rule IDs that count as check-in when completed. If ["any"] then
159
+ * any rule completions count as check-in.
160
+ */
161
+ autoCheckInRuleIds?: Array<(string & {}) | 'any'> | null;
162
+ /**
163
+ * Number of tokens per batch.
164
+ */
165
+ batchSize?: number | null;
166
+ /**
167
+ * Text displayed on the action button.
168
+ */
169
+ buttonText?: string | null;
170
+ /**
171
+ * Flag indicating if commenting is required.
172
+ */
173
+ checkComment?: boolean | null;
174
+ /**
175
+ * Flag indicating if liking the post is required.
176
+ */
177
+ checkLike?: boolean | null;
178
+ /**
179
+ * Flag indicating if reposting is required.
180
+ */
181
+ checkRepost?: boolean | null;
182
+ /**
183
+ * Text to check in the Twitter post, username, or bio.
184
+ */
185
+ checkText?: string | Array<string> | null;
186
+ /**
187
+ * Array of collections associated with the rule.
188
+ */
189
+ collection?: Array<Metadata.Collection>;
190
+ /**
191
+ * Conditions for completing the profile.
192
+ */
193
+ completeProfileConditions?: {
194
+ [key: string]: boolean;
195
+ } | null;
196
+ /**
197
+ * Description of the external rule condition (only for external rules)
198
+ */
199
+ conditionDescription?: string;
200
+ /**
201
+ * Object containing details for the call-to-action.
202
+ */
203
+ cta?: Metadata.Cta | null;
204
+ /**
205
+ * API key for custom rewards integration.
206
+ */
207
+ customRewardsApiKey?: string;
208
+ /**
209
+ * Flag indicating if the rule should use direct RPC to get the balance of tokens.
210
+ */
211
+ directRpc?: boolean;
212
+ /**
213
+ * Array of Discord servers, channels, and roles to join.
214
+ */
215
+ discordServersToJoin?: Array<Metadata.DiscordServersToJoin> | null;
216
+ /**
217
+ * Array of drip quests required to complete the rule.
218
+ */
219
+ dripQuestsToComplete?: Array<Metadata.DripQuestsToComplete> | null;
220
+ /**
221
+ * Flag indicating whether joining Discord servers is required.
222
+ */
223
+ enableJoinDiscordServers?: boolean | null;
224
+ /**
225
+ * Flag indicating whether streaks are enabled.
226
+ */
227
+ enableStreaks?: boolean | null;
228
+ /**
229
+ * Flag indicating whether the verified multiplier is enabled.
230
+ */
231
+ enableVerifiedMultiplier?: boolean;
232
+ /**
233
+ * Type of ERC20 token for the loyalty rule.
234
+ */
235
+ erc20Type?: 'erc20' | 'native';
236
+ /**
237
+ * Fill source of the order for the token sale
238
+ */
239
+ fillSource?: string;
240
+ /**
241
+ * Percentage reward given to a user for their first referral.
242
+ */
243
+ firstReferralReward?: number | null;
244
+ /**
245
+ * Name of the GitHub branch to check for PR merge.
246
+ */
247
+ githubBranchName?: string | null;
248
+ /**
249
+ * URL of the GitHub repository to check for star.
250
+ */
251
+ githubRepoUrl?: string | null;
252
+ /**
253
+ * Flag indicating whether the fill source is included.
254
+ */
255
+ hasFillSource?: boolean;
256
+ /**
257
+ * Indicates if the item has never been sold.
258
+ */
259
+ hasNeverSold?: boolean;
260
+ /**
261
+ * Indicates if the full royalty has been paid for items.
262
+ */
263
+ hasPaidFullRoyalty?: boolean;
264
+ /**
265
+ * Flag indicating if the sale currency is included.
266
+ */
267
+ hasSaleCurrency?: boolean;
268
+ /**
269
+ * Indicates if the user has a verified Twitter account.
270
+ */
271
+ hasVerifiedTwitter?: boolean;
272
+ /**
273
+ * URL of the image associated with the rule.
274
+ */
275
+ imageUrl?: string | null;
276
+ /**
277
+ * If enabled, the first transaction done on the platform will complete this rule
278
+ */
279
+ isCheckInOnEveryTxn?: boolean;
280
+ /**
281
+ * Indicates if the multiplier has been applied to rewards.
282
+ */
283
+ isMultiplierApplied?: boolean;
284
+ /**
285
+ * Flag indicating if the rule is restricted to new users.
286
+ */
287
+ isRestrictedToNewUsers?: boolean;
288
+ /**
289
+ * Flag indicating if rewards are applied retroactively.
290
+ */
291
+ isRetroactive?: boolean | null;
292
+ /**
293
+ * Flag indicating if the token hold multiplier is applied.
294
+ */
295
+ isTokenHoldMultiplier?: boolean;
296
+ /**
297
+ * Optional link associated with the metadata.
298
+ */
299
+ link?: string | null;
300
+ /**
301
+ * Liquidity pool details.
302
+ */
303
+ liquidity?: Metadata.Liquidity;
304
+ /**
305
+ * Maximum quantity constraint for token holding.
306
+ */
307
+ maxQty?: number | null;
308
+ /**
309
+ * Minimum follower count for the rule. Accepts both number and string values.
310
+ */
311
+ minimumFollowerCount?: number | null;
312
+ /**
313
+ * Minimum quantity constraint for token holding.
314
+ */
315
+ minQty?: number | null;
316
+ /**
317
+ * Array of loyalty currency IDs used for multipliers.
318
+ */
319
+ multiplierLoyaltyCurrencyIds?: Array<string> | null;
320
+ /**
321
+ * Flag indicating whether to include only known users.
322
+ */
323
+ onlyKnownUsers?: boolean;
324
+ /**
325
+ * Flag indicating whether to include only native tokens.
326
+ */
327
+ onlyNative?: boolean;
328
+ /**
329
+ * Flag indicating whether to include only non-listed items.
330
+ */
331
+ onlyNonListed?: boolean;
332
+ /**
333
+ * Indicates if only existing users are rewarded.
334
+ */
335
+ onlyRewardExistingUser?: boolean;
336
+ /**
337
+ * give points for only one token ownership per contract
338
+ */
339
+ onlyRewardSingleTokenOwnership?: boolean | null;
340
+ /**
341
+ * Pre-generated text template that will be used to prefill the post content.
342
+ */
343
+ preGeneratedPostText?: string | null;
344
+ /**
345
+ * Promotional code associated with the rule.
346
+ */
347
+ promoCode?: string;
348
+ /**
349
+ * URL of the CSV file containing promo codes.
350
+ */
351
+ promoCodeCsvUrl?: string;
352
+ /**
353
+ * Numbers of the promotional code to be generated.
354
+ */
355
+ promoCodeLength?: number | null;
356
+ /**
357
+ * Type of the promotional code.
358
+ */
359
+ promoCodeType?: 'code' | 'csv' | 'generate';
360
+ /**
361
+ * Array defining ranges and corresponding rewards.
362
+ */
363
+ range?: Array<Metadata.Range>;
364
+ /**
365
+ * ID of the Reddit post.
366
+ */
367
+ redditPostId?: string | null;
368
+ /**
369
+ * Object defining referral requirements.
370
+ */
371
+ referralRequirements?: Metadata.ReferralRequirements | null;
372
+ /**
373
+ * Lump sum reward given to a referrer.
374
+ */
375
+ referrerReward?: number | null;
376
+ /**
377
+ * Loyalty currency ID of the referrer reward.
378
+ */
379
+ referrerRewardLoyaltyCurrencyId?: string | null;
380
+ /**
381
+ * Flag indicating if the post link is required.
382
+ */
383
+ requirePostLink?: boolean | null;
384
+ /**
385
+ * Flag indicating if media metadata is required.
386
+ */
387
+ requirePostMediaLink?: boolean | null;
388
+ /**
389
+ * Flag indicating if the rule can also reward badges per range.
390
+ */
391
+ rewardBadgePerRange?: boolean;
392
+ /**
393
+ * Flag indicating if the reward is rewarded by batch.
394
+ */
395
+ rewardByBatch?: boolean | null;
396
+ /**
397
+ * Criteria to evaluate the reward.
398
+ */
399
+ rewardCriteria?: 'IMPRESSIONS_COUNT' | 'ELIGIBLE_POST' | null;
400
+ /**
401
+ * Flag indicating if the reward is rewarded per action.
402
+ */
403
+ rewardPerAction?: boolean | null;
404
+ /**
405
+ * Flag indicating if rewards are given per impression.
406
+ */
407
+ rewardPerImpression?: boolean | null;
408
+ /**
409
+ * Flag indicating if the rule should reward based on value of traded tokens
410
+ * instead of count.
411
+ */
412
+ rewardPerValue?: boolean;
413
+ /**
414
+ * Flag indicating if the rule should reward quality posts.
415
+ */
416
+ rewardQualityPosts?: boolean;
417
+ robinhoodSymbols?: Array<string> | null;
418
+ /**
419
+ * Wallet address of the user can only be used if userId is not provided
420
+ */
421
+ royaltyAddress?: string;
422
+ /**
423
+ * Royalty percentage of the item.
424
+ */
425
+ royaltyPercentage?: number;
426
+ /**
427
+ * Currency associated with sales.
428
+ */
429
+ saleCurrency?: string;
430
+ /**
431
+ * Percentage reward given for a second-level referral.
432
+ */
433
+ secondReferralReward?: number | null;
434
+ /**
435
+ * Flag indicating if the multiplier is skipped.
436
+ */
437
+ skipMultiplier?: boolean | null;
438
+ /**
439
+ * Object containing details of the associated smart contract.
440
+ */
441
+ smartContract?: Metadata.SmartContract;
442
+ /**
443
+ * Array of snapshot proposals for the rule.
444
+ */
445
+ snapshotProposals?: Array<Metadata.SnapshotProposal> | null;
446
+ /**
447
+ * Social media platform associated with the rule.
448
+ */
449
+ socialPlatform?: 'Custom' | 'Discord' | 'EpicGames' | 'Instagram' | 'Steam' | 'Telegram' | 'TikTok' | 'Twitch' | 'X(Twitter)' | 'YouTube' | 'Google' | 'GitHub' | 'Reddit' | null;
450
+ /**
451
+ * URL of the social platform's logo.
452
+ */
453
+ socialPlatformLogo?: string | null;
454
+ /**
455
+ * Name of the social platform.
456
+ */
457
+ socialPlatformName?: string | null;
458
+ /**
459
+ * ID of the Steam app.
460
+ */
461
+ steamAppId?: string | null;
462
+ /**
463
+ * Array of streak milestones and corresponding rewards.
464
+ */
465
+ streakArray?: Array<Metadata.StreakArray> | null;
466
+ /**
467
+ * Metadata for swap loyalty rules
468
+ */
469
+ swap?: Metadata.Swap;
470
+ /**
471
+ * ID of the Telegram channel.
472
+ */
473
+ telegramChannelId?: string | null;
474
+ /**
475
+ * Time delay in seconds to verify actions.
476
+ */
477
+ timeDelayToVerifySeconds?: string | number | null;
478
+ /**
479
+ * Flag indicating if all contracts are tracked.
480
+ */
481
+ trackAllContracts?: boolean | null;
482
+ /**
483
+ * Flag indicating if the progress is tracked. If enabled, the rule can only be
484
+ * completed once the progress is 100%.
485
+ */
486
+ trackProgress?: boolean | null;
487
+ /**
488
+ * URL of the associated Twitter account.
489
+ */
490
+ twitterAccountUrl?: string;
491
+ /**
492
+ * Hashtag associated with the Twitter post.
493
+ */
494
+ twitterHashtag?: string;
495
+ /**
496
+ * URL of the associated Twitter post.
497
+ */
498
+ twitterPostUrl?: string;
499
+ /**
500
+ * Unique identifier of the Twitter user.
501
+ */
502
+ twitterUserId?: string;
503
+ /**
504
+ * Twitter username of the user.
505
+ */
506
+ twitterUsername?: string;
507
+ /**
508
+ * Minimum length of the verification text.
509
+ */
510
+ verificationTextMinimumLength?: number | null;
511
+ /**
512
+ * Multiplier applied to rewards for verified users.
513
+ */
514
+ verifiedMultiplier?: number | null;
515
+ /**
516
+ * Placeholder text for verification input fields.
517
+ */
518
+ verifyPlaceHolderText?: string | null;
519
+ /**
520
+ * Type of wallet associated with the rule.
521
+ */
522
+ walletType?: 'evm' | 'solana' | 'imx' | 'sui' | 'ton' | 'cosmos' | 'ultra' | 'agw' | 'flow_cadence' | 'substrate' | null;
523
+ /**
524
+ * ID of the Youtube channel.
525
+ */
526
+ youtubeChannelId?: string | null;
527
+ /**
528
+ * ID of the Youtube video.
529
+ */
530
+ youtubeVideoId?: string | null;
531
+ }
532
+ namespace Metadata {
533
+ interface Collection {
534
+ /**
535
+ * Blockchain address of the collection.
536
+ */
537
+ address?: string;
538
+ /**
539
+ * Multiplier applied to the rewards for this collection.
540
+ */
541
+ multiplier?: number;
542
+ /**
543
+ * Blockchain network of the collection.
544
+ */
545
+ network?: 'abstract' | 'abstractTestnet' | 'apechain' | 'arbitrum' | 'avalanche' | 'avalancheFuji' | 'base' | 'baseSepolia' | 'berachain' | 'berachainArtio' | 'berachainBepolia' | 'binance' | 'bscTestnet' | 'campTestnet' | 'fantom' | 'fantomTestnet' | 'flowMainnet' | 'mainnet' | 'nexusTestnet' | 'optimism' | 'polygon' | 'polygon_mumbai' | 'skaleNebula' | 'skaleEuropa' | 'skaleCalypso' | 'solana' | 'sophon' | 'sophonTestnet' | 'sui' | 'superseed' | 'superseedSepolia' | 'vanar' | 'xai' | 'zksync' | 'coti' | 'cotiTestnet' | 'morph' | 'morphTestnet' | 'morphHolesky' | 'ultra' | 'ultraTestnet' | 'nitrograph' | 'sepolia' | 'optimism_sepolia' | 'arbitrumSepolia' | 'goerli' | 'optimism_goerli' | 'arbitrumGoerli' | 'basecamp' | 'somnia' | 'zkverify' | 'polkadot' | 'kusama' | 'flow_cadence';
546
+ }
547
+ /**
548
+ * Object containing details for the call-to-action.
549
+ */
550
+ interface Cta {
551
+ /**
552
+ * Link for the call-to-action.
553
+ */
554
+ href?: string | null;
555
+ /**
556
+ * Label for the call-to-action.
557
+ */
558
+ label?: string | null;
559
+ }
560
+ interface DiscordServersToJoin {
561
+ /**
562
+ * ID of the Discord server to join.
563
+ */
564
+ id?: string;
565
+ /**
566
+ * Array of Discord channels to join.
567
+ */
568
+ channels?: Array<DiscordServersToJoin.Channel>;
569
+ /**
570
+ * Array of roles to assign in the Discord server.
571
+ */
572
+ roles?: Array<DiscordServersToJoin.Role>;
573
+ }
574
+ namespace DiscordServersToJoin {
575
+ interface Channel {
576
+ /**
577
+ * ID of the Discord channel.
578
+ */
579
+ id?: string;
580
+ /**
581
+ * Array of emojis used in the channel.
582
+ */
583
+ emojis?: Array<Channel.Emoji>;
584
+ /**
585
+ * Phrase of text to be present in the discord message
586
+ */
587
+ text?: string;
588
+ }
589
+ namespace Channel {
590
+ interface Emoji {
591
+ /**
592
+ * ID of the emoji used in the channel.
593
+ */
594
+ id?: string;
595
+ }
596
+ }
597
+ interface Role {
598
+ /**
599
+ * ID of the role in the Discord server.
600
+ */
601
+ id: string;
602
+ }
603
+ }
604
+ interface DripQuestsToComplete {
605
+ /**
606
+ * ID of the drip quest to complete.
607
+ */
608
+ id: string;
609
+ }
610
+ /**
611
+ * Liquidity pool details.
612
+ */
613
+ interface Liquidity {
614
+ /**
615
+ * Calculation type of the liquidity pool.
616
+ */
617
+ calculationType?: 'fixed' | 'custom';
618
+ /**
619
+ * Custom function to calculate the the reward amount based on the liquidity
620
+ * provided per day. X is the reward amount, Y is the liquidity provided per day in
621
+ * USD.
622
+ */
623
+ customFunction?: string;
624
+ /**
625
+ * Liquidity provided per day in USD
626
+ */
627
+ liquidityPerDay?: number;
628
+ /**
629
+ * Blockchain network of the liquidity pool.
630
+ */
631
+ network?: 'abstract' | 'abstractTestnet' | 'apechain' | 'arbitrum' | 'avalanche' | 'avalancheFuji' | 'base' | 'baseSepolia' | 'berachain' | 'berachainArtio' | 'berachainBepolia' | 'binance' | 'bscTestnet' | 'campTestnet' | 'fantom' | 'fantomTestnet' | 'flowMainnet' | 'mainnet' | 'nexusTestnet' | 'optimism' | 'polygon' | 'polygon_mumbai' | 'skaleNebula' | 'skaleEuropa' | 'skaleCalypso' | 'solana' | 'sophon' | 'sophonTestnet' | 'sui' | 'superseed' | 'superseedSepolia' | 'vanar' | 'xai' | 'zksync' | 'coti' | 'cotiTestnet' | 'morph' | 'morphTestnet' | 'morphHolesky' | 'ultra' | 'ultraTestnet' | 'nitrograph' | 'sepolia' | 'optimism_sepolia' | 'arbitrumSepolia' | 'goerli' | 'optimism_goerli' | 'arbitrumGoerli' | 'basecamp' | 'somnia' | 'zkverify' | 'polkadot' | 'kusama' | 'flow_cadence';
632
+ /**
633
+ * Indicates if only in-range liquidity is rewarded.
634
+ */
635
+ onlyRewardInRangeLiquidity?: boolean;
636
+ /**
637
+ * Array of liquidity pools associated with the rule.
638
+ */
639
+ pools?: Array<Liquidity.Pool>;
640
+ /**
641
+ * Protocol of the liquidity pool.
642
+ */
643
+ protocol?: string;
644
+ }
645
+ namespace Liquidity {
646
+ interface Pool {
647
+ /**
648
+ * Unique identifier of the liquidity pool.
649
+ */
650
+ id: string;
651
+ }
652
+ }
653
+ interface Range {
654
+ /**
655
+ * Reward amount for this range.
656
+ */
657
+ amount: number;
658
+ /**
659
+ * End value of the range.
660
+ */
661
+ endRange: number;
662
+ /**
663
+ * Start value of the range.
664
+ */
665
+ startRange: number;
666
+ /**
667
+ * ID of the loyalty badge for this range.
668
+ */
669
+ loyaltyBadgeId?: string;
670
+ /**
671
+ * Amount of the loyalty multiplier for this range.
672
+ */
673
+ loyaltyMultiplierAmount?: number;
674
+ }
675
+ /**
676
+ * Object defining referral requirements.
677
+ */
678
+ interface ReferralRequirements {
679
+ /**
680
+ * Flag indicating if achieving points is required.
681
+ */
682
+ achievePoints?: boolean | null;
683
+ /**
684
+ * Flag indicating if completing the profile is required.
685
+ */
686
+ completeProfile?: boolean | null;
687
+ /**
688
+ * Flag indicating if connecting Discord is required.
689
+ */
690
+ connectDiscord?: boolean | null;
691
+ /**
692
+ * Flag indicating if connecting email is required.
693
+ */
694
+ connectEmail?: boolean | null;
695
+ /**
696
+ * Flag indicating if connecting Twitter is required.
697
+ */
698
+ connectTwitter?: boolean | null;
699
+ points?: ReferralRequirements.Points | null;
700
+ }
701
+ namespace ReferralRequirements {
702
+ interface Points {
703
+ /**
704
+ * Points required for referral.
705
+ */
706
+ amount?: number | null;
707
+ /**
708
+ * ID of the loyalty currency for referral.
709
+ */
710
+ loyaltyCurrecyId?: string | null;
711
+ }
712
+ }
713
+ /**
714
+ * Object containing details of the associated smart contract.
715
+ */
716
+ interface SmartContract {
717
+ /**
718
+ * Mapping of addresses for the smart contract.
719
+ */
720
+ addressMapping?: string | null;
721
+ /**
722
+ * Object containing details of the amount multiplier from the event.
723
+ */
724
+ amountMultiplier?: SmartContract.AmountMultiplier | null;
725
+ /**
726
+ * ID of the smart contract.
727
+ */
728
+ contractId?: string | null;
729
+ /**
730
+ * Criteria to evaluate the smart contract event.
731
+ */
732
+ criteria?: 'everyEvent' | 'byParameter' | null;
733
+ /**
734
+ * Event emitted by the smart contract.
735
+ */
736
+ event?: string | null;
737
+ /**
738
+ * Array of parameters for the smart contract.
739
+ */
740
+ params?: Array<SmartContract.Param> | null;
741
+ /**
742
+ * Type of the smart contract interaction.
743
+ */
744
+ type?: 'function' | 'event' | null;
745
+ }
746
+ namespace SmartContract {
747
+ /**
748
+ * Object containing details of the amount multiplier from the event.
749
+ */
750
+ interface AmountMultiplier {
751
+ /**
752
+ * Mapping of the value for the smart contract.
753
+ */
754
+ valueMapping?: string | null;
755
+ }
756
+ interface Param {
757
+ /**
758
+ * Condition to check for the parameter.
759
+ */
760
+ condition?: string | null;
761
+ /**
762
+ * Name of the smart contract parameter.
763
+ */
764
+ name?: string | null;
765
+ /**
766
+ * Value of the parameter.
767
+ */
768
+ value?: string | null;
769
+ }
770
+ }
771
+ interface SnapshotProposal {
772
+ /**
773
+ * ID of the snapshot proposal.
774
+ */
775
+ id: string;
776
+ /**
777
+ * Space associated with the snapshot proposal.
778
+ */
779
+ space: string;
780
+ }
781
+ interface StreakArray {
782
+ /**
783
+ * Reward amount for achieving the streak milestone.
784
+ */
785
+ streakAmount: number;
786
+ /**
787
+ * Milestone required to achieve the streak.
788
+ */
789
+ streakMilestone: number;
790
+ }
791
+ /**
792
+ * Metadata for swap loyalty rules
793
+ */
794
+ interface Swap {
795
+ from?: Swap.From;
796
+ provider?: 'any' | 'relay' | 'lifi';
797
+ relayReferrerId?: string;
798
+ requireCrossChainSwap?: boolean;
799
+ to?: Swap.To;
800
+ }
801
+ namespace Swap {
802
+ interface From {
803
+ chain?: 'any' | number | string;
804
+ mode?: 'any' | 'specific';
805
+ tokens?: Array<From.Token>;
806
+ trackAmount?: boolean;
807
+ }
808
+ namespace From {
809
+ interface Token {
810
+ address: string;
811
+ chainId: string;
812
+ }
813
+ }
814
+ interface To {
815
+ chain?: 'any' | number | string;
816
+ mode?: 'any' | 'specific';
817
+ tokens?: Array<To.Token>;
818
+ trackAmount?: boolean;
819
+ }
820
+ namespace To {
821
+ interface Token {
822
+ address: string;
823
+ chainId: string;
824
+ }
825
+ }
826
+ }
827
+ }
109
828
  }
110
829
  /**
111
830
  * Previous data of the rule before the edit
@@ -118,7 +837,7 @@ export declare namespace RuleEditListResponse {
118
837
  /**
119
838
  * Amount associated with the loyalty rule
120
839
  */
121
- amount: number;
840
+ amount: number | null;
122
841
  /**
123
842
  * Timestamp when the loyalty rule was created
124
843
  */
@@ -127,14 +846,34 @@ export declare namespace RuleEditListResponse {
127
846
  * Timestamp when the loyalty rule was deleted (if applicable)
128
847
  */
129
848
  deletedAt: string | null;
849
+ /**
850
+ * Description of the loyalty rule
851
+ */
852
+ description: string;
853
+ /**
854
+ * End time of the loyalty rule
855
+ */
856
+ endTime: string | null;
130
857
  /**
131
858
  * Frequency of the loyalty rule
132
859
  */
133
860
  frequency: string;
861
+ /**
862
+ * Name of the loyalty rule
863
+ */
864
+ name: string;
134
865
  /**
135
866
  * Unique identifier for the organization
136
867
  */
137
868
  organizationId: string;
869
+ /**
870
+ * Type of the reward
871
+ */
872
+ rewardType: 'points' | 'multiplier' | 'badge';
873
+ /**
874
+ * Start time of the loyalty rule
875
+ */
876
+ startTime: string | null;
138
877
  /**
139
878
  * Type of the loyalty rule
140
879
  */
@@ -151,10 +890,695 @@ export declare namespace RuleEditListResponse {
151
890
  * Optional address of the collection
152
891
  */
153
892
  collectionAddress?: string;
893
+ /**
894
+ * URL of the media associated with the loyalty rule
895
+ */
896
+ mediaUrl?: string | null;
154
897
  /**
155
898
  * Optional metadata for the loyalty rule
156
899
  */
157
- metadata?: Record<string, unknown>;
900
+ metadata?: {
901
+ [key: string]: PreviousData.Metadata;
902
+ };
903
+ }
904
+ namespace PreviousData {
905
+ interface Metadata {
906
+ /**
907
+ * Flag indicating if the rule allows multiple redemptions. Applies to Enter a Code
908
+ * only.
909
+ */
910
+ allowMultipleRedemptions?: boolean;
911
+ /**
912
+ * Array of loyalty rule IDs that count as check-in when completed. If ["any"] then
913
+ * any rule completions count as check-in.
914
+ */
915
+ autoCheckInRuleIds?: Array<(string & {}) | 'any'> | null;
916
+ /**
917
+ * Number of tokens per batch.
918
+ */
919
+ batchSize?: number | null;
920
+ /**
921
+ * Text displayed on the action button.
922
+ */
923
+ buttonText?: string | null;
924
+ /**
925
+ * Flag indicating if commenting is required.
926
+ */
927
+ checkComment?: boolean | null;
928
+ /**
929
+ * Flag indicating if liking the post is required.
930
+ */
931
+ checkLike?: boolean | null;
932
+ /**
933
+ * Flag indicating if reposting is required.
934
+ */
935
+ checkRepost?: boolean | null;
936
+ /**
937
+ * Text to check in the Twitter post, username, or bio.
938
+ */
939
+ checkText?: string | Array<string> | null;
940
+ /**
941
+ * Array of collections associated with the rule.
942
+ */
943
+ collection?: Array<Metadata.Collection>;
944
+ /**
945
+ * Conditions for completing the profile.
946
+ */
947
+ completeProfileConditions?: {
948
+ [key: string]: boolean;
949
+ } | null;
950
+ /**
951
+ * Description of the external rule condition (only for external rules)
952
+ */
953
+ conditionDescription?: string;
954
+ /**
955
+ * Object containing details for the call-to-action.
956
+ */
957
+ cta?: Metadata.Cta | null;
958
+ /**
959
+ * API key for custom rewards integration.
960
+ */
961
+ customRewardsApiKey?: string;
962
+ /**
963
+ * Flag indicating if the rule should use direct RPC to get the balance of tokens.
964
+ */
965
+ directRpc?: boolean;
966
+ /**
967
+ * Array of Discord servers, channels, and roles to join.
968
+ */
969
+ discordServersToJoin?: Array<Metadata.DiscordServersToJoin> | null;
970
+ /**
971
+ * Array of drip quests required to complete the rule.
972
+ */
973
+ dripQuestsToComplete?: Array<Metadata.DripQuestsToComplete> | null;
974
+ /**
975
+ * Flag indicating whether joining Discord servers is required.
976
+ */
977
+ enableJoinDiscordServers?: boolean | null;
978
+ /**
979
+ * Flag indicating whether streaks are enabled.
980
+ */
981
+ enableStreaks?: boolean | null;
982
+ /**
983
+ * Flag indicating whether the verified multiplier is enabled.
984
+ */
985
+ enableVerifiedMultiplier?: boolean;
986
+ /**
987
+ * Type of ERC20 token for the loyalty rule.
988
+ */
989
+ erc20Type?: 'erc20' | 'native';
990
+ /**
991
+ * Fill source of the order for the token sale
992
+ */
993
+ fillSource?: string;
994
+ /**
995
+ * Percentage reward given to a user for their first referral.
996
+ */
997
+ firstReferralReward?: number | null;
998
+ /**
999
+ * Name of the GitHub branch to check for PR merge.
1000
+ */
1001
+ githubBranchName?: string | null;
1002
+ /**
1003
+ * URL of the GitHub repository to check for star.
1004
+ */
1005
+ githubRepoUrl?: string | null;
1006
+ /**
1007
+ * Flag indicating whether the fill source is included.
1008
+ */
1009
+ hasFillSource?: boolean;
1010
+ /**
1011
+ * Indicates if the item has never been sold.
1012
+ */
1013
+ hasNeverSold?: boolean;
1014
+ /**
1015
+ * Indicates if the full royalty has been paid for items.
1016
+ */
1017
+ hasPaidFullRoyalty?: boolean;
1018
+ /**
1019
+ * Flag indicating if the sale currency is included.
1020
+ */
1021
+ hasSaleCurrency?: boolean;
1022
+ /**
1023
+ * Indicates if the user has a verified Twitter account.
1024
+ */
1025
+ hasVerifiedTwitter?: boolean;
1026
+ /**
1027
+ * URL of the image associated with the rule.
1028
+ */
1029
+ imageUrl?: string | null;
1030
+ /**
1031
+ * If enabled, the first transaction done on the platform will complete this rule
1032
+ */
1033
+ isCheckInOnEveryTxn?: boolean;
1034
+ /**
1035
+ * Indicates if the multiplier has been applied to rewards.
1036
+ */
1037
+ isMultiplierApplied?: boolean;
1038
+ /**
1039
+ * Flag indicating if the rule is restricted to new users.
1040
+ */
1041
+ isRestrictedToNewUsers?: boolean;
1042
+ /**
1043
+ * Flag indicating if rewards are applied retroactively.
1044
+ */
1045
+ isRetroactive?: boolean | null;
1046
+ /**
1047
+ * Flag indicating if the token hold multiplier is applied.
1048
+ */
1049
+ isTokenHoldMultiplier?: boolean;
1050
+ /**
1051
+ * Optional link associated with the metadata.
1052
+ */
1053
+ link?: string | null;
1054
+ /**
1055
+ * Liquidity pool details.
1056
+ */
1057
+ liquidity?: Metadata.Liquidity;
1058
+ /**
1059
+ * Maximum quantity constraint for token holding.
1060
+ */
1061
+ maxQty?: number | null;
1062
+ /**
1063
+ * Minimum follower count for the rule. Accepts both number and string values.
1064
+ */
1065
+ minimumFollowerCount?: number | null;
1066
+ /**
1067
+ * Minimum quantity constraint for token holding.
1068
+ */
1069
+ minQty?: number | null;
1070
+ /**
1071
+ * Array of loyalty currency IDs used for multipliers.
1072
+ */
1073
+ multiplierLoyaltyCurrencyIds?: Array<string> | null;
1074
+ /**
1075
+ * Flag indicating whether to include only known users.
1076
+ */
1077
+ onlyKnownUsers?: boolean;
1078
+ /**
1079
+ * Flag indicating whether to include only native tokens.
1080
+ */
1081
+ onlyNative?: boolean;
1082
+ /**
1083
+ * Flag indicating whether to include only non-listed items.
1084
+ */
1085
+ onlyNonListed?: boolean;
1086
+ /**
1087
+ * Indicates if only existing users are rewarded.
1088
+ */
1089
+ onlyRewardExistingUser?: boolean;
1090
+ /**
1091
+ * give points for only one token ownership per contract
1092
+ */
1093
+ onlyRewardSingleTokenOwnership?: boolean | null;
1094
+ /**
1095
+ * Pre-generated text template that will be used to prefill the post content.
1096
+ */
1097
+ preGeneratedPostText?: string | null;
1098
+ /**
1099
+ * Promotional code associated with the rule.
1100
+ */
1101
+ promoCode?: string;
1102
+ /**
1103
+ * URL of the CSV file containing promo codes.
1104
+ */
1105
+ promoCodeCsvUrl?: string;
1106
+ /**
1107
+ * Numbers of the promotional code to be generated.
1108
+ */
1109
+ promoCodeLength?: number | null;
1110
+ /**
1111
+ * Type of the promotional code.
1112
+ */
1113
+ promoCodeType?: 'code' | 'csv' | 'generate';
1114
+ /**
1115
+ * Array defining ranges and corresponding rewards.
1116
+ */
1117
+ range?: Array<Metadata.Range>;
1118
+ /**
1119
+ * ID of the Reddit post.
1120
+ */
1121
+ redditPostId?: string | null;
1122
+ /**
1123
+ * Object defining referral requirements.
1124
+ */
1125
+ referralRequirements?: Metadata.ReferralRequirements | null;
1126
+ /**
1127
+ * Lump sum reward given to a referrer.
1128
+ */
1129
+ referrerReward?: number | null;
1130
+ /**
1131
+ * Loyalty currency ID of the referrer reward.
1132
+ */
1133
+ referrerRewardLoyaltyCurrencyId?: string | null;
1134
+ /**
1135
+ * Flag indicating if the post link is required.
1136
+ */
1137
+ requirePostLink?: boolean | null;
1138
+ /**
1139
+ * Flag indicating if media metadata is required.
1140
+ */
1141
+ requirePostMediaLink?: boolean | null;
1142
+ /**
1143
+ * Flag indicating if the rule can also reward badges per range.
1144
+ */
1145
+ rewardBadgePerRange?: boolean;
1146
+ /**
1147
+ * Flag indicating if the reward is rewarded by batch.
1148
+ */
1149
+ rewardByBatch?: boolean | null;
1150
+ /**
1151
+ * Criteria to evaluate the reward.
1152
+ */
1153
+ rewardCriteria?: 'IMPRESSIONS_COUNT' | 'ELIGIBLE_POST' | null;
1154
+ /**
1155
+ * Flag indicating if the reward is rewarded per action.
1156
+ */
1157
+ rewardPerAction?: boolean | null;
1158
+ /**
1159
+ * Flag indicating if rewards are given per impression.
1160
+ */
1161
+ rewardPerImpression?: boolean | null;
1162
+ /**
1163
+ * Flag indicating if the rule should reward based on value of traded tokens
1164
+ * instead of count.
1165
+ */
1166
+ rewardPerValue?: boolean;
1167
+ /**
1168
+ * Flag indicating if the rule should reward quality posts.
1169
+ */
1170
+ rewardQualityPosts?: boolean;
1171
+ robinhoodSymbols?: Array<string> | null;
1172
+ /**
1173
+ * Wallet address of the user can only be used if userId is not provided
1174
+ */
1175
+ royaltyAddress?: string;
1176
+ /**
1177
+ * Royalty percentage of the item.
1178
+ */
1179
+ royaltyPercentage?: number;
1180
+ /**
1181
+ * Currency associated with sales.
1182
+ */
1183
+ saleCurrency?: string;
1184
+ /**
1185
+ * Percentage reward given for a second-level referral.
1186
+ */
1187
+ secondReferralReward?: number | null;
1188
+ /**
1189
+ * Flag indicating if the multiplier is skipped.
1190
+ */
1191
+ skipMultiplier?: boolean | null;
1192
+ /**
1193
+ * Object containing details of the associated smart contract.
1194
+ */
1195
+ smartContract?: Metadata.SmartContract;
1196
+ /**
1197
+ * Array of snapshot proposals for the rule.
1198
+ */
1199
+ snapshotProposals?: Array<Metadata.SnapshotProposal> | null;
1200
+ /**
1201
+ * Social media platform associated with the rule.
1202
+ */
1203
+ socialPlatform?: 'Custom' | 'Discord' | 'EpicGames' | 'Instagram' | 'Steam' | 'Telegram' | 'TikTok' | 'Twitch' | 'X(Twitter)' | 'YouTube' | 'Google' | 'GitHub' | 'Reddit' | null;
1204
+ /**
1205
+ * URL of the social platform's logo.
1206
+ */
1207
+ socialPlatformLogo?: string | null;
1208
+ /**
1209
+ * Name of the social platform.
1210
+ */
1211
+ socialPlatformName?: string | null;
1212
+ /**
1213
+ * ID of the Steam app.
1214
+ */
1215
+ steamAppId?: string | null;
1216
+ /**
1217
+ * Array of streak milestones and corresponding rewards.
1218
+ */
1219
+ streakArray?: Array<Metadata.StreakArray> | null;
1220
+ /**
1221
+ * Metadata for swap loyalty rules
1222
+ */
1223
+ swap?: Metadata.Swap;
1224
+ /**
1225
+ * ID of the Telegram channel.
1226
+ */
1227
+ telegramChannelId?: string | null;
1228
+ /**
1229
+ * Time delay in seconds to verify actions.
1230
+ */
1231
+ timeDelayToVerifySeconds?: string | number | null;
1232
+ /**
1233
+ * Flag indicating if all contracts are tracked.
1234
+ */
1235
+ trackAllContracts?: boolean | null;
1236
+ /**
1237
+ * Flag indicating if the progress is tracked. If enabled, the rule can only be
1238
+ * completed once the progress is 100%.
1239
+ */
1240
+ trackProgress?: boolean | null;
1241
+ /**
1242
+ * URL of the associated Twitter account.
1243
+ */
1244
+ twitterAccountUrl?: string;
1245
+ /**
1246
+ * Hashtag associated with the Twitter post.
1247
+ */
1248
+ twitterHashtag?: string;
1249
+ /**
1250
+ * URL of the associated Twitter post.
1251
+ */
1252
+ twitterPostUrl?: string;
1253
+ /**
1254
+ * Unique identifier of the Twitter user.
1255
+ */
1256
+ twitterUserId?: string;
1257
+ /**
1258
+ * Twitter username of the user.
1259
+ */
1260
+ twitterUsername?: string;
1261
+ /**
1262
+ * Minimum length of the verification text.
1263
+ */
1264
+ verificationTextMinimumLength?: number | null;
1265
+ /**
1266
+ * Multiplier applied to rewards for verified users.
1267
+ */
1268
+ verifiedMultiplier?: number | null;
1269
+ /**
1270
+ * Placeholder text for verification input fields.
1271
+ */
1272
+ verifyPlaceHolderText?: string | null;
1273
+ /**
1274
+ * Type of wallet associated with the rule.
1275
+ */
1276
+ walletType?: 'evm' | 'solana' | 'imx' | 'sui' | 'ton' | 'cosmos' | 'ultra' | 'agw' | 'flow_cadence' | 'substrate' | null;
1277
+ /**
1278
+ * ID of the Youtube channel.
1279
+ */
1280
+ youtubeChannelId?: string | null;
1281
+ /**
1282
+ * ID of the Youtube video.
1283
+ */
1284
+ youtubeVideoId?: string | null;
1285
+ }
1286
+ namespace Metadata {
1287
+ interface Collection {
1288
+ /**
1289
+ * Blockchain address of the collection.
1290
+ */
1291
+ address?: string;
1292
+ /**
1293
+ * Multiplier applied to the rewards for this collection.
1294
+ */
1295
+ multiplier?: number;
1296
+ /**
1297
+ * Blockchain network of the collection.
1298
+ */
1299
+ network?: 'abstract' | 'abstractTestnet' | 'apechain' | 'arbitrum' | 'avalanche' | 'avalancheFuji' | 'base' | 'baseSepolia' | 'berachain' | 'berachainArtio' | 'berachainBepolia' | 'binance' | 'bscTestnet' | 'campTestnet' | 'fantom' | 'fantomTestnet' | 'flowMainnet' | 'mainnet' | 'nexusTestnet' | 'optimism' | 'polygon' | 'polygon_mumbai' | 'skaleNebula' | 'skaleEuropa' | 'skaleCalypso' | 'solana' | 'sophon' | 'sophonTestnet' | 'sui' | 'superseed' | 'superseedSepolia' | 'vanar' | 'xai' | 'zksync' | 'coti' | 'cotiTestnet' | 'morph' | 'morphTestnet' | 'morphHolesky' | 'ultra' | 'ultraTestnet' | 'nitrograph' | 'sepolia' | 'optimism_sepolia' | 'arbitrumSepolia' | 'goerli' | 'optimism_goerli' | 'arbitrumGoerli' | 'basecamp' | 'somnia' | 'zkverify' | 'polkadot' | 'kusama' | 'flow_cadence';
1300
+ }
1301
+ /**
1302
+ * Object containing details for the call-to-action.
1303
+ */
1304
+ interface Cta {
1305
+ /**
1306
+ * Link for the call-to-action.
1307
+ */
1308
+ href?: string | null;
1309
+ /**
1310
+ * Label for the call-to-action.
1311
+ */
1312
+ label?: string | null;
1313
+ }
1314
+ interface DiscordServersToJoin {
1315
+ /**
1316
+ * ID of the Discord server to join.
1317
+ */
1318
+ id?: string;
1319
+ /**
1320
+ * Array of Discord channels to join.
1321
+ */
1322
+ channels?: Array<DiscordServersToJoin.Channel>;
1323
+ /**
1324
+ * Array of roles to assign in the Discord server.
1325
+ */
1326
+ roles?: Array<DiscordServersToJoin.Role>;
1327
+ }
1328
+ namespace DiscordServersToJoin {
1329
+ interface Channel {
1330
+ /**
1331
+ * ID of the Discord channel.
1332
+ */
1333
+ id?: string;
1334
+ /**
1335
+ * Array of emojis used in the channel.
1336
+ */
1337
+ emojis?: Array<Channel.Emoji>;
1338
+ /**
1339
+ * Phrase of text to be present in the discord message
1340
+ */
1341
+ text?: string;
1342
+ }
1343
+ namespace Channel {
1344
+ interface Emoji {
1345
+ /**
1346
+ * ID of the emoji used in the channel.
1347
+ */
1348
+ id?: string;
1349
+ }
1350
+ }
1351
+ interface Role {
1352
+ /**
1353
+ * ID of the role in the Discord server.
1354
+ */
1355
+ id: string;
1356
+ }
1357
+ }
1358
+ interface DripQuestsToComplete {
1359
+ /**
1360
+ * ID of the drip quest to complete.
1361
+ */
1362
+ id: string;
1363
+ }
1364
+ /**
1365
+ * Liquidity pool details.
1366
+ */
1367
+ interface Liquidity {
1368
+ /**
1369
+ * Calculation type of the liquidity pool.
1370
+ */
1371
+ calculationType?: 'fixed' | 'custom';
1372
+ /**
1373
+ * Custom function to calculate the the reward amount based on the liquidity
1374
+ * provided per day. X is the reward amount, Y is the liquidity provided per day in
1375
+ * USD.
1376
+ */
1377
+ customFunction?: string;
1378
+ /**
1379
+ * Liquidity provided per day in USD
1380
+ */
1381
+ liquidityPerDay?: number;
1382
+ /**
1383
+ * Blockchain network of the liquidity pool.
1384
+ */
1385
+ network?: 'abstract' | 'abstractTestnet' | 'apechain' | 'arbitrum' | 'avalanche' | 'avalancheFuji' | 'base' | 'baseSepolia' | 'berachain' | 'berachainArtio' | 'berachainBepolia' | 'binance' | 'bscTestnet' | 'campTestnet' | 'fantom' | 'fantomTestnet' | 'flowMainnet' | 'mainnet' | 'nexusTestnet' | 'optimism' | 'polygon' | 'polygon_mumbai' | 'skaleNebula' | 'skaleEuropa' | 'skaleCalypso' | 'solana' | 'sophon' | 'sophonTestnet' | 'sui' | 'superseed' | 'superseedSepolia' | 'vanar' | 'xai' | 'zksync' | 'coti' | 'cotiTestnet' | 'morph' | 'morphTestnet' | 'morphHolesky' | 'ultra' | 'ultraTestnet' | 'nitrograph' | 'sepolia' | 'optimism_sepolia' | 'arbitrumSepolia' | 'goerli' | 'optimism_goerli' | 'arbitrumGoerli' | 'basecamp' | 'somnia' | 'zkverify' | 'polkadot' | 'kusama' | 'flow_cadence';
1386
+ /**
1387
+ * Indicates if only in-range liquidity is rewarded.
1388
+ */
1389
+ onlyRewardInRangeLiquidity?: boolean;
1390
+ /**
1391
+ * Array of liquidity pools associated with the rule.
1392
+ */
1393
+ pools?: Array<Liquidity.Pool>;
1394
+ /**
1395
+ * Protocol of the liquidity pool.
1396
+ */
1397
+ protocol?: string;
1398
+ }
1399
+ namespace Liquidity {
1400
+ interface Pool {
1401
+ /**
1402
+ * Unique identifier of the liquidity pool.
1403
+ */
1404
+ id: string;
1405
+ }
1406
+ }
1407
+ interface Range {
1408
+ /**
1409
+ * Reward amount for this range.
1410
+ */
1411
+ amount: number;
1412
+ /**
1413
+ * End value of the range.
1414
+ */
1415
+ endRange: number;
1416
+ /**
1417
+ * Start value of the range.
1418
+ */
1419
+ startRange: number;
1420
+ /**
1421
+ * ID of the loyalty badge for this range.
1422
+ */
1423
+ loyaltyBadgeId?: string;
1424
+ /**
1425
+ * Amount of the loyalty multiplier for this range.
1426
+ */
1427
+ loyaltyMultiplierAmount?: number;
1428
+ }
1429
+ /**
1430
+ * Object defining referral requirements.
1431
+ */
1432
+ interface ReferralRequirements {
1433
+ /**
1434
+ * Flag indicating if achieving points is required.
1435
+ */
1436
+ achievePoints?: boolean | null;
1437
+ /**
1438
+ * Flag indicating if completing the profile is required.
1439
+ */
1440
+ completeProfile?: boolean | null;
1441
+ /**
1442
+ * Flag indicating if connecting Discord is required.
1443
+ */
1444
+ connectDiscord?: boolean | null;
1445
+ /**
1446
+ * Flag indicating if connecting email is required.
1447
+ */
1448
+ connectEmail?: boolean | null;
1449
+ /**
1450
+ * Flag indicating if connecting Twitter is required.
1451
+ */
1452
+ connectTwitter?: boolean | null;
1453
+ points?: ReferralRequirements.Points | null;
1454
+ }
1455
+ namespace ReferralRequirements {
1456
+ interface Points {
1457
+ /**
1458
+ * Points required for referral.
1459
+ */
1460
+ amount?: number | null;
1461
+ /**
1462
+ * ID of the loyalty currency for referral.
1463
+ */
1464
+ loyaltyCurrecyId?: string | null;
1465
+ }
1466
+ }
1467
+ /**
1468
+ * Object containing details of the associated smart contract.
1469
+ */
1470
+ interface SmartContract {
1471
+ /**
1472
+ * Mapping of addresses for the smart contract.
1473
+ */
1474
+ addressMapping?: string | null;
1475
+ /**
1476
+ * Object containing details of the amount multiplier from the event.
1477
+ */
1478
+ amountMultiplier?: SmartContract.AmountMultiplier | null;
1479
+ /**
1480
+ * ID of the smart contract.
1481
+ */
1482
+ contractId?: string | null;
1483
+ /**
1484
+ * Criteria to evaluate the smart contract event.
1485
+ */
1486
+ criteria?: 'everyEvent' | 'byParameter' | null;
1487
+ /**
1488
+ * Event emitted by the smart contract.
1489
+ */
1490
+ event?: string | null;
1491
+ /**
1492
+ * Array of parameters for the smart contract.
1493
+ */
1494
+ params?: Array<SmartContract.Param> | null;
1495
+ /**
1496
+ * Type of the smart contract interaction.
1497
+ */
1498
+ type?: 'function' | 'event' | null;
1499
+ }
1500
+ namespace SmartContract {
1501
+ /**
1502
+ * Object containing details of the amount multiplier from the event.
1503
+ */
1504
+ interface AmountMultiplier {
1505
+ /**
1506
+ * Mapping of the value for the smart contract.
1507
+ */
1508
+ valueMapping?: string | null;
1509
+ }
1510
+ interface Param {
1511
+ /**
1512
+ * Condition to check for the parameter.
1513
+ */
1514
+ condition?: string | null;
1515
+ /**
1516
+ * Name of the smart contract parameter.
1517
+ */
1518
+ name?: string | null;
1519
+ /**
1520
+ * Value of the parameter.
1521
+ */
1522
+ value?: string | null;
1523
+ }
1524
+ }
1525
+ interface SnapshotProposal {
1526
+ /**
1527
+ * ID of the snapshot proposal.
1528
+ */
1529
+ id: string;
1530
+ /**
1531
+ * Space associated with the snapshot proposal.
1532
+ */
1533
+ space: string;
1534
+ }
1535
+ interface StreakArray {
1536
+ /**
1537
+ * Reward amount for achieving the streak milestone.
1538
+ */
1539
+ streakAmount: number;
1540
+ /**
1541
+ * Milestone required to achieve the streak.
1542
+ */
1543
+ streakMilestone: number;
1544
+ }
1545
+ /**
1546
+ * Metadata for swap loyalty rules
1547
+ */
1548
+ interface Swap {
1549
+ from?: Swap.From;
1550
+ provider?: 'any' | 'relay' | 'lifi';
1551
+ relayReferrerId?: string;
1552
+ requireCrossChainSwap?: boolean;
1553
+ to?: Swap.To;
1554
+ }
1555
+ namespace Swap {
1556
+ interface From {
1557
+ chain?: 'any' | number | string;
1558
+ mode?: 'any' | 'specific';
1559
+ tokens?: Array<From.Token>;
1560
+ trackAmount?: boolean;
1561
+ }
1562
+ namespace From {
1563
+ interface Token {
1564
+ address: string;
1565
+ chainId: string;
1566
+ }
1567
+ }
1568
+ interface To {
1569
+ chain?: 'any' | number | string;
1570
+ mode?: 'any' | 'specific';
1571
+ tokens?: Array<To.Token>;
1572
+ trackAmount?: boolean;
1573
+ }
1574
+ namespace To {
1575
+ interface Token {
1576
+ address: string;
1577
+ chainId: string;
1578
+ }
1579
+ }
1580
+ }
1581
+ }
158
1582
  }
159
1583
  }
160
1584
  }
@@ -212,7 +1636,7 @@ export declare namespace RuleEditRestoreResponse {
212
1636
  /**
213
1637
  * Amount associated with the loyalty rule
214
1638
  */
215
- amount: number;
1639
+ amount: number | null;
216
1640
  /**
217
1641
  * Timestamp when the loyalty rule was created
218
1642
  */
@@ -221,14 +1645,34 @@ export declare namespace RuleEditRestoreResponse {
221
1645
  * Timestamp when the loyalty rule was deleted (if applicable)
222
1646
  */
223
1647
  deletedAt: string | null;
1648
+ /**
1649
+ * Description of the loyalty rule
1650
+ */
1651
+ description: string;
1652
+ /**
1653
+ * End time of the loyalty rule
1654
+ */
1655
+ endTime: string | null;
224
1656
  /**
225
1657
  * Frequency of the loyalty rule
226
1658
  */
227
1659
  frequency: string;
1660
+ /**
1661
+ * Name of the loyalty rule
1662
+ */
1663
+ name: string;
228
1664
  /**
229
1665
  * Unique identifier for the organization
230
1666
  */
231
1667
  organizationId: string;
1668
+ /**
1669
+ * Type of the reward
1670
+ */
1671
+ rewardType: 'points' | 'multiplier' | 'badge';
1672
+ /**
1673
+ * Start time of the loyalty rule
1674
+ */
1675
+ startTime: string | null;
232
1676
  /**
233
1677
  * Type of the loyalty rule
234
1678
  */
@@ -245,10 +1689,695 @@ export declare namespace RuleEditRestoreResponse {
245
1689
  * Optional address of the collection
246
1690
  */
247
1691
  collectionAddress?: string;
1692
+ /**
1693
+ * URL of the media associated with the loyalty rule
1694
+ */
1695
+ mediaUrl?: string | null;
248
1696
  /**
249
1697
  * Optional metadata for the loyalty rule
250
1698
  */
251
- metadata?: Record<string, unknown>;
1699
+ metadata?: {
1700
+ [key: string]: Data.Metadata;
1701
+ };
1702
+ }
1703
+ namespace Data {
1704
+ interface Metadata {
1705
+ /**
1706
+ * Flag indicating if the rule allows multiple redemptions. Applies to Enter a Code
1707
+ * only.
1708
+ */
1709
+ allowMultipleRedemptions?: boolean;
1710
+ /**
1711
+ * Array of loyalty rule IDs that count as check-in when completed. If ["any"] then
1712
+ * any rule completions count as check-in.
1713
+ */
1714
+ autoCheckInRuleIds?: Array<(string & {}) | 'any'> | null;
1715
+ /**
1716
+ * Number of tokens per batch.
1717
+ */
1718
+ batchSize?: number | null;
1719
+ /**
1720
+ * Text displayed on the action button.
1721
+ */
1722
+ buttonText?: string | null;
1723
+ /**
1724
+ * Flag indicating if commenting is required.
1725
+ */
1726
+ checkComment?: boolean | null;
1727
+ /**
1728
+ * Flag indicating if liking the post is required.
1729
+ */
1730
+ checkLike?: boolean | null;
1731
+ /**
1732
+ * Flag indicating if reposting is required.
1733
+ */
1734
+ checkRepost?: boolean | null;
1735
+ /**
1736
+ * Text to check in the Twitter post, username, or bio.
1737
+ */
1738
+ checkText?: string | Array<string> | null;
1739
+ /**
1740
+ * Array of collections associated with the rule.
1741
+ */
1742
+ collection?: Array<Metadata.Collection>;
1743
+ /**
1744
+ * Conditions for completing the profile.
1745
+ */
1746
+ completeProfileConditions?: {
1747
+ [key: string]: boolean;
1748
+ } | null;
1749
+ /**
1750
+ * Description of the external rule condition (only for external rules)
1751
+ */
1752
+ conditionDescription?: string;
1753
+ /**
1754
+ * Object containing details for the call-to-action.
1755
+ */
1756
+ cta?: Metadata.Cta | null;
1757
+ /**
1758
+ * API key for custom rewards integration.
1759
+ */
1760
+ customRewardsApiKey?: string;
1761
+ /**
1762
+ * Flag indicating if the rule should use direct RPC to get the balance of tokens.
1763
+ */
1764
+ directRpc?: boolean;
1765
+ /**
1766
+ * Array of Discord servers, channels, and roles to join.
1767
+ */
1768
+ discordServersToJoin?: Array<Metadata.DiscordServersToJoin> | null;
1769
+ /**
1770
+ * Array of drip quests required to complete the rule.
1771
+ */
1772
+ dripQuestsToComplete?: Array<Metadata.DripQuestsToComplete> | null;
1773
+ /**
1774
+ * Flag indicating whether joining Discord servers is required.
1775
+ */
1776
+ enableJoinDiscordServers?: boolean | null;
1777
+ /**
1778
+ * Flag indicating whether streaks are enabled.
1779
+ */
1780
+ enableStreaks?: boolean | null;
1781
+ /**
1782
+ * Flag indicating whether the verified multiplier is enabled.
1783
+ */
1784
+ enableVerifiedMultiplier?: boolean;
1785
+ /**
1786
+ * Type of ERC20 token for the loyalty rule.
1787
+ */
1788
+ erc20Type?: 'erc20' | 'native';
1789
+ /**
1790
+ * Fill source of the order for the token sale
1791
+ */
1792
+ fillSource?: string;
1793
+ /**
1794
+ * Percentage reward given to a user for their first referral.
1795
+ */
1796
+ firstReferralReward?: number | null;
1797
+ /**
1798
+ * Name of the GitHub branch to check for PR merge.
1799
+ */
1800
+ githubBranchName?: string | null;
1801
+ /**
1802
+ * URL of the GitHub repository to check for star.
1803
+ */
1804
+ githubRepoUrl?: string | null;
1805
+ /**
1806
+ * Flag indicating whether the fill source is included.
1807
+ */
1808
+ hasFillSource?: boolean;
1809
+ /**
1810
+ * Indicates if the item has never been sold.
1811
+ */
1812
+ hasNeverSold?: boolean;
1813
+ /**
1814
+ * Indicates if the full royalty has been paid for items.
1815
+ */
1816
+ hasPaidFullRoyalty?: boolean;
1817
+ /**
1818
+ * Flag indicating if the sale currency is included.
1819
+ */
1820
+ hasSaleCurrency?: boolean;
1821
+ /**
1822
+ * Indicates if the user has a verified Twitter account.
1823
+ */
1824
+ hasVerifiedTwitter?: boolean;
1825
+ /**
1826
+ * URL of the image associated with the rule.
1827
+ */
1828
+ imageUrl?: string | null;
1829
+ /**
1830
+ * If enabled, the first transaction done on the platform will complete this rule
1831
+ */
1832
+ isCheckInOnEveryTxn?: boolean;
1833
+ /**
1834
+ * Indicates if the multiplier has been applied to rewards.
1835
+ */
1836
+ isMultiplierApplied?: boolean;
1837
+ /**
1838
+ * Flag indicating if the rule is restricted to new users.
1839
+ */
1840
+ isRestrictedToNewUsers?: boolean;
1841
+ /**
1842
+ * Flag indicating if rewards are applied retroactively.
1843
+ */
1844
+ isRetroactive?: boolean | null;
1845
+ /**
1846
+ * Flag indicating if the token hold multiplier is applied.
1847
+ */
1848
+ isTokenHoldMultiplier?: boolean;
1849
+ /**
1850
+ * Optional link associated with the metadata.
1851
+ */
1852
+ link?: string | null;
1853
+ /**
1854
+ * Liquidity pool details.
1855
+ */
1856
+ liquidity?: Metadata.Liquidity;
1857
+ /**
1858
+ * Maximum quantity constraint for token holding.
1859
+ */
1860
+ maxQty?: number | null;
1861
+ /**
1862
+ * Minimum follower count for the rule. Accepts both number and string values.
1863
+ */
1864
+ minimumFollowerCount?: number | null;
1865
+ /**
1866
+ * Minimum quantity constraint for token holding.
1867
+ */
1868
+ minQty?: number | null;
1869
+ /**
1870
+ * Array of loyalty currency IDs used for multipliers.
1871
+ */
1872
+ multiplierLoyaltyCurrencyIds?: Array<string> | null;
1873
+ /**
1874
+ * Flag indicating whether to include only known users.
1875
+ */
1876
+ onlyKnownUsers?: boolean;
1877
+ /**
1878
+ * Flag indicating whether to include only native tokens.
1879
+ */
1880
+ onlyNative?: boolean;
1881
+ /**
1882
+ * Flag indicating whether to include only non-listed items.
1883
+ */
1884
+ onlyNonListed?: boolean;
1885
+ /**
1886
+ * Indicates if only existing users are rewarded.
1887
+ */
1888
+ onlyRewardExistingUser?: boolean;
1889
+ /**
1890
+ * give points for only one token ownership per contract
1891
+ */
1892
+ onlyRewardSingleTokenOwnership?: boolean | null;
1893
+ /**
1894
+ * Pre-generated text template that will be used to prefill the post content.
1895
+ */
1896
+ preGeneratedPostText?: string | null;
1897
+ /**
1898
+ * Promotional code associated with the rule.
1899
+ */
1900
+ promoCode?: string;
1901
+ /**
1902
+ * URL of the CSV file containing promo codes.
1903
+ */
1904
+ promoCodeCsvUrl?: string;
1905
+ /**
1906
+ * Numbers of the promotional code to be generated.
1907
+ */
1908
+ promoCodeLength?: number | null;
1909
+ /**
1910
+ * Type of the promotional code.
1911
+ */
1912
+ promoCodeType?: 'code' | 'csv' | 'generate';
1913
+ /**
1914
+ * Array defining ranges and corresponding rewards.
1915
+ */
1916
+ range?: Array<Metadata.Range>;
1917
+ /**
1918
+ * ID of the Reddit post.
1919
+ */
1920
+ redditPostId?: string | null;
1921
+ /**
1922
+ * Object defining referral requirements.
1923
+ */
1924
+ referralRequirements?: Metadata.ReferralRequirements | null;
1925
+ /**
1926
+ * Lump sum reward given to a referrer.
1927
+ */
1928
+ referrerReward?: number | null;
1929
+ /**
1930
+ * Loyalty currency ID of the referrer reward.
1931
+ */
1932
+ referrerRewardLoyaltyCurrencyId?: string | null;
1933
+ /**
1934
+ * Flag indicating if the post link is required.
1935
+ */
1936
+ requirePostLink?: boolean | null;
1937
+ /**
1938
+ * Flag indicating if media metadata is required.
1939
+ */
1940
+ requirePostMediaLink?: boolean | null;
1941
+ /**
1942
+ * Flag indicating if the rule can also reward badges per range.
1943
+ */
1944
+ rewardBadgePerRange?: boolean;
1945
+ /**
1946
+ * Flag indicating if the reward is rewarded by batch.
1947
+ */
1948
+ rewardByBatch?: boolean | null;
1949
+ /**
1950
+ * Criteria to evaluate the reward.
1951
+ */
1952
+ rewardCriteria?: 'IMPRESSIONS_COUNT' | 'ELIGIBLE_POST' | null;
1953
+ /**
1954
+ * Flag indicating if the reward is rewarded per action.
1955
+ */
1956
+ rewardPerAction?: boolean | null;
1957
+ /**
1958
+ * Flag indicating if rewards are given per impression.
1959
+ */
1960
+ rewardPerImpression?: boolean | null;
1961
+ /**
1962
+ * Flag indicating if the rule should reward based on value of traded tokens
1963
+ * instead of count.
1964
+ */
1965
+ rewardPerValue?: boolean;
1966
+ /**
1967
+ * Flag indicating if the rule should reward quality posts.
1968
+ */
1969
+ rewardQualityPosts?: boolean;
1970
+ robinhoodSymbols?: Array<string> | null;
1971
+ /**
1972
+ * Wallet address of the user can only be used if userId is not provided
1973
+ */
1974
+ royaltyAddress?: string;
1975
+ /**
1976
+ * Royalty percentage of the item.
1977
+ */
1978
+ royaltyPercentage?: number;
1979
+ /**
1980
+ * Currency associated with sales.
1981
+ */
1982
+ saleCurrency?: string;
1983
+ /**
1984
+ * Percentage reward given for a second-level referral.
1985
+ */
1986
+ secondReferralReward?: number | null;
1987
+ /**
1988
+ * Flag indicating if the multiplier is skipped.
1989
+ */
1990
+ skipMultiplier?: boolean | null;
1991
+ /**
1992
+ * Object containing details of the associated smart contract.
1993
+ */
1994
+ smartContract?: Metadata.SmartContract;
1995
+ /**
1996
+ * Array of snapshot proposals for the rule.
1997
+ */
1998
+ snapshotProposals?: Array<Metadata.SnapshotProposal> | null;
1999
+ /**
2000
+ * Social media platform associated with the rule.
2001
+ */
2002
+ socialPlatform?: 'Custom' | 'Discord' | 'EpicGames' | 'Instagram' | 'Steam' | 'Telegram' | 'TikTok' | 'Twitch' | 'X(Twitter)' | 'YouTube' | 'Google' | 'GitHub' | 'Reddit' | null;
2003
+ /**
2004
+ * URL of the social platform's logo.
2005
+ */
2006
+ socialPlatformLogo?: string | null;
2007
+ /**
2008
+ * Name of the social platform.
2009
+ */
2010
+ socialPlatformName?: string | null;
2011
+ /**
2012
+ * ID of the Steam app.
2013
+ */
2014
+ steamAppId?: string | null;
2015
+ /**
2016
+ * Array of streak milestones and corresponding rewards.
2017
+ */
2018
+ streakArray?: Array<Metadata.StreakArray> | null;
2019
+ /**
2020
+ * Metadata for swap loyalty rules
2021
+ */
2022
+ swap?: Metadata.Swap;
2023
+ /**
2024
+ * ID of the Telegram channel.
2025
+ */
2026
+ telegramChannelId?: string | null;
2027
+ /**
2028
+ * Time delay in seconds to verify actions.
2029
+ */
2030
+ timeDelayToVerifySeconds?: string | number | null;
2031
+ /**
2032
+ * Flag indicating if all contracts are tracked.
2033
+ */
2034
+ trackAllContracts?: boolean | null;
2035
+ /**
2036
+ * Flag indicating if the progress is tracked. If enabled, the rule can only be
2037
+ * completed once the progress is 100%.
2038
+ */
2039
+ trackProgress?: boolean | null;
2040
+ /**
2041
+ * URL of the associated Twitter account.
2042
+ */
2043
+ twitterAccountUrl?: string;
2044
+ /**
2045
+ * Hashtag associated with the Twitter post.
2046
+ */
2047
+ twitterHashtag?: string;
2048
+ /**
2049
+ * URL of the associated Twitter post.
2050
+ */
2051
+ twitterPostUrl?: string;
2052
+ /**
2053
+ * Unique identifier of the Twitter user.
2054
+ */
2055
+ twitterUserId?: string;
2056
+ /**
2057
+ * Twitter username of the user.
2058
+ */
2059
+ twitterUsername?: string;
2060
+ /**
2061
+ * Minimum length of the verification text.
2062
+ */
2063
+ verificationTextMinimumLength?: number | null;
2064
+ /**
2065
+ * Multiplier applied to rewards for verified users.
2066
+ */
2067
+ verifiedMultiplier?: number | null;
2068
+ /**
2069
+ * Placeholder text for verification input fields.
2070
+ */
2071
+ verifyPlaceHolderText?: string | null;
2072
+ /**
2073
+ * Type of wallet associated with the rule.
2074
+ */
2075
+ walletType?: 'evm' | 'solana' | 'imx' | 'sui' | 'ton' | 'cosmos' | 'ultra' | 'agw' | 'flow_cadence' | 'substrate' | null;
2076
+ /**
2077
+ * ID of the Youtube channel.
2078
+ */
2079
+ youtubeChannelId?: string | null;
2080
+ /**
2081
+ * ID of the Youtube video.
2082
+ */
2083
+ youtubeVideoId?: string | null;
2084
+ }
2085
+ namespace Metadata {
2086
+ interface Collection {
2087
+ /**
2088
+ * Blockchain address of the collection.
2089
+ */
2090
+ address?: string;
2091
+ /**
2092
+ * Multiplier applied to the rewards for this collection.
2093
+ */
2094
+ multiplier?: number;
2095
+ /**
2096
+ * Blockchain network of the collection.
2097
+ */
2098
+ network?: 'abstract' | 'abstractTestnet' | 'apechain' | 'arbitrum' | 'avalanche' | 'avalancheFuji' | 'base' | 'baseSepolia' | 'berachain' | 'berachainArtio' | 'berachainBepolia' | 'binance' | 'bscTestnet' | 'campTestnet' | 'fantom' | 'fantomTestnet' | 'flowMainnet' | 'mainnet' | 'nexusTestnet' | 'optimism' | 'polygon' | 'polygon_mumbai' | 'skaleNebula' | 'skaleEuropa' | 'skaleCalypso' | 'solana' | 'sophon' | 'sophonTestnet' | 'sui' | 'superseed' | 'superseedSepolia' | 'vanar' | 'xai' | 'zksync' | 'coti' | 'cotiTestnet' | 'morph' | 'morphTestnet' | 'morphHolesky' | 'ultra' | 'ultraTestnet' | 'nitrograph' | 'sepolia' | 'optimism_sepolia' | 'arbitrumSepolia' | 'goerli' | 'optimism_goerli' | 'arbitrumGoerli' | 'basecamp' | 'somnia' | 'zkverify' | 'polkadot' | 'kusama' | 'flow_cadence';
2099
+ }
2100
+ /**
2101
+ * Object containing details for the call-to-action.
2102
+ */
2103
+ interface Cta {
2104
+ /**
2105
+ * Link for the call-to-action.
2106
+ */
2107
+ href?: string | null;
2108
+ /**
2109
+ * Label for the call-to-action.
2110
+ */
2111
+ label?: string | null;
2112
+ }
2113
+ interface DiscordServersToJoin {
2114
+ /**
2115
+ * ID of the Discord server to join.
2116
+ */
2117
+ id?: string;
2118
+ /**
2119
+ * Array of Discord channels to join.
2120
+ */
2121
+ channels?: Array<DiscordServersToJoin.Channel>;
2122
+ /**
2123
+ * Array of roles to assign in the Discord server.
2124
+ */
2125
+ roles?: Array<DiscordServersToJoin.Role>;
2126
+ }
2127
+ namespace DiscordServersToJoin {
2128
+ interface Channel {
2129
+ /**
2130
+ * ID of the Discord channel.
2131
+ */
2132
+ id?: string;
2133
+ /**
2134
+ * Array of emojis used in the channel.
2135
+ */
2136
+ emojis?: Array<Channel.Emoji>;
2137
+ /**
2138
+ * Phrase of text to be present in the discord message
2139
+ */
2140
+ text?: string;
2141
+ }
2142
+ namespace Channel {
2143
+ interface Emoji {
2144
+ /**
2145
+ * ID of the emoji used in the channel.
2146
+ */
2147
+ id?: string;
2148
+ }
2149
+ }
2150
+ interface Role {
2151
+ /**
2152
+ * ID of the role in the Discord server.
2153
+ */
2154
+ id: string;
2155
+ }
2156
+ }
2157
+ interface DripQuestsToComplete {
2158
+ /**
2159
+ * ID of the drip quest to complete.
2160
+ */
2161
+ id: string;
2162
+ }
2163
+ /**
2164
+ * Liquidity pool details.
2165
+ */
2166
+ interface Liquidity {
2167
+ /**
2168
+ * Calculation type of the liquidity pool.
2169
+ */
2170
+ calculationType?: 'fixed' | 'custom';
2171
+ /**
2172
+ * Custom function to calculate the the reward amount based on the liquidity
2173
+ * provided per day. X is the reward amount, Y is the liquidity provided per day in
2174
+ * USD.
2175
+ */
2176
+ customFunction?: string;
2177
+ /**
2178
+ * Liquidity provided per day in USD
2179
+ */
2180
+ liquidityPerDay?: number;
2181
+ /**
2182
+ * Blockchain network of the liquidity pool.
2183
+ */
2184
+ network?: 'abstract' | 'abstractTestnet' | 'apechain' | 'arbitrum' | 'avalanche' | 'avalancheFuji' | 'base' | 'baseSepolia' | 'berachain' | 'berachainArtio' | 'berachainBepolia' | 'binance' | 'bscTestnet' | 'campTestnet' | 'fantom' | 'fantomTestnet' | 'flowMainnet' | 'mainnet' | 'nexusTestnet' | 'optimism' | 'polygon' | 'polygon_mumbai' | 'skaleNebula' | 'skaleEuropa' | 'skaleCalypso' | 'solana' | 'sophon' | 'sophonTestnet' | 'sui' | 'superseed' | 'superseedSepolia' | 'vanar' | 'xai' | 'zksync' | 'coti' | 'cotiTestnet' | 'morph' | 'morphTestnet' | 'morphHolesky' | 'ultra' | 'ultraTestnet' | 'nitrograph' | 'sepolia' | 'optimism_sepolia' | 'arbitrumSepolia' | 'goerli' | 'optimism_goerli' | 'arbitrumGoerli' | 'basecamp' | 'somnia' | 'zkverify' | 'polkadot' | 'kusama' | 'flow_cadence';
2185
+ /**
2186
+ * Indicates if only in-range liquidity is rewarded.
2187
+ */
2188
+ onlyRewardInRangeLiquidity?: boolean;
2189
+ /**
2190
+ * Array of liquidity pools associated with the rule.
2191
+ */
2192
+ pools?: Array<Liquidity.Pool>;
2193
+ /**
2194
+ * Protocol of the liquidity pool.
2195
+ */
2196
+ protocol?: string;
2197
+ }
2198
+ namespace Liquidity {
2199
+ interface Pool {
2200
+ /**
2201
+ * Unique identifier of the liquidity pool.
2202
+ */
2203
+ id: string;
2204
+ }
2205
+ }
2206
+ interface Range {
2207
+ /**
2208
+ * Reward amount for this range.
2209
+ */
2210
+ amount: number;
2211
+ /**
2212
+ * End value of the range.
2213
+ */
2214
+ endRange: number;
2215
+ /**
2216
+ * Start value of the range.
2217
+ */
2218
+ startRange: number;
2219
+ /**
2220
+ * ID of the loyalty badge for this range.
2221
+ */
2222
+ loyaltyBadgeId?: string;
2223
+ /**
2224
+ * Amount of the loyalty multiplier for this range.
2225
+ */
2226
+ loyaltyMultiplierAmount?: number;
2227
+ }
2228
+ /**
2229
+ * Object defining referral requirements.
2230
+ */
2231
+ interface ReferralRequirements {
2232
+ /**
2233
+ * Flag indicating if achieving points is required.
2234
+ */
2235
+ achievePoints?: boolean | null;
2236
+ /**
2237
+ * Flag indicating if completing the profile is required.
2238
+ */
2239
+ completeProfile?: boolean | null;
2240
+ /**
2241
+ * Flag indicating if connecting Discord is required.
2242
+ */
2243
+ connectDiscord?: boolean | null;
2244
+ /**
2245
+ * Flag indicating if connecting email is required.
2246
+ */
2247
+ connectEmail?: boolean | null;
2248
+ /**
2249
+ * Flag indicating if connecting Twitter is required.
2250
+ */
2251
+ connectTwitter?: boolean | null;
2252
+ points?: ReferralRequirements.Points | null;
2253
+ }
2254
+ namespace ReferralRequirements {
2255
+ interface Points {
2256
+ /**
2257
+ * Points required for referral.
2258
+ */
2259
+ amount?: number | null;
2260
+ /**
2261
+ * ID of the loyalty currency for referral.
2262
+ */
2263
+ loyaltyCurrecyId?: string | null;
2264
+ }
2265
+ }
2266
+ /**
2267
+ * Object containing details of the associated smart contract.
2268
+ */
2269
+ interface SmartContract {
2270
+ /**
2271
+ * Mapping of addresses for the smart contract.
2272
+ */
2273
+ addressMapping?: string | null;
2274
+ /**
2275
+ * Object containing details of the amount multiplier from the event.
2276
+ */
2277
+ amountMultiplier?: SmartContract.AmountMultiplier | null;
2278
+ /**
2279
+ * ID of the smart contract.
2280
+ */
2281
+ contractId?: string | null;
2282
+ /**
2283
+ * Criteria to evaluate the smart contract event.
2284
+ */
2285
+ criteria?: 'everyEvent' | 'byParameter' | null;
2286
+ /**
2287
+ * Event emitted by the smart contract.
2288
+ */
2289
+ event?: string | null;
2290
+ /**
2291
+ * Array of parameters for the smart contract.
2292
+ */
2293
+ params?: Array<SmartContract.Param> | null;
2294
+ /**
2295
+ * Type of the smart contract interaction.
2296
+ */
2297
+ type?: 'function' | 'event' | null;
2298
+ }
2299
+ namespace SmartContract {
2300
+ /**
2301
+ * Object containing details of the amount multiplier from the event.
2302
+ */
2303
+ interface AmountMultiplier {
2304
+ /**
2305
+ * Mapping of the value for the smart contract.
2306
+ */
2307
+ valueMapping?: string | null;
2308
+ }
2309
+ interface Param {
2310
+ /**
2311
+ * Condition to check for the parameter.
2312
+ */
2313
+ condition?: string | null;
2314
+ /**
2315
+ * Name of the smart contract parameter.
2316
+ */
2317
+ name?: string | null;
2318
+ /**
2319
+ * Value of the parameter.
2320
+ */
2321
+ value?: string | null;
2322
+ }
2323
+ }
2324
+ interface SnapshotProposal {
2325
+ /**
2326
+ * ID of the snapshot proposal.
2327
+ */
2328
+ id: string;
2329
+ /**
2330
+ * Space associated with the snapshot proposal.
2331
+ */
2332
+ space: string;
2333
+ }
2334
+ interface StreakArray {
2335
+ /**
2336
+ * Reward amount for achieving the streak milestone.
2337
+ */
2338
+ streakAmount: number;
2339
+ /**
2340
+ * Milestone required to achieve the streak.
2341
+ */
2342
+ streakMilestone: number;
2343
+ }
2344
+ /**
2345
+ * Metadata for swap loyalty rules
2346
+ */
2347
+ interface Swap {
2348
+ from?: Swap.From;
2349
+ provider?: 'any' | 'relay' | 'lifi';
2350
+ relayReferrerId?: string;
2351
+ requireCrossChainSwap?: boolean;
2352
+ to?: Swap.To;
2353
+ }
2354
+ namespace Swap {
2355
+ interface From {
2356
+ chain?: 'any' | number | string;
2357
+ mode?: 'any' | 'specific';
2358
+ tokens?: Array<From.Token>;
2359
+ trackAmount?: boolean;
2360
+ }
2361
+ namespace From {
2362
+ interface Token {
2363
+ address: string;
2364
+ chainId: string;
2365
+ }
2366
+ }
2367
+ interface To {
2368
+ chain?: 'any' | number | string;
2369
+ mode?: 'any' | 'specific';
2370
+ tokens?: Array<To.Token>;
2371
+ trackAmount?: boolean;
2372
+ }
2373
+ namespace To {
2374
+ interface Token {
2375
+ address: string;
2376
+ chainId: string;
2377
+ }
2378
+ }
2379
+ }
2380
+ }
252
2381
  }
253
2382
  /**
254
2383
  * Previous data of the rule before the edit
@@ -261,7 +2390,7 @@ export declare namespace RuleEditRestoreResponse {
261
2390
  /**
262
2391
  * Amount associated with the loyalty rule
263
2392
  */
264
- amount: number;
2393
+ amount: number | null;
265
2394
  /**
266
2395
  * Timestamp when the loyalty rule was created
267
2396
  */
@@ -270,14 +2399,34 @@ export declare namespace RuleEditRestoreResponse {
270
2399
  * Timestamp when the loyalty rule was deleted (if applicable)
271
2400
  */
272
2401
  deletedAt: string | null;
2402
+ /**
2403
+ * Description of the loyalty rule
2404
+ */
2405
+ description: string;
2406
+ /**
2407
+ * End time of the loyalty rule
2408
+ */
2409
+ endTime: string | null;
273
2410
  /**
274
2411
  * Frequency of the loyalty rule
275
2412
  */
276
2413
  frequency: string;
2414
+ /**
2415
+ * Name of the loyalty rule
2416
+ */
2417
+ name: string;
277
2418
  /**
278
2419
  * Unique identifier for the organization
279
2420
  */
280
2421
  organizationId: string;
2422
+ /**
2423
+ * Type of the reward
2424
+ */
2425
+ rewardType: 'points' | 'multiplier' | 'badge';
2426
+ /**
2427
+ * Start time of the loyalty rule
2428
+ */
2429
+ startTime: string | null;
281
2430
  /**
282
2431
  * Type of the loyalty rule
283
2432
  */
@@ -294,10 +2443,695 @@ export declare namespace RuleEditRestoreResponse {
294
2443
  * Optional address of the collection
295
2444
  */
296
2445
  collectionAddress?: string;
2446
+ /**
2447
+ * URL of the media associated with the loyalty rule
2448
+ */
2449
+ mediaUrl?: string | null;
297
2450
  /**
298
2451
  * Optional metadata for the loyalty rule
299
2452
  */
300
- metadata?: Record<string, unknown>;
2453
+ metadata?: {
2454
+ [key: string]: PreviousData.Metadata;
2455
+ };
2456
+ }
2457
+ namespace PreviousData {
2458
+ interface Metadata {
2459
+ /**
2460
+ * Flag indicating if the rule allows multiple redemptions. Applies to Enter a Code
2461
+ * only.
2462
+ */
2463
+ allowMultipleRedemptions?: boolean;
2464
+ /**
2465
+ * Array of loyalty rule IDs that count as check-in when completed. If ["any"] then
2466
+ * any rule completions count as check-in.
2467
+ */
2468
+ autoCheckInRuleIds?: Array<(string & {}) | 'any'> | null;
2469
+ /**
2470
+ * Number of tokens per batch.
2471
+ */
2472
+ batchSize?: number | null;
2473
+ /**
2474
+ * Text displayed on the action button.
2475
+ */
2476
+ buttonText?: string | null;
2477
+ /**
2478
+ * Flag indicating if commenting is required.
2479
+ */
2480
+ checkComment?: boolean | null;
2481
+ /**
2482
+ * Flag indicating if liking the post is required.
2483
+ */
2484
+ checkLike?: boolean | null;
2485
+ /**
2486
+ * Flag indicating if reposting is required.
2487
+ */
2488
+ checkRepost?: boolean | null;
2489
+ /**
2490
+ * Text to check in the Twitter post, username, or bio.
2491
+ */
2492
+ checkText?: string | Array<string> | null;
2493
+ /**
2494
+ * Array of collections associated with the rule.
2495
+ */
2496
+ collection?: Array<Metadata.Collection>;
2497
+ /**
2498
+ * Conditions for completing the profile.
2499
+ */
2500
+ completeProfileConditions?: {
2501
+ [key: string]: boolean;
2502
+ } | null;
2503
+ /**
2504
+ * Description of the external rule condition (only for external rules)
2505
+ */
2506
+ conditionDescription?: string;
2507
+ /**
2508
+ * Object containing details for the call-to-action.
2509
+ */
2510
+ cta?: Metadata.Cta | null;
2511
+ /**
2512
+ * API key for custom rewards integration.
2513
+ */
2514
+ customRewardsApiKey?: string;
2515
+ /**
2516
+ * Flag indicating if the rule should use direct RPC to get the balance of tokens.
2517
+ */
2518
+ directRpc?: boolean;
2519
+ /**
2520
+ * Array of Discord servers, channels, and roles to join.
2521
+ */
2522
+ discordServersToJoin?: Array<Metadata.DiscordServersToJoin> | null;
2523
+ /**
2524
+ * Array of drip quests required to complete the rule.
2525
+ */
2526
+ dripQuestsToComplete?: Array<Metadata.DripQuestsToComplete> | null;
2527
+ /**
2528
+ * Flag indicating whether joining Discord servers is required.
2529
+ */
2530
+ enableJoinDiscordServers?: boolean | null;
2531
+ /**
2532
+ * Flag indicating whether streaks are enabled.
2533
+ */
2534
+ enableStreaks?: boolean | null;
2535
+ /**
2536
+ * Flag indicating whether the verified multiplier is enabled.
2537
+ */
2538
+ enableVerifiedMultiplier?: boolean;
2539
+ /**
2540
+ * Type of ERC20 token for the loyalty rule.
2541
+ */
2542
+ erc20Type?: 'erc20' | 'native';
2543
+ /**
2544
+ * Fill source of the order for the token sale
2545
+ */
2546
+ fillSource?: string;
2547
+ /**
2548
+ * Percentage reward given to a user for their first referral.
2549
+ */
2550
+ firstReferralReward?: number | null;
2551
+ /**
2552
+ * Name of the GitHub branch to check for PR merge.
2553
+ */
2554
+ githubBranchName?: string | null;
2555
+ /**
2556
+ * URL of the GitHub repository to check for star.
2557
+ */
2558
+ githubRepoUrl?: string | null;
2559
+ /**
2560
+ * Flag indicating whether the fill source is included.
2561
+ */
2562
+ hasFillSource?: boolean;
2563
+ /**
2564
+ * Indicates if the item has never been sold.
2565
+ */
2566
+ hasNeverSold?: boolean;
2567
+ /**
2568
+ * Indicates if the full royalty has been paid for items.
2569
+ */
2570
+ hasPaidFullRoyalty?: boolean;
2571
+ /**
2572
+ * Flag indicating if the sale currency is included.
2573
+ */
2574
+ hasSaleCurrency?: boolean;
2575
+ /**
2576
+ * Indicates if the user has a verified Twitter account.
2577
+ */
2578
+ hasVerifiedTwitter?: boolean;
2579
+ /**
2580
+ * URL of the image associated with the rule.
2581
+ */
2582
+ imageUrl?: string | null;
2583
+ /**
2584
+ * If enabled, the first transaction done on the platform will complete this rule
2585
+ */
2586
+ isCheckInOnEveryTxn?: boolean;
2587
+ /**
2588
+ * Indicates if the multiplier has been applied to rewards.
2589
+ */
2590
+ isMultiplierApplied?: boolean;
2591
+ /**
2592
+ * Flag indicating if the rule is restricted to new users.
2593
+ */
2594
+ isRestrictedToNewUsers?: boolean;
2595
+ /**
2596
+ * Flag indicating if rewards are applied retroactively.
2597
+ */
2598
+ isRetroactive?: boolean | null;
2599
+ /**
2600
+ * Flag indicating if the token hold multiplier is applied.
2601
+ */
2602
+ isTokenHoldMultiplier?: boolean;
2603
+ /**
2604
+ * Optional link associated with the metadata.
2605
+ */
2606
+ link?: string | null;
2607
+ /**
2608
+ * Liquidity pool details.
2609
+ */
2610
+ liquidity?: Metadata.Liquidity;
2611
+ /**
2612
+ * Maximum quantity constraint for token holding.
2613
+ */
2614
+ maxQty?: number | null;
2615
+ /**
2616
+ * Minimum follower count for the rule. Accepts both number and string values.
2617
+ */
2618
+ minimumFollowerCount?: number | null;
2619
+ /**
2620
+ * Minimum quantity constraint for token holding.
2621
+ */
2622
+ minQty?: number | null;
2623
+ /**
2624
+ * Array of loyalty currency IDs used for multipliers.
2625
+ */
2626
+ multiplierLoyaltyCurrencyIds?: Array<string> | null;
2627
+ /**
2628
+ * Flag indicating whether to include only known users.
2629
+ */
2630
+ onlyKnownUsers?: boolean;
2631
+ /**
2632
+ * Flag indicating whether to include only native tokens.
2633
+ */
2634
+ onlyNative?: boolean;
2635
+ /**
2636
+ * Flag indicating whether to include only non-listed items.
2637
+ */
2638
+ onlyNonListed?: boolean;
2639
+ /**
2640
+ * Indicates if only existing users are rewarded.
2641
+ */
2642
+ onlyRewardExistingUser?: boolean;
2643
+ /**
2644
+ * give points for only one token ownership per contract
2645
+ */
2646
+ onlyRewardSingleTokenOwnership?: boolean | null;
2647
+ /**
2648
+ * Pre-generated text template that will be used to prefill the post content.
2649
+ */
2650
+ preGeneratedPostText?: string | null;
2651
+ /**
2652
+ * Promotional code associated with the rule.
2653
+ */
2654
+ promoCode?: string;
2655
+ /**
2656
+ * URL of the CSV file containing promo codes.
2657
+ */
2658
+ promoCodeCsvUrl?: string;
2659
+ /**
2660
+ * Numbers of the promotional code to be generated.
2661
+ */
2662
+ promoCodeLength?: number | null;
2663
+ /**
2664
+ * Type of the promotional code.
2665
+ */
2666
+ promoCodeType?: 'code' | 'csv' | 'generate';
2667
+ /**
2668
+ * Array defining ranges and corresponding rewards.
2669
+ */
2670
+ range?: Array<Metadata.Range>;
2671
+ /**
2672
+ * ID of the Reddit post.
2673
+ */
2674
+ redditPostId?: string | null;
2675
+ /**
2676
+ * Object defining referral requirements.
2677
+ */
2678
+ referralRequirements?: Metadata.ReferralRequirements | null;
2679
+ /**
2680
+ * Lump sum reward given to a referrer.
2681
+ */
2682
+ referrerReward?: number | null;
2683
+ /**
2684
+ * Loyalty currency ID of the referrer reward.
2685
+ */
2686
+ referrerRewardLoyaltyCurrencyId?: string | null;
2687
+ /**
2688
+ * Flag indicating if the post link is required.
2689
+ */
2690
+ requirePostLink?: boolean | null;
2691
+ /**
2692
+ * Flag indicating if media metadata is required.
2693
+ */
2694
+ requirePostMediaLink?: boolean | null;
2695
+ /**
2696
+ * Flag indicating if the rule can also reward badges per range.
2697
+ */
2698
+ rewardBadgePerRange?: boolean;
2699
+ /**
2700
+ * Flag indicating if the reward is rewarded by batch.
2701
+ */
2702
+ rewardByBatch?: boolean | null;
2703
+ /**
2704
+ * Criteria to evaluate the reward.
2705
+ */
2706
+ rewardCriteria?: 'IMPRESSIONS_COUNT' | 'ELIGIBLE_POST' | null;
2707
+ /**
2708
+ * Flag indicating if the reward is rewarded per action.
2709
+ */
2710
+ rewardPerAction?: boolean | null;
2711
+ /**
2712
+ * Flag indicating if rewards are given per impression.
2713
+ */
2714
+ rewardPerImpression?: boolean | null;
2715
+ /**
2716
+ * Flag indicating if the rule should reward based on value of traded tokens
2717
+ * instead of count.
2718
+ */
2719
+ rewardPerValue?: boolean;
2720
+ /**
2721
+ * Flag indicating if the rule should reward quality posts.
2722
+ */
2723
+ rewardQualityPosts?: boolean;
2724
+ robinhoodSymbols?: Array<string> | null;
2725
+ /**
2726
+ * Wallet address of the user can only be used if userId is not provided
2727
+ */
2728
+ royaltyAddress?: string;
2729
+ /**
2730
+ * Royalty percentage of the item.
2731
+ */
2732
+ royaltyPercentage?: number;
2733
+ /**
2734
+ * Currency associated with sales.
2735
+ */
2736
+ saleCurrency?: string;
2737
+ /**
2738
+ * Percentage reward given for a second-level referral.
2739
+ */
2740
+ secondReferralReward?: number | null;
2741
+ /**
2742
+ * Flag indicating if the multiplier is skipped.
2743
+ */
2744
+ skipMultiplier?: boolean | null;
2745
+ /**
2746
+ * Object containing details of the associated smart contract.
2747
+ */
2748
+ smartContract?: Metadata.SmartContract;
2749
+ /**
2750
+ * Array of snapshot proposals for the rule.
2751
+ */
2752
+ snapshotProposals?: Array<Metadata.SnapshotProposal> | null;
2753
+ /**
2754
+ * Social media platform associated with the rule.
2755
+ */
2756
+ socialPlatform?: 'Custom' | 'Discord' | 'EpicGames' | 'Instagram' | 'Steam' | 'Telegram' | 'TikTok' | 'Twitch' | 'X(Twitter)' | 'YouTube' | 'Google' | 'GitHub' | 'Reddit' | null;
2757
+ /**
2758
+ * URL of the social platform's logo.
2759
+ */
2760
+ socialPlatformLogo?: string | null;
2761
+ /**
2762
+ * Name of the social platform.
2763
+ */
2764
+ socialPlatformName?: string | null;
2765
+ /**
2766
+ * ID of the Steam app.
2767
+ */
2768
+ steamAppId?: string | null;
2769
+ /**
2770
+ * Array of streak milestones and corresponding rewards.
2771
+ */
2772
+ streakArray?: Array<Metadata.StreakArray> | null;
2773
+ /**
2774
+ * Metadata for swap loyalty rules
2775
+ */
2776
+ swap?: Metadata.Swap;
2777
+ /**
2778
+ * ID of the Telegram channel.
2779
+ */
2780
+ telegramChannelId?: string | null;
2781
+ /**
2782
+ * Time delay in seconds to verify actions.
2783
+ */
2784
+ timeDelayToVerifySeconds?: string | number | null;
2785
+ /**
2786
+ * Flag indicating if all contracts are tracked.
2787
+ */
2788
+ trackAllContracts?: boolean | null;
2789
+ /**
2790
+ * Flag indicating if the progress is tracked. If enabled, the rule can only be
2791
+ * completed once the progress is 100%.
2792
+ */
2793
+ trackProgress?: boolean | null;
2794
+ /**
2795
+ * URL of the associated Twitter account.
2796
+ */
2797
+ twitterAccountUrl?: string;
2798
+ /**
2799
+ * Hashtag associated with the Twitter post.
2800
+ */
2801
+ twitterHashtag?: string;
2802
+ /**
2803
+ * URL of the associated Twitter post.
2804
+ */
2805
+ twitterPostUrl?: string;
2806
+ /**
2807
+ * Unique identifier of the Twitter user.
2808
+ */
2809
+ twitterUserId?: string;
2810
+ /**
2811
+ * Twitter username of the user.
2812
+ */
2813
+ twitterUsername?: string;
2814
+ /**
2815
+ * Minimum length of the verification text.
2816
+ */
2817
+ verificationTextMinimumLength?: number | null;
2818
+ /**
2819
+ * Multiplier applied to rewards for verified users.
2820
+ */
2821
+ verifiedMultiplier?: number | null;
2822
+ /**
2823
+ * Placeholder text for verification input fields.
2824
+ */
2825
+ verifyPlaceHolderText?: string | null;
2826
+ /**
2827
+ * Type of wallet associated with the rule.
2828
+ */
2829
+ walletType?: 'evm' | 'solana' | 'imx' | 'sui' | 'ton' | 'cosmos' | 'ultra' | 'agw' | 'flow_cadence' | 'substrate' | null;
2830
+ /**
2831
+ * ID of the Youtube channel.
2832
+ */
2833
+ youtubeChannelId?: string | null;
2834
+ /**
2835
+ * ID of the Youtube video.
2836
+ */
2837
+ youtubeVideoId?: string | null;
2838
+ }
2839
+ namespace Metadata {
2840
+ interface Collection {
2841
+ /**
2842
+ * Blockchain address of the collection.
2843
+ */
2844
+ address?: string;
2845
+ /**
2846
+ * Multiplier applied to the rewards for this collection.
2847
+ */
2848
+ multiplier?: number;
2849
+ /**
2850
+ * Blockchain network of the collection.
2851
+ */
2852
+ network?: 'abstract' | 'abstractTestnet' | 'apechain' | 'arbitrum' | 'avalanche' | 'avalancheFuji' | 'base' | 'baseSepolia' | 'berachain' | 'berachainArtio' | 'berachainBepolia' | 'binance' | 'bscTestnet' | 'campTestnet' | 'fantom' | 'fantomTestnet' | 'flowMainnet' | 'mainnet' | 'nexusTestnet' | 'optimism' | 'polygon' | 'polygon_mumbai' | 'skaleNebula' | 'skaleEuropa' | 'skaleCalypso' | 'solana' | 'sophon' | 'sophonTestnet' | 'sui' | 'superseed' | 'superseedSepolia' | 'vanar' | 'xai' | 'zksync' | 'coti' | 'cotiTestnet' | 'morph' | 'morphTestnet' | 'morphHolesky' | 'ultra' | 'ultraTestnet' | 'nitrograph' | 'sepolia' | 'optimism_sepolia' | 'arbitrumSepolia' | 'goerli' | 'optimism_goerli' | 'arbitrumGoerli' | 'basecamp' | 'somnia' | 'zkverify' | 'polkadot' | 'kusama' | 'flow_cadence';
2853
+ }
2854
+ /**
2855
+ * Object containing details for the call-to-action.
2856
+ */
2857
+ interface Cta {
2858
+ /**
2859
+ * Link for the call-to-action.
2860
+ */
2861
+ href?: string | null;
2862
+ /**
2863
+ * Label for the call-to-action.
2864
+ */
2865
+ label?: string | null;
2866
+ }
2867
+ interface DiscordServersToJoin {
2868
+ /**
2869
+ * ID of the Discord server to join.
2870
+ */
2871
+ id?: string;
2872
+ /**
2873
+ * Array of Discord channels to join.
2874
+ */
2875
+ channels?: Array<DiscordServersToJoin.Channel>;
2876
+ /**
2877
+ * Array of roles to assign in the Discord server.
2878
+ */
2879
+ roles?: Array<DiscordServersToJoin.Role>;
2880
+ }
2881
+ namespace DiscordServersToJoin {
2882
+ interface Channel {
2883
+ /**
2884
+ * ID of the Discord channel.
2885
+ */
2886
+ id?: string;
2887
+ /**
2888
+ * Array of emojis used in the channel.
2889
+ */
2890
+ emojis?: Array<Channel.Emoji>;
2891
+ /**
2892
+ * Phrase of text to be present in the discord message
2893
+ */
2894
+ text?: string;
2895
+ }
2896
+ namespace Channel {
2897
+ interface Emoji {
2898
+ /**
2899
+ * ID of the emoji used in the channel.
2900
+ */
2901
+ id?: string;
2902
+ }
2903
+ }
2904
+ interface Role {
2905
+ /**
2906
+ * ID of the role in the Discord server.
2907
+ */
2908
+ id: string;
2909
+ }
2910
+ }
2911
+ interface DripQuestsToComplete {
2912
+ /**
2913
+ * ID of the drip quest to complete.
2914
+ */
2915
+ id: string;
2916
+ }
2917
+ /**
2918
+ * Liquidity pool details.
2919
+ */
2920
+ interface Liquidity {
2921
+ /**
2922
+ * Calculation type of the liquidity pool.
2923
+ */
2924
+ calculationType?: 'fixed' | 'custom';
2925
+ /**
2926
+ * Custom function to calculate the the reward amount based on the liquidity
2927
+ * provided per day. X is the reward amount, Y is the liquidity provided per day in
2928
+ * USD.
2929
+ */
2930
+ customFunction?: string;
2931
+ /**
2932
+ * Liquidity provided per day in USD
2933
+ */
2934
+ liquidityPerDay?: number;
2935
+ /**
2936
+ * Blockchain network of the liquidity pool.
2937
+ */
2938
+ network?: 'abstract' | 'abstractTestnet' | 'apechain' | 'arbitrum' | 'avalanche' | 'avalancheFuji' | 'base' | 'baseSepolia' | 'berachain' | 'berachainArtio' | 'berachainBepolia' | 'binance' | 'bscTestnet' | 'campTestnet' | 'fantom' | 'fantomTestnet' | 'flowMainnet' | 'mainnet' | 'nexusTestnet' | 'optimism' | 'polygon' | 'polygon_mumbai' | 'skaleNebula' | 'skaleEuropa' | 'skaleCalypso' | 'solana' | 'sophon' | 'sophonTestnet' | 'sui' | 'superseed' | 'superseedSepolia' | 'vanar' | 'xai' | 'zksync' | 'coti' | 'cotiTestnet' | 'morph' | 'morphTestnet' | 'morphHolesky' | 'ultra' | 'ultraTestnet' | 'nitrograph' | 'sepolia' | 'optimism_sepolia' | 'arbitrumSepolia' | 'goerli' | 'optimism_goerli' | 'arbitrumGoerli' | 'basecamp' | 'somnia' | 'zkverify' | 'polkadot' | 'kusama' | 'flow_cadence';
2939
+ /**
2940
+ * Indicates if only in-range liquidity is rewarded.
2941
+ */
2942
+ onlyRewardInRangeLiquidity?: boolean;
2943
+ /**
2944
+ * Array of liquidity pools associated with the rule.
2945
+ */
2946
+ pools?: Array<Liquidity.Pool>;
2947
+ /**
2948
+ * Protocol of the liquidity pool.
2949
+ */
2950
+ protocol?: string;
2951
+ }
2952
+ namespace Liquidity {
2953
+ interface Pool {
2954
+ /**
2955
+ * Unique identifier of the liquidity pool.
2956
+ */
2957
+ id: string;
2958
+ }
2959
+ }
2960
+ interface Range {
2961
+ /**
2962
+ * Reward amount for this range.
2963
+ */
2964
+ amount: number;
2965
+ /**
2966
+ * End value of the range.
2967
+ */
2968
+ endRange: number;
2969
+ /**
2970
+ * Start value of the range.
2971
+ */
2972
+ startRange: number;
2973
+ /**
2974
+ * ID of the loyalty badge for this range.
2975
+ */
2976
+ loyaltyBadgeId?: string;
2977
+ /**
2978
+ * Amount of the loyalty multiplier for this range.
2979
+ */
2980
+ loyaltyMultiplierAmount?: number;
2981
+ }
2982
+ /**
2983
+ * Object defining referral requirements.
2984
+ */
2985
+ interface ReferralRequirements {
2986
+ /**
2987
+ * Flag indicating if achieving points is required.
2988
+ */
2989
+ achievePoints?: boolean | null;
2990
+ /**
2991
+ * Flag indicating if completing the profile is required.
2992
+ */
2993
+ completeProfile?: boolean | null;
2994
+ /**
2995
+ * Flag indicating if connecting Discord is required.
2996
+ */
2997
+ connectDiscord?: boolean | null;
2998
+ /**
2999
+ * Flag indicating if connecting email is required.
3000
+ */
3001
+ connectEmail?: boolean | null;
3002
+ /**
3003
+ * Flag indicating if connecting Twitter is required.
3004
+ */
3005
+ connectTwitter?: boolean | null;
3006
+ points?: ReferralRequirements.Points | null;
3007
+ }
3008
+ namespace ReferralRequirements {
3009
+ interface Points {
3010
+ /**
3011
+ * Points required for referral.
3012
+ */
3013
+ amount?: number | null;
3014
+ /**
3015
+ * ID of the loyalty currency for referral.
3016
+ */
3017
+ loyaltyCurrecyId?: string | null;
3018
+ }
3019
+ }
3020
+ /**
3021
+ * Object containing details of the associated smart contract.
3022
+ */
3023
+ interface SmartContract {
3024
+ /**
3025
+ * Mapping of addresses for the smart contract.
3026
+ */
3027
+ addressMapping?: string | null;
3028
+ /**
3029
+ * Object containing details of the amount multiplier from the event.
3030
+ */
3031
+ amountMultiplier?: SmartContract.AmountMultiplier | null;
3032
+ /**
3033
+ * ID of the smart contract.
3034
+ */
3035
+ contractId?: string | null;
3036
+ /**
3037
+ * Criteria to evaluate the smart contract event.
3038
+ */
3039
+ criteria?: 'everyEvent' | 'byParameter' | null;
3040
+ /**
3041
+ * Event emitted by the smart contract.
3042
+ */
3043
+ event?: string | null;
3044
+ /**
3045
+ * Array of parameters for the smart contract.
3046
+ */
3047
+ params?: Array<SmartContract.Param> | null;
3048
+ /**
3049
+ * Type of the smart contract interaction.
3050
+ */
3051
+ type?: 'function' | 'event' | null;
3052
+ }
3053
+ namespace SmartContract {
3054
+ /**
3055
+ * Object containing details of the amount multiplier from the event.
3056
+ */
3057
+ interface AmountMultiplier {
3058
+ /**
3059
+ * Mapping of the value for the smart contract.
3060
+ */
3061
+ valueMapping?: string | null;
3062
+ }
3063
+ interface Param {
3064
+ /**
3065
+ * Condition to check for the parameter.
3066
+ */
3067
+ condition?: string | null;
3068
+ /**
3069
+ * Name of the smart contract parameter.
3070
+ */
3071
+ name?: string | null;
3072
+ /**
3073
+ * Value of the parameter.
3074
+ */
3075
+ value?: string | null;
3076
+ }
3077
+ }
3078
+ interface SnapshotProposal {
3079
+ /**
3080
+ * ID of the snapshot proposal.
3081
+ */
3082
+ id: string;
3083
+ /**
3084
+ * Space associated with the snapshot proposal.
3085
+ */
3086
+ space: string;
3087
+ }
3088
+ interface StreakArray {
3089
+ /**
3090
+ * Reward amount for achieving the streak milestone.
3091
+ */
3092
+ streakAmount: number;
3093
+ /**
3094
+ * Milestone required to achieve the streak.
3095
+ */
3096
+ streakMilestone: number;
3097
+ }
3098
+ /**
3099
+ * Metadata for swap loyalty rules
3100
+ */
3101
+ interface Swap {
3102
+ from?: Swap.From;
3103
+ provider?: 'any' | 'relay' | 'lifi';
3104
+ relayReferrerId?: string;
3105
+ requireCrossChainSwap?: boolean;
3106
+ to?: Swap.To;
3107
+ }
3108
+ namespace Swap {
3109
+ interface From {
3110
+ chain?: 'any' | number | string;
3111
+ mode?: 'any' | 'specific';
3112
+ tokens?: Array<From.Token>;
3113
+ trackAmount?: boolean;
3114
+ }
3115
+ namespace From {
3116
+ interface Token {
3117
+ address: string;
3118
+ chainId: string;
3119
+ }
3120
+ }
3121
+ interface To {
3122
+ chain?: 'any' | number | string;
3123
+ mode?: 'any' | 'specific';
3124
+ tokens?: Array<To.Token>;
3125
+ trackAmount?: boolean;
3126
+ }
3127
+ namespace To {
3128
+ interface Token {
3129
+ address: string;
3130
+ chainId: string;
3131
+ }
3132
+ }
3133
+ }
3134
+ }
301
3135
  }
302
3136
  }
303
3137
  export interface RuleEditListParams {