@snagsolutions/sdk 0.1.0-alpha.14 → 0.1.0-alpha.16

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 (352) hide show
  1. package/CHANGELOG.md +33 -0
  2. package/README.md +19 -13
  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.map +1 -1
  7. package/core.js +4 -1
  8. package/core.js.map +1 -1
  9. package/core.mjs +5 -2
  10. package/core.mjs.map +1 -1
  11. package/index.d.mts +17 -11
  12. package/index.d.ts +17 -11
  13. package/index.d.ts.map +1 -1
  14. package/index.js +14 -8
  15. package/index.js.map +1 -1
  16. package/index.mjs +15 -9
  17. package/index.mjs.map +1 -1
  18. package/package.json +8 -29
  19. package/resources/assets.d.ts +50 -0
  20. package/resources/assets.d.ts.map +1 -0
  21. package/resources/assets.js +17 -0
  22. package/resources/assets.js.map +1 -0
  23. package/resources/assets.mjs +13 -0
  24. package/resources/assets.mjs.map +1 -0
  25. package/resources/auctions.d.ts +134 -0
  26. package/resources/auctions.d.ts.map +1 -0
  27. package/resources/{auction-bids.js → auctions.js} +12 -6
  28. package/resources/auctions.js.map +1 -0
  29. package/resources/{auction-bids.mjs → auctions.mjs} +10 -4
  30. package/resources/auctions.mjs.map +1 -0
  31. package/resources/auth.d.ts +40 -0
  32. package/resources/auth.d.ts.map +1 -0
  33. package/resources/auth.js +16 -0
  34. package/resources/auth.js.map +1 -0
  35. package/resources/auth.mjs +12 -0
  36. package/resources/auth.mjs.map +1 -0
  37. package/resources/index.d.ts +7 -5
  38. package/resources/index.d.ts.map +1 -1
  39. package/resources/index.js +11 -7
  40. package/resources/index.js.map +1 -1
  41. package/resources/index.mjs +7 -5
  42. package/resources/index.mjs.map +1 -1
  43. package/resources/loyalty/accounts.d.ts +190 -0
  44. package/resources/loyalty/accounts.d.ts.map +1 -1
  45. package/resources/loyalty/accounts.js +15 -0
  46. package/resources/loyalty/accounts.js.map +1 -1
  47. package/resources/loyalty/accounts.mjs +15 -0
  48. package/resources/loyalty/accounts.mjs.map +1 -1
  49. package/resources/loyalty/badges.d.ts +4 -0
  50. package/resources/loyalty/badges.d.ts.map +1 -1
  51. package/resources/loyalty/currencies.d.ts +6 -0
  52. package/resources/loyalty/currencies.d.ts.map +1 -1
  53. package/resources/loyalty/index.d.ts +8 -5
  54. package/resources/loyalty/index.d.ts.map +1 -1
  55. package/resources/loyalty/index.js +9 -3
  56. package/resources/loyalty/index.js.map +1 -1
  57. package/resources/loyalty/index.mjs +5 -2
  58. package/resources/loyalty/index.mjs.map +1 -1
  59. package/resources/loyalty/loyalty.d.ts +29 -17
  60. package/resources/loyalty/loyalty.d.ts.map +1 -1
  61. package/resources/loyalty/loyalty.js +24 -12
  62. package/resources/loyalty/loyalty.js.map +1 -1
  63. package/resources/loyalty/loyalty.mjs +25 -13
  64. package/resources/loyalty/loyalty.mjs.map +1 -1
  65. package/resources/loyalty/multipliers.d.ts +37 -6
  66. package/resources/loyalty/multipliers.d.ts.map +1 -1
  67. package/resources/loyalty/multipliers.js +7 -1
  68. package/resources/loyalty/multipliers.js.map +1 -1
  69. package/resources/loyalty/multipliers.mjs +7 -1
  70. package/resources/loyalty/multipliers.mjs.map +1 -1
  71. package/resources/loyalty/{transaction-entries/questions-responses.d.ts → questions-responses.d.ts} +2 -2
  72. package/resources/loyalty/questions-responses.d.ts.map +1 -0
  73. package/resources/loyalty/{transaction-entries/questions-responses.js → questions-responses.js} +2 -2
  74. package/resources/loyalty/questions-responses.js.map +1 -0
  75. package/resources/loyalty/{transaction-entries/questions-responses.mjs → questions-responses.mjs} +2 -2
  76. package/resources/loyalty/questions-responses.mjs.map +1 -0
  77. package/resources/loyalty/{transaction-entries/questions.d.ts → questions.d.ts} +2 -2
  78. package/resources/loyalty/questions.d.ts.map +1 -0
  79. package/resources/loyalty/{transaction-entries/questions.js → questions.js} +1 -1
  80. package/resources/loyalty/questions.js.map +1 -0
  81. package/resources/loyalty/{transaction-entries/questions.mjs → questions.mjs} +1 -1
  82. package/resources/loyalty/questions.mjs.map +1 -0
  83. package/resources/loyalty/rule-edits.d.ts +6 -6
  84. package/resources/loyalty/rule-edits.d.ts.map +1 -1
  85. package/resources/loyalty/rule-edits.js +1 -1
  86. package/resources/loyalty/rule-edits.js.map +1 -1
  87. package/resources/loyalty/rule-edits.mjs +1 -1
  88. package/resources/loyalty/rule-edits.mjs.map +1 -1
  89. package/resources/loyalty/rule-groups.d.ts +559 -0
  90. package/resources/loyalty/rule-groups.d.ts.map +1 -0
  91. package/resources/loyalty/rule-groups.js +16 -0
  92. package/resources/loyalty/rule-groups.js.map +1 -0
  93. package/resources/loyalty/rule-groups.mjs +12 -0
  94. package/resources/loyalty/rule-groups.mjs.map +1 -0
  95. package/resources/loyalty/rules.d.ts +144 -23
  96. package/resources/loyalty/rules.d.ts.map +1 -1
  97. package/resources/loyalty/rules.js +1 -1
  98. package/resources/loyalty/rules.js.map +1 -1
  99. package/resources/loyalty/rules.mjs +1 -1
  100. package/resources/loyalty/rules.mjs.map +1 -1
  101. package/resources/loyalty/transactions.d.ts +248 -0
  102. package/resources/loyalty/transactions.d.ts.map +1 -0
  103. package/resources/loyalty/transactions.js +22 -0
  104. package/resources/loyalty/transactions.js.map +1 -0
  105. package/resources/loyalty/transactions.mjs +18 -0
  106. package/resources/loyalty/transactions.mjs.map +1 -0
  107. package/resources/loyalty.d.ts +2 -0
  108. package/resources/loyalty.d.ts.map +1 -0
  109. package/resources/loyalty.js +19 -0
  110. package/resources/loyalty.js.map +1 -0
  111. package/resources/loyalty.mjs +3 -0
  112. package/resources/loyalty.mjs.map +1 -0
  113. package/resources/{assets/minting.d.ts → minting.d.ts} +10 -10
  114. package/resources/minting.d.ts.map +1 -0
  115. package/resources/{assets/minting.js → minting.js} +2 -2
  116. package/resources/minting.js.map +1 -0
  117. package/resources/{assets/minting.mjs → minting.mjs} +2 -2
  118. package/resources/minting.mjs.map +1 -0
  119. package/resources/referral/index.d.ts +3 -0
  120. package/resources/referral/index.d.ts.map +1 -0
  121. package/resources/referral/index.js.map +1 -0
  122. package/resources/{assets/referral → referral}/index.mjs +1 -1
  123. package/resources/referral/index.mjs.map +1 -0
  124. package/resources/referral/referral.d.ts +31 -0
  125. package/resources/referral/referral.d.ts.map +1 -0
  126. package/resources/{assets/referral → referral}/referral.js +4 -4
  127. package/resources/referral/referral.js.map +1 -0
  128. package/resources/{assets/referral → referral}/referral.mjs +5 -5
  129. package/resources/referral/referral.mjs.map +1 -0
  130. package/resources/{assets/referral → referral}/users.d.ts +11 -11
  131. package/resources/referral/users.d.ts.map +1 -0
  132. package/resources/{assets/referral → referral}/users.js +3 -3
  133. package/resources/referral/users.js.map +1 -0
  134. package/resources/{assets/referral → referral}/users.mjs +3 -3
  135. package/resources/referral/users.mjs.map +1 -0
  136. package/resources/referral.d.ts +2 -0
  137. package/resources/referral.d.ts.map +1 -0
  138. package/resources/referral.js +19 -0
  139. package/resources/referral.js.map +1 -0
  140. package/resources/referral.mjs +3 -0
  141. package/resources/referral.mjs.map +1 -0
  142. package/resources/users/index.d.ts +2 -3
  143. package/resources/users/index.d.ts.map +1 -1
  144. package/resources/users/index.js +1 -3
  145. package/resources/users/index.js.map +1 -1
  146. package/resources/users/index.mjs +1 -2
  147. package/resources/users/index.mjs.map +1 -1
  148. package/resources/users/metadatas.d.ts +17 -7
  149. package/resources/users/metadatas.d.ts.map +1 -1
  150. package/resources/users/metadatas.js +2 -2
  151. package/resources/users/metadatas.js.map +1 -1
  152. package/resources/users/metadatas.mjs +2 -2
  153. package/resources/users/metadatas.mjs.map +1 -1
  154. package/resources/users/users.d.ts +296 -6
  155. package/resources/users/users.d.ts.map +1 -1
  156. package/resources/users/users.js +25 -4
  157. package/resources/users/users.js.map +1 -1
  158. package/resources/users/users.mjs +25 -4
  159. package/resources/users/users.mjs.map +1 -1
  160. package/resources/users.d.ts +2 -0
  161. package/resources/users.d.ts.map +1 -0
  162. package/resources/users.js +19 -0
  163. package/resources/users.js.map +1 -0
  164. package/resources/users.mjs +3 -0
  165. package/resources/users.mjs.map +1 -0
  166. package/resources/websites/index.d.ts +4 -0
  167. package/resources/websites/index.d.ts.map +1 -0
  168. package/resources/websites/index.js +11 -0
  169. package/resources/websites/index.js.map +1 -0
  170. package/resources/{assets → websites}/index.mjs +1 -4
  171. package/resources/websites/index.mjs.map +1 -0
  172. package/resources/websites/website-collections.d.ts +73 -0
  173. package/resources/websites/website-collections.d.ts.map +1 -0
  174. package/resources/{assets → websites}/website-collections.js +2 -2
  175. package/resources/websites/website-collections.js.map +1 -0
  176. package/resources/{assets → websites}/website-collections.mjs +2 -2
  177. package/resources/websites/website-collections.mjs.map +1 -0
  178. package/resources/{assets → websites}/website-user-roles.d.ts +28 -28
  179. package/resources/websites/website-user-roles.d.ts.map +1 -0
  180. package/resources/{assets → websites}/website-user-roles.js +7 -7
  181. package/resources/websites/website-user-roles.js.map +1 -0
  182. package/resources/{assets → websites}/website-user-roles.mjs +7 -7
  183. package/resources/websites/website-user-roles.mjs.map +1 -0
  184. package/resources/websites/websites.d.ts +211 -0
  185. package/resources/websites/websites.d.ts.map +1 -0
  186. package/resources/{assets/assets.js → websites/websites.js} +14 -27
  187. package/resources/websites/websites.js.map +1 -0
  188. package/resources/websites/websites.mjs +29 -0
  189. package/resources/websites/websites.mjs.map +1 -0
  190. package/resources/websites.d.ts +1 -202
  191. package/resources/websites.d.ts.map +1 -1
  192. package/resources/websites.js +15 -18
  193. package/resources/websites.js.map +1 -1
  194. package/resources/websites.mjs +1 -16
  195. package/resources/websites.mjs.map +1 -1
  196. package/resources.d.ts +2 -0
  197. package/resources.d.ts.map +1 -0
  198. package/resources.js +18 -0
  199. package/resources.js.map +1 -0
  200. package/resources.mjs +2 -0
  201. package/resources.mjs.map +1 -0
  202. package/src/_shims/index.d.ts +2 -0
  203. package/src/_shims/index.js +5 -1
  204. package/src/_shims/index.mjs +5 -1
  205. package/src/core.ts +8 -3
  206. package/src/index.ts +66 -22
  207. package/src/resources/assets.ts +77 -0
  208. package/src/resources/auctions.ts +209 -0
  209. package/src/resources/auth.ts +69 -0
  210. package/src/resources/index.ts +21 -10
  211. package/src/resources/loyalty/accounts.ts +250 -1
  212. package/src/resources/loyalty/badges.ts +5 -0
  213. package/src/resources/loyalty/currencies.ts +6 -0
  214. package/src/resources/loyalty/index.ts +40 -14
  215. package/src/resources/loyalty/loyalty.ts +129 -69
  216. package/src/resources/loyalty/multipliers.ts +44 -8
  217. package/src/resources/loyalty/{transaction-entries/questions-responses.ts → questions-responses.ts} +3 -3
  218. package/src/resources/loyalty/{transaction-entries/questions.ts → questions.ts} +2 -2
  219. package/src/resources/loyalty/rule-edits.ts +7 -10
  220. package/src/resources/loyalty/rule-groups.ts +818 -0
  221. package/src/resources/loyalty/rules.ts +406 -192
  222. package/src/resources/loyalty/transactions.ts +332 -0
  223. package/src/resources/loyalty.ts +3 -0
  224. package/src/resources/{assets/minting.ts → minting.ts} +32 -27
  225. package/src/resources/referral/index.ts +10 -0
  226. package/src/resources/referral/referral.ts +70 -0
  227. package/src/resources/{assets/referral → referral}/users.ts +14 -20
  228. package/src/resources/referral.ts +3 -0
  229. package/src/resources/users/index.ts +13 -4
  230. package/src/resources/users/metadatas.ts +26 -15
  231. package/src/resources/users/users.ts +423 -9
  232. package/src/resources/users.ts +3 -0
  233. package/src/resources/websites/index.ts +22 -0
  234. package/src/resources/{assets → websites}/website-collections.ts +32 -30
  235. package/src/resources/{assets → websites}/website-user-roles.ts +40 -40
  236. package/src/resources/websites/websites.ts +299 -0
  237. package/src/resources/websites.ts +1 -257
  238. package/src/resources.ts +1 -0
  239. package/src/version.ts +1 -1
  240. package/version.d.ts +1 -1
  241. package/version.js +1 -1
  242. package/version.mjs +1 -1
  243. package/resources/assets/assets.d.ts +0 -153
  244. package/resources/assets/assets.d.ts.map +0 -1
  245. package/resources/assets/assets.js.map +0 -1
  246. package/resources/assets/assets.mjs +0 -42
  247. package/resources/assets/assets.mjs.map +0 -1
  248. package/resources/assets/index.d.ts +0 -7
  249. package/resources/assets/index.d.ts.map +0 -1
  250. package/resources/assets/index.js +0 -17
  251. package/resources/assets/index.js.map +0 -1
  252. package/resources/assets/index.mjs.map +0 -1
  253. package/resources/assets/minting.d.ts.map +0 -1
  254. package/resources/assets/minting.js.map +0 -1
  255. package/resources/assets/minting.mjs.map +0 -1
  256. package/resources/assets/referral/index.d.ts +0 -3
  257. package/resources/assets/referral/index.d.ts.map +0 -1
  258. package/resources/assets/referral/index.js.map +0 -1
  259. package/resources/assets/referral/index.mjs.map +0 -1
  260. package/resources/assets/referral/referral.d.ts +0 -30
  261. package/resources/assets/referral/referral.d.ts.map +0 -1
  262. package/resources/assets/referral/referral.js.map +0 -1
  263. package/resources/assets/referral/referral.mjs.map +0 -1
  264. package/resources/assets/referral/users.d.ts.map +0 -1
  265. package/resources/assets/referral/users.js.map +0 -1
  266. package/resources/assets/referral/users.mjs.map +0 -1
  267. package/resources/assets/users.d.ts +0 -285
  268. package/resources/assets/users.d.ts.map +0 -1
  269. package/resources/assets/users.js +0 -34
  270. package/resources/assets/users.js.map +0 -1
  271. package/resources/assets/users.mjs +0 -30
  272. package/resources/assets/users.mjs.map +0 -1
  273. package/resources/assets/website-collections.d.ts +0 -73
  274. package/resources/assets/website-collections.d.ts.map +0 -1
  275. package/resources/assets/website-collections.js.map +0 -1
  276. package/resources/assets/website-collections.mjs.map +0 -1
  277. package/resources/assets/website-user-roles.d.ts.map +0 -1
  278. package/resources/assets/website-user-roles.js.map +0 -1
  279. package/resources/assets/website-user-roles.mjs.map +0 -1
  280. package/resources/auction-bids.d.ts +0 -51
  281. package/resources/auction-bids.d.ts.map +0 -1
  282. package/resources/auction-bids.js.map +0 -1
  283. package/resources/auction-bids.mjs.map +0 -1
  284. package/resources/drip/drip.d.ts +0 -14
  285. package/resources/drip/drip.d.ts.map +0 -1
  286. package/resources/drip/drip.js +0 -43
  287. package/resources/drip/drip.js.map +0 -1
  288. package/resources/drip/drip.mjs +0 -16
  289. package/resources/drip/drip.mjs.map +0 -1
  290. package/resources/drip/index.d.ts +0 -4
  291. package/resources/drip/index.d.ts.map +0 -1
  292. package/resources/drip/index.js +0 -11
  293. package/resources/drip/index.js.map +0 -1
  294. package/resources/drip/index.mjs +0 -5
  295. package/resources/drip/index.mjs.map +0 -1
  296. package/resources/drip/quests.d.ts +0 -4
  297. package/resources/drip/quests.d.ts.map +0 -1
  298. package/resources/drip/quests.js +0 -9
  299. package/resources/drip/quests.js.map +0 -1
  300. package/resources/drip/quests.mjs +0 -5
  301. package/resources/drip/quests.mjs.map +0 -1
  302. package/resources/drip/status.d.ts +0 -4
  303. package/resources/drip/status.d.ts.map +0 -1
  304. package/resources/drip/status.js +0 -9
  305. package/resources/drip/status.js.map +0 -1
  306. package/resources/drip/status.mjs +0 -5
  307. package/resources/drip/status.mjs.map +0 -1
  308. package/resources/loyalty/transaction-entries/accounts.d.ts +0 -191
  309. package/resources/loyalty/transaction-entries/accounts.d.ts.map +0 -1
  310. package/resources/loyalty/transaction-entries/accounts.js +0 -24
  311. package/resources/loyalty/transaction-entries/accounts.js.map +0 -1
  312. package/resources/loyalty/transaction-entries/accounts.mjs +0 -20
  313. package/resources/loyalty/transaction-entries/accounts.mjs.map +0 -1
  314. package/resources/loyalty/transaction-entries/index.d.ts +0 -5
  315. package/resources/loyalty/transaction-entries/index.d.ts.map +0 -1
  316. package/resources/loyalty/transaction-entries/index.js +0 -13
  317. package/resources/loyalty/transaction-entries/index.js.map +0 -1
  318. package/resources/loyalty/transaction-entries/index.mjs +0 -6
  319. package/resources/loyalty/transaction-entries/index.mjs.map +0 -1
  320. package/resources/loyalty/transaction-entries/questions-responses.d.ts.map +0 -1
  321. package/resources/loyalty/transaction-entries/questions-responses.js.map +0 -1
  322. package/resources/loyalty/transaction-entries/questions-responses.mjs.map +0 -1
  323. package/resources/loyalty/transaction-entries/questions.d.ts.map +0 -1
  324. package/resources/loyalty/transaction-entries/questions.js.map +0 -1
  325. package/resources/loyalty/transaction-entries/questions.mjs.map +0 -1
  326. package/resources/loyalty/transaction-entries/transaction-entries.d.ts +0 -300
  327. package/resources/loyalty/transaction-entries/transaction-entries.d.ts.map +0 -1
  328. package/resources/loyalty/transaction-entries/transaction-entries.js +0 -66
  329. package/resources/loyalty/transaction-entries/transaction-entries.js.map +0 -1
  330. package/resources/loyalty/transaction-entries/transaction-entries.mjs +0 -39
  331. package/resources/loyalty/transaction-entries/transaction-entries.mjs.map +0 -1
  332. package/resources/users/wallets.d.ts +0 -4
  333. package/resources/users/wallets.d.ts.map +0 -1
  334. package/resources/users/wallets.js +0 -9
  335. package/resources/users/wallets.js.map +0 -1
  336. package/resources/users/wallets.mjs +0 -5
  337. package/resources/users/wallets.mjs.map +0 -1
  338. package/src/resources/assets/assets.ts +0 -294
  339. package/src/resources/assets/index.ts +0 -38
  340. package/src/resources/assets/referral/index.ts +0 -14
  341. package/src/resources/assets/referral/referral.ts +0 -74
  342. package/src/resources/assets/users.ts +0 -415
  343. package/src/resources/auction-bids.ts +0 -77
  344. package/src/resources/drip/drip.ts +0 -21
  345. package/src/resources/drip/index.ts +0 -5
  346. package/src/resources/drip/quests.ts +0 -5
  347. package/src/resources/drip/status.ts +0 -5
  348. package/src/resources/loyalty/transaction-entries/accounts.ts +0 -251
  349. package/src/resources/loyalty/transaction-entries/index.ts +0 -34
  350. package/src/resources/loyalty/transaction-entries/transaction-entries.ts +0 -525
  351. package/src/resources/users/wallets.ts +0 -5
  352. /package/resources/{assets/referral → referral}/index.js +0 -0
@@ -5,42 +5,35 @@ import * as Core from '../../core';
5
5
 
6
6
  export class WebsiteUserRoles extends APIResource {
7
7
  /**
8
- * Assign roles to users for a specific website
8
+ * Retrieves roles of users for a specific website. If userId is provided,
9
+ * retrieves the role of that specific user for the website.
9
10
  */
10
- assignRolesToUsers(
11
- body: WebsiteUserRoleAssignRolesToUsersParams,
11
+ list(
12
+ query: WebsiteUserRoleListParams,
12
13
  options?: Core.RequestOptions,
13
- ): Core.APIPromise<WebsiteUserRoleAssignRolesToUsersResponse> {
14
- return this._client.post('/api/website_user_roles', { body, ...options });
14
+ ): Core.APIPromise<WebsiteUserRoleListResponse> {
15
+ return this._client.get('/api/website_user_roles', { query, ...options });
15
16
  }
16
17
 
17
18
  /**
18
- * Retrieves roles of users for a specific website. If userId is provided,
19
- * retrieves the role of that specific user for the website.
19
+ * Assign roles to users for a specific website
20
20
  */
21
- getWebsiteUserRoles(
22
- query: WebsiteUserRoleGetWebsiteUserRolesParams,
21
+ assign(
22
+ body: WebsiteUserRoleAssignParams,
23
23
  options?: Core.RequestOptions,
24
- ): Core.APIPromise<WebsiteUserRoleGetWebsiteUserRolesResponse> {
25
- return this._client.get('/api/website_user_roles', { query, ...options });
24
+ ): Core.APIPromise<WebsiteUserRoleAssignResponse> {
25
+ return this._client.post('/api/website_user_roles', { body, ...options });
26
26
  }
27
27
  }
28
28
 
29
- /**
30
- * Schema for postWebsiteUserRoles response
31
- */
32
- export interface WebsiteUserRoleAssignRolesToUsersResponse {
33
- data?: unknown;
34
- }
35
-
36
29
  /**
37
30
  * Schema for getWebsiteUserRoles response
38
31
  */
39
- export interface WebsiteUserRoleGetWebsiteUserRolesResponse {
40
- data: Array<WebsiteUserRoleGetWebsiteUserRolesResponse.Data>;
32
+ export interface WebsiteUserRoleListResponse {
33
+ data: Array<WebsiteUserRoleListResponse.Data>;
41
34
  }
42
35
 
43
- export namespace WebsiteUserRoleGetWebsiteUserRolesResponse {
36
+ export namespace WebsiteUserRoleListResponse {
44
37
  export interface Data {
45
38
  /**
46
39
  * UUID of the website user role
@@ -49,7 +42,26 @@ export namespace WebsiteUserRoleGetWebsiteUserRolesResponse {
49
42
  }
50
43
  }
51
44
 
52
- export interface WebsiteUserRoleAssignRolesToUsersParams {
45
+ /**
46
+ * Schema for postWebsiteUserRoles response
47
+ */
48
+ export interface WebsiteUserRoleAssignResponse {
49
+ data?: unknown;
50
+ }
51
+
52
+ export interface WebsiteUserRoleListParams {
53
+ /**
54
+ * UUID of the website
55
+ */
56
+ websiteId: string;
57
+
58
+ /**
59
+ * UUID of the user
60
+ */
61
+ userId?: string;
62
+ }
63
+
64
+ export interface WebsiteUserRoleAssignParams {
53
65
  /**
54
66
  * UUID of the website
55
67
  */
@@ -58,10 +70,10 @@ export interface WebsiteUserRoleAssignRolesToUsersParams {
58
70
  /**
59
71
  * Array of website user roles
60
72
  */
61
- websiteUserRoles: Array<WebsiteUserRoleAssignRolesToUsersParams.WebsiteUserRole>;
73
+ websiteUserRoles: Array<WebsiteUserRoleAssignParams.WebsiteUserRole>;
62
74
  }
63
75
 
64
- export namespace WebsiteUserRoleAssignRolesToUsersParams {
76
+ export namespace WebsiteUserRoleAssignParams {
65
77
  export interface WebsiteUserRole {
66
78
  /**
67
79
  * Role type of the user
@@ -85,23 +97,11 @@ export namespace WebsiteUserRoleAssignRolesToUsersParams {
85
97
  }
86
98
  }
87
99
 
88
- export interface WebsiteUserRoleGetWebsiteUserRolesParams {
89
- /**
90
- * UUID of the website
91
- */
92
- websiteId: string;
93
-
94
- /**
95
- * UUID of the user
96
- */
97
- userId?: string;
98
- }
99
-
100
100
  export declare namespace WebsiteUserRoles {
101
101
  export {
102
- type WebsiteUserRoleAssignRolesToUsersResponse as WebsiteUserRoleAssignRolesToUsersResponse,
103
- type WebsiteUserRoleGetWebsiteUserRolesResponse as WebsiteUserRoleGetWebsiteUserRolesResponse,
104
- type WebsiteUserRoleAssignRolesToUsersParams as WebsiteUserRoleAssignRolesToUsersParams,
105
- type WebsiteUserRoleGetWebsiteUserRolesParams as WebsiteUserRoleGetWebsiteUserRolesParams,
102
+ type WebsiteUserRoleListResponse as WebsiteUserRoleListResponse,
103
+ type WebsiteUserRoleAssignResponse as WebsiteUserRoleAssignResponse,
104
+ type WebsiteUserRoleListParams as WebsiteUserRoleListParams,
105
+ type WebsiteUserRoleAssignParams as WebsiteUserRoleAssignParams,
106
106
  };
107
107
  }
@@ -0,0 +1,299 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../../resource';
4
+ import { isRequestOptions } from '../../core';
5
+ import * as Core from '../../core';
6
+ import * as WebsiteCollectionsAPI from './website-collections';
7
+ import {
8
+ WebsiteCollectionCreateParams,
9
+ WebsiteCollectionListParams,
10
+ WebsiteCollectionListResponse,
11
+ WebsiteCollections,
12
+ } from './website-collections';
13
+ import * as WebsiteUserRolesAPI from './website-user-roles';
14
+ import {
15
+ WebsiteUserRoleAssignParams,
16
+ WebsiteUserRoleAssignResponse,
17
+ WebsiteUserRoleListParams,
18
+ WebsiteUserRoleListResponse,
19
+ WebsiteUserRoles,
20
+ } from './website-user-roles';
21
+
22
+ export class Websites extends APIResource {
23
+ websiteCollections: WebsiteCollectionsAPI.WebsiteCollections = new WebsiteCollectionsAPI.WebsiteCollections(
24
+ this._client,
25
+ );
26
+ websiteUserRoles: WebsiteUserRolesAPI.WebsiteUserRoles = new WebsiteUserRolesAPI.WebsiteUserRoles(
27
+ this._client,
28
+ );
29
+
30
+ /**
31
+ * Creates a new website
32
+ */
33
+ create(body: WebsiteCreateParams, options?: Core.RequestOptions): Core.APIPromise<WebsiteCreateResponse> {
34
+ return this._client.post('/api/websites', { body, ...options });
35
+ }
36
+
37
+ /**
38
+ * Returns a list of websites. Includes optional query parameters for filtering and
39
+ * pagination.
40
+ */
41
+ list(query?: WebsiteListParams, options?: Core.RequestOptions): Core.APIPromise<WebsiteListResponse>;
42
+ list(options?: Core.RequestOptions): Core.APIPromise<WebsiteListResponse>;
43
+ list(
44
+ query: WebsiteListParams | Core.RequestOptions = {},
45
+ options?: Core.RequestOptions,
46
+ ): Core.APIPromise<WebsiteListResponse> {
47
+ if (isRequestOptions(query)) {
48
+ return this.list({}, query);
49
+ }
50
+ return this._client.get('/api/websites', { query, ...options });
51
+ }
52
+ }
53
+
54
+ /**
55
+ * Schema representing a website
56
+ */
57
+ export interface WebsiteCreateResponse {
58
+ /**
59
+ * Website ID
60
+ */
61
+ id: string;
62
+
63
+ /**
64
+ * Counts of related entities
65
+ */
66
+ _count: WebsiteCreateResponse._Count;
67
+
68
+ /**
69
+ * Collections associated with the website
70
+ */
71
+ collections: Array<WebsiteCreateResponse.Collection>;
72
+
73
+ /**
74
+ * Website name
75
+ */
76
+ name: string;
77
+
78
+ /**
79
+ * Date when terms were signed
80
+ */
81
+ termsSignedAt: string | null;
82
+ }
83
+
84
+ export namespace WebsiteCreateResponse {
85
+ /**
86
+ * Counts of related entities
87
+ */
88
+ export interface _Count {
89
+ /**
90
+ * Count of minting contract assets
91
+ */
92
+ mintingContractAssets: number;
93
+ }
94
+
95
+ /**
96
+ * Schema representing a collection
97
+ */
98
+ export interface Collection {
99
+ /**
100
+ * Collection ID
101
+ */
102
+ id: string;
103
+
104
+ /**
105
+ * URL of the collection image
106
+ */
107
+ imageUrl: string | null;
108
+
109
+ /**
110
+ * Collection name
111
+ */
112
+ name: string;
113
+
114
+ /**
115
+ * Royalty fee percentage
116
+ */
117
+ royaltyFee: number;
118
+
119
+ /**
120
+ * Address to receive royalty fees
121
+ */
122
+ royaltyFeeAddress: string;
123
+ }
124
+ }
125
+
126
+ /**
127
+ * Response schema for fetching websites
128
+ */
129
+ export interface WebsiteListResponse {
130
+ /**
131
+ * Array of websites
132
+ */
133
+ data: Array<WebsiteListResponse.Data>;
134
+
135
+ /**
136
+ * Indicates if more pages are available
137
+ */
138
+ hasNextPage: boolean;
139
+ }
140
+
141
+ export namespace WebsiteListResponse {
142
+ /**
143
+ * Schema representing a website
144
+ */
145
+ export interface Data {
146
+ /**
147
+ * Website ID
148
+ */
149
+ id: string;
150
+
151
+ /**
152
+ * Counts of related entities
153
+ */
154
+ _count: Data._Count;
155
+
156
+ /**
157
+ * Collections associated with the website
158
+ */
159
+ collections: Array<Data.Collection>;
160
+
161
+ /**
162
+ * Website name
163
+ */
164
+ name: string;
165
+
166
+ /**
167
+ * Date when terms were signed
168
+ */
169
+ termsSignedAt: string | null;
170
+ }
171
+
172
+ export namespace Data {
173
+ /**
174
+ * Counts of related entities
175
+ */
176
+ export interface _Count {
177
+ /**
178
+ * Count of minting contract assets
179
+ */
180
+ mintingContractAssets: number;
181
+ }
182
+
183
+ /**
184
+ * Schema representing a collection
185
+ */
186
+ export interface Collection {
187
+ /**
188
+ * Collection ID
189
+ */
190
+ id: string;
191
+
192
+ /**
193
+ * URL of the collection image
194
+ */
195
+ imageUrl: string | null;
196
+
197
+ /**
198
+ * Collection name
199
+ */
200
+ name: string;
201
+
202
+ /**
203
+ * Royalty fee percentage
204
+ */
205
+ royaltyFee: number;
206
+
207
+ /**
208
+ * Address to receive royalty fees
209
+ */
210
+ royaltyFeeAddress: string;
211
+ }
212
+ }
213
+ }
214
+
215
+ export interface WebsiteCreateParams {
216
+ /**
217
+ * Name of the website
218
+ */
219
+ name: string;
220
+
221
+ /**
222
+ * Discord URL of the website account
223
+ */
224
+ discordUrl?: string;
225
+
226
+ /**
227
+ * Home URL of the official website
228
+ */
229
+ homeUrl?: string;
230
+
231
+ /**
232
+ * Instagram username of the website account
233
+ */
234
+ instagramUsername?: string;
235
+
236
+ /**
237
+ * Organization ID for which this website is being created
238
+ */
239
+ organizationId?: string;
240
+
241
+ /**
242
+ * Telegram URL of the website account
243
+ */
244
+ telegramUrl?: string;
245
+
246
+ /**
247
+ * Twitter username of the website account
248
+ */
249
+ twitterUsername?: string;
250
+ }
251
+
252
+ export interface WebsiteListParams {
253
+ /**
254
+ * Number of items to return
255
+ */
256
+ limit?: number;
257
+
258
+ /**
259
+ * Filter by name
260
+ */
261
+ name?: string;
262
+
263
+ /**
264
+ * Filter by organization ID
265
+ */
266
+ organizationId?: string;
267
+
268
+ /**
269
+ * Pagination cursor, start after this ID
270
+ */
271
+ startingAfter?: string;
272
+ }
273
+
274
+ Websites.WebsiteCollections = WebsiteCollections;
275
+ Websites.WebsiteUserRoles = WebsiteUserRoles;
276
+
277
+ export declare namespace Websites {
278
+ export {
279
+ type WebsiteCreateResponse as WebsiteCreateResponse,
280
+ type WebsiteListResponse as WebsiteListResponse,
281
+ type WebsiteCreateParams as WebsiteCreateParams,
282
+ type WebsiteListParams as WebsiteListParams,
283
+ };
284
+
285
+ export {
286
+ WebsiteCollections as WebsiteCollections,
287
+ type WebsiteCollectionListResponse as WebsiteCollectionListResponse,
288
+ type WebsiteCollectionCreateParams as WebsiteCollectionCreateParams,
289
+ type WebsiteCollectionListParams as WebsiteCollectionListParams,
290
+ };
291
+
292
+ export {
293
+ WebsiteUserRoles as WebsiteUserRoles,
294
+ type WebsiteUserRoleListResponse as WebsiteUserRoleListResponse,
295
+ type WebsiteUserRoleAssignResponse as WebsiteUserRoleAssignResponse,
296
+ type WebsiteUserRoleListParams as WebsiteUserRoleListParams,
297
+ type WebsiteUserRoleAssignParams as WebsiteUserRoleAssignParams,
298
+ };
299
+ }
@@ -1,259 +1,3 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
- import { APIResource } from '../resource';
4
- import { isRequestOptions } from '../core';
5
- import * as Core from '../core';
6
-
7
- export class Websites extends APIResource {
8
- /**
9
- * Creates a new website
10
- */
11
- create(body: WebsiteCreateParams, options?: Core.RequestOptions): Core.APIPromise<WebsiteCreateResponse> {
12
- return this._client.post('/api/websites', { body, ...options });
13
- }
14
-
15
- /**
16
- * Returns a list of websites. Includes optional query parameters for filtering and
17
- * pagination.
18
- */
19
- list(query?: WebsiteListParams, options?: Core.RequestOptions): Core.APIPromise<WebsiteListResponse>;
20
- list(options?: Core.RequestOptions): Core.APIPromise<WebsiteListResponse>;
21
- list(
22
- query: WebsiteListParams | Core.RequestOptions = {},
23
- options?: Core.RequestOptions,
24
- ): Core.APIPromise<WebsiteListResponse> {
25
- if (isRequestOptions(query)) {
26
- return this.list({}, query);
27
- }
28
- return this._client.get('/api/websites', { query, ...options });
29
- }
30
- }
31
-
32
- /**
33
- * Schema representing a website
34
- */
35
- export interface WebsiteCreateResponse {
36
- /**
37
- * Website ID
38
- */
39
- id: string;
40
-
41
- /**
42
- * Counts of related entities
43
- */
44
- _count: WebsiteCreateResponse._Count;
45
-
46
- /**
47
- * Collections associated with the website
48
- */
49
- collections: Array<WebsiteCreateResponse.Collection>;
50
-
51
- /**
52
- * Website name
53
- */
54
- name: string;
55
-
56
- /**
57
- * Date when terms were signed
58
- */
59
- termsSignedAt: string | null;
60
- }
61
-
62
- export namespace WebsiteCreateResponse {
63
- /**
64
- * Counts of related entities
65
- */
66
- export interface _Count {
67
- /**
68
- * Count of minting contract assets
69
- */
70
- mintingContractAssets: number;
71
- }
72
-
73
- /**
74
- * Schema representing a collection
75
- */
76
- export interface Collection {
77
- /**
78
- * Collection ID
79
- */
80
- id: string;
81
-
82
- /**
83
- * URL of the collection image
84
- */
85
- imageUrl: string | null;
86
-
87
- /**
88
- * Collection name
89
- */
90
- name: string;
91
-
92
- /**
93
- * Royalty fee percentage
94
- */
95
- royaltyFee: number;
96
-
97
- /**
98
- * Address to receive royalty fees
99
- */
100
- royaltyFeeAddress: string;
101
- }
102
- }
103
-
104
- /**
105
- * Response schema for fetching websites
106
- */
107
- export interface WebsiteListResponse {
108
- /**
109
- * Array of websites
110
- */
111
- data: Array<WebsiteListResponse.Data>;
112
-
113
- /**
114
- * Indicates if more pages are available
115
- */
116
- hasNextPage: boolean;
117
- }
118
-
119
- export namespace WebsiteListResponse {
120
- /**
121
- * Schema representing a website
122
- */
123
- export interface Data {
124
- /**
125
- * Website ID
126
- */
127
- id: string;
128
-
129
- /**
130
- * Counts of related entities
131
- */
132
- _count: Data._Count;
133
-
134
- /**
135
- * Collections associated with the website
136
- */
137
- collections: Array<Data.Collection>;
138
-
139
- /**
140
- * Website name
141
- */
142
- name: string;
143
-
144
- /**
145
- * Date when terms were signed
146
- */
147
- termsSignedAt: string | null;
148
- }
149
-
150
- export namespace Data {
151
- /**
152
- * Counts of related entities
153
- */
154
- export interface _Count {
155
- /**
156
- * Count of minting contract assets
157
- */
158
- mintingContractAssets: number;
159
- }
160
-
161
- /**
162
- * Schema representing a collection
163
- */
164
- export interface Collection {
165
- /**
166
- * Collection ID
167
- */
168
- id: string;
169
-
170
- /**
171
- * URL of the collection image
172
- */
173
- imageUrl: string | null;
174
-
175
- /**
176
- * Collection name
177
- */
178
- name: string;
179
-
180
- /**
181
- * Royalty fee percentage
182
- */
183
- royaltyFee: number;
184
-
185
- /**
186
- * Address to receive royalty fees
187
- */
188
- royaltyFeeAddress: string;
189
- }
190
- }
191
- }
192
-
193
- export interface WebsiteCreateParams {
194
- /**
195
- * Name of the website
196
- */
197
- name: string;
198
-
199
- /**
200
- * Discord URL of the website account
201
- */
202
- discordUrl?: string;
203
-
204
- /**
205
- * Home URL of the official website
206
- */
207
- homeUrl?: string;
208
-
209
- /**
210
- * Instagram username of the website account
211
- */
212
- instagramUsername?: string;
213
-
214
- /**
215
- * Organization ID for which this website is being created
216
- */
217
- organizationId?: string;
218
-
219
- /**
220
- * Telegram URL of the website account
221
- */
222
- telegramUrl?: string;
223
-
224
- /**
225
- * Twitter username of the website account
226
- */
227
- twitterUsername?: string;
228
- }
229
-
230
- export interface WebsiteListParams {
231
- /**
232
- * Number of items to return
233
- */
234
- limit?: number;
235
-
236
- /**
237
- * Filter by name
238
- */
239
- name?: string;
240
-
241
- /**
242
- * Filter by organization ID
243
- */
244
- organizationId?: string;
245
-
246
- /**
247
- * Pagination cursor, start after this ID
248
- */
249
- startingAfter?: string;
250
- }
251
-
252
- export declare namespace Websites {
253
- export {
254
- type WebsiteCreateResponse as WebsiteCreateResponse,
255
- type WebsiteListResponse as WebsiteListResponse,
256
- type WebsiteCreateParams as WebsiteCreateParams,
257
- type WebsiteListParams as WebsiteListParams,
258
- };
259
- }
3
+ export * from './websites/index';
@@ -0,0 +1 @@
1
+ export * from './resources/index';
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '0.1.0-alpha.14'; // x-release-please-version
1
+ export const VERSION = '0.1.0-alpha.16'; // x-release-please-version
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.1.0-alpha.14";
1
+ export declare const VERSION = "0.1.0-alpha.16";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '0.1.0-alpha.14'; // x-release-please-version
4
+ exports.VERSION = '0.1.0-alpha.16'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '0.1.0-alpha.14'; // x-release-please-version
1
+ export const VERSION = '0.1.0-alpha.16'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map