@snagsolutions/sdk 0.1.0-alpha.15 → 0.1.0-alpha.150

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 (426) hide show
  1. package/CHANGELOG.md +1243 -45
  2. package/README.md +17 -29
  3. package/_shims/index.d.ts +2 -0
  4. package/_shims/index.js +5 -1
  5. package/_shims/index.mjs +5 -1
  6. package/core.d.ts +19 -5
  7. package/core.d.ts.map +1 -1
  8. package/core.js +26 -17
  9. package/core.js.map +1 -1
  10. package/core.mjs +27 -18
  11. package/core.mjs.map +1 -1
  12. package/index.d.mts +30 -6
  13. package/index.d.ts +30 -6
  14. package/index.d.ts.map +1 -1
  15. package/index.js +36 -11
  16. package/index.js.map +1 -1
  17. package/index.mjs +36 -11
  18. package/index.mjs.map +1 -1
  19. package/package.json +4 -5
  20. package/resource.d.ts +1 -1
  21. package/resource.d.ts.map +1 -1
  22. package/resource.js.map +1 -1
  23. package/resource.mjs.map +1 -1
  24. package/resources/assets.d.ts +64 -0
  25. package/resources/assets.d.ts.map +1 -0
  26. package/resources/assets.js +25 -0
  27. package/resources/assets.js.map +1 -0
  28. package/resources/assets.mjs +21 -0
  29. package/resources/assets.mjs.map +1 -0
  30. package/resources/auctions/auctions.d.ts +285 -0
  31. package/resources/auctions/auctions.d.ts.map +1 -0
  32. package/resources/auctions/auctions.js +76 -0
  33. package/resources/auctions/auctions.js.map +1 -0
  34. package/resources/auctions/auctions.mjs +49 -0
  35. package/resources/auctions/auctions.mjs.map +1 -0
  36. package/resources/auctions/index.d.ts +3 -0
  37. package/resources/auctions/index.d.ts.map +1 -0
  38. package/resources/auctions/index.js +9 -0
  39. package/resources/auctions/index.js.map +1 -0
  40. package/resources/auctions/index.mjs +4 -0
  41. package/resources/auctions/index.mjs.map +1 -0
  42. package/resources/auctions/website-user-attributes/index.d.ts +3 -0
  43. package/resources/auctions/website-user-attributes/index.d.ts.map +1 -0
  44. package/resources/auctions/website-user-attributes/index.js +9 -0
  45. package/resources/auctions/website-user-attributes/index.js.map +1 -0
  46. package/resources/auctions/website-user-attributes/index.mjs +4 -0
  47. package/resources/auctions/website-user-attributes/index.mjs.map +1 -0
  48. package/resources/auctions/website-user-attributes/values.d.ts +122 -0
  49. package/resources/auctions/website-user-attributes/values.d.ts.map +1 -0
  50. package/resources/auctions/website-user-attributes/values.js +49 -0
  51. package/resources/auctions/website-user-attributes/values.js.map +1 -0
  52. package/resources/auctions/website-user-attributes/values.mjs +45 -0
  53. package/resources/auctions/website-user-attributes/values.mjs.map +1 -0
  54. package/resources/auctions/website-user-attributes/website-user-attributes.d.ts +132 -0
  55. package/resources/auctions/website-user-attributes/website-user-attributes.d.ts.map +1 -0
  56. package/resources/auctions/website-user-attributes/website-user-attributes.js +76 -0
  57. package/resources/auctions/website-user-attributes/website-user-attributes.js.map +1 -0
  58. package/resources/auctions/website-user-attributes/website-user-attributes.mjs +49 -0
  59. package/resources/auctions/website-user-attributes/website-user-attributes.mjs.map +1 -0
  60. package/resources/auctions/website-user-attributes.d.ts +2 -0
  61. package/resources/auctions/website-user-attributes.d.ts.map +1 -0
  62. package/resources/auctions/website-user-attributes.js +19 -0
  63. package/resources/auctions/website-user-attributes.js.map +1 -0
  64. package/resources/auctions/website-user-attributes.mjs +3 -0
  65. package/resources/auctions/website-user-attributes.mjs.map +1 -0
  66. package/resources/auctions.d.ts +2 -0
  67. package/resources/auctions.d.ts.map +1 -0
  68. package/resources/{api.js → auctions.js} +2 -2
  69. package/resources/auctions.js.map +1 -0
  70. package/resources/{api.mjs → auctions.mjs} +2 -2
  71. package/resources/auctions.mjs.map +1 -0
  72. package/resources/auth.d.ts +48 -0
  73. package/resources/auth.d.ts.map +1 -0
  74. package/resources/auth.js +16 -0
  75. package/resources/auth.js.map +1 -0
  76. package/resources/auth.mjs +12 -0
  77. package/resources/auth.mjs.map +1 -0
  78. package/resources/index.d.ts +8 -1
  79. package/resources/index.d.ts.map +1 -1
  80. package/resources/index.js +17 -3
  81. package/resources/index.js.map +1 -1
  82. package/resources/index.mjs +8 -1
  83. package/resources/index.mjs.map +1 -1
  84. package/resources/loyalty/account-streaks.d.ts +81 -0
  85. package/resources/loyalty/account-streaks.d.ts.map +1 -0
  86. package/resources/loyalty/account-streaks.js +24 -0
  87. package/resources/loyalty/account-streaks.js.map +1 -0
  88. package/resources/loyalty/account-streaks.mjs +20 -0
  89. package/resources/loyalty/account-streaks.mjs.map +1 -0
  90. package/resources/{api/loyalty → loyalty}/accounts.d.ts +36 -27
  91. package/resources/loyalty/accounts.d.ts.map +1 -0
  92. package/resources/{api/loyalty → loyalty}/accounts.js +17 -4
  93. package/resources/loyalty/accounts.js.map +1 -0
  94. package/resources/loyalty/accounts.mjs +33 -0
  95. package/resources/loyalty/accounts.mjs.map +1 -0
  96. package/resources/{api/loyalty → loyalty}/badges.d.ts +474 -24
  97. package/resources/loyalty/badges.d.ts.map +1 -0
  98. package/resources/{api/loyalty → loyalty}/badges.js +21 -3
  99. package/resources/loyalty/badges.js.map +1 -0
  100. package/resources/{api/loyalty → loyalty}/badges.mjs +21 -3
  101. package/resources/loyalty/badges.mjs.map +1 -0
  102. package/resources/{api/loyalty → loyalty}/currencies.d.ts +27 -2
  103. package/resources/loyalty/currencies.d.ts.map +1 -0
  104. package/resources/loyalty/currencies.js +40 -0
  105. package/resources/loyalty/currencies.js.map +1 -0
  106. package/resources/loyalty/currencies.mjs +36 -0
  107. package/resources/loyalty/currencies.mjs.map +1 -0
  108. package/resources/{api/loyalty → loyalty}/index.d.ts +6 -3
  109. package/resources/loyalty/index.d.ts.map +1 -0
  110. package/resources/{api/loyalty → loyalty}/index.js +7 -1
  111. package/resources/loyalty/index.js.map +1 -0
  112. package/resources/{api/loyalty → loyalty}/index.mjs +4 -1
  113. package/resources/loyalty/index.mjs.map +1 -0
  114. package/resources/loyalty/loyalty.d.ts +50 -0
  115. package/resources/loyalty/loyalty.d.ts.map +1 -0
  116. package/resources/{api/loyalty → loyalty}/loyalty.js +13 -20
  117. package/resources/loyalty/loyalty.js.map +1 -0
  118. package/resources/{api/loyalty → loyalty}/loyalty.mjs +13 -20
  119. package/resources/loyalty/loyalty.mjs.map +1 -0
  120. package/resources/{api/loyalty → loyalty}/multipliers.d.ts +65 -4
  121. package/resources/loyalty/multipliers.d.ts.map +1 -0
  122. package/resources/{api/loyalty → loyalty}/multipliers.js +25 -2
  123. package/resources/loyalty/multipliers.js.map +1 -0
  124. package/resources/{api/loyalty → loyalty}/multipliers.mjs +25 -2
  125. package/resources/loyalty/multipliers.mjs.map +1 -0
  126. package/resources/{api/loyalty → loyalty}/questions-responses.d.ts +41 -2
  127. package/resources/loyalty/questions-responses.d.ts.map +1 -0
  128. package/resources/{api/loyalty → loyalty}/questions-responses.js +11 -2
  129. package/resources/loyalty/questions-responses.js.map +1 -0
  130. package/resources/{api/loyalty → loyalty}/questions-responses.mjs +11 -2
  131. package/resources/loyalty/questions-responses.mjs.map +1 -0
  132. package/resources/{api/loyalty → loyalty}/questions.d.ts +39 -4
  133. package/resources/loyalty/questions.d.ts.map +1 -0
  134. package/resources/loyalty/questions.js +58 -0
  135. package/resources/loyalty/questions.js.map +1 -0
  136. package/resources/loyalty/questions.mjs +54 -0
  137. package/resources/loyalty/questions.mjs.map +1 -0
  138. package/resources/loyalty/rule-edits.d.ts +2904 -0
  139. package/resources/loyalty/rule-edits.d.ts.map +1 -0
  140. package/resources/{api/loyalty → loyalty}/rule-edits.js +15 -1
  141. package/resources/loyalty/rule-edits.js.map +1 -0
  142. package/resources/{api/loyalty → loyalty}/rule-edits.mjs +15 -1
  143. package/resources/loyalty/rule-edits.mjs.map +1 -0
  144. package/resources/{api/loyalty/loyalty.d.ts → loyalty/rule-groups.d.ts} +275 -320
  145. package/resources/loyalty/rule-groups.d.ts.map +1 -0
  146. package/resources/loyalty/rule-groups.js +52 -0
  147. package/resources/loyalty/rule-groups.js.map +1 -0
  148. package/resources/loyalty/rule-groups.mjs +48 -0
  149. package/resources/loyalty/rule-groups.mjs.map +1 -0
  150. package/resources/{api/loyalty → loyalty}/rules.d.ts +1743 -224
  151. package/resources/loyalty/rules.d.ts.map +1 -0
  152. package/resources/loyalty/rules.js +77 -0
  153. package/resources/loyalty/rules.js.map +1 -0
  154. package/resources/loyalty/rules.mjs +73 -0
  155. package/resources/loyalty/rules.mjs.map +1 -0
  156. package/resources/loyalty/transactions/index.d.ts +3 -0
  157. package/resources/loyalty/transactions/index.d.ts.map +1 -0
  158. package/resources/loyalty/transactions/index.js +9 -0
  159. package/resources/loyalty/transactions/index.js.map +1 -0
  160. package/resources/loyalty/transactions/index.mjs +4 -0
  161. package/resources/loyalty/transactions/index.mjs.map +1 -0
  162. package/resources/loyalty/transactions/rule-statuses.d.ts +120 -0
  163. package/resources/loyalty/transactions/rule-statuses.d.ts.map +1 -0
  164. package/resources/loyalty/transactions/rule-statuses.js +30 -0
  165. package/resources/loyalty/transactions/rule-statuses.js.map +1 -0
  166. package/resources/loyalty/transactions/rule-statuses.mjs +26 -0
  167. package/resources/loyalty/transactions/rule-statuses.mjs.map +1 -0
  168. package/resources/loyalty/transactions/transactions.d.ts +410 -0
  169. package/resources/loyalty/transactions/transactions.d.ts.map +1 -0
  170. package/resources/loyalty/transactions/transactions.js +76 -0
  171. package/resources/loyalty/transactions/transactions.js.map +1 -0
  172. package/resources/loyalty/transactions/transactions.mjs +49 -0
  173. package/resources/loyalty/transactions/transactions.mjs.map +1 -0
  174. package/resources/loyalty/transactions.d.ts +2 -0
  175. package/resources/loyalty/transactions.d.ts.map +1 -0
  176. package/resources/loyalty/transactions.js +19 -0
  177. package/resources/loyalty/transactions.js.map +1 -0
  178. package/resources/loyalty/transactions.mjs +3 -0
  179. package/resources/loyalty/transactions.mjs.map +1 -0
  180. package/resources/loyalty.d.ts.map +1 -0
  181. package/resources/loyalty.js.map +1 -0
  182. package/resources/loyalty.mjs.map +1 -0
  183. package/resources/{api/minting.d.ts → minting.d.ts} +7 -7
  184. package/resources/minting.d.ts.map +1 -0
  185. package/resources/{api/minting.js → minting.js} +1 -1
  186. package/resources/minting.js.map +1 -0
  187. package/resources/{api/minting.mjs → minting.mjs} +1 -1
  188. package/resources/minting.mjs.map +1 -0
  189. package/resources/referral/index.d.ts.map +1 -0
  190. package/resources/referral/index.js.map +1 -0
  191. package/resources/referral/index.mjs.map +1 -0
  192. package/resources/{api/referral → referral}/referral.d.ts +13 -5
  193. package/resources/referral/referral.d.ts.map +1 -0
  194. package/resources/{api/referral → referral}/referral.js +12 -6
  195. package/resources/referral/referral.js.map +1 -0
  196. package/resources/{api/referral → referral}/referral.mjs +12 -6
  197. package/resources/referral/referral.mjs.map +1 -0
  198. package/resources/{api/referral → referral}/users.d.ts +30 -3
  199. package/resources/referral/users.d.ts.map +1 -0
  200. package/resources/{api/referral → referral}/users.js +15 -1
  201. package/resources/referral/users.js.map +1 -0
  202. package/resources/{api/referral → referral}/users.mjs +15 -1
  203. package/resources/referral/users.mjs.map +1 -0
  204. package/resources/referral.d.ts.map +1 -0
  205. package/resources/referral.js.map +1 -0
  206. package/resources/referral.mjs.map +1 -0
  207. package/resources/users/index.d.ts +3 -0
  208. package/resources/users/index.d.ts.map +1 -0
  209. package/resources/users/index.js.map +1 -0
  210. package/resources/users/index.mjs.map +1 -0
  211. package/resources/{api/users → users}/metadatas.d.ts +34 -2
  212. package/resources/users/metadatas.d.ts.map +1 -0
  213. package/resources/{api/users → users}/metadatas.js +2 -2
  214. package/resources/users/metadatas.js.map +1 -0
  215. package/resources/{api/users → users}/metadatas.mjs +2 -2
  216. package/resources/users/metadatas.mjs.map +1 -0
  217. package/resources/users/users.d.ts +422 -0
  218. package/resources/users/users.d.ts.map +1 -0
  219. package/resources/{api/users → users}/users.js +61 -2
  220. package/resources/users/users.js.map +1 -0
  221. package/resources/users/users.mjs +89 -0
  222. package/resources/users/users.mjs.map +1 -0
  223. package/resources/users.d.ts.map +1 -0
  224. package/resources/users.js.map +1 -0
  225. package/resources/users.mjs.map +1 -0
  226. package/resources/websites/index.d.ts +4 -0
  227. package/resources/websites/index.d.ts.map +1 -0
  228. package/resources/websites/index.js +11 -0
  229. package/resources/websites/index.js.map +1 -0
  230. package/resources/{api → websites}/index.mjs +0 -5
  231. package/resources/websites/index.mjs.map +1 -0
  232. package/resources/{api → websites}/website-collections.d.ts +22 -1
  233. package/resources/websites/website-collections.d.ts.map +1 -0
  234. package/resources/{api → websites}/website-collections.js +21 -0
  235. package/resources/websites/website-collections.js.map +1 -0
  236. package/resources/websites/website-collections.mjs +42 -0
  237. package/resources/websites/website-collections.mjs.map +1 -0
  238. package/resources/{api → websites}/website-user-roles.d.ts +23 -0
  239. package/resources/websites/website-user-roles.d.ts.map +1 -0
  240. package/resources/{api → websites}/website-user-roles.js +23 -0
  241. package/resources/websites/website-user-roles.js.map +1 -0
  242. package/resources/websites/website-user-roles.mjs +41 -0
  243. package/resources/websites/website-user-roles.mjs.map +1 -0
  244. package/resources/{api → websites}/websites.d.ts +20 -0
  245. package/resources/websites/websites.d.ts.map +1 -0
  246. package/resources/websites/websites.js +63 -0
  247. package/resources/websites/websites.js.map +1 -0
  248. package/resources/websites/websites.mjs +36 -0
  249. package/resources/websites/websites.mjs.map +1 -0
  250. package/resources/websites.d.ts +2 -0
  251. package/resources/websites.d.ts.map +1 -0
  252. package/resources/websites.js +19 -0
  253. package/resources/websites.js.map +1 -0
  254. package/resources/websites.mjs +3 -0
  255. package/resources/websites.mjs.map +1 -0
  256. package/src/_shims/index.d.ts +2 -0
  257. package/src/_shims/index.js +5 -1
  258. package/src/_shims/index.mjs +5 -1
  259. package/src/core.ts +45 -17
  260. package/src/index.ts +126 -24
  261. package/src/resource.ts +1 -1
  262. package/src/resources/assets.ts +93 -0
  263. package/src/resources/auctions/auctions.ts +436 -0
  264. package/src/resources/auctions/index.ts +18 -0
  265. package/src/resources/auctions/website-user-attributes/index.ts +18 -0
  266. package/src/resources/auctions/website-user-attributes/values.ts +165 -0
  267. package/src/resources/auctions/website-user-attributes/website-user-attributes.ts +207 -0
  268. package/src/resources/auctions/website-user-attributes.ts +3 -0
  269. package/src/resources/{api.ts → auctions.ts} +1 -1
  270. package/src/resources/auth.ts +79 -0
  271. package/src/resources/index.ts +37 -8
  272. package/src/resources/loyalty/account-streaks.ts +110 -0
  273. package/src/resources/{api/loyalty → loyalty}/accounts.ts +41 -35
  274. package/src/resources/{api/loyalty → loyalty}/badges.ts +570 -27
  275. package/src/resources/{api/loyalty → loyalty}/currencies.ts +27 -2
  276. package/src/resources/{api/loyalty → loyalty}/index.ts +28 -11
  277. package/src/resources/loyalty/loyalty.ts +259 -0
  278. package/src/resources/{api/loyalty → loyalty}/multipliers.ts +70 -7
  279. package/src/resources/{api/loyalty → loyalty}/questions-responses.ts +48 -3
  280. package/src/resources/{api/loyalty → loyalty}/questions.ts +40 -4
  281. package/src/resources/loyalty/rule-edits.ts +3988 -0
  282. package/src/resources/{api/loyalty/loyalty.ts → loyalty/rule-groups.ts} +437 -550
  283. package/src/resources/{api/loyalty → loyalty}/rules.ts +2906 -530
  284. package/src/resources/loyalty/transactions/index.ts +18 -0
  285. package/src/resources/loyalty/transactions/rule-statuses.ts +178 -0
  286. package/src/resources/loyalty/transactions/transactions.ts +677 -0
  287. package/src/resources/loyalty/transactions.ts +3 -0
  288. package/src/resources/{api/minting.ts → minting.ts} +37 -23
  289. package/src/resources/{api/referral → referral}/referral.ts +15 -13
  290. package/src/resources/{api/referral → referral}/users.ts +35 -4
  291. package/src/resources/{api/users → users}/index.ts +6 -0
  292. package/src/resources/{api/users → users}/metadatas.ts +62 -3
  293. package/src/resources/users/users.ts +603 -0
  294. package/src/resources/websites/index.ts +22 -0
  295. package/src/resources/{api → websites}/website-collections.ts +52 -17
  296. package/src/resources/{api → websites}/website-user-roles.ts +23 -0
  297. package/src/resources/{api → websites}/websites.ts +52 -0
  298. package/src/resources/websites.ts +3 -0
  299. package/src/version.ts +1 -1
  300. package/version.d.ts +1 -1
  301. package/version.d.ts.map +1 -1
  302. package/version.js +1 -1
  303. package/version.js.map +1 -1
  304. package/version.mjs +1 -1
  305. package/version.mjs.map +1 -1
  306. package/resources/api/api.d.ts +0 -365
  307. package/resources/api/api.d.ts.map +0 -1
  308. package/resources/api/api.js +0 -94
  309. package/resources/api/api.js.map +0 -1
  310. package/resources/api/api.mjs +0 -67
  311. package/resources/api/api.mjs.map +0 -1
  312. package/resources/api/index.d.ts +0 -9
  313. package/resources/api/index.d.ts.map +0 -1
  314. package/resources/api/index.js +0 -21
  315. package/resources/api/index.js.map +0 -1
  316. package/resources/api/index.mjs.map +0 -1
  317. package/resources/api/loyalty/accounts.d.ts.map +0 -1
  318. package/resources/api/loyalty/accounts.js.map +0 -1
  319. package/resources/api/loyalty/accounts.mjs +0 -20
  320. package/resources/api/loyalty/accounts.mjs.map +0 -1
  321. package/resources/api/loyalty/badges.d.ts.map +0 -1
  322. package/resources/api/loyalty/badges.js.map +0 -1
  323. package/resources/api/loyalty/badges.mjs.map +0 -1
  324. package/resources/api/loyalty/currencies.d.ts.map +0 -1
  325. package/resources/api/loyalty/currencies.js +0 -21
  326. package/resources/api/loyalty/currencies.js.map +0 -1
  327. package/resources/api/loyalty/currencies.mjs +0 -17
  328. package/resources/api/loyalty/currencies.mjs.map +0 -1
  329. package/resources/api/loyalty/index.d.ts.map +0 -1
  330. package/resources/api/loyalty/index.js.map +0 -1
  331. package/resources/api/loyalty/index.mjs.map +0 -1
  332. package/resources/api/loyalty/loyalty.d.ts.map +0 -1
  333. package/resources/api/loyalty/loyalty.js.map +0 -1
  334. package/resources/api/loyalty/loyalty.mjs.map +0 -1
  335. package/resources/api/loyalty/multipliers.d.ts.map +0 -1
  336. package/resources/api/loyalty/multipliers.js.map +0 -1
  337. package/resources/api/loyalty/multipliers.mjs.map +0 -1
  338. package/resources/api/loyalty/questions-responses.d.ts.map +0 -1
  339. package/resources/api/loyalty/questions-responses.js.map +0 -1
  340. package/resources/api/loyalty/questions-responses.mjs.map +0 -1
  341. package/resources/api/loyalty/questions.d.ts.map +0 -1
  342. package/resources/api/loyalty/questions.js +0 -27
  343. package/resources/api/loyalty/questions.js.map +0 -1
  344. package/resources/api/loyalty/questions.mjs +0 -23
  345. package/resources/api/loyalty/questions.mjs.map +0 -1
  346. package/resources/api/loyalty/rule-edits.d.ts +0 -330
  347. package/resources/api/loyalty/rule-edits.d.ts.map +0 -1
  348. package/resources/api/loyalty/rule-edits.js.map +0 -1
  349. package/resources/api/loyalty/rule-edits.mjs.map +0 -1
  350. package/resources/api/loyalty/rules.d.ts.map +0 -1
  351. package/resources/api/loyalty/rules.js +0 -46
  352. package/resources/api/loyalty/rules.js.map +0 -1
  353. package/resources/api/loyalty/rules.mjs +0 -42
  354. package/resources/api/loyalty/rules.mjs.map +0 -1
  355. package/resources/api/loyalty.d.ts.map +0 -1
  356. package/resources/api/loyalty.js.map +0 -1
  357. package/resources/api/loyalty.mjs.map +0 -1
  358. package/resources/api/minting.d.ts.map +0 -1
  359. package/resources/api/minting.js.map +0 -1
  360. package/resources/api/minting.mjs.map +0 -1
  361. package/resources/api/referral/index.d.ts.map +0 -1
  362. package/resources/api/referral/index.js.map +0 -1
  363. package/resources/api/referral/index.mjs.map +0 -1
  364. package/resources/api/referral/referral.d.ts.map +0 -1
  365. package/resources/api/referral/referral.js.map +0 -1
  366. package/resources/api/referral/referral.mjs.map +0 -1
  367. package/resources/api/referral/users.d.ts.map +0 -1
  368. package/resources/api/referral/users.js.map +0 -1
  369. package/resources/api/referral/users.mjs.map +0 -1
  370. package/resources/api/referral.d.ts.map +0 -1
  371. package/resources/api/referral.js.map +0 -1
  372. package/resources/api/referral.mjs.map +0 -1
  373. package/resources/api/users/index.d.ts +0 -3
  374. package/resources/api/users/index.d.ts.map +0 -1
  375. package/resources/api/users/index.js.map +0 -1
  376. package/resources/api/users/index.mjs.map +0 -1
  377. package/resources/api/users/metadatas.d.ts.map +0 -1
  378. package/resources/api/users/metadatas.js.map +0 -1
  379. package/resources/api/users/metadatas.mjs.map +0 -1
  380. package/resources/api/users/users.d.ts +0 -133
  381. package/resources/api/users/users.d.ts.map +0 -1
  382. package/resources/api/users/users.js.map +0 -1
  383. package/resources/api/users/users.mjs +0 -30
  384. package/resources/api/users/users.mjs.map +0 -1
  385. package/resources/api/users.d.ts.map +0 -1
  386. package/resources/api/users.js.map +0 -1
  387. package/resources/api/users.mjs.map +0 -1
  388. package/resources/api/website-collections.d.ts.map +0 -1
  389. package/resources/api/website-collections.js.map +0 -1
  390. package/resources/api/website-collections.mjs +0 -21
  391. package/resources/api/website-collections.mjs.map +0 -1
  392. package/resources/api/website-user-roles.d.ts.map +0 -1
  393. package/resources/api/website-user-roles.js.map +0 -1
  394. package/resources/api/website-user-roles.mjs +0 -18
  395. package/resources/api/website-user-roles.mjs.map +0 -1
  396. package/resources/api/websites.d.ts.map +0 -1
  397. package/resources/api/websites.js +0 -22
  398. package/resources/api/websites.js.map +0 -1
  399. package/resources/api/websites.mjs +0 -18
  400. package/resources/api/websites.mjs.map +0 -1
  401. package/resources/api.d.ts +0 -2
  402. package/resources/api.d.ts.map +0 -1
  403. package/resources/api.js.map +0 -1
  404. package/resources/api.mjs.map +0 -1
  405. package/src/resources/api/api.ts +0 -629
  406. package/src/resources/api/index.ts +0 -51
  407. package/src/resources/api/loyalty/rule-edits.ts +0 -418
  408. package/src/resources/api/users/users.ts +0 -203
  409. /package/resources/{api/loyalty.d.ts → loyalty.d.ts} +0 -0
  410. /package/resources/{api/loyalty.js → loyalty.js} +0 -0
  411. /package/resources/{api/loyalty.mjs → loyalty.mjs} +0 -0
  412. /package/resources/{api/referral → referral}/index.d.ts +0 -0
  413. /package/resources/{api/referral → referral}/index.js +0 -0
  414. /package/resources/{api/referral → referral}/index.mjs +0 -0
  415. /package/resources/{api/referral.d.ts → referral.d.ts} +0 -0
  416. /package/resources/{api/referral.js → referral.js} +0 -0
  417. /package/resources/{api/referral.mjs → referral.mjs} +0 -0
  418. /package/resources/{api/users → users}/index.js +0 -0
  419. /package/resources/{api/users → users}/index.mjs +0 -0
  420. /package/resources/{api/users.d.ts → users.d.ts} +0 -0
  421. /package/resources/{api/users.js → users.js} +0 -0
  422. /package/resources/{api/users.mjs → users.mjs} +0 -0
  423. /package/src/resources/{api/loyalty.ts → loyalty.ts} +0 -0
  424. /package/src/resources/{api/referral → referral}/index.ts +0 -0
  425. /package/src/resources/{api/referral.ts → referral.ts} +0 -0
  426. /package/src/resources/{api/users.ts → users.ts} +0 -0
@@ -0,0 +1,3988 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../../resource';
4
+ import * as Core from '../../core';
5
+
6
+ export class RuleEdits extends APIResource {
7
+ /**
8
+ * Retrieve configured loyalty rule edits with optional pagination and filters
9
+ *
10
+ * @example
11
+ * ```ts
12
+ * const ruleEdits = await client.loyalty.ruleEdits.list({
13
+ * loyaltyRuleId: true,
14
+ * });
15
+ * ```
16
+ */
17
+ list(query: RuleEditListParams, options?: Core.RequestOptions): Core.APIPromise<RuleEditListResponse> {
18
+ return this._client.get('/api/loyalty/rule_edits', { query, ...options });
19
+ }
20
+
21
+ /**
22
+ * Restore a loyalty rule from a rule edit
23
+ *
24
+ * @example
25
+ * ```ts
26
+ * const response = await client.loyalty.ruleEdits.restore(
27
+ * '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
28
+ * );
29
+ * ```
30
+ */
31
+ restore(
32
+ id: string,
33
+ body?: RuleEditRestoreParams | null | undefined,
34
+ options?: Core.RequestOptions,
35
+ ): Core.APIPromise<RuleEditRestoreResponse> {
36
+ return this._client.post(`/api/loyalty/rule_edits/${id}/restore`, { body, ...options });
37
+ }
38
+ }
39
+
40
+ export interface RuleEditListResponse {
41
+ data: Array<RuleEditListResponse.Data>;
42
+
43
+ hasNextPage: boolean;
44
+ }
45
+
46
+ export namespace RuleEditListResponse {
47
+ export interface Data {
48
+ /**
49
+ * Unique identifier for the rule edit
50
+ */
51
+ id: string;
52
+
53
+ /**
54
+ * Type of action that was made on the rule
55
+ */
56
+ action: 'create' | 'update' | 'delete' | 'restore';
57
+
58
+ /**
59
+ * Data that was changed on the rule
60
+ */
61
+ data: Data.Data;
62
+
63
+ /**
64
+ * Timestamp of when the rule edit was made
65
+ */
66
+ editedAt: string;
67
+
68
+ /**
69
+ * User ID of the user who made the edit
70
+ */
71
+ editedByUserId: string;
72
+
73
+ /**
74
+ * ID of the loyalty rule
75
+ */
76
+ loyaltyRuleId: string;
77
+
78
+ /**
79
+ * Unique identifier for the organization
80
+ */
81
+ organizationId: string;
82
+
83
+ /**
84
+ * Unique identifier for the website
85
+ */
86
+ websiteId: string;
87
+
88
+ /**
89
+ * Comment that was made on the edit
90
+ */
91
+ comment?: string;
92
+
93
+ /**
94
+ * Previous data of the rule before the edit
95
+ */
96
+ previousData?: Data.PreviousData;
97
+ }
98
+
99
+ export namespace Data {
100
+ /**
101
+ * Data that was changed on the rule
102
+ */
103
+ export interface Data {
104
+ /**
105
+ * Unique identifier for the loyalty rule
106
+ */
107
+ id: string;
108
+
109
+ /**
110
+ * Amount associated with the loyalty rule
111
+ */
112
+ amount: number;
113
+
114
+ /**
115
+ * Timestamp when the loyalty rule was created
116
+ */
117
+ createdAt: string;
118
+
119
+ /**
120
+ * Timestamp when the loyalty rule was deleted (if applicable)
121
+ */
122
+ deletedAt: string | null;
123
+
124
+ /**
125
+ * Description of the loyalty rule
126
+ */
127
+ description: string;
128
+
129
+ /**
130
+ * End time of the loyalty rule
131
+ */
132
+ endTime: string;
133
+
134
+ /**
135
+ * Frequency of the loyalty rule
136
+ */
137
+ frequency: string;
138
+
139
+ /**
140
+ * Name of the loyalty rule
141
+ */
142
+ name: string;
143
+
144
+ /**
145
+ * Unique identifier for the organization
146
+ */
147
+ organizationId: string;
148
+
149
+ /**
150
+ * Type of the reward
151
+ */
152
+ rewardType: 'points' | 'multiplier' | 'badge';
153
+
154
+ /**
155
+ * Start time of the loyalty rule
156
+ */
157
+ startTime: string;
158
+
159
+ /**
160
+ * Type of the loyalty rule
161
+ */
162
+ type: string;
163
+
164
+ /**
165
+ * Timestamp when the loyalty rule was last updated
166
+ */
167
+ updatedAt: string;
168
+
169
+ /**
170
+ * Unique identifier for the website
171
+ */
172
+ websiteId: string;
173
+
174
+ /**
175
+ * Optional address of the collection
176
+ */
177
+ collectionAddress?: string;
178
+
179
+ /**
180
+ * URL of the media associated with the loyalty rule
181
+ */
182
+ mediaUrl?: string | null;
183
+
184
+ /**
185
+ * Optional metadata for the loyalty rule
186
+ */
187
+ metadata?: { [key: string]: Data.Metadata };
188
+ }
189
+
190
+ export namespace Data {
191
+ export interface Metadata {
192
+ /**
193
+ * Number of tokens per batch.
194
+ */
195
+ batchSize?: number | null;
196
+
197
+ /**
198
+ * Text displayed on the action button.
199
+ */
200
+ buttonText?: string | null;
201
+
202
+ /**
203
+ * Flag indicating if commenting is required.
204
+ */
205
+ checkComment?: boolean | null;
206
+
207
+ /**
208
+ * Flag indicating if liking the post is required.
209
+ */
210
+ checkLike?: boolean | null;
211
+
212
+ /**
213
+ * Flag indicating if reposting is required.
214
+ */
215
+ checkRepost?: boolean | null;
216
+
217
+ /**
218
+ * Text to check in the Twitter post, username, or bio.
219
+ */
220
+ checkText?: string | null;
221
+
222
+ /**
223
+ * Array of collections associated with the rule.
224
+ */
225
+ collection?: Array<Metadata.Collection>;
226
+
227
+ /**
228
+ * Conditions for completing the profile.
229
+ */
230
+ completeProfileConditions?: { [key: string]: boolean } | null;
231
+
232
+ /**
233
+ * Description of the external rule condition (only for external rules)
234
+ */
235
+ conditionDescription?: string;
236
+
237
+ /**
238
+ * Object containing details for the call-to-action.
239
+ */
240
+ cta?: Metadata.Cta | null;
241
+
242
+ /**
243
+ * API key for custom rewards integration.
244
+ */
245
+ customRewardsApiKey?: string;
246
+
247
+ /**
248
+ * Flag indicating if the rule should use direct RPC to get the balance of tokens.
249
+ */
250
+ directRpc?: boolean;
251
+
252
+ /**
253
+ * Array of Discord servers, channels, and roles to join.
254
+ */
255
+ discordServersToJoin?: Array<Metadata.DiscordServersToJoin> | null;
256
+
257
+ /**
258
+ * Array of drip quests required to complete the rule.
259
+ */
260
+ dripQuestsToComplete?: Array<Metadata.DripQuestsToComplete> | null;
261
+
262
+ /**
263
+ * Flag indicating whether joining Discord servers is required.
264
+ */
265
+ enableJoinDiscordServers?: boolean | null;
266
+
267
+ /**
268
+ * Flag indicating whether streaks are enabled.
269
+ */
270
+ enableStreaks?: boolean | null;
271
+
272
+ /**
273
+ * Flag indicating whether the verified multiplier is enabled.
274
+ */
275
+ enableVerifiedMultiplier?: boolean;
276
+
277
+ /**
278
+ * Fill source of the order for the token sale
279
+ */
280
+ fillSource?: string;
281
+
282
+ /**
283
+ * Percentage reward given to a user for their first referral.
284
+ */
285
+ firstReferralReward?: number | null;
286
+
287
+ /**
288
+ * Flag indicating whether the fill source is included.
289
+ */
290
+ hasFillSource?: boolean;
291
+
292
+ /**
293
+ * Indicates if the item has never been sold.
294
+ */
295
+ hasNeverSold?: boolean;
296
+
297
+ /**
298
+ * Indicates if the full royalty has been paid for items.
299
+ */
300
+ hasPaidFullRoyalty?: boolean;
301
+
302
+ /**
303
+ * Flag indicating if the sale currency is included.
304
+ */
305
+ hasSaleCurrency?: boolean;
306
+
307
+ /**
308
+ * Indicates if the user has a verified Twitter account.
309
+ */
310
+ hasVerifiedTwitter?: boolean;
311
+
312
+ /**
313
+ * URL of the image associated with the rule.
314
+ */
315
+ imageUrl?: string | null;
316
+
317
+ /**
318
+ * If enabled, the first transaction done on the platform will complete this rule
319
+ */
320
+ isCheckInOnEveryTxn?: boolean;
321
+
322
+ /**
323
+ * Indicates if the multiplier has been applied to rewards.
324
+ */
325
+ isMultiplierApplied?: boolean;
326
+
327
+ /**
328
+ * Flag indicating if the rule is restricted to new users.
329
+ */
330
+ isRestrictedToNewUsers?: boolean;
331
+
332
+ /**
333
+ * Flag indicating if rewards are applied retroactively.
334
+ */
335
+ isRetroactive?: boolean | null;
336
+
337
+ /**
338
+ * Flag indicating if the token hold multiplier is applied.
339
+ */
340
+ isTokenHoldMultiplier?: boolean;
341
+
342
+ /**
343
+ * Optional link associated with the metadata.
344
+ */
345
+ link?: string | null;
346
+
347
+ /**
348
+ * Liquidity pool details.
349
+ */
350
+ liquidity?: Metadata.Liquidity;
351
+
352
+ /**
353
+ * Maximum quantity constraint for token holding.
354
+ */
355
+ maxQty?: number | null;
356
+
357
+ /**
358
+ * Minimum quantity constraint for token holding.
359
+ */
360
+ minQty?: number | null;
361
+
362
+ /**
363
+ * Array of loyalty currency IDs used for multipliers.
364
+ */
365
+ multiplierLoyaltyCurrencyIds?: Array<string> | null;
366
+
367
+ /**
368
+ * Flag indicating whether to include only known users.
369
+ */
370
+ onlyKnownUsers?: boolean;
371
+
372
+ /**
373
+ * Flag indicating whether to include only native tokens.
374
+ */
375
+ onlyNative?: boolean;
376
+
377
+ /**
378
+ * Flag indicating whether to include only non-listed items.
379
+ */
380
+ onlyNonListed?: boolean;
381
+
382
+ /**
383
+ * Indicates if only existing users are rewarded.
384
+ */
385
+ onlyRewardExistingUser?: boolean;
386
+
387
+ /**
388
+ * give points for only one token ownership per contract
389
+ */
390
+ onlyRewardSingleTokenOwnership?: boolean | null;
391
+
392
+ /**
393
+ * Promotional code associated with the rule.
394
+ */
395
+ promoCode?: string;
396
+
397
+ /**
398
+ * URL of the CSV file containing promo codes.
399
+ */
400
+ promoCodeCsvUrl?: string;
401
+
402
+ /**
403
+ * Numbers of the promotional code to be generated.
404
+ */
405
+ promoCodeLength?: number | null;
406
+
407
+ /**
408
+ * Type of the promotional code.
409
+ */
410
+ promoCodeType?: 'code' | 'csv' | 'generate';
411
+
412
+ /**
413
+ * Array defining ranges and corresponding rewards.
414
+ */
415
+ range?: Array<Metadata.Range>;
416
+
417
+ /**
418
+ * Object defining referral requirements.
419
+ */
420
+ referralRequirements?: Metadata.ReferralRequirements | null;
421
+
422
+ /**
423
+ * Lump sum reward given to a referrer.
424
+ */
425
+ referrerReward?: number | null;
426
+
427
+ /**
428
+ * Loyalty currency ID of the referrer reward.
429
+ */
430
+ referrerRewardLoyaltyCurrencyId?: string | null;
431
+
432
+ /**
433
+ * Flag indicating if the post link is required.
434
+ */
435
+ requirePostLink?: boolean | null;
436
+
437
+ /**
438
+ * Flag indicating if the rule can also reward badges per range.
439
+ */
440
+ rewardBadgePerRange?: boolean;
441
+
442
+ /**
443
+ * Flag indicating if the reward is rewarded by batch.
444
+ */
445
+ rewardByBatch?: boolean | null;
446
+
447
+ /**
448
+ * Flag indicating if the reward is rewarded per action.
449
+ */
450
+ rewardPerAction?: boolean | null;
451
+
452
+ /**
453
+ * Flag indicating if rewards are given per impression.
454
+ */
455
+ rewardPerImpression?: boolean | null;
456
+
457
+ /**
458
+ * Flag indicating if the rule should reward based on value of traded tokens
459
+ * instead of count.
460
+ */
461
+ rewardPerValue?: boolean;
462
+
463
+ /**
464
+ * Wallet address of the user can only be used if userId is not provided
465
+ */
466
+ royaltyAddress?: string;
467
+
468
+ /**
469
+ * Royalty percentage of the item.
470
+ */
471
+ royaltyPercentage?: number;
472
+
473
+ /**
474
+ * Currency associated with sales.
475
+ */
476
+ saleCurrency?: string;
477
+
478
+ /**
479
+ * Percentage reward given for a second-level referral.
480
+ */
481
+ secondReferralReward?: number | null;
482
+
483
+ /**
484
+ * Flag indicating if the multiplier is skipped.
485
+ */
486
+ skipMultiplier?: boolean | null;
487
+
488
+ /**
489
+ * Object containing details of the associated smart contract.
490
+ */
491
+ smartContract?: Metadata.SmartContract;
492
+
493
+ /**
494
+ * Array of snapshot proposals for the rule.
495
+ */
496
+ snapshotProposals?: Array<Metadata.SnapshotProposal> | null;
497
+
498
+ /**
499
+ * Social media platform associated with the rule.
500
+ */
501
+ socialPlatform?:
502
+ | 'Custom'
503
+ | 'Discord'
504
+ | 'EpicGames'
505
+ | 'Instagram'
506
+ | 'Steam'
507
+ | 'Telegram'
508
+ | 'TikTok'
509
+ | 'Twitch'
510
+ | 'X(Twitter)'
511
+ | 'YouTube'
512
+ | 'Google'
513
+ | null;
514
+
515
+ /**
516
+ * URL of the social platform's logo.
517
+ */
518
+ socialPlatformLogo?: string | null;
519
+
520
+ /**
521
+ * Name of the social platform.
522
+ */
523
+ socialPlatformName?: string | null;
524
+
525
+ /**
526
+ * ID of the Steam app.
527
+ */
528
+ steamAppId?: string | null;
529
+
530
+ /**
531
+ * Array of streak milestones and corresponding rewards.
532
+ */
533
+ streakArray?: Array<Metadata.StreakArray> | null;
534
+
535
+ /**
536
+ * Metadata for swap loyalty rules
537
+ */
538
+ swap?: Metadata.Swap;
539
+
540
+ /**
541
+ * ID of the Telegram channel.
542
+ */
543
+ telegramChannelId?: string | null;
544
+
545
+ /**
546
+ * Time delay in seconds to verify actions.
547
+ */
548
+ timeDelayToVerifySeconds?: string | number | null;
549
+
550
+ /**
551
+ * Flag indicating if all contracts are tracked.
552
+ */
553
+ trackAllContracts?: boolean | null;
554
+
555
+ /**
556
+ * Flag indicating if the progress is tracked. If enabled, the rule can only be
557
+ * completed once the progress is 100%.
558
+ */
559
+ trackProgress?: boolean | null;
560
+
561
+ /**
562
+ * URL of the associated Twitter account.
563
+ */
564
+ twitterAccountUrl?: string;
565
+
566
+ /**
567
+ * Hashtag associated with the Twitter post.
568
+ */
569
+ twitterHashtag?: string;
570
+
571
+ /**
572
+ * URL of the associated Twitter post.
573
+ */
574
+ twitterPostUrl?: string;
575
+
576
+ /**
577
+ * Unique identifier of the Twitter user.
578
+ */
579
+ twitterUserId?: string;
580
+
581
+ /**
582
+ * Twitter username of the user.
583
+ */
584
+ twitterUsername?: string;
585
+
586
+ /**
587
+ * Minimum length of the verification text.
588
+ */
589
+ verificationTextMinimumLength?: number | null;
590
+
591
+ /**
592
+ * Multiplier applied to rewards for verified users.
593
+ */
594
+ verifiedMultiplier?: number | null;
595
+
596
+ /**
597
+ * Placeholder text for verification input fields.
598
+ */
599
+ verifyPlaceHolderText?: string | null;
600
+
601
+ /**
602
+ * Type of wallet associated with the rule.
603
+ */
604
+ walletType?: 'evm' | 'solana' | 'imx' | 'sui' | 'ton' | 'cosmos' | 'ultra' | 'agw' | null;
605
+
606
+ /**
607
+ * ID of the Youtube channel.
608
+ */
609
+ youtubeChannelId?: string | null;
610
+
611
+ /**
612
+ * ID of the Youtube video.
613
+ */
614
+ youtubeVideoId?: string | null;
615
+ }
616
+
617
+ export namespace Metadata {
618
+ export interface Collection {
619
+ /**
620
+ * Blockchain address of the collection.
621
+ */
622
+ address?: string;
623
+
624
+ /**
625
+ * Multiplier applied to the rewards for this collection.
626
+ */
627
+ multiplier?: number;
628
+
629
+ /**
630
+ * Blockchain network of the collection.
631
+ */
632
+ network?:
633
+ | 'abstract'
634
+ | 'abstractTestnet'
635
+ | 'apechain'
636
+ | 'arbitrum'
637
+ | 'avalanche'
638
+ | 'avalancheFuji'
639
+ | 'base'
640
+ | 'baseSepolia'
641
+ | 'berachain'
642
+ | 'berachainArtio'
643
+ | 'berachainBepolia'
644
+ | 'binance'
645
+ | 'bscTestnet'
646
+ | 'campTestnet'
647
+ | 'fantom'
648
+ | 'fantomTestnet'
649
+ | 'flowMainnet'
650
+ | 'mainnet'
651
+ | 'nexusTestnet'
652
+ | 'optimism'
653
+ | 'polygon'
654
+ | 'polygon_mumbai'
655
+ | 'skaleNebula'
656
+ | 'solana'
657
+ | 'sophon'
658
+ | 'sophonTestnet'
659
+ | 'sui'
660
+ | 'superseed'
661
+ | 'superseedSepolia'
662
+ | 'vanar'
663
+ | 'xai'
664
+ | 'zksync'
665
+ | 'coti'
666
+ | 'cotiTestnet'
667
+ | 'morph'
668
+ | 'morphTestnet'
669
+ | 'morphHolesky'
670
+ | 'ultra'
671
+ | 'ultraTestnet'
672
+ | 'nitrograph'
673
+ | 'sepolia'
674
+ | 'optimism_sepolia'
675
+ | 'arbitrumSepolia'
676
+ | 'goerli'
677
+ | 'optimism_goerli'
678
+ | 'arbitrumGoerli'
679
+ | 'basecamp';
680
+ }
681
+
682
+ /**
683
+ * Object containing details for the call-to-action.
684
+ */
685
+ export interface Cta {
686
+ /**
687
+ * Link for the call-to-action.
688
+ */
689
+ href?: string | null;
690
+
691
+ /**
692
+ * Label for the call-to-action.
693
+ */
694
+ label?: string | null;
695
+ }
696
+
697
+ export interface DiscordServersToJoin {
698
+ /**
699
+ * ID of the Discord server to join.
700
+ */
701
+ id?: string;
702
+
703
+ /**
704
+ * Array of Discord channels to join.
705
+ */
706
+ channels?: Array<DiscordServersToJoin.Channel>;
707
+
708
+ /**
709
+ * Array of roles to assign in the Discord server.
710
+ */
711
+ roles?: Array<DiscordServersToJoin.Role>;
712
+ }
713
+
714
+ export namespace DiscordServersToJoin {
715
+ export interface Channel {
716
+ /**
717
+ * ID of the Discord channel.
718
+ */
719
+ id?: string;
720
+
721
+ /**
722
+ * Array of emojis used in the channel.
723
+ */
724
+ emojis?: Array<Channel.Emoji>;
725
+
726
+ /**
727
+ * Phrase of text to be present in the discord message
728
+ */
729
+ text?: string;
730
+ }
731
+
732
+ export namespace Channel {
733
+ export interface Emoji {
734
+ /**
735
+ * ID of the emoji used in the channel.
736
+ */
737
+ id?: string;
738
+ }
739
+ }
740
+
741
+ export interface Role {
742
+ /**
743
+ * ID of the role in the Discord server.
744
+ */
745
+ id: string;
746
+ }
747
+ }
748
+
749
+ export interface DripQuestsToComplete {
750
+ /**
751
+ * ID of the drip quest to complete.
752
+ */
753
+ id: string;
754
+ }
755
+
756
+ /**
757
+ * Liquidity pool details.
758
+ */
759
+ export interface Liquidity {
760
+ /**
761
+ * Calculation type of the liquidity pool.
762
+ */
763
+ calculationType?: 'fixed' | 'custom';
764
+
765
+ /**
766
+ * Custom function to calculate the the reward amount based on the liquidity
767
+ * provided per day. X is the reward amount, Y is the liquidity provided per day in
768
+ * USD.
769
+ */
770
+ customFunction?: string;
771
+
772
+ /**
773
+ * Liquidity provided per day in USD
774
+ */
775
+ liquidityPerDay?: number;
776
+
777
+ /**
778
+ * Blockchain network of the liquidity pool.
779
+ */
780
+ network?:
781
+ | 'abstract'
782
+ | 'abstractTestnet'
783
+ | 'apechain'
784
+ | 'arbitrum'
785
+ | 'avalanche'
786
+ | 'avalancheFuji'
787
+ | 'base'
788
+ | 'baseSepolia'
789
+ | 'berachain'
790
+ | 'berachainArtio'
791
+ | 'berachainBepolia'
792
+ | 'binance'
793
+ | 'bscTestnet'
794
+ | 'campTestnet'
795
+ | 'fantom'
796
+ | 'fantomTestnet'
797
+ | 'flowMainnet'
798
+ | 'mainnet'
799
+ | 'nexusTestnet'
800
+ | 'optimism'
801
+ | 'polygon'
802
+ | 'polygon_mumbai'
803
+ | 'skaleNebula'
804
+ | 'solana'
805
+ | 'sophon'
806
+ | 'sophonTestnet'
807
+ | 'sui'
808
+ | 'superseed'
809
+ | 'superseedSepolia'
810
+ | 'vanar'
811
+ | 'xai'
812
+ | 'zksync'
813
+ | 'coti'
814
+ | 'cotiTestnet'
815
+ | 'morph'
816
+ | 'morphTestnet'
817
+ | 'morphHolesky'
818
+ | 'ultra'
819
+ | 'ultraTestnet'
820
+ | 'nitrograph'
821
+ | 'sepolia'
822
+ | 'optimism_sepolia'
823
+ | 'arbitrumSepolia'
824
+ | 'goerli'
825
+ | 'optimism_goerli'
826
+ | 'arbitrumGoerli'
827
+ | 'basecamp';
828
+
829
+ /**
830
+ * Indicates if only in-range liquidity is rewarded.
831
+ */
832
+ onlyRewardInRangeLiquidity?: boolean;
833
+
834
+ /**
835
+ * Array of liquidity pools associated with the rule.
836
+ */
837
+ pools?: Array<Liquidity.Pool>;
838
+
839
+ /**
840
+ * Protocol of the liquidity pool.
841
+ */
842
+ protocol?: string;
843
+ }
844
+
845
+ export namespace Liquidity {
846
+ export interface Pool {
847
+ /**
848
+ * Unique identifier of the liquidity pool.
849
+ */
850
+ id: string;
851
+ }
852
+ }
853
+
854
+ export interface Range {
855
+ /**
856
+ * Reward amount for this range.
857
+ */
858
+ amount: number;
859
+
860
+ /**
861
+ * End value of the range.
862
+ */
863
+ endRange: number;
864
+
865
+ /**
866
+ * Start value of the range.
867
+ */
868
+ startRange: number;
869
+
870
+ /**
871
+ * ID of the loyalty badge for this range.
872
+ */
873
+ loyaltyBadgeId?: string;
874
+
875
+ /**
876
+ * Amount of the loyalty multiplier for this range.
877
+ */
878
+ loyaltyMultiplierAmount?: number;
879
+ }
880
+
881
+ /**
882
+ * Object defining referral requirements.
883
+ */
884
+ export interface ReferralRequirements {
885
+ /**
886
+ * Flag indicating if achieving points is required.
887
+ */
888
+ achievePoints?: boolean | null;
889
+
890
+ /**
891
+ * Flag indicating if completing the profile is required.
892
+ */
893
+ completeProfile?: boolean | null;
894
+
895
+ /**
896
+ * Flag indicating if connecting Discord is required.
897
+ */
898
+ connectDiscord?: boolean | null;
899
+
900
+ /**
901
+ * Flag indicating if connecting email is required.
902
+ */
903
+ connectEmail?: boolean | null;
904
+
905
+ /**
906
+ * Flag indicating if connecting Twitter is required.
907
+ */
908
+ connectTwitter?: boolean | null;
909
+
910
+ points?: ReferralRequirements.Points | null;
911
+ }
912
+
913
+ export namespace ReferralRequirements {
914
+ export interface Points {
915
+ /**
916
+ * Points required for referral.
917
+ */
918
+ amount?: number | null;
919
+
920
+ /**
921
+ * ID of the loyalty currency for referral.
922
+ */
923
+ loyaltyCurrecyId?: string | null;
924
+ }
925
+ }
926
+
927
+ /**
928
+ * Object containing details of the associated smart contract.
929
+ */
930
+ export interface SmartContract {
931
+ /**
932
+ * Mapping of addresses for the smart contract.
933
+ */
934
+ addressMapping?: string | null;
935
+
936
+ /**
937
+ * Object containing details of the amount multiplier from the event.
938
+ */
939
+ amountMultiplier?: SmartContract.AmountMultiplier | null;
940
+
941
+ /**
942
+ * ID of the smart contract.
943
+ */
944
+ contractId?: string | null;
945
+
946
+ /**
947
+ * Criteria to evaluate the smart contract event.
948
+ */
949
+ criteria?: 'everyEvent' | 'byParameter' | null;
950
+
951
+ /**
952
+ * Event emitted by the smart contract.
953
+ */
954
+ event?: string | null;
955
+
956
+ /**
957
+ * Array of parameters for the smart contract.
958
+ */
959
+ params?: Array<SmartContract.Param> | null;
960
+
961
+ /**
962
+ * Type of the smart contract interaction.
963
+ */
964
+ type?: 'function' | 'event' | null;
965
+ }
966
+
967
+ export namespace SmartContract {
968
+ /**
969
+ * Object containing details of the amount multiplier from the event.
970
+ */
971
+ export interface AmountMultiplier {
972
+ /**
973
+ * Mapping of the value for the smart contract.
974
+ */
975
+ valueMapping?: string | null;
976
+ }
977
+
978
+ export interface Param {
979
+ /**
980
+ * Condition to check for the parameter.
981
+ */
982
+ condition?: string | null;
983
+
984
+ /**
985
+ * Name of the smart contract parameter.
986
+ */
987
+ name?: string | null;
988
+
989
+ /**
990
+ * Value of the parameter.
991
+ */
992
+ value?: string | null;
993
+ }
994
+ }
995
+
996
+ export interface SnapshotProposal {
997
+ /**
998
+ * ID of the snapshot proposal.
999
+ */
1000
+ id: string;
1001
+
1002
+ /**
1003
+ * Space associated with the snapshot proposal.
1004
+ */
1005
+ space: string;
1006
+ }
1007
+
1008
+ export interface StreakArray {
1009
+ /**
1010
+ * Reward amount for achieving the streak milestone.
1011
+ */
1012
+ streakAmount: number;
1013
+
1014
+ /**
1015
+ * Milestone required to achieve the streak.
1016
+ */
1017
+ streakMilestone: number;
1018
+ }
1019
+
1020
+ /**
1021
+ * Metadata for swap loyalty rules
1022
+ */
1023
+ export interface Swap {
1024
+ provider?: 'any' | 'relay' | 'lifi';
1025
+
1026
+ relayReferrerId?: string;
1027
+
1028
+ requireCrossChainSwap?: boolean;
1029
+
1030
+ swappedToChain?: 'any' | number | string;
1031
+
1032
+ swappedToTokens?: Array<Swap.SwappedToToken>;
1033
+
1034
+ tokenMode?: 'any' | 'specific';
1035
+
1036
+ trackTokenAmount?: boolean;
1037
+ }
1038
+
1039
+ export namespace Swap {
1040
+ export interface SwappedToToken {
1041
+ address: string;
1042
+
1043
+ chainId: string;
1044
+ }
1045
+ }
1046
+ }
1047
+ }
1048
+
1049
+ /**
1050
+ * Previous data of the rule before the edit
1051
+ */
1052
+ export interface PreviousData {
1053
+ /**
1054
+ * Unique identifier for the loyalty rule
1055
+ */
1056
+ id: string;
1057
+
1058
+ /**
1059
+ * Amount associated with the loyalty rule
1060
+ */
1061
+ amount: number;
1062
+
1063
+ /**
1064
+ * Timestamp when the loyalty rule was created
1065
+ */
1066
+ createdAt: string;
1067
+
1068
+ /**
1069
+ * Timestamp when the loyalty rule was deleted (if applicable)
1070
+ */
1071
+ deletedAt: string | null;
1072
+
1073
+ /**
1074
+ * Description of the loyalty rule
1075
+ */
1076
+ description: string;
1077
+
1078
+ /**
1079
+ * End time of the loyalty rule
1080
+ */
1081
+ endTime: string;
1082
+
1083
+ /**
1084
+ * Frequency of the loyalty rule
1085
+ */
1086
+ frequency: string;
1087
+
1088
+ /**
1089
+ * Name of the loyalty rule
1090
+ */
1091
+ name: string;
1092
+
1093
+ /**
1094
+ * Unique identifier for the organization
1095
+ */
1096
+ organizationId: string;
1097
+
1098
+ /**
1099
+ * Type of the reward
1100
+ */
1101
+ rewardType: 'points' | 'multiplier' | 'badge';
1102
+
1103
+ /**
1104
+ * Start time of the loyalty rule
1105
+ */
1106
+ startTime: string;
1107
+
1108
+ /**
1109
+ * Type of the loyalty rule
1110
+ */
1111
+ type: string;
1112
+
1113
+ /**
1114
+ * Timestamp when the loyalty rule was last updated
1115
+ */
1116
+ updatedAt: string;
1117
+
1118
+ /**
1119
+ * Unique identifier for the website
1120
+ */
1121
+ websiteId: string;
1122
+
1123
+ /**
1124
+ * Optional address of the collection
1125
+ */
1126
+ collectionAddress?: string;
1127
+
1128
+ /**
1129
+ * URL of the media associated with the loyalty rule
1130
+ */
1131
+ mediaUrl?: string | null;
1132
+
1133
+ /**
1134
+ * Optional metadata for the loyalty rule
1135
+ */
1136
+ metadata?: { [key: string]: PreviousData.Metadata };
1137
+ }
1138
+
1139
+ export namespace PreviousData {
1140
+ export interface Metadata {
1141
+ /**
1142
+ * Number of tokens per batch.
1143
+ */
1144
+ batchSize?: number | null;
1145
+
1146
+ /**
1147
+ * Text displayed on the action button.
1148
+ */
1149
+ buttonText?: string | null;
1150
+
1151
+ /**
1152
+ * Flag indicating if commenting is required.
1153
+ */
1154
+ checkComment?: boolean | null;
1155
+
1156
+ /**
1157
+ * Flag indicating if liking the post is required.
1158
+ */
1159
+ checkLike?: boolean | null;
1160
+
1161
+ /**
1162
+ * Flag indicating if reposting is required.
1163
+ */
1164
+ checkRepost?: boolean | null;
1165
+
1166
+ /**
1167
+ * Text to check in the Twitter post, username, or bio.
1168
+ */
1169
+ checkText?: string | null;
1170
+
1171
+ /**
1172
+ * Array of collections associated with the rule.
1173
+ */
1174
+ collection?: Array<Metadata.Collection>;
1175
+
1176
+ /**
1177
+ * Conditions for completing the profile.
1178
+ */
1179
+ completeProfileConditions?: { [key: string]: boolean } | null;
1180
+
1181
+ /**
1182
+ * Description of the external rule condition (only for external rules)
1183
+ */
1184
+ conditionDescription?: string;
1185
+
1186
+ /**
1187
+ * Object containing details for the call-to-action.
1188
+ */
1189
+ cta?: Metadata.Cta | null;
1190
+
1191
+ /**
1192
+ * API key for custom rewards integration.
1193
+ */
1194
+ customRewardsApiKey?: string;
1195
+
1196
+ /**
1197
+ * Flag indicating if the rule should use direct RPC to get the balance of tokens.
1198
+ */
1199
+ directRpc?: boolean;
1200
+
1201
+ /**
1202
+ * Array of Discord servers, channels, and roles to join.
1203
+ */
1204
+ discordServersToJoin?: Array<Metadata.DiscordServersToJoin> | null;
1205
+
1206
+ /**
1207
+ * Array of drip quests required to complete the rule.
1208
+ */
1209
+ dripQuestsToComplete?: Array<Metadata.DripQuestsToComplete> | null;
1210
+
1211
+ /**
1212
+ * Flag indicating whether joining Discord servers is required.
1213
+ */
1214
+ enableJoinDiscordServers?: boolean | null;
1215
+
1216
+ /**
1217
+ * Flag indicating whether streaks are enabled.
1218
+ */
1219
+ enableStreaks?: boolean | null;
1220
+
1221
+ /**
1222
+ * Flag indicating whether the verified multiplier is enabled.
1223
+ */
1224
+ enableVerifiedMultiplier?: boolean;
1225
+
1226
+ /**
1227
+ * Fill source of the order for the token sale
1228
+ */
1229
+ fillSource?: string;
1230
+
1231
+ /**
1232
+ * Percentage reward given to a user for their first referral.
1233
+ */
1234
+ firstReferralReward?: number | null;
1235
+
1236
+ /**
1237
+ * Flag indicating whether the fill source is included.
1238
+ */
1239
+ hasFillSource?: boolean;
1240
+
1241
+ /**
1242
+ * Indicates if the item has never been sold.
1243
+ */
1244
+ hasNeverSold?: boolean;
1245
+
1246
+ /**
1247
+ * Indicates if the full royalty has been paid for items.
1248
+ */
1249
+ hasPaidFullRoyalty?: boolean;
1250
+
1251
+ /**
1252
+ * Flag indicating if the sale currency is included.
1253
+ */
1254
+ hasSaleCurrency?: boolean;
1255
+
1256
+ /**
1257
+ * Indicates if the user has a verified Twitter account.
1258
+ */
1259
+ hasVerifiedTwitter?: boolean;
1260
+
1261
+ /**
1262
+ * URL of the image associated with the rule.
1263
+ */
1264
+ imageUrl?: string | null;
1265
+
1266
+ /**
1267
+ * If enabled, the first transaction done on the platform will complete this rule
1268
+ */
1269
+ isCheckInOnEveryTxn?: boolean;
1270
+
1271
+ /**
1272
+ * Indicates if the multiplier has been applied to rewards.
1273
+ */
1274
+ isMultiplierApplied?: boolean;
1275
+
1276
+ /**
1277
+ * Flag indicating if the rule is restricted to new users.
1278
+ */
1279
+ isRestrictedToNewUsers?: boolean;
1280
+
1281
+ /**
1282
+ * Flag indicating if rewards are applied retroactively.
1283
+ */
1284
+ isRetroactive?: boolean | null;
1285
+
1286
+ /**
1287
+ * Flag indicating if the token hold multiplier is applied.
1288
+ */
1289
+ isTokenHoldMultiplier?: boolean;
1290
+
1291
+ /**
1292
+ * Optional link associated with the metadata.
1293
+ */
1294
+ link?: string | null;
1295
+
1296
+ /**
1297
+ * Liquidity pool details.
1298
+ */
1299
+ liquidity?: Metadata.Liquidity;
1300
+
1301
+ /**
1302
+ * Maximum quantity constraint for token holding.
1303
+ */
1304
+ maxQty?: number | null;
1305
+
1306
+ /**
1307
+ * Minimum quantity constraint for token holding.
1308
+ */
1309
+ minQty?: number | null;
1310
+
1311
+ /**
1312
+ * Array of loyalty currency IDs used for multipliers.
1313
+ */
1314
+ multiplierLoyaltyCurrencyIds?: Array<string> | null;
1315
+
1316
+ /**
1317
+ * Flag indicating whether to include only known users.
1318
+ */
1319
+ onlyKnownUsers?: boolean;
1320
+
1321
+ /**
1322
+ * Flag indicating whether to include only native tokens.
1323
+ */
1324
+ onlyNative?: boolean;
1325
+
1326
+ /**
1327
+ * Flag indicating whether to include only non-listed items.
1328
+ */
1329
+ onlyNonListed?: boolean;
1330
+
1331
+ /**
1332
+ * Indicates if only existing users are rewarded.
1333
+ */
1334
+ onlyRewardExistingUser?: boolean;
1335
+
1336
+ /**
1337
+ * give points for only one token ownership per contract
1338
+ */
1339
+ onlyRewardSingleTokenOwnership?: boolean | null;
1340
+
1341
+ /**
1342
+ * Promotional code associated with the rule.
1343
+ */
1344
+ promoCode?: string;
1345
+
1346
+ /**
1347
+ * URL of the CSV file containing promo codes.
1348
+ */
1349
+ promoCodeCsvUrl?: string;
1350
+
1351
+ /**
1352
+ * Numbers of the promotional code to be generated.
1353
+ */
1354
+ promoCodeLength?: number | null;
1355
+
1356
+ /**
1357
+ * Type of the promotional code.
1358
+ */
1359
+ promoCodeType?: 'code' | 'csv' | 'generate';
1360
+
1361
+ /**
1362
+ * Array defining ranges and corresponding rewards.
1363
+ */
1364
+ range?: Array<Metadata.Range>;
1365
+
1366
+ /**
1367
+ * Object defining referral requirements.
1368
+ */
1369
+ referralRequirements?: Metadata.ReferralRequirements | null;
1370
+
1371
+ /**
1372
+ * Lump sum reward given to a referrer.
1373
+ */
1374
+ referrerReward?: number | null;
1375
+
1376
+ /**
1377
+ * Loyalty currency ID of the referrer reward.
1378
+ */
1379
+ referrerRewardLoyaltyCurrencyId?: string | null;
1380
+
1381
+ /**
1382
+ * Flag indicating if the post link is required.
1383
+ */
1384
+ requirePostLink?: boolean | null;
1385
+
1386
+ /**
1387
+ * Flag indicating if the rule can also reward badges per range.
1388
+ */
1389
+ rewardBadgePerRange?: boolean;
1390
+
1391
+ /**
1392
+ * Flag indicating if the reward is rewarded by batch.
1393
+ */
1394
+ rewardByBatch?: boolean | null;
1395
+
1396
+ /**
1397
+ * Flag indicating if the reward is rewarded per action.
1398
+ */
1399
+ rewardPerAction?: boolean | null;
1400
+
1401
+ /**
1402
+ * Flag indicating if rewards are given per impression.
1403
+ */
1404
+ rewardPerImpression?: boolean | null;
1405
+
1406
+ /**
1407
+ * Flag indicating if the rule should reward based on value of traded tokens
1408
+ * instead of count.
1409
+ */
1410
+ rewardPerValue?: boolean;
1411
+
1412
+ /**
1413
+ * Wallet address of the user can only be used if userId is not provided
1414
+ */
1415
+ royaltyAddress?: string;
1416
+
1417
+ /**
1418
+ * Royalty percentage of the item.
1419
+ */
1420
+ royaltyPercentage?: number;
1421
+
1422
+ /**
1423
+ * Currency associated with sales.
1424
+ */
1425
+ saleCurrency?: string;
1426
+
1427
+ /**
1428
+ * Percentage reward given for a second-level referral.
1429
+ */
1430
+ secondReferralReward?: number | null;
1431
+
1432
+ /**
1433
+ * Flag indicating if the multiplier is skipped.
1434
+ */
1435
+ skipMultiplier?: boolean | null;
1436
+
1437
+ /**
1438
+ * Object containing details of the associated smart contract.
1439
+ */
1440
+ smartContract?: Metadata.SmartContract;
1441
+
1442
+ /**
1443
+ * Array of snapshot proposals for the rule.
1444
+ */
1445
+ snapshotProposals?: Array<Metadata.SnapshotProposal> | null;
1446
+
1447
+ /**
1448
+ * Social media platform associated with the rule.
1449
+ */
1450
+ socialPlatform?:
1451
+ | 'Custom'
1452
+ | 'Discord'
1453
+ | 'EpicGames'
1454
+ | 'Instagram'
1455
+ | 'Steam'
1456
+ | 'Telegram'
1457
+ | 'TikTok'
1458
+ | 'Twitch'
1459
+ | 'X(Twitter)'
1460
+ | 'YouTube'
1461
+ | 'Google'
1462
+ | null;
1463
+
1464
+ /**
1465
+ * URL of the social platform's logo.
1466
+ */
1467
+ socialPlatformLogo?: string | null;
1468
+
1469
+ /**
1470
+ * Name of the social platform.
1471
+ */
1472
+ socialPlatformName?: string | null;
1473
+
1474
+ /**
1475
+ * ID of the Steam app.
1476
+ */
1477
+ steamAppId?: string | null;
1478
+
1479
+ /**
1480
+ * Array of streak milestones and corresponding rewards.
1481
+ */
1482
+ streakArray?: Array<Metadata.StreakArray> | null;
1483
+
1484
+ /**
1485
+ * Metadata for swap loyalty rules
1486
+ */
1487
+ swap?: Metadata.Swap;
1488
+
1489
+ /**
1490
+ * ID of the Telegram channel.
1491
+ */
1492
+ telegramChannelId?: string | null;
1493
+
1494
+ /**
1495
+ * Time delay in seconds to verify actions.
1496
+ */
1497
+ timeDelayToVerifySeconds?: string | number | null;
1498
+
1499
+ /**
1500
+ * Flag indicating if all contracts are tracked.
1501
+ */
1502
+ trackAllContracts?: boolean | null;
1503
+
1504
+ /**
1505
+ * Flag indicating if the progress is tracked. If enabled, the rule can only be
1506
+ * completed once the progress is 100%.
1507
+ */
1508
+ trackProgress?: boolean | null;
1509
+
1510
+ /**
1511
+ * URL of the associated Twitter account.
1512
+ */
1513
+ twitterAccountUrl?: string;
1514
+
1515
+ /**
1516
+ * Hashtag associated with the Twitter post.
1517
+ */
1518
+ twitterHashtag?: string;
1519
+
1520
+ /**
1521
+ * URL of the associated Twitter post.
1522
+ */
1523
+ twitterPostUrl?: string;
1524
+
1525
+ /**
1526
+ * Unique identifier of the Twitter user.
1527
+ */
1528
+ twitterUserId?: string;
1529
+
1530
+ /**
1531
+ * Twitter username of the user.
1532
+ */
1533
+ twitterUsername?: string;
1534
+
1535
+ /**
1536
+ * Minimum length of the verification text.
1537
+ */
1538
+ verificationTextMinimumLength?: number | null;
1539
+
1540
+ /**
1541
+ * Multiplier applied to rewards for verified users.
1542
+ */
1543
+ verifiedMultiplier?: number | null;
1544
+
1545
+ /**
1546
+ * Placeholder text for verification input fields.
1547
+ */
1548
+ verifyPlaceHolderText?: string | null;
1549
+
1550
+ /**
1551
+ * Type of wallet associated with the rule.
1552
+ */
1553
+ walletType?: 'evm' | 'solana' | 'imx' | 'sui' | 'ton' | 'cosmos' | 'ultra' | 'agw' | null;
1554
+
1555
+ /**
1556
+ * ID of the Youtube channel.
1557
+ */
1558
+ youtubeChannelId?: string | null;
1559
+
1560
+ /**
1561
+ * ID of the Youtube video.
1562
+ */
1563
+ youtubeVideoId?: string | null;
1564
+ }
1565
+
1566
+ export namespace Metadata {
1567
+ export interface Collection {
1568
+ /**
1569
+ * Blockchain address of the collection.
1570
+ */
1571
+ address?: string;
1572
+
1573
+ /**
1574
+ * Multiplier applied to the rewards for this collection.
1575
+ */
1576
+ multiplier?: number;
1577
+
1578
+ /**
1579
+ * Blockchain network of the collection.
1580
+ */
1581
+ network?:
1582
+ | 'abstract'
1583
+ | 'abstractTestnet'
1584
+ | 'apechain'
1585
+ | 'arbitrum'
1586
+ | 'avalanche'
1587
+ | 'avalancheFuji'
1588
+ | 'base'
1589
+ | 'baseSepolia'
1590
+ | 'berachain'
1591
+ | 'berachainArtio'
1592
+ | 'berachainBepolia'
1593
+ | 'binance'
1594
+ | 'bscTestnet'
1595
+ | 'campTestnet'
1596
+ | 'fantom'
1597
+ | 'fantomTestnet'
1598
+ | 'flowMainnet'
1599
+ | 'mainnet'
1600
+ | 'nexusTestnet'
1601
+ | 'optimism'
1602
+ | 'polygon'
1603
+ | 'polygon_mumbai'
1604
+ | 'skaleNebula'
1605
+ | 'solana'
1606
+ | 'sophon'
1607
+ | 'sophonTestnet'
1608
+ | 'sui'
1609
+ | 'superseed'
1610
+ | 'superseedSepolia'
1611
+ | 'vanar'
1612
+ | 'xai'
1613
+ | 'zksync'
1614
+ | 'coti'
1615
+ | 'cotiTestnet'
1616
+ | 'morph'
1617
+ | 'morphTestnet'
1618
+ | 'morphHolesky'
1619
+ | 'ultra'
1620
+ | 'ultraTestnet'
1621
+ | 'nitrograph'
1622
+ | 'sepolia'
1623
+ | 'optimism_sepolia'
1624
+ | 'arbitrumSepolia'
1625
+ | 'goerli'
1626
+ | 'optimism_goerli'
1627
+ | 'arbitrumGoerli'
1628
+ | 'basecamp';
1629
+ }
1630
+
1631
+ /**
1632
+ * Object containing details for the call-to-action.
1633
+ */
1634
+ export interface Cta {
1635
+ /**
1636
+ * Link for the call-to-action.
1637
+ */
1638
+ href?: string | null;
1639
+
1640
+ /**
1641
+ * Label for the call-to-action.
1642
+ */
1643
+ label?: string | null;
1644
+ }
1645
+
1646
+ export interface DiscordServersToJoin {
1647
+ /**
1648
+ * ID of the Discord server to join.
1649
+ */
1650
+ id?: string;
1651
+
1652
+ /**
1653
+ * Array of Discord channels to join.
1654
+ */
1655
+ channels?: Array<DiscordServersToJoin.Channel>;
1656
+
1657
+ /**
1658
+ * Array of roles to assign in the Discord server.
1659
+ */
1660
+ roles?: Array<DiscordServersToJoin.Role>;
1661
+ }
1662
+
1663
+ export namespace DiscordServersToJoin {
1664
+ export interface Channel {
1665
+ /**
1666
+ * ID of the Discord channel.
1667
+ */
1668
+ id?: string;
1669
+
1670
+ /**
1671
+ * Array of emojis used in the channel.
1672
+ */
1673
+ emojis?: Array<Channel.Emoji>;
1674
+
1675
+ /**
1676
+ * Phrase of text to be present in the discord message
1677
+ */
1678
+ text?: string;
1679
+ }
1680
+
1681
+ export namespace Channel {
1682
+ export interface Emoji {
1683
+ /**
1684
+ * ID of the emoji used in the channel.
1685
+ */
1686
+ id?: string;
1687
+ }
1688
+ }
1689
+
1690
+ export interface Role {
1691
+ /**
1692
+ * ID of the role in the Discord server.
1693
+ */
1694
+ id: string;
1695
+ }
1696
+ }
1697
+
1698
+ export interface DripQuestsToComplete {
1699
+ /**
1700
+ * ID of the drip quest to complete.
1701
+ */
1702
+ id: string;
1703
+ }
1704
+
1705
+ /**
1706
+ * Liquidity pool details.
1707
+ */
1708
+ export interface Liquidity {
1709
+ /**
1710
+ * Calculation type of the liquidity pool.
1711
+ */
1712
+ calculationType?: 'fixed' | 'custom';
1713
+
1714
+ /**
1715
+ * Custom function to calculate the the reward amount based on the liquidity
1716
+ * provided per day. X is the reward amount, Y is the liquidity provided per day in
1717
+ * USD.
1718
+ */
1719
+ customFunction?: string;
1720
+
1721
+ /**
1722
+ * Liquidity provided per day in USD
1723
+ */
1724
+ liquidityPerDay?: number;
1725
+
1726
+ /**
1727
+ * Blockchain network of the liquidity pool.
1728
+ */
1729
+ network?:
1730
+ | 'abstract'
1731
+ | 'abstractTestnet'
1732
+ | 'apechain'
1733
+ | 'arbitrum'
1734
+ | 'avalanche'
1735
+ | 'avalancheFuji'
1736
+ | 'base'
1737
+ | 'baseSepolia'
1738
+ | 'berachain'
1739
+ | 'berachainArtio'
1740
+ | 'berachainBepolia'
1741
+ | 'binance'
1742
+ | 'bscTestnet'
1743
+ | 'campTestnet'
1744
+ | 'fantom'
1745
+ | 'fantomTestnet'
1746
+ | 'flowMainnet'
1747
+ | 'mainnet'
1748
+ | 'nexusTestnet'
1749
+ | 'optimism'
1750
+ | 'polygon'
1751
+ | 'polygon_mumbai'
1752
+ | 'skaleNebula'
1753
+ | 'solana'
1754
+ | 'sophon'
1755
+ | 'sophonTestnet'
1756
+ | 'sui'
1757
+ | 'superseed'
1758
+ | 'superseedSepolia'
1759
+ | 'vanar'
1760
+ | 'xai'
1761
+ | 'zksync'
1762
+ | 'coti'
1763
+ | 'cotiTestnet'
1764
+ | 'morph'
1765
+ | 'morphTestnet'
1766
+ | 'morphHolesky'
1767
+ | 'ultra'
1768
+ | 'ultraTestnet'
1769
+ | 'nitrograph'
1770
+ | 'sepolia'
1771
+ | 'optimism_sepolia'
1772
+ | 'arbitrumSepolia'
1773
+ | 'goerli'
1774
+ | 'optimism_goerli'
1775
+ | 'arbitrumGoerli'
1776
+ | 'basecamp';
1777
+
1778
+ /**
1779
+ * Indicates if only in-range liquidity is rewarded.
1780
+ */
1781
+ onlyRewardInRangeLiquidity?: boolean;
1782
+
1783
+ /**
1784
+ * Array of liquidity pools associated with the rule.
1785
+ */
1786
+ pools?: Array<Liquidity.Pool>;
1787
+
1788
+ /**
1789
+ * Protocol of the liquidity pool.
1790
+ */
1791
+ protocol?: string;
1792
+ }
1793
+
1794
+ export namespace Liquidity {
1795
+ export interface Pool {
1796
+ /**
1797
+ * Unique identifier of the liquidity pool.
1798
+ */
1799
+ id: string;
1800
+ }
1801
+ }
1802
+
1803
+ export interface Range {
1804
+ /**
1805
+ * Reward amount for this range.
1806
+ */
1807
+ amount: number;
1808
+
1809
+ /**
1810
+ * End value of the range.
1811
+ */
1812
+ endRange: number;
1813
+
1814
+ /**
1815
+ * Start value of the range.
1816
+ */
1817
+ startRange: number;
1818
+
1819
+ /**
1820
+ * ID of the loyalty badge for this range.
1821
+ */
1822
+ loyaltyBadgeId?: string;
1823
+
1824
+ /**
1825
+ * Amount of the loyalty multiplier for this range.
1826
+ */
1827
+ loyaltyMultiplierAmount?: number;
1828
+ }
1829
+
1830
+ /**
1831
+ * Object defining referral requirements.
1832
+ */
1833
+ export interface ReferralRequirements {
1834
+ /**
1835
+ * Flag indicating if achieving points is required.
1836
+ */
1837
+ achievePoints?: boolean | null;
1838
+
1839
+ /**
1840
+ * Flag indicating if completing the profile is required.
1841
+ */
1842
+ completeProfile?: boolean | null;
1843
+
1844
+ /**
1845
+ * Flag indicating if connecting Discord is required.
1846
+ */
1847
+ connectDiscord?: boolean | null;
1848
+
1849
+ /**
1850
+ * Flag indicating if connecting email is required.
1851
+ */
1852
+ connectEmail?: boolean | null;
1853
+
1854
+ /**
1855
+ * Flag indicating if connecting Twitter is required.
1856
+ */
1857
+ connectTwitter?: boolean | null;
1858
+
1859
+ points?: ReferralRequirements.Points | null;
1860
+ }
1861
+
1862
+ export namespace ReferralRequirements {
1863
+ export interface Points {
1864
+ /**
1865
+ * Points required for referral.
1866
+ */
1867
+ amount?: number | null;
1868
+
1869
+ /**
1870
+ * ID of the loyalty currency for referral.
1871
+ */
1872
+ loyaltyCurrecyId?: string | null;
1873
+ }
1874
+ }
1875
+
1876
+ /**
1877
+ * Object containing details of the associated smart contract.
1878
+ */
1879
+ export interface SmartContract {
1880
+ /**
1881
+ * Mapping of addresses for the smart contract.
1882
+ */
1883
+ addressMapping?: string | null;
1884
+
1885
+ /**
1886
+ * Object containing details of the amount multiplier from the event.
1887
+ */
1888
+ amountMultiplier?: SmartContract.AmountMultiplier | null;
1889
+
1890
+ /**
1891
+ * ID of the smart contract.
1892
+ */
1893
+ contractId?: string | null;
1894
+
1895
+ /**
1896
+ * Criteria to evaluate the smart contract event.
1897
+ */
1898
+ criteria?: 'everyEvent' | 'byParameter' | null;
1899
+
1900
+ /**
1901
+ * Event emitted by the smart contract.
1902
+ */
1903
+ event?: string | null;
1904
+
1905
+ /**
1906
+ * Array of parameters for the smart contract.
1907
+ */
1908
+ params?: Array<SmartContract.Param> | null;
1909
+
1910
+ /**
1911
+ * Type of the smart contract interaction.
1912
+ */
1913
+ type?: 'function' | 'event' | null;
1914
+ }
1915
+
1916
+ export namespace SmartContract {
1917
+ /**
1918
+ * Object containing details of the amount multiplier from the event.
1919
+ */
1920
+ export interface AmountMultiplier {
1921
+ /**
1922
+ * Mapping of the value for the smart contract.
1923
+ */
1924
+ valueMapping?: string | null;
1925
+ }
1926
+
1927
+ export interface Param {
1928
+ /**
1929
+ * Condition to check for the parameter.
1930
+ */
1931
+ condition?: string | null;
1932
+
1933
+ /**
1934
+ * Name of the smart contract parameter.
1935
+ */
1936
+ name?: string | null;
1937
+
1938
+ /**
1939
+ * Value of the parameter.
1940
+ */
1941
+ value?: string | null;
1942
+ }
1943
+ }
1944
+
1945
+ export interface SnapshotProposal {
1946
+ /**
1947
+ * ID of the snapshot proposal.
1948
+ */
1949
+ id: string;
1950
+
1951
+ /**
1952
+ * Space associated with the snapshot proposal.
1953
+ */
1954
+ space: string;
1955
+ }
1956
+
1957
+ export interface StreakArray {
1958
+ /**
1959
+ * Reward amount for achieving the streak milestone.
1960
+ */
1961
+ streakAmount: number;
1962
+
1963
+ /**
1964
+ * Milestone required to achieve the streak.
1965
+ */
1966
+ streakMilestone: number;
1967
+ }
1968
+
1969
+ /**
1970
+ * Metadata for swap loyalty rules
1971
+ */
1972
+ export interface Swap {
1973
+ provider?: 'any' | 'relay' | 'lifi';
1974
+
1975
+ relayReferrerId?: string;
1976
+
1977
+ requireCrossChainSwap?: boolean;
1978
+
1979
+ swappedToChain?: 'any' | number | string;
1980
+
1981
+ swappedToTokens?: Array<Swap.SwappedToToken>;
1982
+
1983
+ tokenMode?: 'any' | 'specific';
1984
+
1985
+ trackTokenAmount?: boolean;
1986
+ }
1987
+
1988
+ export namespace Swap {
1989
+ export interface SwappedToToken {
1990
+ address: string;
1991
+
1992
+ chainId: string;
1993
+ }
1994
+ }
1995
+ }
1996
+ }
1997
+ }
1998
+ }
1999
+
2000
+ export interface RuleEditRestoreResponse {
2001
+ /**
2002
+ * Unique identifier for the rule edit
2003
+ */
2004
+ id: string;
2005
+
2006
+ /**
2007
+ * Type of action that was made on the rule
2008
+ */
2009
+ action: 'create' | 'update' | 'delete' | 'restore';
2010
+
2011
+ /**
2012
+ * Data that was changed on the rule
2013
+ */
2014
+ data: RuleEditRestoreResponse.Data;
2015
+
2016
+ /**
2017
+ * Timestamp of when the rule edit was made
2018
+ */
2019
+ editedAt: string;
2020
+
2021
+ /**
2022
+ * User ID of the user who made the edit
2023
+ */
2024
+ editedByUserId: string;
2025
+
2026
+ /**
2027
+ * ID of the loyalty rule
2028
+ */
2029
+ loyaltyRuleId: string;
2030
+
2031
+ /**
2032
+ * Unique identifier for the organization
2033
+ */
2034
+ organizationId: string;
2035
+
2036
+ /**
2037
+ * Unique identifier for the website
2038
+ */
2039
+ websiteId: string;
2040
+
2041
+ /**
2042
+ * Comment that was made on the edit
2043
+ */
2044
+ comment?: string;
2045
+
2046
+ /**
2047
+ * Previous data of the rule before the edit
2048
+ */
2049
+ previousData?: RuleEditRestoreResponse.PreviousData;
2050
+ }
2051
+
2052
+ export namespace RuleEditRestoreResponse {
2053
+ /**
2054
+ * Data that was changed on the rule
2055
+ */
2056
+ export interface Data {
2057
+ /**
2058
+ * Unique identifier for the loyalty rule
2059
+ */
2060
+ id: string;
2061
+
2062
+ /**
2063
+ * Amount associated with the loyalty rule
2064
+ */
2065
+ amount: number;
2066
+
2067
+ /**
2068
+ * Timestamp when the loyalty rule was created
2069
+ */
2070
+ createdAt: string;
2071
+
2072
+ /**
2073
+ * Timestamp when the loyalty rule was deleted (if applicable)
2074
+ */
2075
+ deletedAt: string | null;
2076
+
2077
+ /**
2078
+ * Description of the loyalty rule
2079
+ */
2080
+ description: string;
2081
+
2082
+ /**
2083
+ * End time of the loyalty rule
2084
+ */
2085
+ endTime: string;
2086
+
2087
+ /**
2088
+ * Frequency of the loyalty rule
2089
+ */
2090
+ frequency: string;
2091
+
2092
+ /**
2093
+ * Name of the loyalty rule
2094
+ */
2095
+ name: string;
2096
+
2097
+ /**
2098
+ * Unique identifier for the organization
2099
+ */
2100
+ organizationId: string;
2101
+
2102
+ /**
2103
+ * Type of the reward
2104
+ */
2105
+ rewardType: 'points' | 'multiplier' | 'badge';
2106
+
2107
+ /**
2108
+ * Start time of the loyalty rule
2109
+ */
2110
+ startTime: string;
2111
+
2112
+ /**
2113
+ * Type of the loyalty rule
2114
+ */
2115
+ type: string;
2116
+
2117
+ /**
2118
+ * Timestamp when the loyalty rule was last updated
2119
+ */
2120
+ updatedAt: string;
2121
+
2122
+ /**
2123
+ * Unique identifier for the website
2124
+ */
2125
+ websiteId: string;
2126
+
2127
+ /**
2128
+ * Optional address of the collection
2129
+ */
2130
+ collectionAddress?: string;
2131
+
2132
+ /**
2133
+ * URL of the media associated with the loyalty rule
2134
+ */
2135
+ mediaUrl?: string | null;
2136
+
2137
+ /**
2138
+ * Optional metadata for the loyalty rule
2139
+ */
2140
+ metadata?: { [key: string]: Data.Metadata };
2141
+ }
2142
+
2143
+ export namespace Data {
2144
+ export interface Metadata {
2145
+ /**
2146
+ * Number of tokens per batch.
2147
+ */
2148
+ batchSize?: number | null;
2149
+
2150
+ /**
2151
+ * Text displayed on the action button.
2152
+ */
2153
+ buttonText?: string | null;
2154
+
2155
+ /**
2156
+ * Flag indicating if commenting is required.
2157
+ */
2158
+ checkComment?: boolean | null;
2159
+
2160
+ /**
2161
+ * Flag indicating if liking the post is required.
2162
+ */
2163
+ checkLike?: boolean | null;
2164
+
2165
+ /**
2166
+ * Flag indicating if reposting is required.
2167
+ */
2168
+ checkRepost?: boolean | null;
2169
+
2170
+ /**
2171
+ * Text to check in the Twitter post, username, or bio.
2172
+ */
2173
+ checkText?: string | null;
2174
+
2175
+ /**
2176
+ * Array of collections associated with the rule.
2177
+ */
2178
+ collection?: Array<Metadata.Collection>;
2179
+
2180
+ /**
2181
+ * Conditions for completing the profile.
2182
+ */
2183
+ completeProfileConditions?: { [key: string]: boolean } | null;
2184
+
2185
+ /**
2186
+ * Description of the external rule condition (only for external rules)
2187
+ */
2188
+ conditionDescription?: string;
2189
+
2190
+ /**
2191
+ * Object containing details for the call-to-action.
2192
+ */
2193
+ cta?: Metadata.Cta | null;
2194
+
2195
+ /**
2196
+ * API key for custom rewards integration.
2197
+ */
2198
+ customRewardsApiKey?: string;
2199
+
2200
+ /**
2201
+ * Flag indicating if the rule should use direct RPC to get the balance of tokens.
2202
+ */
2203
+ directRpc?: boolean;
2204
+
2205
+ /**
2206
+ * Array of Discord servers, channels, and roles to join.
2207
+ */
2208
+ discordServersToJoin?: Array<Metadata.DiscordServersToJoin> | null;
2209
+
2210
+ /**
2211
+ * Array of drip quests required to complete the rule.
2212
+ */
2213
+ dripQuestsToComplete?: Array<Metadata.DripQuestsToComplete> | null;
2214
+
2215
+ /**
2216
+ * Flag indicating whether joining Discord servers is required.
2217
+ */
2218
+ enableJoinDiscordServers?: boolean | null;
2219
+
2220
+ /**
2221
+ * Flag indicating whether streaks are enabled.
2222
+ */
2223
+ enableStreaks?: boolean | null;
2224
+
2225
+ /**
2226
+ * Flag indicating whether the verified multiplier is enabled.
2227
+ */
2228
+ enableVerifiedMultiplier?: boolean;
2229
+
2230
+ /**
2231
+ * Fill source of the order for the token sale
2232
+ */
2233
+ fillSource?: string;
2234
+
2235
+ /**
2236
+ * Percentage reward given to a user for their first referral.
2237
+ */
2238
+ firstReferralReward?: number | null;
2239
+
2240
+ /**
2241
+ * Flag indicating whether the fill source is included.
2242
+ */
2243
+ hasFillSource?: boolean;
2244
+
2245
+ /**
2246
+ * Indicates if the item has never been sold.
2247
+ */
2248
+ hasNeverSold?: boolean;
2249
+
2250
+ /**
2251
+ * Indicates if the full royalty has been paid for items.
2252
+ */
2253
+ hasPaidFullRoyalty?: boolean;
2254
+
2255
+ /**
2256
+ * Flag indicating if the sale currency is included.
2257
+ */
2258
+ hasSaleCurrency?: boolean;
2259
+
2260
+ /**
2261
+ * Indicates if the user has a verified Twitter account.
2262
+ */
2263
+ hasVerifiedTwitter?: boolean;
2264
+
2265
+ /**
2266
+ * URL of the image associated with the rule.
2267
+ */
2268
+ imageUrl?: string | null;
2269
+
2270
+ /**
2271
+ * If enabled, the first transaction done on the platform will complete this rule
2272
+ */
2273
+ isCheckInOnEveryTxn?: boolean;
2274
+
2275
+ /**
2276
+ * Indicates if the multiplier has been applied to rewards.
2277
+ */
2278
+ isMultiplierApplied?: boolean;
2279
+
2280
+ /**
2281
+ * Flag indicating if the rule is restricted to new users.
2282
+ */
2283
+ isRestrictedToNewUsers?: boolean;
2284
+
2285
+ /**
2286
+ * Flag indicating if rewards are applied retroactively.
2287
+ */
2288
+ isRetroactive?: boolean | null;
2289
+
2290
+ /**
2291
+ * Flag indicating if the token hold multiplier is applied.
2292
+ */
2293
+ isTokenHoldMultiplier?: boolean;
2294
+
2295
+ /**
2296
+ * Optional link associated with the metadata.
2297
+ */
2298
+ link?: string | null;
2299
+
2300
+ /**
2301
+ * Liquidity pool details.
2302
+ */
2303
+ liquidity?: Metadata.Liquidity;
2304
+
2305
+ /**
2306
+ * Maximum quantity constraint for token holding.
2307
+ */
2308
+ maxQty?: number | null;
2309
+
2310
+ /**
2311
+ * Minimum quantity constraint for token holding.
2312
+ */
2313
+ minQty?: number | null;
2314
+
2315
+ /**
2316
+ * Array of loyalty currency IDs used for multipliers.
2317
+ */
2318
+ multiplierLoyaltyCurrencyIds?: Array<string> | null;
2319
+
2320
+ /**
2321
+ * Flag indicating whether to include only known users.
2322
+ */
2323
+ onlyKnownUsers?: boolean;
2324
+
2325
+ /**
2326
+ * Flag indicating whether to include only native tokens.
2327
+ */
2328
+ onlyNative?: boolean;
2329
+
2330
+ /**
2331
+ * Flag indicating whether to include only non-listed items.
2332
+ */
2333
+ onlyNonListed?: boolean;
2334
+
2335
+ /**
2336
+ * Indicates if only existing users are rewarded.
2337
+ */
2338
+ onlyRewardExistingUser?: boolean;
2339
+
2340
+ /**
2341
+ * give points for only one token ownership per contract
2342
+ */
2343
+ onlyRewardSingleTokenOwnership?: boolean | null;
2344
+
2345
+ /**
2346
+ * Promotional code associated with the rule.
2347
+ */
2348
+ promoCode?: string;
2349
+
2350
+ /**
2351
+ * URL of the CSV file containing promo codes.
2352
+ */
2353
+ promoCodeCsvUrl?: string;
2354
+
2355
+ /**
2356
+ * Numbers of the promotional code to be generated.
2357
+ */
2358
+ promoCodeLength?: number | null;
2359
+
2360
+ /**
2361
+ * Type of the promotional code.
2362
+ */
2363
+ promoCodeType?: 'code' | 'csv' | 'generate';
2364
+
2365
+ /**
2366
+ * Array defining ranges and corresponding rewards.
2367
+ */
2368
+ range?: Array<Metadata.Range>;
2369
+
2370
+ /**
2371
+ * Object defining referral requirements.
2372
+ */
2373
+ referralRequirements?: Metadata.ReferralRequirements | null;
2374
+
2375
+ /**
2376
+ * Lump sum reward given to a referrer.
2377
+ */
2378
+ referrerReward?: number | null;
2379
+
2380
+ /**
2381
+ * Loyalty currency ID of the referrer reward.
2382
+ */
2383
+ referrerRewardLoyaltyCurrencyId?: string | null;
2384
+
2385
+ /**
2386
+ * Flag indicating if the post link is required.
2387
+ */
2388
+ requirePostLink?: boolean | null;
2389
+
2390
+ /**
2391
+ * Flag indicating if the rule can also reward badges per range.
2392
+ */
2393
+ rewardBadgePerRange?: boolean;
2394
+
2395
+ /**
2396
+ * Flag indicating if the reward is rewarded by batch.
2397
+ */
2398
+ rewardByBatch?: boolean | null;
2399
+
2400
+ /**
2401
+ * Flag indicating if the reward is rewarded per action.
2402
+ */
2403
+ rewardPerAction?: boolean | null;
2404
+
2405
+ /**
2406
+ * Flag indicating if rewards are given per impression.
2407
+ */
2408
+ rewardPerImpression?: boolean | null;
2409
+
2410
+ /**
2411
+ * Flag indicating if the rule should reward based on value of traded tokens
2412
+ * instead of count.
2413
+ */
2414
+ rewardPerValue?: boolean;
2415
+
2416
+ /**
2417
+ * Wallet address of the user can only be used if userId is not provided
2418
+ */
2419
+ royaltyAddress?: string;
2420
+
2421
+ /**
2422
+ * Royalty percentage of the item.
2423
+ */
2424
+ royaltyPercentage?: number;
2425
+
2426
+ /**
2427
+ * Currency associated with sales.
2428
+ */
2429
+ saleCurrency?: string;
2430
+
2431
+ /**
2432
+ * Percentage reward given for a second-level referral.
2433
+ */
2434
+ secondReferralReward?: number | null;
2435
+
2436
+ /**
2437
+ * Flag indicating if the multiplier is skipped.
2438
+ */
2439
+ skipMultiplier?: boolean | null;
2440
+
2441
+ /**
2442
+ * Object containing details of the associated smart contract.
2443
+ */
2444
+ smartContract?: Metadata.SmartContract;
2445
+
2446
+ /**
2447
+ * Array of snapshot proposals for the rule.
2448
+ */
2449
+ snapshotProposals?: Array<Metadata.SnapshotProposal> | null;
2450
+
2451
+ /**
2452
+ * Social media platform associated with the rule.
2453
+ */
2454
+ socialPlatform?:
2455
+ | 'Custom'
2456
+ | 'Discord'
2457
+ | 'EpicGames'
2458
+ | 'Instagram'
2459
+ | 'Steam'
2460
+ | 'Telegram'
2461
+ | 'TikTok'
2462
+ | 'Twitch'
2463
+ | 'X(Twitter)'
2464
+ | 'YouTube'
2465
+ | 'Google'
2466
+ | null;
2467
+
2468
+ /**
2469
+ * URL of the social platform's logo.
2470
+ */
2471
+ socialPlatformLogo?: string | null;
2472
+
2473
+ /**
2474
+ * Name of the social platform.
2475
+ */
2476
+ socialPlatformName?: string | null;
2477
+
2478
+ /**
2479
+ * ID of the Steam app.
2480
+ */
2481
+ steamAppId?: string | null;
2482
+
2483
+ /**
2484
+ * Array of streak milestones and corresponding rewards.
2485
+ */
2486
+ streakArray?: Array<Metadata.StreakArray> | null;
2487
+
2488
+ /**
2489
+ * Metadata for swap loyalty rules
2490
+ */
2491
+ swap?: Metadata.Swap;
2492
+
2493
+ /**
2494
+ * ID of the Telegram channel.
2495
+ */
2496
+ telegramChannelId?: string | null;
2497
+
2498
+ /**
2499
+ * Time delay in seconds to verify actions.
2500
+ */
2501
+ timeDelayToVerifySeconds?: string | number | null;
2502
+
2503
+ /**
2504
+ * Flag indicating if all contracts are tracked.
2505
+ */
2506
+ trackAllContracts?: boolean | null;
2507
+
2508
+ /**
2509
+ * Flag indicating if the progress is tracked. If enabled, the rule can only be
2510
+ * completed once the progress is 100%.
2511
+ */
2512
+ trackProgress?: boolean | null;
2513
+
2514
+ /**
2515
+ * URL of the associated Twitter account.
2516
+ */
2517
+ twitterAccountUrl?: string;
2518
+
2519
+ /**
2520
+ * Hashtag associated with the Twitter post.
2521
+ */
2522
+ twitterHashtag?: string;
2523
+
2524
+ /**
2525
+ * URL of the associated Twitter post.
2526
+ */
2527
+ twitterPostUrl?: string;
2528
+
2529
+ /**
2530
+ * Unique identifier of the Twitter user.
2531
+ */
2532
+ twitterUserId?: string;
2533
+
2534
+ /**
2535
+ * Twitter username of the user.
2536
+ */
2537
+ twitterUsername?: string;
2538
+
2539
+ /**
2540
+ * Minimum length of the verification text.
2541
+ */
2542
+ verificationTextMinimumLength?: number | null;
2543
+
2544
+ /**
2545
+ * Multiplier applied to rewards for verified users.
2546
+ */
2547
+ verifiedMultiplier?: number | null;
2548
+
2549
+ /**
2550
+ * Placeholder text for verification input fields.
2551
+ */
2552
+ verifyPlaceHolderText?: string | null;
2553
+
2554
+ /**
2555
+ * Type of wallet associated with the rule.
2556
+ */
2557
+ walletType?: 'evm' | 'solana' | 'imx' | 'sui' | 'ton' | 'cosmos' | 'ultra' | 'agw' | null;
2558
+
2559
+ /**
2560
+ * ID of the Youtube channel.
2561
+ */
2562
+ youtubeChannelId?: string | null;
2563
+
2564
+ /**
2565
+ * ID of the Youtube video.
2566
+ */
2567
+ youtubeVideoId?: string | null;
2568
+ }
2569
+
2570
+ export namespace Metadata {
2571
+ export interface Collection {
2572
+ /**
2573
+ * Blockchain address of the collection.
2574
+ */
2575
+ address?: string;
2576
+
2577
+ /**
2578
+ * Multiplier applied to the rewards for this collection.
2579
+ */
2580
+ multiplier?: number;
2581
+
2582
+ /**
2583
+ * Blockchain network of the collection.
2584
+ */
2585
+ network?:
2586
+ | 'abstract'
2587
+ | 'abstractTestnet'
2588
+ | 'apechain'
2589
+ | 'arbitrum'
2590
+ | 'avalanche'
2591
+ | 'avalancheFuji'
2592
+ | 'base'
2593
+ | 'baseSepolia'
2594
+ | 'berachain'
2595
+ | 'berachainArtio'
2596
+ | 'berachainBepolia'
2597
+ | 'binance'
2598
+ | 'bscTestnet'
2599
+ | 'campTestnet'
2600
+ | 'fantom'
2601
+ | 'fantomTestnet'
2602
+ | 'flowMainnet'
2603
+ | 'mainnet'
2604
+ | 'nexusTestnet'
2605
+ | 'optimism'
2606
+ | 'polygon'
2607
+ | 'polygon_mumbai'
2608
+ | 'skaleNebula'
2609
+ | 'solana'
2610
+ | 'sophon'
2611
+ | 'sophonTestnet'
2612
+ | 'sui'
2613
+ | 'superseed'
2614
+ | 'superseedSepolia'
2615
+ | 'vanar'
2616
+ | 'xai'
2617
+ | 'zksync'
2618
+ | 'coti'
2619
+ | 'cotiTestnet'
2620
+ | 'morph'
2621
+ | 'morphTestnet'
2622
+ | 'morphHolesky'
2623
+ | 'ultra'
2624
+ | 'ultraTestnet'
2625
+ | 'nitrograph'
2626
+ | 'sepolia'
2627
+ | 'optimism_sepolia'
2628
+ | 'arbitrumSepolia'
2629
+ | 'goerli'
2630
+ | 'optimism_goerli'
2631
+ | 'arbitrumGoerli'
2632
+ | 'basecamp';
2633
+ }
2634
+
2635
+ /**
2636
+ * Object containing details for the call-to-action.
2637
+ */
2638
+ export interface Cta {
2639
+ /**
2640
+ * Link for the call-to-action.
2641
+ */
2642
+ href?: string | null;
2643
+
2644
+ /**
2645
+ * Label for the call-to-action.
2646
+ */
2647
+ label?: string | null;
2648
+ }
2649
+
2650
+ export interface DiscordServersToJoin {
2651
+ /**
2652
+ * ID of the Discord server to join.
2653
+ */
2654
+ id?: string;
2655
+
2656
+ /**
2657
+ * Array of Discord channels to join.
2658
+ */
2659
+ channels?: Array<DiscordServersToJoin.Channel>;
2660
+
2661
+ /**
2662
+ * Array of roles to assign in the Discord server.
2663
+ */
2664
+ roles?: Array<DiscordServersToJoin.Role>;
2665
+ }
2666
+
2667
+ export namespace DiscordServersToJoin {
2668
+ export interface Channel {
2669
+ /**
2670
+ * ID of the Discord channel.
2671
+ */
2672
+ id?: string;
2673
+
2674
+ /**
2675
+ * Array of emojis used in the channel.
2676
+ */
2677
+ emojis?: Array<Channel.Emoji>;
2678
+
2679
+ /**
2680
+ * Phrase of text to be present in the discord message
2681
+ */
2682
+ text?: string;
2683
+ }
2684
+
2685
+ export namespace Channel {
2686
+ export interface Emoji {
2687
+ /**
2688
+ * ID of the emoji used in the channel.
2689
+ */
2690
+ id?: string;
2691
+ }
2692
+ }
2693
+
2694
+ export interface Role {
2695
+ /**
2696
+ * ID of the role in the Discord server.
2697
+ */
2698
+ id: string;
2699
+ }
2700
+ }
2701
+
2702
+ export interface DripQuestsToComplete {
2703
+ /**
2704
+ * ID of the drip quest to complete.
2705
+ */
2706
+ id: string;
2707
+ }
2708
+
2709
+ /**
2710
+ * Liquidity pool details.
2711
+ */
2712
+ export interface Liquidity {
2713
+ /**
2714
+ * Calculation type of the liquidity pool.
2715
+ */
2716
+ calculationType?: 'fixed' | 'custom';
2717
+
2718
+ /**
2719
+ * Custom function to calculate the the reward amount based on the liquidity
2720
+ * provided per day. X is the reward amount, Y is the liquidity provided per day in
2721
+ * USD.
2722
+ */
2723
+ customFunction?: string;
2724
+
2725
+ /**
2726
+ * Liquidity provided per day in USD
2727
+ */
2728
+ liquidityPerDay?: number;
2729
+
2730
+ /**
2731
+ * Blockchain network of the liquidity pool.
2732
+ */
2733
+ network?:
2734
+ | 'abstract'
2735
+ | 'abstractTestnet'
2736
+ | 'apechain'
2737
+ | 'arbitrum'
2738
+ | 'avalanche'
2739
+ | 'avalancheFuji'
2740
+ | 'base'
2741
+ | 'baseSepolia'
2742
+ | 'berachain'
2743
+ | 'berachainArtio'
2744
+ | 'berachainBepolia'
2745
+ | 'binance'
2746
+ | 'bscTestnet'
2747
+ | 'campTestnet'
2748
+ | 'fantom'
2749
+ | 'fantomTestnet'
2750
+ | 'flowMainnet'
2751
+ | 'mainnet'
2752
+ | 'nexusTestnet'
2753
+ | 'optimism'
2754
+ | 'polygon'
2755
+ | 'polygon_mumbai'
2756
+ | 'skaleNebula'
2757
+ | 'solana'
2758
+ | 'sophon'
2759
+ | 'sophonTestnet'
2760
+ | 'sui'
2761
+ | 'superseed'
2762
+ | 'superseedSepolia'
2763
+ | 'vanar'
2764
+ | 'xai'
2765
+ | 'zksync'
2766
+ | 'coti'
2767
+ | 'cotiTestnet'
2768
+ | 'morph'
2769
+ | 'morphTestnet'
2770
+ | 'morphHolesky'
2771
+ | 'ultra'
2772
+ | 'ultraTestnet'
2773
+ | 'nitrograph'
2774
+ | 'sepolia'
2775
+ | 'optimism_sepolia'
2776
+ | 'arbitrumSepolia'
2777
+ | 'goerli'
2778
+ | 'optimism_goerli'
2779
+ | 'arbitrumGoerli'
2780
+ | 'basecamp';
2781
+
2782
+ /**
2783
+ * Indicates if only in-range liquidity is rewarded.
2784
+ */
2785
+ onlyRewardInRangeLiquidity?: boolean;
2786
+
2787
+ /**
2788
+ * Array of liquidity pools associated with the rule.
2789
+ */
2790
+ pools?: Array<Liquidity.Pool>;
2791
+
2792
+ /**
2793
+ * Protocol of the liquidity pool.
2794
+ */
2795
+ protocol?: string;
2796
+ }
2797
+
2798
+ export namespace Liquidity {
2799
+ export interface Pool {
2800
+ /**
2801
+ * Unique identifier of the liquidity pool.
2802
+ */
2803
+ id: string;
2804
+ }
2805
+ }
2806
+
2807
+ export interface Range {
2808
+ /**
2809
+ * Reward amount for this range.
2810
+ */
2811
+ amount: number;
2812
+
2813
+ /**
2814
+ * End value of the range.
2815
+ */
2816
+ endRange: number;
2817
+
2818
+ /**
2819
+ * Start value of the range.
2820
+ */
2821
+ startRange: number;
2822
+
2823
+ /**
2824
+ * ID of the loyalty badge for this range.
2825
+ */
2826
+ loyaltyBadgeId?: string;
2827
+
2828
+ /**
2829
+ * Amount of the loyalty multiplier for this range.
2830
+ */
2831
+ loyaltyMultiplierAmount?: number;
2832
+ }
2833
+
2834
+ /**
2835
+ * Object defining referral requirements.
2836
+ */
2837
+ export interface ReferralRequirements {
2838
+ /**
2839
+ * Flag indicating if achieving points is required.
2840
+ */
2841
+ achievePoints?: boolean | null;
2842
+
2843
+ /**
2844
+ * Flag indicating if completing the profile is required.
2845
+ */
2846
+ completeProfile?: boolean | null;
2847
+
2848
+ /**
2849
+ * Flag indicating if connecting Discord is required.
2850
+ */
2851
+ connectDiscord?: boolean | null;
2852
+
2853
+ /**
2854
+ * Flag indicating if connecting email is required.
2855
+ */
2856
+ connectEmail?: boolean | null;
2857
+
2858
+ /**
2859
+ * Flag indicating if connecting Twitter is required.
2860
+ */
2861
+ connectTwitter?: boolean | null;
2862
+
2863
+ points?: ReferralRequirements.Points | null;
2864
+ }
2865
+
2866
+ export namespace ReferralRequirements {
2867
+ export interface Points {
2868
+ /**
2869
+ * Points required for referral.
2870
+ */
2871
+ amount?: number | null;
2872
+
2873
+ /**
2874
+ * ID of the loyalty currency for referral.
2875
+ */
2876
+ loyaltyCurrecyId?: string | null;
2877
+ }
2878
+ }
2879
+
2880
+ /**
2881
+ * Object containing details of the associated smart contract.
2882
+ */
2883
+ export interface SmartContract {
2884
+ /**
2885
+ * Mapping of addresses for the smart contract.
2886
+ */
2887
+ addressMapping?: string | null;
2888
+
2889
+ /**
2890
+ * Object containing details of the amount multiplier from the event.
2891
+ */
2892
+ amountMultiplier?: SmartContract.AmountMultiplier | null;
2893
+
2894
+ /**
2895
+ * ID of the smart contract.
2896
+ */
2897
+ contractId?: string | null;
2898
+
2899
+ /**
2900
+ * Criteria to evaluate the smart contract event.
2901
+ */
2902
+ criteria?: 'everyEvent' | 'byParameter' | null;
2903
+
2904
+ /**
2905
+ * Event emitted by the smart contract.
2906
+ */
2907
+ event?: string | null;
2908
+
2909
+ /**
2910
+ * Array of parameters for the smart contract.
2911
+ */
2912
+ params?: Array<SmartContract.Param> | null;
2913
+
2914
+ /**
2915
+ * Type of the smart contract interaction.
2916
+ */
2917
+ type?: 'function' | 'event' | null;
2918
+ }
2919
+
2920
+ export namespace SmartContract {
2921
+ /**
2922
+ * Object containing details of the amount multiplier from the event.
2923
+ */
2924
+ export interface AmountMultiplier {
2925
+ /**
2926
+ * Mapping of the value for the smart contract.
2927
+ */
2928
+ valueMapping?: string | null;
2929
+ }
2930
+
2931
+ export interface Param {
2932
+ /**
2933
+ * Condition to check for the parameter.
2934
+ */
2935
+ condition?: string | null;
2936
+
2937
+ /**
2938
+ * Name of the smart contract parameter.
2939
+ */
2940
+ name?: string | null;
2941
+
2942
+ /**
2943
+ * Value of the parameter.
2944
+ */
2945
+ value?: string | null;
2946
+ }
2947
+ }
2948
+
2949
+ export interface SnapshotProposal {
2950
+ /**
2951
+ * ID of the snapshot proposal.
2952
+ */
2953
+ id: string;
2954
+
2955
+ /**
2956
+ * Space associated with the snapshot proposal.
2957
+ */
2958
+ space: string;
2959
+ }
2960
+
2961
+ export interface StreakArray {
2962
+ /**
2963
+ * Reward amount for achieving the streak milestone.
2964
+ */
2965
+ streakAmount: number;
2966
+
2967
+ /**
2968
+ * Milestone required to achieve the streak.
2969
+ */
2970
+ streakMilestone: number;
2971
+ }
2972
+
2973
+ /**
2974
+ * Metadata for swap loyalty rules
2975
+ */
2976
+ export interface Swap {
2977
+ provider?: 'any' | 'relay' | 'lifi';
2978
+
2979
+ relayReferrerId?: string;
2980
+
2981
+ requireCrossChainSwap?: boolean;
2982
+
2983
+ swappedToChain?: 'any' | number | string;
2984
+
2985
+ swappedToTokens?: Array<Swap.SwappedToToken>;
2986
+
2987
+ tokenMode?: 'any' | 'specific';
2988
+
2989
+ trackTokenAmount?: boolean;
2990
+ }
2991
+
2992
+ export namespace Swap {
2993
+ export interface SwappedToToken {
2994
+ address: string;
2995
+
2996
+ chainId: string;
2997
+ }
2998
+ }
2999
+ }
3000
+ }
3001
+
3002
+ /**
3003
+ * Previous data of the rule before the edit
3004
+ */
3005
+ export interface PreviousData {
3006
+ /**
3007
+ * Unique identifier for the loyalty rule
3008
+ */
3009
+ id: string;
3010
+
3011
+ /**
3012
+ * Amount associated with the loyalty rule
3013
+ */
3014
+ amount: number;
3015
+
3016
+ /**
3017
+ * Timestamp when the loyalty rule was created
3018
+ */
3019
+ createdAt: string;
3020
+
3021
+ /**
3022
+ * Timestamp when the loyalty rule was deleted (if applicable)
3023
+ */
3024
+ deletedAt: string | null;
3025
+
3026
+ /**
3027
+ * Description of the loyalty rule
3028
+ */
3029
+ description: string;
3030
+
3031
+ /**
3032
+ * End time of the loyalty rule
3033
+ */
3034
+ endTime: string;
3035
+
3036
+ /**
3037
+ * Frequency of the loyalty rule
3038
+ */
3039
+ frequency: string;
3040
+
3041
+ /**
3042
+ * Name of the loyalty rule
3043
+ */
3044
+ name: string;
3045
+
3046
+ /**
3047
+ * Unique identifier for the organization
3048
+ */
3049
+ organizationId: string;
3050
+
3051
+ /**
3052
+ * Type of the reward
3053
+ */
3054
+ rewardType: 'points' | 'multiplier' | 'badge';
3055
+
3056
+ /**
3057
+ * Start time of the loyalty rule
3058
+ */
3059
+ startTime: string;
3060
+
3061
+ /**
3062
+ * Type of the loyalty rule
3063
+ */
3064
+ type: string;
3065
+
3066
+ /**
3067
+ * Timestamp when the loyalty rule was last updated
3068
+ */
3069
+ updatedAt: string;
3070
+
3071
+ /**
3072
+ * Unique identifier for the website
3073
+ */
3074
+ websiteId: string;
3075
+
3076
+ /**
3077
+ * Optional address of the collection
3078
+ */
3079
+ collectionAddress?: string;
3080
+
3081
+ /**
3082
+ * URL of the media associated with the loyalty rule
3083
+ */
3084
+ mediaUrl?: string | null;
3085
+
3086
+ /**
3087
+ * Optional metadata for the loyalty rule
3088
+ */
3089
+ metadata?: { [key: string]: PreviousData.Metadata };
3090
+ }
3091
+
3092
+ export namespace PreviousData {
3093
+ export interface Metadata {
3094
+ /**
3095
+ * Number of tokens per batch.
3096
+ */
3097
+ batchSize?: number | null;
3098
+
3099
+ /**
3100
+ * Text displayed on the action button.
3101
+ */
3102
+ buttonText?: string | null;
3103
+
3104
+ /**
3105
+ * Flag indicating if commenting is required.
3106
+ */
3107
+ checkComment?: boolean | null;
3108
+
3109
+ /**
3110
+ * Flag indicating if liking the post is required.
3111
+ */
3112
+ checkLike?: boolean | null;
3113
+
3114
+ /**
3115
+ * Flag indicating if reposting is required.
3116
+ */
3117
+ checkRepost?: boolean | null;
3118
+
3119
+ /**
3120
+ * Text to check in the Twitter post, username, or bio.
3121
+ */
3122
+ checkText?: string | null;
3123
+
3124
+ /**
3125
+ * Array of collections associated with the rule.
3126
+ */
3127
+ collection?: Array<Metadata.Collection>;
3128
+
3129
+ /**
3130
+ * Conditions for completing the profile.
3131
+ */
3132
+ completeProfileConditions?: { [key: string]: boolean } | null;
3133
+
3134
+ /**
3135
+ * Description of the external rule condition (only for external rules)
3136
+ */
3137
+ conditionDescription?: string;
3138
+
3139
+ /**
3140
+ * Object containing details for the call-to-action.
3141
+ */
3142
+ cta?: Metadata.Cta | null;
3143
+
3144
+ /**
3145
+ * API key for custom rewards integration.
3146
+ */
3147
+ customRewardsApiKey?: string;
3148
+
3149
+ /**
3150
+ * Flag indicating if the rule should use direct RPC to get the balance of tokens.
3151
+ */
3152
+ directRpc?: boolean;
3153
+
3154
+ /**
3155
+ * Array of Discord servers, channels, and roles to join.
3156
+ */
3157
+ discordServersToJoin?: Array<Metadata.DiscordServersToJoin> | null;
3158
+
3159
+ /**
3160
+ * Array of drip quests required to complete the rule.
3161
+ */
3162
+ dripQuestsToComplete?: Array<Metadata.DripQuestsToComplete> | null;
3163
+
3164
+ /**
3165
+ * Flag indicating whether joining Discord servers is required.
3166
+ */
3167
+ enableJoinDiscordServers?: boolean | null;
3168
+
3169
+ /**
3170
+ * Flag indicating whether streaks are enabled.
3171
+ */
3172
+ enableStreaks?: boolean | null;
3173
+
3174
+ /**
3175
+ * Flag indicating whether the verified multiplier is enabled.
3176
+ */
3177
+ enableVerifiedMultiplier?: boolean;
3178
+
3179
+ /**
3180
+ * Fill source of the order for the token sale
3181
+ */
3182
+ fillSource?: string;
3183
+
3184
+ /**
3185
+ * Percentage reward given to a user for their first referral.
3186
+ */
3187
+ firstReferralReward?: number | null;
3188
+
3189
+ /**
3190
+ * Flag indicating whether the fill source is included.
3191
+ */
3192
+ hasFillSource?: boolean;
3193
+
3194
+ /**
3195
+ * Indicates if the item has never been sold.
3196
+ */
3197
+ hasNeverSold?: boolean;
3198
+
3199
+ /**
3200
+ * Indicates if the full royalty has been paid for items.
3201
+ */
3202
+ hasPaidFullRoyalty?: boolean;
3203
+
3204
+ /**
3205
+ * Flag indicating if the sale currency is included.
3206
+ */
3207
+ hasSaleCurrency?: boolean;
3208
+
3209
+ /**
3210
+ * Indicates if the user has a verified Twitter account.
3211
+ */
3212
+ hasVerifiedTwitter?: boolean;
3213
+
3214
+ /**
3215
+ * URL of the image associated with the rule.
3216
+ */
3217
+ imageUrl?: string | null;
3218
+
3219
+ /**
3220
+ * If enabled, the first transaction done on the platform will complete this rule
3221
+ */
3222
+ isCheckInOnEveryTxn?: boolean;
3223
+
3224
+ /**
3225
+ * Indicates if the multiplier has been applied to rewards.
3226
+ */
3227
+ isMultiplierApplied?: boolean;
3228
+
3229
+ /**
3230
+ * Flag indicating if the rule is restricted to new users.
3231
+ */
3232
+ isRestrictedToNewUsers?: boolean;
3233
+
3234
+ /**
3235
+ * Flag indicating if rewards are applied retroactively.
3236
+ */
3237
+ isRetroactive?: boolean | null;
3238
+
3239
+ /**
3240
+ * Flag indicating if the token hold multiplier is applied.
3241
+ */
3242
+ isTokenHoldMultiplier?: boolean;
3243
+
3244
+ /**
3245
+ * Optional link associated with the metadata.
3246
+ */
3247
+ link?: string | null;
3248
+
3249
+ /**
3250
+ * Liquidity pool details.
3251
+ */
3252
+ liquidity?: Metadata.Liquidity;
3253
+
3254
+ /**
3255
+ * Maximum quantity constraint for token holding.
3256
+ */
3257
+ maxQty?: number | null;
3258
+
3259
+ /**
3260
+ * Minimum quantity constraint for token holding.
3261
+ */
3262
+ minQty?: number | null;
3263
+
3264
+ /**
3265
+ * Array of loyalty currency IDs used for multipliers.
3266
+ */
3267
+ multiplierLoyaltyCurrencyIds?: Array<string> | null;
3268
+
3269
+ /**
3270
+ * Flag indicating whether to include only known users.
3271
+ */
3272
+ onlyKnownUsers?: boolean;
3273
+
3274
+ /**
3275
+ * Flag indicating whether to include only native tokens.
3276
+ */
3277
+ onlyNative?: boolean;
3278
+
3279
+ /**
3280
+ * Flag indicating whether to include only non-listed items.
3281
+ */
3282
+ onlyNonListed?: boolean;
3283
+
3284
+ /**
3285
+ * Indicates if only existing users are rewarded.
3286
+ */
3287
+ onlyRewardExistingUser?: boolean;
3288
+
3289
+ /**
3290
+ * give points for only one token ownership per contract
3291
+ */
3292
+ onlyRewardSingleTokenOwnership?: boolean | null;
3293
+
3294
+ /**
3295
+ * Promotional code associated with the rule.
3296
+ */
3297
+ promoCode?: string;
3298
+
3299
+ /**
3300
+ * URL of the CSV file containing promo codes.
3301
+ */
3302
+ promoCodeCsvUrl?: string;
3303
+
3304
+ /**
3305
+ * Numbers of the promotional code to be generated.
3306
+ */
3307
+ promoCodeLength?: number | null;
3308
+
3309
+ /**
3310
+ * Type of the promotional code.
3311
+ */
3312
+ promoCodeType?: 'code' | 'csv' | 'generate';
3313
+
3314
+ /**
3315
+ * Array defining ranges and corresponding rewards.
3316
+ */
3317
+ range?: Array<Metadata.Range>;
3318
+
3319
+ /**
3320
+ * Object defining referral requirements.
3321
+ */
3322
+ referralRequirements?: Metadata.ReferralRequirements | null;
3323
+
3324
+ /**
3325
+ * Lump sum reward given to a referrer.
3326
+ */
3327
+ referrerReward?: number | null;
3328
+
3329
+ /**
3330
+ * Loyalty currency ID of the referrer reward.
3331
+ */
3332
+ referrerRewardLoyaltyCurrencyId?: string | null;
3333
+
3334
+ /**
3335
+ * Flag indicating if the post link is required.
3336
+ */
3337
+ requirePostLink?: boolean | null;
3338
+
3339
+ /**
3340
+ * Flag indicating if the rule can also reward badges per range.
3341
+ */
3342
+ rewardBadgePerRange?: boolean;
3343
+
3344
+ /**
3345
+ * Flag indicating if the reward is rewarded by batch.
3346
+ */
3347
+ rewardByBatch?: boolean | null;
3348
+
3349
+ /**
3350
+ * Flag indicating if the reward is rewarded per action.
3351
+ */
3352
+ rewardPerAction?: boolean | null;
3353
+
3354
+ /**
3355
+ * Flag indicating if rewards are given per impression.
3356
+ */
3357
+ rewardPerImpression?: boolean | null;
3358
+
3359
+ /**
3360
+ * Flag indicating if the rule should reward based on value of traded tokens
3361
+ * instead of count.
3362
+ */
3363
+ rewardPerValue?: boolean;
3364
+
3365
+ /**
3366
+ * Wallet address of the user can only be used if userId is not provided
3367
+ */
3368
+ royaltyAddress?: string;
3369
+
3370
+ /**
3371
+ * Royalty percentage of the item.
3372
+ */
3373
+ royaltyPercentage?: number;
3374
+
3375
+ /**
3376
+ * Currency associated with sales.
3377
+ */
3378
+ saleCurrency?: string;
3379
+
3380
+ /**
3381
+ * Percentage reward given for a second-level referral.
3382
+ */
3383
+ secondReferralReward?: number | null;
3384
+
3385
+ /**
3386
+ * Flag indicating if the multiplier is skipped.
3387
+ */
3388
+ skipMultiplier?: boolean | null;
3389
+
3390
+ /**
3391
+ * Object containing details of the associated smart contract.
3392
+ */
3393
+ smartContract?: Metadata.SmartContract;
3394
+
3395
+ /**
3396
+ * Array of snapshot proposals for the rule.
3397
+ */
3398
+ snapshotProposals?: Array<Metadata.SnapshotProposal> | null;
3399
+
3400
+ /**
3401
+ * Social media platform associated with the rule.
3402
+ */
3403
+ socialPlatform?:
3404
+ | 'Custom'
3405
+ | 'Discord'
3406
+ | 'EpicGames'
3407
+ | 'Instagram'
3408
+ | 'Steam'
3409
+ | 'Telegram'
3410
+ | 'TikTok'
3411
+ | 'Twitch'
3412
+ | 'X(Twitter)'
3413
+ | 'YouTube'
3414
+ | 'Google'
3415
+ | null;
3416
+
3417
+ /**
3418
+ * URL of the social platform's logo.
3419
+ */
3420
+ socialPlatformLogo?: string | null;
3421
+
3422
+ /**
3423
+ * Name of the social platform.
3424
+ */
3425
+ socialPlatformName?: string | null;
3426
+
3427
+ /**
3428
+ * ID of the Steam app.
3429
+ */
3430
+ steamAppId?: string | null;
3431
+
3432
+ /**
3433
+ * Array of streak milestones and corresponding rewards.
3434
+ */
3435
+ streakArray?: Array<Metadata.StreakArray> | null;
3436
+
3437
+ /**
3438
+ * Metadata for swap loyalty rules
3439
+ */
3440
+ swap?: Metadata.Swap;
3441
+
3442
+ /**
3443
+ * ID of the Telegram channel.
3444
+ */
3445
+ telegramChannelId?: string | null;
3446
+
3447
+ /**
3448
+ * Time delay in seconds to verify actions.
3449
+ */
3450
+ timeDelayToVerifySeconds?: string | number | null;
3451
+
3452
+ /**
3453
+ * Flag indicating if all contracts are tracked.
3454
+ */
3455
+ trackAllContracts?: boolean | null;
3456
+
3457
+ /**
3458
+ * Flag indicating if the progress is tracked. If enabled, the rule can only be
3459
+ * completed once the progress is 100%.
3460
+ */
3461
+ trackProgress?: boolean | null;
3462
+
3463
+ /**
3464
+ * URL of the associated Twitter account.
3465
+ */
3466
+ twitterAccountUrl?: string;
3467
+
3468
+ /**
3469
+ * Hashtag associated with the Twitter post.
3470
+ */
3471
+ twitterHashtag?: string;
3472
+
3473
+ /**
3474
+ * URL of the associated Twitter post.
3475
+ */
3476
+ twitterPostUrl?: string;
3477
+
3478
+ /**
3479
+ * Unique identifier of the Twitter user.
3480
+ */
3481
+ twitterUserId?: string;
3482
+
3483
+ /**
3484
+ * Twitter username of the user.
3485
+ */
3486
+ twitterUsername?: string;
3487
+
3488
+ /**
3489
+ * Minimum length of the verification text.
3490
+ */
3491
+ verificationTextMinimumLength?: number | null;
3492
+
3493
+ /**
3494
+ * Multiplier applied to rewards for verified users.
3495
+ */
3496
+ verifiedMultiplier?: number | null;
3497
+
3498
+ /**
3499
+ * Placeholder text for verification input fields.
3500
+ */
3501
+ verifyPlaceHolderText?: string | null;
3502
+
3503
+ /**
3504
+ * Type of wallet associated with the rule.
3505
+ */
3506
+ walletType?: 'evm' | 'solana' | 'imx' | 'sui' | 'ton' | 'cosmos' | 'ultra' | 'agw' | null;
3507
+
3508
+ /**
3509
+ * ID of the Youtube channel.
3510
+ */
3511
+ youtubeChannelId?: string | null;
3512
+
3513
+ /**
3514
+ * ID of the Youtube video.
3515
+ */
3516
+ youtubeVideoId?: string | null;
3517
+ }
3518
+
3519
+ export namespace Metadata {
3520
+ export interface Collection {
3521
+ /**
3522
+ * Blockchain address of the collection.
3523
+ */
3524
+ address?: string;
3525
+
3526
+ /**
3527
+ * Multiplier applied to the rewards for this collection.
3528
+ */
3529
+ multiplier?: number;
3530
+
3531
+ /**
3532
+ * Blockchain network of the collection.
3533
+ */
3534
+ network?:
3535
+ | 'abstract'
3536
+ | 'abstractTestnet'
3537
+ | 'apechain'
3538
+ | 'arbitrum'
3539
+ | 'avalanche'
3540
+ | 'avalancheFuji'
3541
+ | 'base'
3542
+ | 'baseSepolia'
3543
+ | 'berachain'
3544
+ | 'berachainArtio'
3545
+ | 'berachainBepolia'
3546
+ | 'binance'
3547
+ | 'bscTestnet'
3548
+ | 'campTestnet'
3549
+ | 'fantom'
3550
+ | 'fantomTestnet'
3551
+ | 'flowMainnet'
3552
+ | 'mainnet'
3553
+ | 'nexusTestnet'
3554
+ | 'optimism'
3555
+ | 'polygon'
3556
+ | 'polygon_mumbai'
3557
+ | 'skaleNebula'
3558
+ | 'solana'
3559
+ | 'sophon'
3560
+ | 'sophonTestnet'
3561
+ | 'sui'
3562
+ | 'superseed'
3563
+ | 'superseedSepolia'
3564
+ | 'vanar'
3565
+ | 'xai'
3566
+ | 'zksync'
3567
+ | 'coti'
3568
+ | 'cotiTestnet'
3569
+ | 'morph'
3570
+ | 'morphTestnet'
3571
+ | 'morphHolesky'
3572
+ | 'ultra'
3573
+ | 'ultraTestnet'
3574
+ | 'nitrograph'
3575
+ | 'sepolia'
3576
+ | 'optimism_sepolia'
3577
+ | 'arbitrumSepolia'
3578
+ | 'goerli'
3579
+ | 'optimism_goerli'
3580
+ | 'arbitrumGoerli'
3581
+ | 'basecamp';
3582
+ }
3583
+
3584
+ /**
3585
+ * Object containing details for the call-to-action.
3586
+ */
3587
+ export interface Cta {
3588
+ /**
3589
+ * Link for the call-to-action.
3590
+ */
3591
+ href?: string | null;
3592
+
3593
+ /**
3594
+ * Label for the call-to-action.
3595
+ */
3596
+ label?: string | null;
3597
+ }
3598
+
3599
+ export interface DiscordServersToJoin {
3600
+ /**
3601
+ * ID of the Discord server to join.
3602
+ */
3603
+ id?: string;
3604
+
3605
+ /**
3606
+ * Array of Discord channels to join.
3607
+ */
3608
+ channels?: Array<DiscordServersToJoin.Channel>;
3609
+
3610
+ /**
3611
+ * Array of roles to assign in the Discord server.
3612
+ */
3613
+ roles?: Array<DiscordServersToJoin.Role>;
3614
+ }
3615
+
3616
+ export namespace DiscordServersToJoin {
3617
+ export interface Channel {
3618
+ /**
3619
+ * ID of the Discord channel.
3620
+ */
3621
+ id?: string;
3622
+
3623
+ /**
3624
+ * Array of emojis used in the channel.
3625
+ */
3626
+ emojis?: Array<Channel.Emoji>;
3627
+
3628
+ /**
3629
+ * Phrase of text to be present in the discord message
3630
+ */
3631
+ text?: string;
3632
+ }
3633
+
3634
+ export namespace Channel {
3635
+ export interface Emoji {
3636
+ /**
3637
+ * ID of the emoji used in the channel.
3638
+ */
3639
+ id?: string;
3640
+ }
3641
+ }
3642
+
3643
+ export interface Role {
3644
+ /**
3645
+ * ID of the role in the Discord server.
3646
+ */
3647
+ id: string;
3648
+ }
3649
+ }
3650
+
3651
+ export interface DripQuestsToComplete {
3652
+ /**
3653
+ * ID of the drip quest to complete.
3654
+ */
3655
+ id: string;
3656
+ }
3657
+
3658
+ /**
3659
+ * Liquidity pool details.
3660
+ */
3661
+ export interface Liquidity {
3662
+ /**
3663
+ * Calculation type of the liquidity pool.
3664
+ */
3665
+ calculationType?: 'fixed' | 'custom';
3666
+
3667
+ /**
3668
+ * Custom function to calculate the the reward amount based on the liquidity
3669
+ * provided per day. X is the reward amount, Y is the liquidity provided per day in
3670
+ * USD.
3671
+ */
3672
+ customFunction?: string;
3673
+
3674
+ /**
3675
+ * Liquidity provided per day in USD
3676
+ */
3677
+ liquidityPerDay?: number;
3678
+
3679
+ /**
3680
+ * Blockchain network of the liquidity pool.
3681
+ */
3682
+ network?:
3683
+ | 'abstract'
3684
+ | 'abstractTestnet'
3685
+ | 'apechain'
3686
+ | 'arbitrum'
3687
+ | 'avalanche'
3688
+ | 'avalancheFuji'
3689
+ | 'base'
3690
+ | 'baseSepolia'
3691
+ | 'berachain'
3692
+ | 'berachainArtio'
3693
+ | 'berachainBepolia'
3694
+ | 'binance'
3695
+ | 'bscTestnet'
3696
+ | 'campTestnet'
3697
+ | 'fantom'
3698
+ | 'fantomTestnet'
3699
+ | 'flowMainnet'
3700
+ | 'mainnet'
3701
+ | 'nexusTestnet'
3702
+ | 'optimism'
3703
+ | 'polygon'
3704
+ | 'polygon_mumbai'
3705
+ | 'skaleNebula'
3706
+ | 'solana'
3707
+ | 'sophon'
3708
+ | 'sophonTestnet'
3709
+ | 'sui'
3710
+ | 'superseed'
3711
+ | 'superseedSepolia'
3712
+ | 'vanar'
3713
+ | 'xai'
3714
+ | 'zksync'
3715
+ | 'coti'
3716
+ | 'cotiTestnet'
3717
+ | 'morph'
3718
+ | 'morphTestnet'
3719
+ | 'morphHolesky'
3720
+ | 'ultra'
3721
+ | 'ultraTestnet'
3722
+ | 'nitrograph'
3723
+ | 'sepolia'
3724
+ | 'optimism_sepolia'
3725
+ | 'arbitrumSepolia'
3726
+ | 'goerli'
3727
+ | 'optimism_goerli'
3728
+ | 'arbitrumGoerli'
3729
+ | 'basecamp';
3730
+
3731
+ /**
3732
+ * Indicates if only in-range liquidity is rewarded.
3733
+ */
3734
+ onlyRewardInRangeLiquidity?: boolean;
3735
+
3736
+ /**
3737
+ * Array of liquidity pools associated with the rule.
3738
+ */
3739
+ pools?: Array<Liquidity.Pool>;
3740
+
3741
+ /**
3742
+ * Protocol of the liquidity pool.
3743
+ */
3744
+ protocol?: string;
3745
+ }
3746
+
3747
+ export namespace Liquidity {
3748
+ export interface Pool {
3749
+ /**
3750
+ * Unique identifier of the liquidity pool.
3751
+ */
3752
+ id: string;
3753
+ }
3754
+ }
3755
+
3756
+ export interface Range {
3757
+ /**
3758
+ * Reward amount for this range.
3759
+ */
3760
+ amount: number;
3761
+
3762
+ /**
3763
+ * End value of the range.
3764
+ */
3765
+ endRange: number;
3766
+
3767
+ /**
3768
+ * Start value of the range.
3769
+ */
3770
+ startRange: number;
3771
+
3772
+ /**
3773
+ * ID of the loyalty badge for this range.
3774
+ */
3775
+ loyaltyBadgeId?: string;
3776
+
3777
+ /**
3778
+ * Amount of the loyalty multiplier for this range.
3779
+ */
3780
+ loyaltyMultiplierAmount?: number;
3781
+ }
3782
+
3783
+ /**
3784
+ * Object defining referral requirements.
3785
+ */
3786
+ export interface ReferralRequirements {
3787
+ /**
3788
+ * Flag indicating if achieving points is required.
3789
+ */
3790
+ achievePoints?: boolean | null;
3791
+
3792
+ /**
3793
+ * Flag indicating if completing the profile is required.
3794
+ */
3795
+ completeProfile?: boolean | null;
3796
+
3797
+ /**
3798
+ * Flag indicating if connecting Discord is required.
3799
+ */
3800
+ connectDiscord?: boolean | null;
3801
+
3802
+ /**
3803
+ * Flag indicating if connecting email is required.
3804
+ */
3805
+ connectEmail?: boolean | null;
3806
+
3807
+ /**
3808
+ * Flag indicating if connecting Twitter is required.
3809
+ */
3810
+ connectTwitter?: boolean | null;
3811
+
3812
+ points?: ReferralRequirements.Points | null;
3813
+ }
3814
+
3815
+ export namespace ReferralRequirements {
3816
+ export interface Points {
3817
+ /**
3818
+ * Points required for referral.
3819
+ */
3820
+ amount?: number | null;
3821
+
3822
+ /**
3823
+ * ID of the loyalty currency for referral.
3824
+ */
3825
+ loyaltyCurrecyId?: string | null;
3826
+ }
3827
+ }
3828
+
3829
+ /**
3830
+ * Object containing details of the associated smart contract.
3831
+ */
3832
+ export interface SmartContract {
3833
+ /**
3834
+ * Mapping of addresses for the smart contract.
3835
+ */
3836
+ addressMapping?: string | null;
3837
+
3838
+ /**
3839
+ * Object containing details of the amount multiplier from the event.
3840
+ */
3841
+ amountMultiplier?: SmartContract.AmountMultiplier | null;
3842
+
3843
+ /**
3844
+ * ID of the smart contract.
3845
+ */
3846
+ contractId?: string | null;
3847
+
3848
+ /**
3849
+ * Criteria to evaluate the smart contract event.
3850
+ */
3851
+ criteria?: 'everyEvent' | 'byParameter' | null;
3852
+
3853
+ /**
3854
+ * Event emitted by the smart contract.
3855
+ */
3856
+ event?: string | null;
3857
+
3858
+ /**
3859
+ * Array of parameters for the smart contract.
3860
+ */
3861
+ params?: Array<SmartContract.Param> | null;
3862
+
3863
+ /**
3864
+ * Type of the smart contract interaction.
3865
+ */
3866
+ type?: 'function' | 'event' | null;
3867
+ }
3868
+
3869
+ export namespace SmartContract {
3870
+ /**
3871
+ * Object containing details of the amount multiplier from the event.
3872
+ */
3873
+ export interface AmountMultiplier {
3874
+ /**
3875
+ * Mapping of the value for the smart contract.
3876
+ */
3877
+ valueMapping?: string | null;
3878
+ }
3879
+
3880
+ export interface Param {
3881
+ /**
3882
+ * Condition to check for the parameter.
3883
+ */
3884
+ condition?: string | null;
3885
+
3886
+ /**
3887
+ * Name of the smart contract parameter.
3888
+ */
3889
+ name?: string | null;
3890
+
3891
+ /**
3892
+ * Value of the parameter.
3893
+ */
3894
+ value?: string | null;
3895
+ }
3896
+ }
3897
+
3898
+ export interface SnapshotProposal {
3899
+ /**
3900
+ * ID of the snapshot proposal.
3901
+ */
3902
+ id: string;
3903
+
3904
+ /**
3905
+ * Space associated with the snapshot proposal.
3906
+ */
3907
+ space: string;
3908
+ }
3909
+
3910
+ export interface StreakArray {
3911
+ /**
3912
+ * Reward amount for achieving the streak milestone.
3913
+ */
3914
+ streakAmount: number;
3915
+
3916
+ /**
3917
+ * Milestone required to achieve the streak.
3918
+ */
3919
+ streakMilestone: number;
3920
+ }
3921
+
3922
+ /**
3923
+ * Metadata for swap loyalty rules
3924
+ */
3925
+ export interface Swap {
3926
+ provider?: 'any' | 'relay' | 'lifi';
3927
+
3928
+ relayReferrerId?: string;
3929
+
3930
+ requireCrossChainSwap?: boolean;
3931
+
3932
+ swappedToChain?: 'any' | number | string;
3933
+
3934
+ swappedToTokens?: Array<Swap.SwappedToToken>;
3935
+
3936
+ tokenMode?: 'any' | 'specific';
3937
+
3938
+ trackTokenAmount?: boolean;
3939
+ }
3940
+
3941
+ export namespace Swap {
3942
+ export interface SwappedToToken {
3943
+ address: string;
3944
+
3945
+ chainId: string;
3946
+ }
3947
+ }
3948
+ }
3949
+ }
3950
+ }
3951
+
3952
+ export interface RuleEditListParams {
3953
+ /**
3954
+ * ID of the loyalty rule
3955
+ */
3956
+ loyaltyRuleId: boolean;
3957
+
3958
+ /**
3959
+ * Maximum number of edits to return
3960
+ */
3961
+ limit?: number;
3962
+
3963
+ /**
3964
+ * Unique identifier for the organization to filter by
3965
+ */
3966
+ organizationId?: string;
3967
+
3968
+ /**
3969
+ * Pagination cursor to start after a specific rule edit ID
3970
+ */
3971
+ startingAfter?: string;
3972
+
3973
+ /**
3974
+ * Unique identifier for the website to filter by
3975
+ */
3976
+ websiteId?: string;
3977
+ }
3978
+
3979
+ export interface RuleEditRestoreParams {}
3980
+
3981
+ export declare namespace RuleEdits {
3982
+ export {
3983
+ type RuleEditListResponse as RuleEditListResponse,
3984
+ type RuleEditRestoreResponse as RuleEditRestoreResponse,
3985
+ type RuleEditListParams as RuleEditListParams,
3986
+ type RuleEditRestoreParams as RuleEditRestoreParams,
3987
+ };
3988
+ }