@misonetwork/sdk 0.7.0 → 0.8.0

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 (289) hide show
  1. package/README.md +181 -139
  2. package/dist/client.d.ts +1225 -8
  3. package/dist/client.d.ts.map +1 -1
  4. package/dist/client.js +43 -19
  5. package/dist/client.js.map +1 -1
  6. package/dist/contracts/composition_credits/composition_credits.d.ts +181 -0
  7. package/dist/contracts/composition_credits/composition_credits.d.ts.map +1 -0
  8. package/dist/contracts/composition_credits/composition_credits.js +109 -0
  9. package/dist/contracts/composition_credits/composition_credits.js.map +1 -0
  10. package/dist/contracts/composition_credits/composition_party_role.d.ts +119 -0
  11. package/dist/contracts/composition_credits/composition_party_role.d.ts.map +1 -0
  12. package/dist/contracts/composition_credits/composition_party_role.js +139 -0
  13. package/dist/contracts/composition_credits/composition_party_role.js.map +1 -0
  14. package/dist/contracts/composition_credits/deps/miso_credit/credit.d.ts +24 -0
  15. package/dist/contracts/composition_credits/deps/miso_credit/credit.d.ts.map +1 -0
  16. package/dist/contracts/composition_credits/deps/miso_credit/credit.js +23 -0
  17. package/dist/contracts/composition_credits/deps/miso_credit/credit.js.map +1 -0
  18. package/dist/contracts/composition_credits/deps/sui/vec_map.d.ts +37 -0
  19. package/dist/contracts/composition_credits/deps/sui/vec_map.d.ts.map +1 -0
  20. package/dist/contracts/composition_credits/deps/sui/vec_map.js +28 -0
  21. package/dist/contracts/composition_credits/deps/sui/vec_map.js.map +1 -0
  22. package/dist/contracts/miso/composition.d.ts +1 -1
  23. package/dist/contracts/miso/composition.js +2 -2
  24. package/dist/contracts/miso/deps/bps/bps.d.ts +1 -1
  25. package/dist/contracts/miso/deps/bps/bps.js +1 -1
  26. package/dist/contracts/miso/recording.d.ts +1 -1
  27. package/dist/contracts/miso/recording.js +1 -1
  28. package/dist/contracts/miso/release.d.ts +61 -37
  29. package/dist/contracts/miso/release.d.ts.map +1 -1
  30. package/dist/contracts/miso/release.js +65 -38
  31. package/dist/contracts/miso/release.js.map +1 -1
  32. package/dist/contracts/miso/track.d.ts +2 -2
  33. package/dist/contracts/miso/track.js +2 -2
  34. package/dist/contracts/recording_advisory/recording_advisory.d.ts +194 -0
  35. package/dist/contracts/recording_advisory/recording_advisory.d.ts.map +1 -0
  36. package/dist/contracts/recording_advisory/recording_advisory.js +204 -0
  37. package/dist/contracts/recording_advisory/recording_advisory.js.map +1 -0
  38. package/dist/contracts/recording_credits/deps/miso_credit/credit.d.ts +24 -0
  39. package/dist/contracts/recording_credits/deps/miso_credit/credit.d.ts.map +1 -0
  40. package/dist/contracts/recording_credits/deps/miso_credit/credit.js +23 -0
  41. package/dist/contracts/recording_credits/deps/miso_credit/credit.js.map +1 -0
  42. package/dist/contracts/recording_credits/deps/sui/vec_map.d.ts +37 -0
  43. package/dist/contracts/recording_credits/deps/sui/vec_map.d.ts.map +1 -0
  44. package/dist/contracts/recording_credits/deps/sui/vec_map.js +28 -0
  45. package/dist/contracts/recording_credits/deps/sui/vec_map.js.map +1 -0
  46. package/dist/contracts/recording_credits/deps/sui/vec_set.d.ts +21 -0
  47. package/dist/contracts/recording_credits/deps/sui/vec_set.d.ts.map +1 -0
  48. package/dist/contracts/recording_credits/deps/sui/vec_set.js +20 -0
  49. package/dist/contracts/recording_credits/deps/sui/vec_set.js.map +1 -0
  50. package/dist/contracts/recording_credits/recording_credits.d.ts +2313 -0
  51. package/dist/contracts/recording_credits/recording_credits.d.ts.map +1 -0
  52. package/dist/contracts/recording_credits/recording_credits.js +270 -0
  53. package/dist/contracts/recording_credits/recording_credits.js.map +1 -0
  54. package/dist/contracts/recording_credits/recording_party_role.d.ts +1174 -0
  55. package/dist/contracts/recording_credits/recording_party_role.d.ts.map +1 -0
  56. package/dist/contracts/recording_credits/recording_party_role.js +692 -0
  57. package/dist/contracts/recording_credits/recording_party_role.js.map +1 -0
  58. package/dist/contracts/recording_language/deps/language_code/language_code.d.ts +6 -0
  59. package/dist/contracts/recording_language/deps/language_code/language_code.d.ts.map +1 -0
  60. package/dist/contracts/recording_language/deps/language_code/language_code.js +8 -0
  61. package/dist/contracts/recording_language/deps/language_code/language_code.js.map +1 -0
  62. package/dist/contracts/recording_language/recording_language.d.ts +152 -0
  63. package/dist/contracts/recording_language/recording_language.d.ts.map +1 -0
  64. package/dist/contracts/recording_language/recording_language.js +149 -0
  65. package/dist/contracts/recording_language/recording_language.js.map +1 -0
  66. package/dist/contracts/recording_master_reference/deps/ori/walrus_data.d.ts +52 -0
  67. package/dist/contracts/recording_master_reference/deps/ori/walrus_data.d.ts.map +1 -0
  68. package/dist/contracts/recording_master_reference/deps/ori/walrus_data.js +37 -0
  69. package/dist/contracts/recording_master_reference/deps/ori/walrus_data.js.map +1 -0
  70. package/dist/contracts/recording_master_reference/recording_master_reference.d.ts +131 -0
  71. package/dist/contracts/recording_master_reference/recording_master_reference.d.ts.map +1 -0
  72. package/dist/contracts/recording_master_reference/recording_master_reference.js +121 -0
  73. package/dist/contracts/recording_master_reference/recording_master_reference.js.map +1 -0
  74. package/dist/contracts/recording_preview/deps/ori/walrus_data.d.ts +52 -0
  75. package/dist/contracts/recording_preview/deps/ori/walrus_data.d.ts.map +1 -0
  76. package/dist/contracts/recording_preview/deps/ori/walrus_data.js +37 -0
  77. package/dist/contracts/recording_preview/deps/ori/walrus_data.js.map +1 -0
  78. package/dist/contracts/recording_preview/recording_preview.d.ts +104 -0
  79. package/dist/contracts/recording_preview/recording_preview.d.ts.map +1 -0
  80. package/dist/contracts/recording_preview/recording_preview.js +94 -0
  81. package/dist/contracts/recording_preview/recording_preview.js.map +1 -0
  82. package/dist/contracts/release_cover_art/deps/0x340057f2174fb59e4626742dd2b46c662237837b6187450cb59e4976ce7eac78/walrus_data.d.ts +52 -0
  83. package/dist/contracts/release_cover_art/deps/0x340057f2174fb59e4626742dd2b46c662237837b6187450cb59e4976ce7eac78/walrus_data.d.ts.map +1 -0
  84. package/dist/contracts/release_cover_art/deps/0x340057f2174fb59e4626742dd2b46c662237837b6187450cb59e4976ce7eac78/walrus_data.js +37 -0
  85. package/dist/contracts/release_cover_art/deps/0x340057f2174fb59e4626742dd2b46c662237837b6187450cb59e4976ce7eac78/walrus_data.js.map +1 -0
  86. package/dist/contracts/release_cover_art/deps/cover_art/cover_art.d.ts +46 -0
  87. package/dist/contracts/release_cover_art/deps/cover_art/cover_art.d.ts.map +1 -0
  88. package/dist/contracts/release_cover_art/deps/cover_art/cover_art.js +21 -0
  89. package/dist/contracts/release_cover_art/deps/cover_art/cover_art.js.map +1 -0
  90. package/dist/contracts/release_cover_art/deps/per_track/per_track.d.ts +33 -0
  91. package/dist/contracts/release_cover_art/deps/per_track/per_track.d.ts.map +1 -0
  92. package/dist/contracts/release_cover_art/deps/per_track/per_track.js +32 -0
  93. package/dist/contracts/release_cover_art/deps/per_track/per_track.js.map +1 -0
  94. package/dist/contracts/release_cover_art/release_cover_art.d.ts +300 -0
  95. package/dist/contracts/release_cover_art/release_cover_art.d.ts.map +1 -0
  96. package/dist/contracts/release_cover_art/release_cover_art.js +168 -0
  97. package/dist/contracts/release_cover_art/release_cover_art.js.map +1 -0
  98. package/dist/contracts/release_credits/deps/miso_credit/credit.d.ts +24 -0
  99. package/dist/contracts/release_credits/deps/miso_credit/credit.d.ts.map +1 -0
  100. package/dist/contracts/release_credits/deps/miso_credit/credit.js +23 -0
  101. package/dist/contracts/release_credits/deps/miso_credit/credit.js.map +1 -0
  102. package/dist/contracts/release_credits/deps/sui/vec_map.d.ts +37 -0
  103. package/dist/contracts/release_credits/deps/sui/vec_map.d.ts.map +1 -0
  104. package/dist/contracts/release_credits/deps/sui/vec_map.js +28 -0
  105. package/dist/contracts/release_credits/deps/sui/vec_map.js.map +1 -0
  106. package/dist/contracts/release_credits/release_credits.d.ts +142 -0
  107. package/dist/contracts/release_credits/release_credits.d.ts.map +1 -0
  108. package/dist/contracts/release_credits/release_credits.js +108 -0
  109. package/dist/contracts/release_credits/release_credits.js.map +1 -0
  110. package/dist/contracts/release_credits/release_party_role.d.ts +58 -0
  111. package/dist/contracts/release_credits/release_party_role.d.ts.map +1 -0
  112. package/dist/contracts/release_credits/release_party_role.js +66 -0
  113. package/dist/contracts/release_credits/release_party_role.js.map +1 -0
  114. package/dist/contracts/release_description/release_description.d.ts +112 -0
  115. package/dist/contracts/release_description/release_description.d.ts.map +1 -0
  116. package/dist/contracts/release_description/release_description.js +123 -0
  117. package/dist/contracts/release_description/release_description.js.map +1 -0
  118. package/dist/contracts/release_dsp_link/release_dsp_link.d.ts +644 -0
  119. package/dist/contracts/release_dsp_link/release_dsp_link.d.ts.map +1 -0
  120. package/dist/contracts/release_dsp_link/release_dsp_link.js +556 -0
  121. package/dist/contracts/release_dsp_link/release_dsp_link.js.map +1 -0
  122. package/dist/contracts/release_genre/deps/per_track/per_track.d.ts +33 -0
  123. package/dist/contracts/release_genre/deps/per_track/per_track.d.ts.map +1 -0
  124. package/dist/contracts/release_genre/deps/per_track/per_track.js +32 -0
  125. package/dist/contracts/release_genre/deps/per_track/per_track.js.map +1 -0
  126. package/dist/contracts/release_genre/release_genre.d.ts +193 -0
  127. package/dist/contracts/release_genre/release_genre.d.ts.map +1 -0
  128. package/dist/contracts/release_genre/release_genre.js +207 -0
  129. package/dist/contracts/release_genre/release_genre.js.map +1 -0
  130. package/dist/contracts/release_kind/release_kind.d.ts +98 -0
  131. package/dist/contracts/release_kind/release_kind.d.ts.map +1 -0
  132. package/dist/contracts/release_kind/release_kind.js +109 -0
  133. package/dist/contracts/release_kind/release_kind.js.map +1 -0
  134. package/dist/contracts/release_snapshot_bundle/deps/ori/walrus_data.d.ts +52 -0
  135. package/dist/contracts/release_snapshot_bundle/deps/ori/walrus_data.d.ts.map +1 -0
  136. package/dist/contracts/release_snapshot_bundle/deps/ori/walrus_data.js +37 -0
  137. package/dist/contracts/release_snapshot_bundle/deps/ori/walrus_data.js.map +1 -0
  138. package/dist/contracts/release_snapshot_bundle/release_snapshot_bundle.d.ts +91 -0
  139. package/dist/contracts/release_snapshot_bundle/release_snapshot_bundle.d.ts.map +1 -0
  140. package/dist/contracts/release_snapshot_bundle/release_snapshot_bundle.js +91 -0
  141. package/dist/contracts/release_snapshot_bundle/release_snapshot_bundle.js.map +1 -0
  142. package/dist/contracts/routed_stake/deps/royalty_pool/stake.d.ts +54 -0
  143. package/dist/contracts/routed_stake/deps/royalty_pool/stake.d.ts.map +1 -0
  144. package/dist/contracts/routed_stake/deps/royalty_pool/stake.js +37 -0
  145. package/dist/contracts/routed_stake/deps/royalty_pool/stake.js.map +1 -0
  146. package/dist/contracts/routed_stake/deps/std/type_name.d.ts +18 -0
  147. package/dist/contracts/routed_stake/deps/std/type_name.d.ts.map +1 -0
  148. package/dist/contracts/routed_stake/deps/std/type_name.js +20 -0
  149. package/dist/contracts/routed_stake/deps/std/type_name.js.map +1 -0
  150. package/dist/contracts/routed_stake/deps/sui/balance.d.ts +13 -0
  151. package/dist/contracts/routed_stake/deps/sui/balance.d.ts.map +1 -0
  152. package/dist/contracts/routed_stake/deps/sui/balance.js +15 -0
  153. package/dist/contracts/routed_stake/deps/sui/balance.js.map +1 -0
  154. package/dist/contracts/routed_stake/deps/sui/vec_map.d.ts +37 -0
  155. package/dist/contracts/routed_stake/deps/sui/vec_map.d.ts.map +1 -0
  156. package/dist/contracts/routed_stake/deps/sui/vec_map.js +28 -0
  157. package/dist/contracts/routed_stake/deps/sui/vec_map.js.map +1 -0
  158. package/dist/contracts/routed_stake/routed_stake.d.ts +356 -0
  159. package/dist/contracts/routed_stake/routed_stake.d.ts.map +1 -0
  160. package/dist/contracts/routed_stake/routed_stake.js +311 -0
  161. package/dist/contracts/routed_stake/routed_stake.js.map +1 -0
  162. package/dist/contracts/royalty_pool/deps/std/type_name.d.ts +18 -0
  163. package/dist/contracts/royalty_pool/deps/std/type_name.d.ts.map +1 -0
  164. package/dist/contracts/royalty_pool/deps/std/type_name.js +20 -0
  165. package/dist/contracts/royalty_pool/deps/std/type_name.js.map +1 -0
  166. package/dist/contracts/royalty_pool/deps/sui/balance.d.ts +13 -0
  167. package/dist/contracts/royalty_pool/deps/sui/balance.d.ts.map +1 -0
  168. package/dist/contracts/royalty_pool/deps/sui/balance.js +15 -0
  169. package/dist/contracts/royalty_pool/deps/sui/balance.js.map +1 -0
  170. package/dist/contracts/royalty_pool/deps/sui/vec_map.d.ts +37 -0
  171. package/dist/contracts/royalty_pool/deps/sui/vec_map.d.ts.map +1 -0
  172. package/dist/contracts/royalty_pool/deps/sui/vec_map.js +28 -0
  173. package/dist/contracts/royalty_pool/deps/sui/vec_map.js.map +1 -0
  174. package/dist/contracts/royalty_pool/pool.d.ts +394 -0
  175. package/dist/contracts/royalty_pool/pool.d.ts.map +1 -0
  176. package/dist/contracts/royalty_pool/pool.js +387 -0
  177. package/dist/contracts/royalty_pool/pool.js.map +1 -0
  178. package/dist/contracts/royalty_pool/stake.d.ts +202 -0
  179. package/dist/contracts/royalty_pool/stake.d.ts.map +1 -0
  180. package/dist/contracts/royalty_pool/stake.js +197 -0
  181. package/dist/contracts/royalty_pool/stake.js.map +1 -0
  182. package/dist/contracts.d.ts +37 -3
  183. package/dist/contracts.d.ts.map +1 -1
  184. package/dist/contracts.js +42 -8
  185. package/dist/contracts.js.map +1 -1
  186. package/dist/deployments.d.ts +46 -12
  187. package/dist/deployments.d.ts.map +1 -1
  188. package/dist/deployments.js +119 -11
  189. package/dist/deployments.js.map +1 -1
  190. package/dist/events.d.ts +1081 -0
  191. package/dist/events.d.ts.map +1 -0
  192. package/dist/events.js +124 -0
  193. package/dist/events.js.map +1 -0
  194. package/dist/execute.d.ts.map +1 -1
  195. package/dist/execute.js +0 -4
  196. package/dist/execute.js.map +1 -1
  197. package/dist/index.d.ts +3 -0
  198. package/dist/index.d.ts.map +1 -1
  199. package/dist/index.js +6 -3
  200. package/dist/index.js.map +1 -1
  201. package/dist/internal.d.ts.map +1 -1
  202. package/dist/internal.js.map +1 -1
  203. package/dist/numeric.d.ts +5 -0
  204. package/dist/numeric.d.ts.map +1 -0
  205. package/dist/numeric.js +21 -0
  206. package/dist/numeric.js.map +1 -0
  207. package/dist/packages.d.ts +159 -0
  208. package/dist/packages.d.ts.map +1 -0
  209. package/dist/packages.js +179 -0
  210. package/dist/packages.js.map +1 -0
  211. package/dist/parsers.d.ts +5 -1
  212. package/dist/parsers.d.ts.map +1 -1
  213. package/dist/parsers.js +18 -2
  214. package/dist/parsers.js.map +1 -1
  215. package/dist/queries.d.ts +92 -0
  216. package/dist/queries.d.ts.map +1 -1
  217. package/dist/queries.js +132 -23
  218. package/dist/queries.js.map +1 -1
  219. package/dist/transactions.d.ts +96 -3
  220. package/dist/transactions.d.ts.map +1 -1
  221. package/dist/transactions.js +123 -11
  222. package/dist/transactions.js.map +1 -1
  223. package/dist/types.d.ts +18 -0
  224. package/dist/types.d.ts.map +1 -1
  225. package/dist/view.d.ts +6 -5
  226. package/dist/view.d.ts.map +1 -1
  227. package/dist/view.js +8 -2
  228. package/dist/view.js.map +1 -1
  229. package/package.json +14 -4
  230. package/src/client.ts +57 -23
  231. package/src/contracts/composition_credits/composition_credits.ts +169 -0
  232. package/src/contracts/composition_credits/composition_party_role.ts +189 -0
  233. package/src/contracts/composition_credits/deps/miso_credit/credit.ts +27 -0
  234. package/src/contracts/composition_credits/deps/sui/vec_map.ts +33 -0
  235. package/src/contracts/miso/composition.ts +8 -8
  236. package/src/contracts/miso/deps/bps/bps.ts +3 -3
  237. package/src/contracts/miso/recording.ts +10 -10
  238. package/src/contracts/miso/release.ts +103 -67
  239. package/src/contracts/miso/track.ts +5 -5
  240. package/src/contracts/recording_advisory/recording_advisory.ts +315 -0
  241. package/src/contracts/recording_credits/deps/miso_credit/credit.ts +27 -0
  242. package/src/contracts/recording_credits/deps/sui/vec_map.ts +33 -0
  243. package/src/contracts/recording_credits/deps/sui/vec_set.ts +21 -0
  244. package/src/contracts/recording_credits/recording_credits.ts +458 -0
  245. package/src/contracts/recording_credits/recording_party_role.ts +1041 -0
  246. package/src/contracts/recording_language/deps/language_code/language_code.ts +7 -0
  247. package/src/contracts/recording_language/recording_language.ts +237 -0
  248. package/src/contracts/recording_master_reference/deps/ori/walrus_data.ts +36 -0
  249. package/src/contracts/recording_master_reference/recording_master_reference.ts +181 -0
  250. package/src/contracts/recording_preview/deps/ori/walrus_data.ts +36 -0
  251. package/src/contracts/recording_preview/recording_preview.ts +154 -0
  252. package/src/contracts/release_cover_art/deps/0x340057f2174fb59e4626742dd2b46c662237837b6187450cb59e4976ce7eac78/walrus_data.ts +36 -0
  253. package/src/contracts/release_cover_art/deps/cover_art/cover_art.ts +23 -0
  254. package/src/contracts/release_cover_art/deps/per_track/per_track.ts +36 -0
  255. package/src/contracts/release_cover_art/release_cover_art.ts +251 -0
  256. package/src/contracts/release_credits/deps/miso_credit/credit.ts +27 -0
  257. package/src/contracts/release_credits/deps/sui/vec_map.ts +33 -0
  258. package/src/contracts/release_credits/release_credits.ts +156 -0
  259. package/src/contracts/release_credits/release_party_role.ts +87 -0
  260. package/src/contracts/release_description/release_description.ts +167 -0
  261. package/src/contracts/release_dsp_link/release_dsp_link.ts +813 -0
  262. package/src/contracts/release_genre/deps/per_track/per_track.ts +36 -0
  263. package/src/contracts/release_genre/release_genre.ts +314 -0
  264. package/src/contracts/release_kind/release_kind.ts +153 -0
  265. package/src/contracts/release_snapshot_bundle/deps/ori/walrus_data.ts +36 -0
  266. package/src/contracts/release_snapshot_bundle/release_snapshot_bundle.ts +124 -0
  267. package/src/contracts/routed_stake/deps/royalty_pool/stake.ts +39 -0
  268. package/src/contracts/routed_stake/deps/std/type_name.ts +22 -0
  269. package/src/contracts/routed_stake/deps/sui/balance.ts +17 -0
  270. package/src/contracts/routed_stake/deps/sui/vec_map.ts +33 -0
  271. package/src/contracts/routed_stake/routed_stake.ts +508 -0
  272. package/src/contracts/royalty_pool/deps/std/type_name.ts +22 -0
  273. package/src/contracts/royalty_pool/deps/sui/balance.ts +17 -0
  274. package/src/contracts/royalty_pool/deps/sui/vec_map.ts +33 -0
  275. package/src/contracts/royalty_pool/pool.ts +613 -0
  276. package/src/contracts/royalty_pool/stake.ts +317 -0
  277. package/src/contracts.ts +59 -6
  278. package/src/deployments.ts +160 -22
  279. package/src/events.ts +129 -0
  280. package/src/execute.ts +0 -4
  281. package/src/index.ts +6 -3
  282. package/src/internal.ts +0 -4
  283. package/src/numeric.ts +25 -0
  284. package/src/packages.ts +251 -0
  285. package/src/parsers.ts +32 -2
  286. package/src/queries.ts +227 -25
  287. package/src/transactions.ts +254 -12
  288. package/src/types.ts +20 -0
  289. package/src/view.ts +12 -6
@@ -0,0 +1,36 @@
1
+ /**************************************************************
2
+ * THIS FILE IS GENERATED AND SHOULD NOT BE MANUALLY MODIFIED *
3
+ **************************************************************/
4
+ import { MoveEnum, MoveStruct, MoveTuple } from '../../../utils/index.ts';
5
+ import { bcs } from '@mysten/sui/bcs';
6
+ const $moduleName = '0x340057f2174fb59e4626742dd2b46c662237837b6187450cb59e4976ce7eac78::walrus_data';
7
+ /**
8
+ * Confidentiality of a stored blob: cleartext, or encrypted with an access policy.
9
+ * Only applies to standalone blobs — a quilt patch is a slice of a shared quilt
10
+ * blob and can never be the direct product of an encryption.
11
+ */
12
+ export const Confidentiality = new MoveEnum({ name: `${$moduleName}::Confidentiality`, fields: {
13
+ /** The blob is stored in the clear. */
14
+ Unencrypted: null,
15
+ /**
16
+ * The blob is AES-encrypted. `dek` is the AES data-encryption key sealed via Seal
17
+ * — a small ciphertext stored on-chain, not the blob bytes. The sealed DEK is
18
+ * itself a Seal `EncryptedObject`, which already carries the decryption-policy
19
+ * package id, so no separate policy field is stored here. Decryption is gated by
20
+ * that policy package's `seal_approve`, not by this library.
21
+ */
22
+ Encrypted: new MoveStruct({ name: `Confidentiality.Encrypted`, fields: {
23
+ dek: bcs.vector(bcs.u8())
24
+ } })
25
+ } });
26
+ /** Represents either a standalone Walrus blob or a patch within a quilt. */
27
+ export const WalrusData = new MoveEnum({ name: `${$moduleName}::WalrusData`, fields: {
28
+ /** A standalone Walrus blob. Fields: blob_id, confidentiality. */
29
+ Blob: new MoveTuple({ name: `WalrusData.Blob`, fields: [bcs.u256(), Confidentiality] }),
30
+ /**
31
+ * A patch within a Walrus quilt. Fields: quilt_id, version, start_index,
32
+ * end_index. Always a plaintext reference into a (possibly separately encrypted)
33
+ * quilt blob.
34
+ */
35
+ QuiltPatch: new MoveTuple({ name: `WalrusData.QuiltPatch`, fields: [bcs.u256(), bcs.u8(), bcs.u16(), bcs.u16()] })
36
+ } });
@@ -0,0 +1,23 @@
1
+ /**************************************************************
2
+ * THIS FILE IS GENERATED AND SHOULD NOT BE MANUALLY MODIFIED *
3
+ **************************************************************/
4
+
5
+
6
+ /**
7
+ * The evolvable cover art value used by the recording/release cover art
8
+ * extensions.
9
+ *
10
+ * CoverArt format changes over time (static-only → +animated → future formats).
11
+ * Keeping it in an extension rather than immutable core means a new format is a
12
+ * republish of this small package (or a brand-new cover art standard), not of the
13
+ * frozen protocol. `CoverArt` references external storage via `ori::WalrusData`.
14
+ */
15
+
16
+ import { MoveStruct } from '../../../utils/index.ts';
17
+ import { bcs } from '@mysten/sui/bcs';
18
+ import * as walrus_data from '../0x340057f2174fb59e4626742dd2b46c662237837b6187450cb59e4976ce7eac78/walrus_data.ts';
19
+ const $moduleName = 'cover_art::cover_art';
20
+ export const CoverArt = new MoveStruct({ name: `${$moduleName}::CoverArt`, fields: {
21
+ still: walrus_data.WalrusData,
22
+ animated: bcs.option(walrus_data.WalrusData)
23
+ } });
@@ -0,0 +1,36 @@
1
+ /**************************************************************
2
+ * THIS FILE IS GENERATED AND SHOULD NOT BE MANUALLY MODIFIED *
3
+ **************************************************************/
4
+
5
+
6
+ /**
7
+ * `PerTrack<Data>` — one `Data` value per track of a release, held in tracklist
8
+ * order.
9
+ *
10
+ * A release's tracks are a flat, ordered `vector<Track>`, frozen at release
11
+ * creation. `PerTrack` is the parallel array to that list: index `i` holds the
12
+ * payload for the `i`-th track. It is the shared shape behind per-track release
13
+ * metadata such as cover art (`PerTrack<Option<CoverArt>>`) or genre — and the
14
+ * natural home for display grouping (disc/side boundaries), which core
15
+ * deliberately does not store.
16
+ *
17
+ * Construction reads the `Release` and sizes/validates the array against the
18
+ * tracklist length, so a `PerTrack` is parallel to the tracklist _by construction_
19
+ * — an extension cannot attach a misaligned array. Because a release's tracklist
20
+ * is frozen at creation, that alignment holds for the release's whole life.
21
+ */
22
+
23
+ import { type BcsType, bcs } from '@mysten/sui/bcs';
24
+ import { MoveTuple } from '../../../utils/index.ts';
25
+ const $moduleName = 'per_track::per_track';
26
+ /**
27
+ * One `Data` per track, indexed by the release's tracklist position. `Data` is the
28
+ * per-track payload — e.g. `CoverArt` when every track carries one, or
29
+ * `Option<CoverArt>` for override-style metadata layered over an album-level
30
+ * default.
31
+ */
32
+ export function PerTrack<Data extends BcsType<any>>(...typeParameters: [
33
+ Data
34
+ ]) {
35
+ return new MoveTuple({ name: `${$moduleName}::PerTrack<${typeParameters[0].name as Data['name']}>`, fields: [bcs.vector(typeParameters[0])] });
36
+ }
@@ -0,0 +1,251 @@
1
+ /**************************************************************
2
+ * THIS FILE IS GENERATED AND SHOULD NOT BE MANUALLY MODIFIED *
3
+ **************************************************************/
4
+
5
+
6
+ /**
7
+ * Release cover art: an album-level cover plus optional per-track cover overrides.
8
+ * Stored as a dynamic field on the release's UID, set/cleared via the release's
9
+ * cap-gated `uid_mut`.
10
+ *
11
+ * Cover art is presentation, not objective recording data, so it lives on the
12
+ * release (the consumer object) rather than the recording. A track's effective
13
+ * cover resolves as: its per-track override if set, else the album cover. The
14
+ * overrides are a `PerTrack<Option<CoverArt>>` — one slot per track, aligned to
15
+ * the release's tracklist by construction (sized from `tracks().length()`).
16
+ */
17
+
18
+ import { MoveTuple, MoveStruct, normalizeMoveArguments, type RawTransactionArgument } from '../utils/index.ts';
19
+ import { bcs } from '@mysten/sui/bcs';
20
+ import { type Transaction, type TransactionArgument } from '@mysten/sui/transactions';
21
+ import * as cover_art from './deps/cover_art/cover_art.ts';
22
+ import * as per_track from './deps/per_track/per_track.ts';
23
+ const $moduleName = '@local-pkg/release_cover_art::release_cover_art';
24
+ export const ExtensionKey = new MoveTuple({ name: `${$moduleName}::ExtensionKey`, fields: [bcs.bool()] });
25
+ export const ReleaseCoverArt = new MoveStruct({ name: `${$moduleName}::ReleaseCoverArt`, fields: {
26
+ cover: bcs.option(cover_art.CoverArt),
27
+ track_covers: per_track.PerTrack(bcs.option(cover_art.CoverArt))
28
+ } });
29
+ export const CoverSetEvent = new MoveStruct({ name: `${$moduleName}::CoverSetEvent`, fields: {
30
+ release_id: bcs.Address,
31
+ /** The full cover art record that was written. */
32
+ art: cover_art.CoverArt
33
+ } });
34
+ export const CoverUnsetEvent = new MoveStruct({ name: `${$moduleName}::CoverUnsetEvent`, fields: {
35
+ release_id: bcs.Address
36
+ } });
37
+ export const TrackCoverSetEvent = new MoveStruct({ name: `${$moduleName}::TrackCoverSetEvent`, fields: {
38
+ release_id: bcs.Address,
39
+ track_index: bcs.u64(),
40
+ /** The full cover art record that was written. */
41
+ art: cover_art.CoverArt
42
+ } });
43
+ export const TrackCoverUnsetEvent = new MoveStruct({ name: `${$moduleName}::TrackCoverUnsetEvent`, fields: {
44
+ release_id: bcs.Address,
45
+ track_index: bcs.u64()
46
+ } });
47
+ export interface SetCoverArguments {
48
+ self: RawTransactionArgument<string>;
49
+ cap: RawTransactionArgument<string>;
50
+ art: TransactionArgument;
51
+ }
52
+ export interface SetCoverOptions {
53
+ package?: string;
54
+ arguments: SetCoverArguments | [
55
+ self: RawTransactionArgument<string>,
56
+ cap: RawTransactionArgument<string>,
57
+ art: TransactionArgument
58
+ ];
59
+ }
60
+ /** Sets (or replaces) the album-level cover. */
61
+ export function setCover(options: SetCoverOptions) {
62
+ const packageAddress = options.package ?? '@local-pkg/release_cover_art';
63
+ const argumentsTypes = [
64
+ null,
65
+ null,
66
+ null
67
+ ] satisfies (string | null)[];
68
+ const parameterNames = ["self", "cap", "art"];
69
+ return (tx: Transaction) => tx.moveCall({
70
+ package: packageAddress,
71
+ module: 'release_cover_art',
72
+ function: 'set_cover',
73
+ arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
74
+ });
75
+ }
76
+ export interface UnsetCoverArguments {
77
+ self: RawTransactionArgument<string>;
78
+ cap: RawTransactionArgument<string>;
79
+ }
80
+ export interface UnsetCoverOptions {
81
+ package?: string;
82
+ arguments: UnsetCoverArguments | [
83
+ self: RawTransactionArgument<string>,
84
+ cap: RawTransactionArgument<string>
85
+ ];
86
+ }
87
+ /**
88
+ * Removes the album-level cover. Per-track overrides are untouched. Aborts with
89
+ * `ENoCoverArt` if no cover art record is attached.
90
+ */
91
+ export function unsetCover(options: UnsetCoverOptions) {
92
+ const packageAddress = options.package ?? '@local-pkg/release_cover_art';
93
+ const argumentsTypes = [
94
+ null,
95
+ null
96
+ ] satisfies (string | null)[];
97
+ const parameterNames = ["self", "cap"];
98
+ return (tx: Transaction) => tx.moveCall({
99
+ package: packageAddress,
100
+ module: 'release_cover_art',
101
+ function: 'unset_cover',
102
+ arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
103
+ });
104
+ }
105
+ export interface SetTrackCoverArguments {
106
+ self: RawTransactionArgument<string>;
107
+ cap: RawTransactionArgument<string>;
108
+ trackIndex: RawTransactionArgument<number | bigint>;
109
+ art: TransactionArgument;
110
+ }
111
+ export interface SetTrackCoverOptions {
112
+ package?: string;
113
+ arguments: SetTrackCoverArguments | [
114
+ self: RawTransactionArgument<string>,
115
+ cap: RawTransactionArgument<string>,
116
+ trackIndex: RawTransactionArgument<number | bigint>,
117
+ art: TransactionArgument
118
+ ];
119
+ }
120
+ /**
121
+ * Sets (or replaces) the cover override for a specific track (by tracklist index).
122
+ * Aborts if the index is out of range for the release.
123
+ */
124
+ export function setTrackCover(options: SetTrackCoverOptions) {
125
+ const packageAddress = options.package ?? '@local-pkg/release_cover_art';
126
+ const argumentsTypes = [
127
+ null,
128
+ null,
129
+ 'u64',
130
+ null
131
+ ] satisfies (string | null)[];
132
+ const parameterNames = ["self", "cap", "trackIndex", "art"];
133
+ return (tx: Transaction) => tx.moveCall({
134
+ package: packageAddress,
135
+ module: 'release_cover_art',
136
+ function: 'set_track_cover',
137
+ arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
138
+ });
139
+ }
140
+ export interface UnsetTrackCoverArguments {
141
+ self: RawTransactionArgument<string>;
142
+ cap: RawTransactionArgument<string>;
143
+ trackIndex: RawTransactionArgument<number | bigint>;
144
+ }
145
+ export interface UnsetTrackCoverOptions {
146
+ package?: string;
147
+ arguments: UnsetTrackCoverArguments | [
148
+ self: RawTransactionArgument<string>,
149
+ cap: RawTransactionArgument<string>,
150
+ trackIndex: RawTransactionArgument<number | bigint>
151
+ ];
152
+ }
153
+ /**
154
+ * Removes the cover override for a specific track — the track then falls back to
155
+ * the album cover. Aborts if no cover art record is attached, or if the index is
156
+ * out of range for the release.
157
+ */
158
+ export function unsetTrackCover(options: UnsetTrackCoverOptions) {
159
+ const packageAddress = options.package ?? '@local-pkg/release_cover_art';
160
+ const argumentsTypes = [
161
+ null,
162
+ null,
163
+ 'u64'
164
+ ] satisfies (string | null)[];
165
+ const parameterNames = ["self", "cap", "trackIndex"];
166
+ return (tx: Transaction) => tx.moveCall({
167
+ package: packageAddress,
168
+ module: 'release_cover_art',
169
+ function: 'unset_track_cover',
170
+ arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
171
+ });
172
+ }
173
+ export interface HasCoverArtArguments {
174
+ self: RawTransactionArgument<string>;
175
+ }
176
+ export interface HasCoverArtOptions {
177
+ package?: string;
178
+ arguments: HasCoverArtArguments | [
179
+ self: RawTransactionArgument<string>
180
+ ];
181
+ }
182
+ /** Returns whether a cover art record is attached to this release. */
183
+ export function hasCoverArt(options: HasCoverArtOptions) {
184
+ const packageAddress = options.package ?? '@local-pkg/release_cover_art';
185
+ const argumentsTypes = [
186
+ null
187
+ ] satisfies (string | null)[];
188
+ const parameterNames = ["self"];
189
+ return (tx: Transaction) => tx.moveCall({
190
+ package: packageAddress,
191
+ module: 'release_cover_art',
192
+ function: 'has_cover_art',
193
+ arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
194
+ });
195
+ }
196
+ export interface CoverArguments {
197
+ self: RawTransactionArgument<string>;
198
+ }
199
+ export interface CoverOptions {
200
+ package?: string;
201
+ arguments: CoverArguments | [
202
+ self: RawTransactionArgument<string>
203
+ ];
204
+ }
205
+ /**
206
+ * Returns the album-level cover (none if unset). Aborts if no cover art record is
207
+ * attached at all.
208
+ */
209
+ export function cover(options: CoverOptions) {
210
+ const packageAddress = options.package ?? '@local-pkg/release_cover_art';
211
+ const argumentsTypes = [
212
+ null
213
+ ] satisfies (string | null)[];
214
+ const parameterNames = ["self"];
215
+ return (tx: Transaction) => tx.moveCall({
216
+ package: packageAddress,
217
+ module: 'release_cover_art',
218
+ function: 'cover',
219
+ arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
220
+ });
221
+ }
222
+ export interface TrackCoverArguments {
223
+ self: RawTransactionArgument<string>;
224
+ trackIndex: RawTransactionArgument<number | bigint>;
225
+ }
226
+ export interface TrackCoverOptions {
227
+ package?: string;
228
+ arguments: TrackCoverArguments | [
229
+ self: RawTransactionArgument<string>,
230
+ trackIndex: RawTransactionArgument<number | bigint>
231
+ ];
232
+ }
233
+ /**
234
+ * Returns a track's effective cover: its per-track override if set, otherwise the
235
+ * album cover (which may itself be none). Aborts if no cover art record is
236
+ * attached, or if the track index is out of range.
237
+ */
238
+ export function trackCover(options: TrackCoverOptions) {
239
+ const packageAddress = options.package ?? '@local-pkg/release_cover_art';
240
+ const argumentsTypes = [
241
+ null,
242
+ 'u64'
243
+ ] satisfies (string | null)[];
244
+ const parameterNames = ["self", "trackIndex"];
245
+ return (tx: Transaction) => tx.moveCall({
246
+ package: packageAddress,
247
+ module: 'release_cover_art',
248
+ function: 'track_cover',
249
+ arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
250
+ });
251
+ }
@@ -0,0 +1,27 @@
1
+ /**************************************************************
2
+ * THIS FILE IS GENERATED AND SHOULD NOT BE MANUALLY MODIFIED *
3
+ **************************************************************/
4
+
5
+
6
+ /**
7
+ * Represents a party's credit on a work or activity. A credit pairs a display name
8
+ * with one or more roles, identifying how a party contributed to the work.
9
+ */
10
+
11
+ import { type BcsType, bcs } from '@mysten/sui/bcs';
12
+ import { MoveStruct } from '../../../utils/index.ts';
13
+ const $moduleName = 'miso_credit::credit';
14
+ /**
15
+ * A credit attributing roles to a party on a work. Generic over the role type to
16
+ * support domain-specific roles.
17
+ */
18
+ export function Credit<Role extends BcsType<any>>(...typeParameters: [
19
+ Role
20
+ ]) {
21
+ return new MoveStruct({ name: `${$moduleName}::Credit<${typeParameters[0].name as Role['name']}>`, fields: {
22
+ /** Human-readable name to display for this credit. */
23
+ display_name: bcs.string(),
24
+ /** Roles assigned to the credited party. */
25
+ roles: bcs.vector(typeParameters[0])
26
+ } });
27
+ }
@@ -0,0 +1,33 @@
1
+ /**************************************************************
2
+ * THIS FILE IS GENERATED AND SHOULD NOT BE MANUALLY MODIFIED *
3
+ **************************************************************/
4
+ import { type BcsType, bcs } from '@mysten/sui/bcs';
5
+ import { MoveStruct } from '../../../utils/index.ts';
6
+ const $moduleName = '0x2::vec_map';
7
+ /** An entry in the map */
8
+ export function Entry<K extends BcsType<any>, V extends BcsType<any>>(...typeParameters: [
9
+ K,
10
+ V
11
+ ]) {
12
+ return new MoveStruct({ name: `${$moduleName}::Entry<${typeParameters[0].name as K['name']}, ${typeParameters[1].name as V['name']}>`, fields: {
13
+ key: typeParameters[0],
14
+ value: typeParameters[1]
15
+ } });
16
+ }
17
+ /**
18
+ * A map data structure backed by a vector. The map is guaranteed not to contain
19
+ * duplicate keys, but entries are _not_ sorted by key--entries are included in
20
+ * insertion order. All operations are O(N) in the size of the map--the intention
21
+ * of this data structure is only to provide the convenience of programming against
22
+ * a map API. Large maps should use handwritten parent/child relationships instead.
23
+ * Maps that need sorted iteration rather than insertion order iteration should
24
+ * also be handwritten.
25
+ */
26
+ export function VecMap<K extends BcsType<any>, V extends BcsType<any>>(...typeParameters: [
27
+ K,
28
+ V
29
+ ]) {
30
+ return new MoveStruct({ name: `${$moduleName}::VecMap<${typeParameters[0].name as K['name']}, ${typeParameters[1].name as V['name']}>`, fields: {
31
+ contents: bcs.vector(Entry(typeParameters[0], typeParameters[1]))
32
+ } });
33
+ }
@@ -0,0 +1,156 @@
1
+ /**************************************************************
2
+ * THIS FILE IS GENERATED AND SHOULD NOT BE MANUALLY MODIFIED *
3
+ **************************************************************/
4
+
5
+
6
+ /**
7
+ * First-party credits extension for releases.
8
+ *
9
+ * Attribution (top-line billing) is display-oriented and varies across platforms,
10
+ * so it lives here as a dynamic field on the release rather than in immutable
11
+ * core. The data is attached under `ExtensionKey()` via the release's cap-gated
12
+ * `uid_mut`, so every mutation is authorized by the release's admin and credits
13
+ * survive into any lifecycle state (they may be attached before or after the
14
+ * release is published).
15
+ *
16
+ * This is Miso's canonical credits standard; because it is an extension, other
17
+ * parties may publish their own release-credits standard against the same
18
+ * `Release`. Credits are NOT read by the economics — they are attribution.
19
+ *
20
+ * A release credit carries exactly one role: a party is billed as either a
21
+ * `Primary` or a `Featured` artist on the release.
22
+ */
23
+
24
+ import { MoveTuple, MoveStruct, normalizeMoveArguments, type RawTransactionArgument } from '../utils/index.ts';
25
+ import { bcs } from '@mysten/sui/bcs';
26
+ import { type Transaction, type TransactionArgument } from '@mysten/sui/transactions';
27
+ import * as vec_map from './deps/sui/vec_map.ts';
28
+ import * as credit from './deps/miso_credit/credit.ts';
29
+ import * as release_party_role from './release_party_role.ts';
30
+ const $moduleName = '@local-pkg/release_credits::release_credits';
31
+ export const ExtensionKey = new MoveTuple({ name: `${$moduleName}::ExtensionKey`, fields: [bcs.bool()] });
32
+ export const ReleaseCredits = new MoveStruct({ name: `${$moduleName}::ReleaseCredits`, fields: {
33
+ /** Map of party IDs to their credit (display name + role). */
34
+ credits: vec_map.VecMap(bcs.Address, credit.Credit(release_party_role.ReleasePartyRole))
35
+ } });
36
+ export const CreditAddedEvent = new MoveStruct({ name: `${$moduleName}::CreditAddedEvent`, fields: {
37
+ release_id: bcs.Address,
38
+ party_id: bcs.Address,
39
+ credit: credit.Credit(release_party_role.ReleasePartyRole)
40
+ } });
41
+ export const CreditRemovedEvent = new MoveStruct({ name: `${$moduleName}::CreditRemovedEvent`, fields: {
42
+ release_id: bcs.Address,
43
+ party_id: bcs.Address,
44
+ credit: credit.Credit(release_party_role.ReleasePartyRole)
45
+ } });
46
+ export interface AddCreditArguments {
47
+ self: RawTransactionArgument<string>;
48
+ cap: RawTransactionArgument<string>;
49
+ party: RawTransactionArgument<string>;
50
+ credit: TransactionArgument;
51
+ }
52
+ export interface AddCreditOptions {
53
+ package?: string;
54
+ arguments: AddCreditArguments | [
55
+ self: RawTransactionArgument<string>,
56
+ cap: RawTransactionArgument<string>,
57
+ party: RawTransactionArgument<string>,
58
+ credit: TransactionArgument
59
+ ];
60
+ }
61
+ /**
62
+ * Adds a credit for a party on the release, lazily creating the credits record on
63
+ * first use. Each credit must carry exactly one role (Primary or Featured), and a
64
+ * party may hold at most one credit. Requires the release's admin capability.
65
+ */
66
+ export function addCredit(options: AddCreditOptions) {
67
+ const packageAddress = options.package ?? '@local-pkg/release_credits';
68
+ const argumentsTypes = [
69
+ null,
70
+ null,
71
+ null,
72
+ null
73
+ ] satisfies (string | null)[];
74
+ const parameterNames = ["self", "cap", "party", "credit"];
75
+ return (tx: Transaction) => tx.moveCall({
76
+ package: packageAddress,
77
+ module: 'release_credits',
78
+ function: 'add_credit',
79
+ arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
80
+ });
81
+ }
82
+ export interface RemoveCreditArguments {
83
+ self: RawTransactionArgument<string>;
84
+ cap: RawTransactionArgument<string>;
85
+ partyId: RawTransactionArgument<string>;
86
+ }
87
+ export interface RemoveCreditOptions {
88
+ package?: string;
89
+ arguments: RemoveCreditArguments | [
90
+ self: RawTransactionArgument<string>,
91
+ cap: RawTransactionArgument<string>,
92
+ partyId: RawTransactionArgument<string>
93
+ ];
94
+ }
95
+ /** Removes a party's credit. Requires the release's admin capability. */
96
+ export function removeCredit(options: RemoveCreditOptions) {
97
+ const packageAddress = options.package ?? '@local-pkg/release_credits';
98
+ const argumentsTypes = [
99
+ null,
100
+ null,
101
+ '0x2::object::ID'
102
+ ] satisfies (string | null)[];
103
+ const parameterNames = ["self", "cap", "partyId"];
104
+ return (tx: Transaction) => tx.moveCall({
105
+ package: packageAddress,
106
+ module: 'release_credits',
107
+ function: 'remove_credit',
108
+ arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
109
+ });
110
+ }
111
+ export interface HasCreditsArguments {
112
+ self: RawTransactionArgument<string>;
113
+ }
114
+ export interface HasCreditsOptions {
115
+ package?: string;
116
+ arguments: HasCreditsArguments | [
117
+ self: RawTransactionArgument<string>
118
+ ];
119
+ }
120
+ /** Returns whether a credits record has been attached to this release yet. */
121
+ export function hasCredits(options: HasCreditsOptions) {
122
+ const packageAddress = options.package ?? '@local-pkg/release_credits';
123
+ const argumentsTypes = [
124
+ null
125
+ ] satisfies (string | null)[];
126
+ const parameterNames = ["self"];
127
+ return (tx: Transaction) => tx.moveCall({
128
+ package: packageAddress,
129
+ module: 'release_credits',
130
+ function: 'has_credits',
131
+ arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
132
+ });
133
+ }
134
+ export interface CreditsArguments {
135
+ self: RawTransactionArgument<string>;
136
+ }
137
+ export interface CreditsOptions {
138
+ package?: string;
139
+ arguments: CreditsArguments | [
140
+ self: RawTransactionArgument<string>
141
+ ];
142
+ }
143
+ /** Returns the party-to-credit map. Aborts if no credits are attached. */
144
+ export function credits(options: CreditsOptions) {
145
+ const packageAddress = options.package ?? '@local-pkg/release_credits';
146
+ const argumentsTypes = [
147
+ null
148
+ ] satisfies (string | null)[];
149
+ const parameterNames = ["self"];
150
+ return (tx: Transaction) => tx.moveCall({
151
+ package: packageAddress,
152
+ module: 'release_credits',
153
+ function: 'credits',
154
+ arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
155
+ });
156
+ }
@@ -0,0 +1,87 @@
1
+ /**************************************************************
2
+ * THIS FILE IS GENERATED AND SHOULD NOT BE MANUALLY MODIFIED *
3
+ **************************************************************/
4
+
5
+
6
+ /**
7
+ * Defines the roles that parties can hold on a release. Releases are the
8
+ * commercial packaging of recordings (an album, single, EP), and a release credit
9
+ * captures top-line billing: a party is either a primary artist or a featured
10
+ * artist on the release.
11
+ *
12
+ * ### Design
13
+ *
14
+ * `ReleasePartyRole` is a closed enum: variants can only be constructed and
15
+ * matched inside this module, so the `new_*_role` constructors are the external
16
+ * write-API and `name()` is the external read-API.
17
+ *
18
+ * - **No level axis and no `Custom` escape hatch.** Release billing is a small,
19
+ * fixed vocabulary: `Primary` or `Featured`.
20
+ * - **`name()` is the canonical identifier**, returned as a stable PascalCase
21
+ * token (`"Primary"` / `"Featured"`).
22
+ *
23
+ * These identifiers are Miso's own canonical vocabulary; any overlap with an
24
+ * external standard (e.g. DDEX) is coincidental, not a reproduction of it.
25
+ */
26
+
27
+ import { MoveEnum, normalizeMoveArguments } from '../utils/index.ts';
28
+ import { type Transaction, type TransactionArgument } from '@mysten/sui/transactions';
29
+ const $moduleName = '@local-pkg/release_credits::release_party_role';
30
+ /** Represents a party's billing on a release. */
31
+ export const ReleasePartyRole = new MoveEnum({ name: `${$moduleName}::ReleasePartyRole`, fields: {
32
+ /** A primary (headline) artist on the release. */
33
+ Primary: null,
34
+ /** A featured (guest) artist on the release. */
35
+ Featured: null
36
+ } });
37
+ export interface NewPrimaryRoleOptions {
38
+ package?: string;
39
+ arguments?: [
40
+ ];
41
+ }
42
+ /** Creates a new Primary role. */
43
+ export function newPrimaryRole(options: NewPrimaryRoleOptions = {}) {
44
+ const packageAddress = options.package ?? '@local-pkg/release_credits';
45
+ return (tx: Transaction) => tx.moveCall({
46
+ package: packageAddress,
47
+ module: 'release_party_role',
48
+ function: 'new_primary_role',
49
+ });
50
+ }
51
+ export interface NewFeaturedRoleOptions {
52
+ package?: string;
53
+ arguments?: [
54
+ ];
55
+ }
56
+ /** Creates a new Featured role. */
57
+ export function newFeaturedRole(options: NewFeaturedRoleOptions = {}) {
58
+ const packageAddress = options.package ?? '@local-pkg/release_credits';
59
+ return (tx: Transaction) => tx.moveCall({
60
+ package: packageAddress,
61
+ module: 'release_party_role',
62
+ function: 'new_featured_role',
63
+ });
64
+ }
65
+ export interface NameArguments {
66
+ self: TransactionArgument;
67
+ }
68
+ export interface NameOptions {
69
+ package?: string;
70
+ arguments: NameArguments | [
71
+ self: TransactionArgument
72
+ ];
73
+ }
74
+ /** Returns the canonical identifier of the role as a stable PascalCase token. */
75
+ export function name(options: NameOptions) {
76
+ const packageAddress = options.package ?? '@local-pkg/release_credits';
77
+ const argumentsTypes = [
78
+ null
79
+ ] satisfies (string | null)[];
80
+ const parameterNames = ["self"];
81
+ return (tx: Transaction) => tx.moveCall({
82
+ package: packageAddress,
83
+ module: 'release_party_role',
84
+ function: 'name',
85
+ arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
86
+ });
87
+ }