@seedprotocol/publish 0.6.9 → 0.6.10

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 (312) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/README.md +1 -1
  3. package/dist/{chainConfig-CA1Hrrjg.js → chainConfig-DWzoOtkS.js} +394 -328
  4. package/dist/chainConfig-DWzoOtkS.js.map +1 -0
  5. package/dist/config.d.ts +5 -4
  6. package/dist/config.d.ts.map +1 -1
  7. package/dist/ensureAutomationSessionKey-h3zOmDr5.js +84 -0
  8. package/dist/ensureAutomationSessionKey-h3zOmDr5.js.map +1 -0
  9. package/dist/{ensureModularPublishBootstrap-DGBKVGg5.js → ensureModularPublishBootstrap-BImiIFJe.js} +9 -10
  10. package/dist/{ensureModularPublishBootstrap-5HJDqJJM.js.map → ensureModularPublishBootstrap-BImiIFJe.js.map} +1 -1
  11. package/dist/{ensureSmartWalletThenPublish-Bm58tc-b.js → ensureSmartWalletThenPublish-DuOYPJFd.js} +9 -10
  12. package/dist/{ensureSmartWalletThenPublish-Bm58tc-b.js.map → ensureSmartWalletThenPublish-DuOYPJFd.js.map} +1 -1
  13. package/dist/errors.d.ts +9 -0
  14. package/dist/errors.d.ts.map +1 -1
  15. package/dist/helpers/abi/executor.d.ts +12 -0
  16. package/dist/helpers/abi/executor.d.ts.map +1 -1
  17. package/dist/helpers/abi/factory.d.ts +11 -0
  18. package/dist/helpers/abi/factory.d.ts.map +1 -1
  19. package/dist/helpers/abi/seedExecutorRouter.d.ts +9 -1
  20. package/dist/helpers/abi/seedExecutorRouter.d.ts.map +1 -1
  21. package/dist/helpers/adapters/thirdwebAccount.d.ts.map +1 -1
  22. package/dist/helpers/chainClient.d.ts +18 -2
  23. package/dist/helpers/chainClient.d.ts.map +1 -1
  24. package/dist/helpers/contracts/index.d.ts +9 -0
  25. package/dist/helpers/contracts/index.d.ts.map +1 -1
  26. package/dist/helpers/describeRevert.d.ts +3 -2
  27. package/dist/helpers/describeRevert.d.ts.map +1 -1
  28. package/dist/helpers/enrollPublishAutomation.d.ts +2 -2
  29. package/dist/helpers/enrollPublishAutomation.d.ts.map +1 -1
  30. package/dist/helpers/ensureAutomationSessionKey.d.ts.map +1 -1
  31. package/dist/helpers/ensureExecutorModule.d.ts +28 -5
  32. package/dist/helpers/ensureExecutorModule.d.ts.map +1 -1
  33. package/dist/helpers/executorModuleReadiness.d.ts +15 -1
  34. package/dist/helpers/executorModuleReadiness.d.ts.map +1 -1
  35. package/dist/helpers/gasLog.d.ts +8 -0
  36. package/dist/helpers/gasLog.d.ts.map +1 -0
  37. package/dist/helpers/seedPaymaster.d.ts +27 -0
  38. package/dist/helpers/seedPaymaster.d.ts.map +1 -0
  39. package/dist/helpers/thirdweb.d.ts.map +1 -1
  40. package/dist/index.d.ts +3 -3
  41. package/dist/index.d.ts.map +1 -1
  42. package/dist/index.js +271 -272
  43. package/dist/index.js.map +1 -1
  44. package/dist/{managedAccountAdmin-B64V1rlU.js → managedAccountAdmin-B4HkLWWE.js} +9 -10
  45. package/dist/{managedAccountAdmin-B64V1rlU.js.map → managedAccountAdmin-B4HkLWWE.js.map} +1 -1
  46. package/dist/{publishAuthorization-CxBkijU6.js → publishAuthorization-DgDI4zor.js} +1104 -1018
  47. package/dist/publishAuthorization-DgDI4zor.js.map +1 -0
  48. package/dist/{publishThirdwebClient-CBD9sKJR.js → publishThirdwebClient-CO18ST7C.js} +2 -2
  49. package/dist/{publishThirdwebClient-CBD9sKJR.js.map → publishThirdwebClient-CO18ST7C.js.map} +1 -1
  50. package/dist/{resolveRevokeAccount-CehU81k6.js → resolveRevokeAccount-DsNod8ti.js} +11 -11
  51. package/dist/{resolveRevokeAccount-B5iXpuRT.js.map → resolveRevokeAccount-DsNod8ti.js.map} +1 -1
  52. package/dist/thirdweb.d.ts +2 -1
  53. package/dist/thirdweb.d.ts.map +1 -1
  54. package/dist/thirdweb.js +147 -148
  55. package/dist/thirdweb.js.map +1 -1
  56. package/dist/{worker-2dUZSapK.js → worker-CN7zg73B.js} +2 -2
  57. package/dist/{worker-2dUZSapK.js.map → worker-CN7zg73B.js.map} +1 -1
  58. package/package.json +6 -6
  59. package/dist/chainConfig-3sSqEVQh.js +0 -1433
  60. package/dist/chainConfig-3sSqEVQh.js.map +0 -1
  61. package/dist/chainConfig-3wlYarAG.js +0 -1433
  62. package/dist/chainConfig-3wlYarAG.js.map +0 -1
  63. package/dist/chainConfig-BRcsMopd.js +0 -1442
  64. package/dist/chainConfig-BRcsMopd.js.map +0 -1
  65. package/dist/chainConfig-BYm5OXpk.js +0 -1433
  66. package/dist/chainConfig-BYm5OXpk.js.map +0 -1
  67. package/dist/chainConfig-CA1Hrrjg.js.map +0 -1
  68. package/dist/chainConfig-CYy0XJ0M.js +0 -1283
  69. package/dist/chainConfig-CYy0XJ0M.js.map +0 -1
  70. package/dist/chainConfig-CfVGYAsY.js +0 -1311
  71. package/dist/chainConfig-CfVGYAsY.js.map +0 -1
  72. package/dist/chainConfig-DDA4YmAB.js +0 -1424
  73. package/dist/chainConfig-DDA4YmAB.js.map +0 -1
  74. package/dist/config-BA9la8B6.js +0 -941
  75. package/dist/config-BA9la8B6.js.map +0 -1
  76. package/dist/config-BqguD2Tt.js +0 -806
  77. package/dist/config-BqguD2Tt.js.map +0 -1
  78. package/dist/config-CPBd5C_b.js +0 -1201
  79. package/dist/config-CPBd5C_b.js.map +0 -1
  80. package/dist/config-DkIapO94.js +0 -955
  81. package/dist/config-DkIapO94.js.map +0 -1
  82. package/dist/config-EQZZNH9H.js +0 -955
  83. package/dist/config-EQZZNH9H.js.map +0 -1
  84. package/dist/config-qjpaJcBA.js +0 -947
  85. package/dist/config-qjpaJcBA.js.map +0 -1
  86. package/dist/deploy-BJYwLfz-.js +0 -15
  87. package/dist/deploy-BJYwLfz-.js.map +0 -1
  88. package/dist/enrollPublishAutomation-DYQMoylY.js +0 -3422
  89. package/dist/enrollPublishAutomation-DYQMoylY.js.map +0 -1
  90. package/dist/ensureAutomationSessionKey-BMHLKfjj.js +0 -85
  91. package/dist/ensureAutomationSessionKey-BMHLKfjj.js.map +0 -1
  92. package/dist/ensureAutomationSessionKey-BZ9_3FMW.js +0 -86
  93. package/dist/ensureAutomationSessionKey-BZ9_3FMW.js.map +0 -1
  94. package/dist/ensureAutomationSessionKey-Bq0PaTYE.js +0 -84
  95. package/dist/ensureAutomationSessionKey-Bq0PaTYE.js.map +0 -1
  96. package/dist/ensureAutomationSessionKey-Bw74ZSGI.js +0 -85
  97. package/dist/ensureAutomationSessionKey-Bw74ZSGI.js.map +0 -1
  98. package/dist/ensureAutomationSessionKey-C8D7BFjU.js +0 -85
  99. package/dist/ensureAutomationSessionKey-C8D7BFjU.js.map +0 -1
  100. package/dist/ensureAutomationSessionKey-CClLVX2w.js +0 -85
  101. package/dist/ensureAutomationSessionKey-CClLVX2w.js.map +0 -1
  102. package/dist/ensureAutomationSessionKey-CNNN1jBQ.js +0 -85
  103. package/dist/ensureAutomationSessionKey-CNNN1jBQ.js.map +0 -1
  104. package/dist/ensureAutomationSessionKey-CeUbjcCl.js +0 -85
  105. package/dist/ensureAutomationSessionKey-CeUbjcCl.js.map +0 -1
  106. package/dist/ensureAutomationSessionKey-D8Gki6U6.js +0 -85
  107. package/dist/ensureAutomationSessionKey-D8Gki6U6.js.map +0 -1
  108. package/dist/ensureAutomationSessionKey-DEH7nwUc.js +0 -86
  109. package/dist/ensureAutomationSessionKey-DEH7nwUc.js.map +0 -1
  110. package/dist/ensureAutomationSessionKey-DKriW4Hr.js +0 -85
  111. package/dist/ensureAutomationSessionKey-DKriW4Hr.js.map +0 -1
  112. package/dist/ensureAutomationSessionKey-Dhvbii2M.js +0 -86
  113. package/dist/ensureAutomationSessionKey-Dhvbii2M.js.map +0 -1
  114. package/dist/ensureAutomationSessionKey-Dyfk8qVp.js +0 -85
  115. package/dist/ensureAutomationSessionKey-Dyfk8qVp.js.map +0 -1
  116. package/dist/ensureModularPublishBootstrap-5HJDqJJM.js +0 -24
  117. package/dist/ensureModularPublishBootstrap-BW8jKN_A.js +0 -24
  118. package/dist/ensureModularPublishBootstrap-BW8jKN_A.js.map +0 -1
  119. package/dist/ensureModularPublishBootstrap-BhYNmLzT.js +0 -24
  120. package/dist/ensureModularPublishBootstrap-BhYNmLzT.js.map +0 -1
  121. package/dist/ensureModularPublishBootstrap-Bsw1xSCt.js +0 -24
  122. package/dist/ensureModularPublishBootstrap-Bsw1xSCt.js.map +0 -1
  123. package/dist/ensureModularPublishBootstrap-Btih5xbB.js +0 -129
  124. package/dist/ensureModularPublishBootstrap-Btih5xbB.js.map +0 -1
  125. package/dist/ensureModularPublishBootstrap-C8wdnH1P.js +0 -128
  126. package/dist/ensureModularPublishBootstrap-C8wdnH1P.js.map +0 -1
  127. package/dist/ensureModularPublishBootstrap-CI4U08Gc.js +0 -129
  128. package/dist/ensureModularPublishBootstrap-CI4U08Gc.js.map +0 -1
  129. package/dist/ensureModularPublishBootstrap-CcU-hXll.js +0 -128
  130. package/dist/ensureModularPublishBootstrap-CcU-hXll.js.map +0 -1
  131. package/dist/ensureModularPublishBootstrap-CdrykHAi.js +0 -24
  132. package/dist/ensureModularPublishBootstrap-CdrykHAi.js.map +0 -1
  133. package/dist/ensureModularPublishBootstrap-DGBKVGg5.js.map +0 -1
  134. package/dist/ensureModularPublishBootstrap-DaREOqSc.js +0 -129
  135. package/dist/ensureModularPublishBootstrap-DaREOqSc.js.map +0 -1
  136. package/dist/ensureModularPublishBootstrap-DxIG-LUP.js +0 -24
  137. package/dist/ensureModularPublishBootstrap-DxIG-LUP.js.map +0 -1
  138. package/dist/ensureModularPublishBootstrap-Jm1AAqBo.js +0 -127
  139. package/dist/ensureModularPublishBootstrap-Jm1AAqBo.js.map +0 -1
  140. package/dist/ensureSessionKey-D2Lq-56x.js +0 -363
  141. package/dist/ensureSessionKey-D2Lq-56x.js.map +0 -1
  142. package/dist/ensureSmartWalletThenPublish-BFPugsKJ.js +0 -48
  143. package/dist/ensureSmartWalletThenPublish-BFPugsKJ.js.map +0 -1
  144. package/dist/ensureSmartWalletThenPublish-BSYzckyS.js +0 -49
  145. package/dist/ensureSmartWalletThenPublish-BSYzckyS.js.map +0 -1
  146. package/dist/ensureSmartWalletThenPublish-Bf8FN1un.js +0 -49
  147. package/dist/ensureSmartWalletThenPublish-Bf8FN1un.js.map +0 -1
  148. package/dist/ensureSmartWalletThenPublish-Bl415Ss6.js +0 -48
  149. package/dist/ensureSmartWalletThenPublish-Bl415Ss6.js.map +0 -1
  150. package/dist/ensureSmartWalletThenPublish-Bmm5Fpat.js +0 -49
  151. package/dist/ensureSmartWalletThenPublish-Bmm5Fpat.js.map +0 -1
  152. package/dist/ensureSmartWalletThenPublish-CE7acryB.js +0 -49
  153. package/dist/ensureSmartWalletThenPublish-CE7acryB.js.map +0 -1
  154. package/dist/ensureSmartWalletThenPublish-D5GSZRyZ.js +0 -48
  155. package/dist/ensureSmartWalletThenPublish-D5GSZRyZ.js.map +0 -1
  156. package/dist/ensureSmartWalletThenPublish-DAomriGc.js +0 -48
  157. package/dist/ensureSmartWalletThenPublish-DAomriGc.js.map +0 -1
  158. package/dist/ensureSmartWalletThenPublish-DaZf3q5S.js +0 -48
  159. package/dist/ensureSmartWalletThenPublish-DaZf3q5S.js.map +0 -1
  160. package/dist/ensureSmartWalletThenPublish-Dta2AOyJ.js +0 -48
  161. package/dist/ensureSmartWalletThenPublish-Dta2AOyJ.js.map +0 -1
  162. package/dist/ensureSmartWalletThenPublish-ekb0xJRn.js +0 -48
  163. package/dist/ensureSmartWalletThenPublish-ekb0xJRn.js.map +0 -1
  164. package/dist/ensureSmartWalletThenPublish-v5fhvKxZ.js +0 -48
  165. package/dist/ensureSmartWalletThenPublish-v5fhvKxZ.js.map +0 -1
  166. package/dist/errors-Du3LNbJN.js +0 -70
  167. package/dist/errors-Du3LNbJN.js.map +0 -1
  168. package/dist/errors-PZAaDlkq.js +0 -79
  169. package/dist/errors-PZAaDlkq.js.map +0 -1
  170. package/dist/helpers/adapters/managedAccountTxSender.d.ts +0 -21
  171. package/dist/helpers/adapters/managedAccountTxSender.d.ts.map +0 -1
  172. package/dist/helpers/modularAccount/abi.d.ts +0 -173
  173. package/dist/helpers/modularAccount/abi.d.ts.map +0 -1
  174. package/dist/helpers/modularAccount/deploy.d.ts +0 -13
  175. package/dist/helpers/modularAccount/deploy.d.ts.map +0 -1
  176. package/dist/helpers/modularAccount/eip712.d.ts +0 -30
  177. package/dist/helpers/modularAccount/eip712.d.ts.map +0 -1
  178. package/dist/helpers/modularAccount/encode.d.ts +0 -16
  179. package/dist/helpers/modularAccount/encode.d.ts.map +0 -1
  180. package/dist/helpers/modularAccount/ensureModule.d.ts +0 -10
  181. package/dist/helpers/modularAccount/ensureModule.d.ts.map +0 -1
  182. package/dist/helpers/modularAccount/ensureSessionKey.d.ts +0 -25
  183. package/dist/helpers/modularAccount/ensureSessionKey.d.ts.map +0 -1
  184. package/dist/helpers/modularAccount/index.d.ts +0 -9
  185. package/dist/helpers/modularAccount/index.d.ts.map +0 -1
  186. package/dist/helpers/modularAccount/permissions.d.ts +0 -32
  187. package/dist/helpers/modularAccount/permissions.d.ts.map +0 -1
  188. package/dist/helpers/modularAccount/reads.d.ts +0 -28
  189. package/dist/helpers/modularAccount/reads.d.ts.map +0 -1
  190. package/dist/helpers/thirdwebEnrollPublishAutomation.d.ts +0 -31
  191. package/dist/helpers/thirdwebEnrollPublishAutomation.d.ts.map +0 -1
  192. package/dist/helpers/thirdwebModularBootstrap.d.ts +0 -8
  193. package/dist/helpers/thirdwebModularBootstrap.d.ts.map +0 -1
  194. package/dist/helpers/transformPayloadToIntegerIds.d.ts +0 -34
  195. package/dist/helpers/transformPayloadToIntegerIds.d.ts.map +0 -1
  196. package/dist/managedAccountAdmin-BVLGWpEb.js +0 -29
  197. package/dist/managedAccountAdmin-BVLGWpEb.js.map +0 -1
  198. package/dist/managedAccountAdmin-Bje6X8Ds.js +0 -29
  199. package/dist/managedAccountAdmin-Bje6X8Ds.js.map +0 -1
  200. package/dist/managedAccountAdmin-C84-IlQ9.js +0 -29
  201. package/dist/managedAccountAdmin-C84-IlQ9.js.map +0 -1
  202. package/dist/managedAccountAdmin-DJMw6UH6.js +0 -29
  203. package/dist/managedAccountAdmin-DJMw6UH6.js.map +0 -1
  204. package/dist/managedAccountAdmin-DhCRBoPX.js +0 -29
  205. package/dist/managedAccountAdmin-DhCRBoPX.js.map +0 -1
  206. package/dist/managedAccountAdmin-NXD66lP5.js +0 -29
  207. package/dist/managedAccountAdmin-NXD66lP5.js.map +0 -1
  208. package/dist/publishAuthorization-B0G1em4a.js +0 -3695
  209. package/dist/publishAuthorization-B0G1em4a.js.map +0 -1
  210. package/dist/publishAuthorization-B1BVVfp0.js +0 -3604
  211. package/dist/publishAuthorization-B1BVVfp0.js.map +0 -1
  212. package/dist/publishAuthorization-BEqRnP2h.js +0 -3925
  213. package/dist/publishAuthorization-BEqRnP2h.js.map +0 -1
  214. package/dist/publishAuthorization-Bltn3y_K.js +0 -3599
  215. package/dist/publishAuthorization-Bltn3y_K.js.map +0 -1
  216. package/dist/publishAuthorization-By2Tt9kW.js +0 -3912
  217. package/dist/publishAuthorization-By2Tt9kW.js.map +0 -1
  218. package/dist/publishAuthorization-CSN2FsQk.js +0 -3479
  219. package/dist/publishAuthorization-CSN2FsQk.js.map +0 -1
  220. package/dist/publishAuthorization-CxBkijU6.js.map +0 -1
  221. package/dist/publishAuthorization-CxWY7lAQ.js +0 -3706
  222. package/dist/publishAuthorization-CxWY7lAQ.js.map +0 -1
  223. package/dist/publishAuthorization-DEriY_jm.js +0 -3687
  224. package/dist/publishAuthorization-DEriY_jm.js.map +0 -1
  225. package/dist/publishAuthorization-DfAQs1sN.js +0 -3707
  226. package/dist/publishAuthorization-DfAQs1sN.js.map +0 -1
  227. package/dist/publishAuthorization-DgdmgLTa.js +0 -3520
  228. package/dist/publishAuthorization-DgdmgLTa.js.map +0 -1
  229. package/dist/publishAuthorization-DjVrnMC0.js +0 -3925
  230. package/dist/publishAuthorization-DjVrnMC0.js.map +0 -1
  231. package/dist/publishAuthorization-DqhhCAhd.js +0 -3652
  232. package/dist/publishAuthorization-DqhhCAhd.js.map +0 -1
  233. package/dist/publishThirdwebClient-BdgkcqM7.js +0 -18
  234. package/dist/publishThirdwebClient-BdgkcqM7.js.map +0 -1
  235. package/dist/publishThirdwebClient-BkmDN480.js +0 -18
  236. package/dist/publishThirdwebClient-BkmDN480.js.map +0 -1
  237. package/dist/publishThirdwebClient-BnDhP3N-.js +0 -18
  238. package/dist/publishThirdwebClient-BnDhP3N-.js.map +0 -1
  239. package/dist/publishThirdwebClient-CQ29pzG2.js +0 -18
  240. package/dist/publishThirdwebClient-CQ29pzG2.js.map +0 -1
  241. package/dist/publishThirdwebClient-CZIVmr9Z.js +0 -18
  242. package/dist/publishThirdwebClient-CZIVmr9Z.js.map +0 -1
  243. package/dist/publishThirdwebClient-Ce7iBIsj.js +0 -18
  244. package/dist/publishThirdwebClient-Ce7iBIsj.js.map +0 -1
  245. package/dist/publishThirdwebClient-DroRrOFQ.js +0 -18
  246. package/dist/publishThirdwebClient-DroRrOFQ.js.map +0 -1
  247. package/dist/publishThirdwebClient-DzXFjQ7L.js +0 -18
  248. package/dist/publishThirdwebClient-DzXFjQ7L.js.map +0 -1
  249. package/dist/publishThirdwebClient-Dzb2vcEs.js +0 -18
  250. package/dist/publishThirdwebClient-Dzb2vcEs.js.map +0 -1
  251. package/dist/publishThirdwebClient-i8P7fivi.js +0 -18
  252. package/dist/publishThirdwebClient-i8P7fivi.js.map +0 -1
  253. package/dist/publishWalletRegistry-Cugh691z.js +0 -37
  254. package/dist/publishWalletRegistry-Cugh691z.js.map +0 -1
  255. package/dist/resolveRevokeAccount-B5iXpuRT.js +0 -38
  256. package/dist/resolveRevokeAccount-B7ImSb4Y.js +0 -38
  257. package/dist/resolveRevokeAccount-B7ImSb4Y.js.map +0 -1
  258. package/dist/resolveRevokeAccount-BEhKQBTm.js +0 -38
  259. package/dist/resolveRevokeAccount-BEhKQBTm.js.map +0 -1
  260. package/dist/resolveRevokeAccount-BM1j2l5Q.js +0 -38
  261. package/dist/resolveRevokeAccount-BM1j2l5Q.js.map +0 -1
  262. package/dist/resolveRevokeAccount-BtVG0xxc.js +0 -38
  263. package/dist/resolveRevokeAccount-BtVG0xxc.js.map +0 -1
  264. package/dist/resolveRevokeAccount-CJZZdBcQ.js +0 -39
  265. package/dist/resolveRevokeAccount-CJZZdBcQ.js.map +0 -1
  266. package/dist/resolveRevokeAccount-CaIMuCee.js +0 -39
  267. package/dist/resolveRevokeAccount-CaIMuCee.js.map +0 -1
  268. package/dist/resolveRevokeAccount-CehU81k6.js.map +0 -1
  269. package/dist/resolveRevokeAccount-Cg4TQgnd.js +0 -38
  270. package/dist/resolveRevokeAccount-Cg4TQgnd.js.map +0 -1
  271. package/dist/resolveRevokeAccount-DHnxtEIj.js +0 -39
  272. package/dist/resolveRevokeAccount-DHnxtEIj.js.map +0 -1
  273. package/dist/resolveRevokeAccount-DJKfLlyK.js +0 -38
  274. package/dist/resolveRevokeAccount-DJKfLlyK.js.map +0 -1
  275. package/dist/resolveRevokeAccount-S-2WXkNh.js +0 -38
  276. package/dist/resolveRevokeAccount-S-2WXkNh.js.map +0 -1
  277. package/dist/resolveRevokeAccount-mzR11KJ4.js +0 -38
  278. package/dist/resolveRevokeAccount-mzR11KJ4.js.map +0 -1
  279. package/dist/resolveRevokeAccount-yWARIv9i.js +0 -38
  280. package/dist/resolveRevokeAccount-yWARIv9i.js.map +0 -1
  281. package/dist/seedSigner-CFzMD7Rb.js +0 -66
  282. package/dist/seedSigner-CFzMD7Rb.js.map +0 -1
  283. package/dist/thirdweb-BoksPRz3.js +0 -194
  284. package/dist/thirdweb-BoksPRz3.js.map +0 -1
  285. package/dist/thirdwebAccount-C2iOcp4_.js +0 -59
  286. package/dist/thirdwebAccount-C2iOcp4_.js.map +0 -1
  287. package/dist/worker-B1PcFPLi.js +0 -69
  288. package/dist/worker-B1PcFPLi.js.map +0 -1
  289. package/dist/worker-B8gN5WTx.js +0 -69
  290. package/dist/worker-B8gN5WTx.js.map +0 -1
  291. package/dist/worker-BCG1r0AS.js +0 -69
  292. package/dist/worker-BCG1r0AS.js.map +0 -1
  293. package/dist/worker-BgErCNTb.js +0 -69
  294. package/dist/worker-BgErCNTb.js.map +0 -1
  295. package/dist/worker-C07rPV2G.js +0 -69
  296. package/dist/worker-C07rPV2G.js.map +0 -1
  297. package/dist/worker-C9Za_dlQ.js +0 -69
  298. package/dist/worker-C9Za_dlQ.js.map +0 -1
  299. package/dist/worker-CEgulQnm.js +0 -69
  300. package/dist/worker-CEgulQnm.js.map +0 -1
  301. package/dist/worker-C_TL94He.js +0 -69
  302. package/dist/worker-C_TL94He.js.map +0 -1
  303. package/dist/worker-CbtzcKG6.js +0 -69
  304. package/dist/worker-CbtzcKG6.js.map +0 -1
  305. package/dist/worker-DBC_g-3I.js +0 -69
  306. package/dist/worker-DBC_g-3I.js.map +0 -1
  307. package/dist/worker-DHUm-TeQ.js +0 -69
  308. package/dist/worker-DHUm-TeQ.js.map +0 -1
  309. package/dist/worker-DypHzXgH.js +0 -69
  310. package/dist/worker-DypHzXgH.js.map +0 -1
  311. package/dist/worker-ZL4Wg19t.js +0 -69
  312. package/dist/worker-ZL4Wg19t.js.map +0 -1
@@ -1,1433 +0,0 @@
1
- import { t as e } from "./rolldown-runtime-Dy4uBu1J.js";
2
- import { optimismSepolia as t } from "viem/chains";
3
- import { DEFAULT_ARWEAVE_GRAPHQL_URL as n, VERSION_SCHEMA_UID as r, assertLocalDbChain as i, client as a, getAttesterForSeed as o, getGetAdditionalSyncAddresses as s, getMetadataAttestationUidsForSeedUid as c, getVersionsForSeedUid as ee, isValidEasAttestationUid as l, setAdditionalSyncAddresses as u, setGetPublisherForNewSeeds as d, setRevokeExecutor as te, updateSeedRevokedAt as ne } from "@seedprotocol/sdk";
4
- import { createPublicClient as f, encodeAbiParameters as p, encodeFunctionData as m, http as h, parseEventLogs as g } from "viem";
5
- import { prepareTransaction as re, sendTransaction as ie } from "thirdweb";
6
- import { ethers as ae } from "ethers";
7
- import { defineChain as oe, optimismSepolia as se } from "thirdweb/chains";
8
- import { configureEasReadChain as ce, expectEasReadChain as le, resolveEasChainDeployment as ue } from "@seedprotocol/eas";
9
- //#region src/helpers/constants.ts
10
- var de = "0x44d562ac1d7cd77e232978687fea027ace48f719cf1d58c7888e509663bb87fc", fe = { 11155420: "0x76f47d88bfaf670f5208911181fcdc0e160cb16d" }, pe = "0xcd8c945872df8e664e55cf8885c85ea3ea8f2148", me = pe, he = {
11
- SUCCESS: "success",
12
- FAILURE: "failure"
13
- }, ge = [
14
- "pollingForConfirmation",
15
- "uploadingData",
16
- "uploadingViaBundler",
17
- "uploadingViaBundlerPhase2"
18
- ], _e = 3e4, _ = t, ve = [
19
- {
20
- type: "error",
21
- name: "AccessDenied",
22
- inputs: []
23
- },
24
- {
25
- type: "error",
26
- name: "AlreadyRevoked",
27
- inputs: []
28
- },
29
- {
30
- type: "error",
31
- name: "InvalidRevocation",
32
- inputs: []
33
- },
34
- {
35
- type: "error",
36
- name: "InvalidRevocations",
37
- inputs: []
38
- },
39
- {
40
- type: "error",
41
- name: "InvalidSchema",
42
- inputs: []
43
- },
44
- {
45
- type: "error",
46
- name: "Irrevocable",
47
- inputs: []
48
- },
49
- {
50
- type: "error",
51
- name: "NotFound",
52
- inputs: []
53
- },
54
- {
55
- type: "error",
56
- name: "NotPayable",
57
- inputs: []
58
- },
59
- {
60
- type: "error",
61
- name: "InsufficientValue",
62
- inputs: []
63
- },
64
- {
65
- type: "error",
66
- name: "InvalidLength",
67
- inputs: []
68
- }
69
- ], ye = [
70
- {
71
- name: "recipient",
72
- type: "address"
73
- },
74
- {
75
- name: "expirationTime",
76
- type: "uint64"
77
- },
78
- {
79
- name: "revocable",
80
- type: "bool"
81
- },
82
- {
83
- name: "refUID",
84
- type: "bytes32"
85
- },
86
- {
87
- name: "data",
88
- type: "bytes"
89
- },
90
- {
91
- name: "value",
92
- type: "uint256"
93
- }
94
- ], v = [
95
- {
96
- type: "function",
97
- name: "attest",
98
- stateMutability: "payable",
99
- inputs: [{
100
- name: "request",
101
- type: "tuple",
102
- components: [{
103
- name: "schema",
104
- type: "bytes32"
105
- }, {
106
- name: "data",
107
- type: "tuple",
108
- components: ye
109
- }]
110
- }],
111
- outputs: [{ type: "bytes32" }]
112
- },
113
- {
114
- type: "function",
115
- name: "multiAttest",
116
- stateMutability: "payable",
117
- inputs: [{
118
- name: "requests",
119
- type: "tuple[]",
120
- components: [{
121
- name: "schema",
122
- type: "bytes32"
123
- }, {
124
- name: "data",
125
- type: "tuple[]",
126
- components: ye
127
- }]
128
- }],
129
- outputs: [{ type: "bytes32[]" }]
130
- },
131
- {
132
- type: "function",
133
- name: "multiRevoke",
134
- stateMutability: "payable",
135
- inputs: [{
136
- name: "multiRequests",
137
- type: "tuple[]",
138
- components: [{
139
- name: "schema",
140
- type: "bytes32"
141
- }, {
142
- name: "data",
143
- type: "tuple[]",
144
- components: [{
145
- name: "uid",
146
- type: "bytes32"
147
- }, {
148
- name: "value",
149
- type: "uint256"
150
- }]
151
- }]
152
- }],
153
- outputs: []
154
- },
155
- {
156
- type: "event",
157
- name: "Attested",
158
- inputs: [
159
- {
160
- name: "recipient",
161
- type: "address",
162
- indexed: !0
163
- },
164
- {
165
- name: "attester",
166
- type: "address",
167
- indexed: !0
168
- },
169
- {
170
- name: "uid",
171
- type: "bytes32",
172
- indexed: !1
173
- },
174
- {
175
- name: "schemaUID",
176
- type: "bytes32",
177
- indexed: !0
178
- }
179
- ]
180
- },
181
- ...ve
182
- ], y = [{
183
- name: "schema",
184
- type: "bytes32"
185
- }, {
186
- name: "data",
187
- type: "tuple[]",
188
- components: [
189
- {
190
- name: "recipient",
191
- type: "address"
192
- },
193
- {
194
- name: "expirationTime",
195
- type: "uint64"
196
- },
197
- {
198
- name: "revocable",
199
- type: "bool"
200
- },
201
- {
202
- name: "refUID",
203
- type: "bytes32"
204
- },
205
- {
206
- name: "data",
207
- type: "bytes"
208
- },
209
- {
210
- name: "value",
211
- type: "uint256"
212
- }
213
- ]
214
- }], be = [{
215
- type: "function",
216
- name: "multiPublish",
217
- stateMutability: "nonpayable",
218
- inputs: [{
219
- name: "requests",
220
- type: "tuple[]",
221
- components: [
222
- {
223
- name: "localId",
224
- type: "string"
225
- },
226
- {
227
- name: "seedUid",
228
- type: "bytes32"
229
- },
230
- {
231
- name: "seedSchemaUid",
232
- type: "bytes32"
233
- },
234
- {
235
- name: "versionUid",
236
- type: "bytes32"
237
- },
238
- {
239
- name: "versionSchemaUid",
240
- type: "bytes32"
241
- },
242
- {
243
- name: "seedIsRevocable",
244
- type: "bool"
245
- },
246
- {
247
- name: "listOfAttestations",
248
- type: "tuple[]",
249
- components: y
250
- },
251
- {
252
- name: "propertiesToUpdate",
253
- type: "tuple[]",
254
- components: [{
255
- name: "publishLocalId",
256
- type: "string"
257
- }, {
258
- name: "propertySchemaUid",
259
- type: "bytes32"
260
- }]
261
- }
262
- ]
263
- }],
264
- outputs: [{ type: "bytes32[]" }]
265
- }], xe = [{
266
- type: "function",
267
- name: "multiPublish",
268
- stateMutability: "nonpayable",
269
- inputs: [{
270
- name: "requests",
271
- type: "tuple[]",
272
- components: [
273
- {
274
- name: "localIdIndex",
275
- type: "uint256"
276
- },
277
- {
278
- name: "seedUid",
279
- type: "bytes32"
280
- },
281
- {
282
- name: "seedSchemaUid",
283
- type: "bytes32"
284
- },
285
- {
286
- name: "versionUid",
287
- type: "bytes32"
288
- },
289
- {
290
- name: "versionSchemaUid",
291
- type: "bytes32"
292
- },
293
- {
294
- name: "seedIsRevocable",
295
- type: "bool"
296
- },
297
- {
298
- name: "listOfAttestations",
299
- type: "tuple[]",
300
- components: y
301
- },
302
- {
303
- name: "propertiesToUpdate",
304
- type: "tuple[]",
305
- components: [{
306
- name: "publishLocalIdIndex",
307
- type: "uint256"
308
- }, {
309
- name: "propertySchemaUid",
310
- type: "bytes32"
311
- }]
312
- }
313
- ]
314
- }],
315
- outputs: [{ type: "bytes32[]" }]
316
- }], b = [
317
- {
318
- type: "function",
319
- name: "getEas",
320
- stateMutability: "view",
321
- inputs: [],
322
- outputs: [{ type: "address" }]
323
- },
324
- {
325
- type: "function",
326
- name: "setEas",
327
- stateMutability: "nonpayable",
328
- inputs: [{
329
- name: "_eas",
330
- type: "address"
331
- }],
332
- outputs: [{ type: "string" }]
333
- },
334
- {
335
- type: "function",
336
- name: "isActiveSigner",
337
- stateMutability: "view",
338
- inputs: [{
339
- name: "signer",
340
- type: "address"
341
- }],
342
- outputs: [{ type: "bool" }]
343
- },
344
- {
345
- type: "function",
346
- name: "isAdmin",
347
- stateMutability: "view",
348
- inputs: [{
349
- name: "signer",
350
- type: "address"
351
- }],
352
- outputs: [{ type: "bool" }]
353
- }
354
- ], Se = [{
355
- type: "event",
356
- name: "CreatedAttestation",
357
- inputs: [{
358
- name: "result",
359
- type: "tuple",
360
- indexed: !1,
361
- components: [{
362
- name: "schemaUid",
363
- type: "bytes32"
364
- }, {
365
- name: "attestationUid",
366
- type: "bytes32"
367
- }]
368
- }]
369
- }, {
370
- type: "event",
371
- name: "SeedPublished",
372
- inputs: [{
373
- name: "returnedDataFromEAS",
374
- type: "bytes",
375
- indexed: !1
376
- }]
377
- }], x = [{
378
- type: "function",
379
- name: "getAddress",
380
- stateMutability: "view",
381
- inputs: [{
382
- name: "_adminSigner",
383
- type: "address"
384
- }, {
385
- name: "_data",
386
- type: "bytes"
387
- }],
388
- outputs: [{ type: "address" }]
389
- }, {
390
- type: "function",
391
- name: "createAccount",
392
- stateMutability: "nonpayable",
393
- inputs: [{
394
- name: "_admin",
395
- type: "address"
396
- }, {
397
- name: "_data",
398
- type: "bytes"
399
- }],
400
- outputs: [{ type: "address" }]
401
- }], Ce = [{
402
- type: "event",
403
- name: "CreatedAttestation",
404
- inputs: [{
405
- name: "result",
406
- type: "tuple",
407
- indexed: !1,
408
- components: [{
409
- name: "schemaUid",
410
- type: "bytes32"
411
- }, {
412
- name: "attestationUid",
413
- type: "bytes32"
414
- }]
415
- }]
416
- }, {
417
- type: "event",
418
- name: "SeedPublished",
419
- inputs: [{
420
- name: "seedUid",
421
- type: "bytes32",
422
- indexed: !1
423
- }, {
424
- name: "versionUid",
425
- type: "bytes32",
426
- indexed: !1
427
- }]
428
- }], S = [
429
- {
430
- type: "function",
431
- name: "multiPublish",
432
- stateMutability: "payable",
433
- inputs: [{
434
- name: "requests",
435
- type: "tuple[]",
436
- components: [
437
- {
438
- name: "localId",
439
- type: "string"
440
- },
441
- {
442
- name: "seedUid",
443
- type: "bytes32"
444
- },
445
- {
446
- name: "versionUid",
447
- type: "bytes32"
448
- },
449
- {
450
- name: "seedSchemaUid",
451
- type: "bytes32"
452
- },
453
- {
454
- name: "versionSchemaUid",
455
- type: "bytes32"
456
- },
457
- {
458
- name: "seedIsRevocable",
459
- type: "bool"
460
- },
461
- {
462
- name: "listOfAttestations",
463
- type: "tuple[]",
464
- components: [{
465
- name: "schema",
466
- type: "bytes32"
467
- }, {
468
- name: "data",
469
- type: "tuple[]",
470
- components: [
471
- {
472
- name: "recipient",
473
- type: "address"
474
- },
475
- {
476
- name: "expirationTime",
477
- type: "uint64"
478
- },
479
- {
480
- name: "revocable",
481
- type: "bool"
482
- },
483
- {
484
- name: "refUID",
485
- type: "bytes32"
486
- },
487
- {
488
- name: "data",
489
- type: "bytes"
490
- },
491
- {
492
- name: "value",
493
- type: "uint256"
494
- }
495
- ]
496
- }]
497
- },
498
- {
499
- name: "propertiesToUpdate",
500
- type: "tuple[]",
501
- components: [{
502
- name: "publishIndex",
503
- type: "uint256"
504
- }, {
505
- name: "propertySchemaUid",
506
- type: "bytes32"
507
- }]
508
- }
509
- ]
510
- }],
511
- outputs: [{
512
- name: "",
513
- type: "bytes32[]"
514
- }]
515
- },
516
- {
517
- type: "function",
518
- name: "isInitialized",
519
- stateMutability: "view",
520
- inputs: [{
521
- name: "account",
522
- type: "address"
523
- }],
524
- outputs: [{
525
- name: "",
526
- type: "bool"
527
- }]
528
- },
529
- {
530
- type: "function",
531
- name: "getEAS",
532
- stateMutability: "view",
533
- inputs: [{
534
- name: "account",
535
- type: "address"
536
- }],
537
- outputs: [{
538
- name: "",
539
- type: "address"
540
- }]
541
- },
542
- {
543
- type: "error",
544
- name: "AlreadyInitialized",
545
- inputs: [{
546
- name: "account",
547
- type: "address"
548
- }]
549
- },
550
- {
551
- type: "error",
552
- name: "NotInitialized",
553
- inputs: [{
554
- name: "account",
555
- type: "address"
556
- }]
557
- },
558
- {
559
- type: "error",
560
- name: "InvalidEASAddress",
561
- inputs: []
562
- },
563
- {
564
- type: "error",
565
- name: "AttestationFailed",
566
- inputs: []
567
- },
568
- {
569
- type: "error",
570
- name: "MultiAttestFailed",
571
- inputs: []
572
- }
573
- ], C = [
574
- {
575
- type: "function",
576
- name: "installSeedExecutor",
577
- stateMutability: "nonpayable",
578
- inputs: [],
579
- outputs: []
580
- },
581
- {
582
- type: "function",
583
- name: "getSeedExecutor",
584
- stateMutability: "view",
585
- inputs: [],
586
- outputs: [{
587
- name: "executor",
588
- type: "address"
589
- }, {
590
- name: "eas",
591
- type: "address"
592
- }]
593
- },
594
- {
595
- type: "function",
596
- name: "isModuleInstalled",
597
- stateMutability: "view",
598
- inputs: [
599
- {
600
- name: "moduleTypeId",
601
- type: "uint256"
602
- },
603
- {
604
- name: "module",
605
- type: "address"
606
- },
607
- {
608
- name: "additionalContext",
609
- type: "bytes"
610
- }
611
- ],
612
- outputs: [{
613
- name: "",
614
- type: "bool"
615
- }]
616
- },
617
- {
618
- type: "error",
619
- name: "Unauthorized",
620
- inputs: [{
621
- name: "caller",
622
- type: "address"
623
- }]
624
- },
625
- {
626
- type: "error",
627
- name: "SeedExecutorAlreadyInstalled",
628
- inputs: []
629
- },
630
- {
631
- type: "error",
632
- name: "SeedExecutorNotInstalled",
633
- inputs: []
634
- }
635
- ], we = 2n, w = [{
636
- type: "function",
637
- name: "getSchema",
638
- stateMutability: "view",
639
- inputs: [{
640
- name: "uid",
641
- type: "bytes32"
642
- }],
643
- outputs: [{
644
- name: "",
645
- type: "tuple",
646
- components: [
647
- {
648
- name: "uid",
649
- type: "bytes32"
650
- },
651
- {
652
- name: "resolver",
653
- type: "address"
654
- },
655
- {
656
- name: "revocable",
657
- type: "bool"
658
- },
659
- {
660
- name: "schema",
661
- type: "string"
662
- }
663
- ]
664
- }]
665
- }, {
666
- type: "function",
667
- name: "register",
668
- stateMutability: "nonpayable",
669
- inputs: [
670
- {
671
- name: "schema",
672
- type: "string"
673
- },
674
- {
675
- name: "resolver",
676
- type: "address"
677
- },
678
- {
679
- name: "revocable",
680
- type: "bool"
681
- }
682
- ],
683
- outputs: [{ type: "bytes32" }]
684
- }], T = null, E = null;
685
- function Te() {
686
- try {
687
- let e = Y().thirdwebSecretKey;
688
- return e ? { headers: { "x-secret-key": e } } : void 0;
689
- } catch {
690
- return;
691
- }
692
- }
693
- function Ee() {
694
- let e = Q(), t = $(), n = Te();
695
- return f({
696
- chain: e,
697
- transport: h(t, n ? { fetchOptions: n } : void 0)
698
- });
699
- }
700
- function D() {
701
- let e = Q(), t = $(), n = "";
702
- try {
703
- n = Y().thirdwebSecretKey ?? "";
704
- } catch {
705
- n = "";
706
- }
707
- let r = `${e.id}:${t}:${n ? "1" : "0"}:${n}`;
708
- return (!T || E !== r) && (E = r, T = Ee()), T;
709
- }
710
- async function O(e) {
711
- return D().waitForTransactionReceipt({ hash: e });
712
- }
713
- async function k(e) {
714
- let t = await D().getBytecode({ address: e });
715
- return !!t && t !== "0x";
716
- }
717
- async function De(e) {
718
- try {
719
- let t = await D().getBlock({ blockNumber: e });
720
- if (t?.timestamp != null) return Number(t.timestamp) * 1e3;
721
- } catch {}
722
- return null;
723
- }
724
- var Oe = 5, ke = 6e3;
725
- async function Ae(e, t = Oe, n = ke) {
726
- for (let r = 0; r < t; r++) {
727
- if (await k(e)) return !0;
728
- r < t - 1 && await new Promise((e) => {
729
- setTimeout(e, n);
730
- });
731
- }
732
- return !1;
733
- }
734
- //#endregion
735
- //#region src/helpers/contracts/index.ts
736
- function je(e, t, n) {
737
- return {
738
- to: e,
739
- data: m({
740
- abi: be,
741
- functionName: "multiPublish",
742
- args: [t]
743
- }),
744
- gas: n
745
- };
746
- }
747
- function Me(e, t, n) {
748
- return {
749
- to: e,
750
- data: m({
751
- abi: xe,
752
- functionName: "multiPublish",
753
- args: [t]
754
- }),
755
- gas: n
756
- };
757
- }
758
- function Ne(e, t, n) {
759
- let r = /* @__PURE__ */ new Map();
760
- t.forEach((e, t) => {
761
- e.localId && r.set(e.localId, BigInt(t));
762
- });
763
- let i = t.map((e) => ({
764
- localId: e.localId,
765
- seedUid: e.seedUid,
766
- versionUid: e.versionUid,
767
- seedSchemaUid: e.seedSchemaUid,
768
- versionSchemaUid: e.versionSchemaUid,
769
- seedIsRevocable: e.seedIsRevocable,
770
- listOfAttestations: e.listOfAttestations,
771
- propertiesToUpdate: (e.propertiesToUpdate ?? []).flatMap((e) => {
772
- let t = e.publishLocalId ? r.get(e.publishLocalId) : void 0;
773
- return t === void 0 ? [] : [{
774
- publishIndex: t,
775
- propertySchemaUid: e.propertySchemaUid
776
- }];
777
- })
778
- }));
779
- return {
780
- to: e,
781
- data: m({
782
- abi: S,
783
- functionName: "multiPublish",
784
- args: [i]
785
- }),
786
- gas: n
787
- };
788
- }
789
- async function Pe(e, t) {
790
- return D().readContract({
791
- address: e,
792
- abi: S,
793
- functionName: "isInitialized",
794
- args: [t]
795
- });
796
- }
797
- async function Fe(e, t) {
798
- return D().readContract({
799
- address: e,
800
- abi: S,
801
- functionName: "getEAS",
802
- args: [t]
803
- });
804
- }
805
- async function Ie(e) {
806
- try {
807
- let [t, n] = await D().readContract({
808
- address: e,
809
- abi: C,
810
- functionName: "getSeedExecutor"
811
- });
812
- return {
813
- executor: t,
814
- eas: n
815
- };
816
- } catch {
817
- return null;
818
- }
819
- }
820
- async function Le(e, t) {
821
- return D().readContract({
822
- address: e,
823
- abi: C,
824
- functionName: "isModuleInstalled",
825
- args: [
826
- we,
827
- t,
828
- "0x"
829
- ]
830
- });
831
- }
832
- function Re(e) {
833
- return {
834
- to: e,
835
- data: m({
836
- abi: C,
837
- functionName: "installSeedExecutor"
838
- })
839
- };
840
- }
841
- function ze(e, t) {
842
- return {
843
- to: e,
844
- data: m({
845
- abi: b,
846
- functionName: "setEas",
847
- args: [t]
848
- })
849
- };
850
- }
851
- async function Be(e) {
852
- return D().readContract({
853
- address: e,
854
- abi: b,
855
- functionName: "getEas"
856
- });
857
- }
858
- async function Ve(e, t) {
859
- return D().readContract({
860
- address: e,
861
- abi: b,
862
- functionName: "isActiveSigner",
863
- args: [t]
864
- });
865
- }
866
- async function He(e, t) {
867
- return D().readContract({
868
- address: e,
869
- abi: b,
870
- functionName: "isAdmin",
871
- args: [t]
872
- });
873
- }
874
- async function Ue(e, t = "0x") {
875
- return D().readContract({
876
- address: Z(),
877
- abi: x,
878
- functionName: "getAddress",
879
- args: [e, t]
880
- });
881
- }
882
- function We(e, t = "0x") {
883
- return {
884
- to: Z(),
885
- data: m({
886
- abi: x,
887
- functionName: "createAccount",
888
- args: [e, t]
889
- })
890
- };
891
- }
892
- var Ge = "0x0000000000000000000000000000000000000000";
893
- function A(e) {
894
- let { easContractAddress: t } = Y();
895
- return {
896
- to: t,
897
- data: m({
898
- abi: v,
899
- functionName: "attest",
900
- args: [{
901
- schema: e.schema,
902
- data: {
903
- recipient: e.data.recipient ?? Ge,
904
- expirationTime: e.data.expirationTime ?? 0n,
905
- revocable: e.data.revocable ?? !0,
906
- refUID: e.data.refUID,
907
- data: e.data.data,
908
- value: e.data.value ?? 0n
909
- }
910
- }]
911
- })
912
- };
913
- }
914
- function j(e) {
915
- let { easContractAddress: t } = Y();
916
- return {
917
- to: t,
918
- data: m({
919
- abi: v,
920
- functionName: "multiAttest",
921
- args: [e]
922
- })
923
- };
924
- }
925
- function M(e) {
926
- let { easContractAddress: t } = Y();
927
- return {
928
- to: t,
929
- data: m({
930
- abi: v,
931
- functionName: "multiRevoke",
932
- args: [e.map((e) => ({
933
- schema: e.schema,
934
- data: e.data.map((e) => ({
935
- uid: e.uid,
936
- value: e.value ?? 0n
937
- }))
938
- }))]
939
- })
940
- };
941
- }
942
- var Ke = "0x" + "0".repeat(64);
943
- async function qe(e) {
944
- let t = await D().readContract({
945
- address: Y().schemaRegistryAddress,
946
- abi: w,
947
- functionName: "getSchema",
948
- args: [e]
949
- });
950
- return !t || t.uid === Ke ? null : {
951
- uid: t.uid,
952
- resolver: t.resolver,
953
- revocable: t.revocable,
954
- schema: t.schema
955
- };
956
- }
957
- function Je(e) {
958
- return {
959
- to: Y().schemaRegistryAddress,
960
- data: m({
961
- abi: w,
962
- functionName: "register",
963
- args: [
964
- e.schema,
965
- e.resolverAddress,
966
- e.revocable
967
- ]
968
- })
969
- };
970
- }
971
- //#endregion
972
- //#region src/helpers/easDirect.ts
973
- var Ye = "0x0000000000000000000000000000000000000000", N = "0x" + "0".repeat(64);
974
- function Xe(e) {
975
- return A(e);
976
- }
977
- function Ze(e) {
978
- return j(e);
979
- }
980
- function Qe(e) {
981
- return p([{ type: "bytes32" }], [e]);
982
- }
983
- function $e(e, t) {
984
- return P(e, t)[0]?.uid;
985
- }
986
- function P(e, t) {
987
- if (!e.logs?.length) return [];
988
- let n = t.toLowerCase(), r = e.logs.filter((e) => e.address && e.address.toLowerCase() === n);
989
- if (!r.length) return [];
990
- try {
991
- let e = g({
992
- abi: v,
993
- eventName: "Attested",
994
- logs: r,
995
- strict: !1
996
- }), t = [];
997
- for (let n of e) {
998
- let e = n.args?.uid, r = n.args?.schemaUID;
999
- e && e !== N && r && t.push({
1000
- schemaUid: r,
1001
- uid: e
1002
- });
1003
- }
1004
- return t;
1005
- } catch {
1006
- return [];
1007
- }
1008
- }
1009
- function F(e) {
1010
- return M(e);
1011
- }
1012
- //#endregion
1013
- //#region src/helpers/publishWalletRegistry.ts
1014
- var I = null;
1015
- function et() {
1016
- return a.isInitialized() ? Promise.resolve() : new Promise((e) => {
1017
- a.onReady(() => e());
1018
- });
1019
- }
1020
- async function tt(e) {
1021
- if (I = e, !e) return;
1022
- await et();
1023
- let t = /* @__PURE__ */ new Set();
1024
- for (let n of e.ownedAddresses ?? []) n && t.add(n.toLowerCase());
1025
- t.add(e.signer.address.toLowerCase()), t.add(e.txSender.address.toLowerCase()), e.publisherAddress && t.add(e.publisherAddress.toLowerCase());
1026
- try {
1027
- await a.setAddresses({ owned: [...t] });
1028
- let n = e.publisherAddress ?? e.signer.address;
1029
- n && await a.claimUnpublishedDrafts(n);
1030
- } catch (e) {
1031
- console.warn("[publishWalletRegistry] Failed to set seed client addresses:", e);
1032
- }
1033
- }
1034
- function L() {
1035
- return I;
1036
- }
1037
- function nt() {
1038
- I = null;
1039
- }
1040
- //#endregion
1041
- //#region src/helpers/retryNonceTooLow.ts
1042
- function rt(e) {
1043
- let t = [], n = e;
1044
- for (let e = 0; n && e < 5; e++) {
1045
- let e = n;
1046
- t.push(String(e.message ?? ""), String(e.shortMessage ?? ""), String(e.details ?? ""), String(e.code ?? "")), n = e.cause;
1047
- }
1048
- return /nonce too low|nonce has already been used|NONCE_EXPIRED|nonce.*already.*(used|known)|lower than the current nonce/i.test(t.join(" "));
1049
- }
1050
- async function R(e, { attempts: t = 3, delayMs: n = 1e3 } = {}) {
1051
- for (let r = 1;; r++) try {
1052
- return await e();
1053
- } catch (e) {
1054
- if (r >= t || !rt(e)) throw e;
1055
- await new Promise((e) => setTimeout(e, n));
1056
- }
1057
- }
1058
- //#endregion
1059
- //#region src/helpers/seedSigner.ts
1060
- var it = Symbol.for("seedprotocol.SeedSigner"), at = Symbol.for("seedprotocol.SeedTxSender");
1061
- function z(e) {
1062
- return Object.assign(e, { [it]: !0 });
1063
- }
1064
- function B(e) {
1065
- return Object.assign(e, { [at]: !0 });
1066
- }
1067
- function V(e) {
1068
- return !!e && typeof e == "object" && it in e;
1069
- }
1070
- function H(e) {
1071
- return !!e && typeof e == "object" && at in e;
1072
- }
1073
- function U(e) {
1074
- return !!e && typeof e == "object" && "signer" in e && "txSender" in e && V(e.signer) && H(e.txSender);
1075
- }
1076
- function ot(e) {
1077
- let t = e.address;
1078
- return {
1079
- signer: z({
1080
- address: t,
1081
- signMessage: async ({ message: t }) => {
1082
- if (typeof t == "string") return await e.signMessage(t);
1083
- let n = t.raw, r = typeof n == "string" ? ae.getBytes(n) : n instanceof Uint8Array ? n : new Uint8Array(n);
1084
- return await e.signMessage(r);
1085
- }
1086
- }),
1087
- txSender: B({
1088
- address: t,
1089
- sendTransaction: async (t) => ({ transactionHash: (await R(() => e.sendTransaction({
1090
- to: t.to,
1091
- data: t.data,
1092
- value: t.value,
1093
- gasLimit: t.gas
1094
- }))).hash })
1095
- })
1096
- };
1097
- }
1098
- function st(e) {
1099
- if (U(e)) return e.signer;
1100
- if (V(e)) return e;
1101
- throw Error("@seedprotocol/publish: expected a SeedSigner or PublishWallet. Use fromEthersWallet, fromEip1193Provider, or fromThirdwebAccount.");
1102
- }
1103
- function ct(e) {
1104
- if (U(e)) return e.txSender;
1105
- if (H(e)) return e;
1106
- throw Error("@seedprotocol/publish: expected a SeedTxSender or PublishWallet. Use fromEthersWallet, fromEip1193Provider, or fromThirdwebAccount.");
1107
- }
1108
- function lt(e) {
1109
- if (U(e)) return e;
1110
- throw Error("@seedprotocol/publish: expected a PublishWallet (signer + txSender). Use fromEthersWallet, fromEip1193Provider, or fromThirdwebAccount.");
1111
- }
1112
- //#endregion
1113
- //#region src/helpers/thirdwebChain.ts
1114
- var W = null;
1115
- function ut(e) {
1116
- let t = e ?? wt() ?? {}, n = t.chain ?? _, r = t.rpcUrl?.trim() || void 0, i = `${n.id}|${r ?? ""}`;
1117
- if (W?.key === i) return W.chain;
1118
- let a;
1119
- return a = n.id === se.id && !r ? se : oe({
1120
- id: n.id,
1121
- name: n.name,
1122
- nativeCurrency: n.nativeCurrency,
1123
- testnet: n.testnet ? !0 : void 0,
1124
- blockExplorers: n.blockExplorers ? Object.values(n.blockExplorers).map(({ name: e, url: t, apiUrl: n }) => ({
1125
- name: e,
1126
- url: t,
1127
- apiUrl: n
1128
- })) : void 0,
1129
- ...r ? { rpc: r } : {}
1130
- }), W = {
1131
- key: i,
1132
- chain: a
1133
- }, a;
1134
- }
1135
- var dt = /* @__PURE__ */ new Set([31337, 1337]);
1136
- function ft(e) {
1137
- if (dt.has(e.id)) return !0;
1138
- try {
1139
- let t = new URL(e.rpc).hostname.replace(/^\[|\]$/g, "");
1140
- return t === "localhost" || t === "127.0.0.1" || t === "::1" || t.endsWith(".localhost");
1141
- } catch {
1142
- return !1;
1143
- }
1144
- }
1145
- //#endregion
1146
- //#region src/helpers/adapters/thirdwebAccount.ts
1147
- var pt = /* @__PURE__ */ e({
1148
- asSeedSignerFromThirdweb: () => ht,
1149
- asThirdwebPublishWallet: () => mt,
1150
- fromThirdwebAccount: () => G
1151
- });
1152
- function G(e, t) {
1153
- let n = t?.client, r = e.address;
1154
- return {
1155
- signer: z({
1156
- address: r,
1157
- signMessage: async ({ message: t }) => await e.signMessage({ message: t })
1158
- }),
1159
- txSender: B({
1160
- address: r,
1161
- sendTransaction: async (t) => {
1162
- let r = n ?? (await import("./publishThirdwebClient-BnDhP3N-.js").then((e) => e.n)).getClient(), i = ut(), a = re({
1163
- client: r,
1164
- chain: i,
1165
- to: t.to,
1166
- data: t.data,
1167
- value: t.value,
1168
- gas: t.gas
1169
- });
1170
- return { transactionHash: (await R(() => ie({
1171
- account: e,
1172
- transaction: a
1173
- }))).transactionHash };
1174
- }
1175
- })
1176
- };
1177
- }
1178
- function mt(e, t) {
1179
- if (U(e)) return e;
1180
- if (V(e)) throw Error("@seedprotocol/publish/thirdweb: SeedSigner alone cannot send sponsored txs. Pass fromThirdwebAccount(account) or a PublishWallet.");
1181
- return G(e, t);
1182
- }
1183
- function ht(e) {
1184
- return U(e) ? e.signer : V(e) ? e : G(e).signer;
1185
- }
1186
- //#endregion
1187
- //#region src/helpers/verifyPublishChain.ts
1188
- var K = class extends Error {
1189
- chainId;
1190
- problems;
1191
- name = "PublishChainConfigError";
1192
- constructor(e, t) {
1193
- super(`@seedprotocol/publish: chain ${e} is not set up for publishing:\n- ${t.join("\n- ")}`), this.chainId = e, this.problems = t;
1194
- }
1195
- }, q = null;
1196
- function gt() {
1197
- let e = Y();
1198
- return [
1199
- e.chain.id,
1200
- $(),
1201
- e.easContractAddress,
1202
- e.schemaRegistryAddress,
1203
- e.thirdwebAccountFactoryAddress ?? "",
1204
- e.modularAccountModuleContract ?? ""
1205
- ].join("|").toLowerCase();
1206
- }
1207
- async function _t() {
1208
- let e = Y(), { chain: t } = e, n = [], r;
1209
- try {
1210
- r = await D().getChainId();
1211
- } catch (e) {
1212
- throw new K(t.id, [`could not reach the RPC (${vt($())}): ${e instanceof Error ? e.message : String(e)}`]);
1213
- }
1214
- if (r !== t.id) throw new K(t.id, [`the RPC reports chain ${r}, but PublishConfig.chain is ${t.name} (${t.id}). Point rpcUrl at ${t.name}.`]);
1215
- let i = [
1216
- [
1217
- "EAS contract",
1218
- e.easContractAddress,
1219
- "set easContractAddress"
1220
- ],
1221
- [
1222
- "EAS SchemaRegistry",
1223
- e.schemaRegistryAddress,
1224
- "set schemaRegistryAddress"
1225
- ],
1226
- [
1227
- "ManagedAccount factory",
1228
- e.thirdwebAccountFactoryAddress,
1229
- "deploy the factory or fix managedAccountFactoryAddress"
1230
- ],
1231
- [
1232
- "executor module",
1233
- e.modularAccountModuleContract?.trim() || void 0,
1234
- "deploy the module or fix modularAccountModuleContract"
1235
- ]
1236
- ], a = await Promise.all(i.map(async ([e, n, r]) => n ? await k(n) ? null : `no ${e} at ${n} on ${t.name}; ${r}.` : null));
1237
- for (let e of a) e && n.push(e);
1238
- if (n.length > 0) throw new K(t.id, n);
1239
- }
1240
- function vt(e) {
1241
- try {
1242
- let t = new URL(e);
1243
- return `${t.protocol}//${t.host}`;
1244
- } catch {
1245
- return "configured rpcUrl";
1246
- }
1247
- }
1248
- function yt() {
1249
- let e = gt();
1250
- if (q?.key === e) return q.result;
1251
- let t = _t();
1252
- return q = {
1253
- key: e,
1254
- result: t
1255
- }, t.catch(() => {
1256
- q?.result === t && (q = null);
1257
- }), t;
1258
- }
1259
- //#endregion
1260
- //#region src/services/revoke/revokeAttestations.ts
1261
- async function bt(e) {
1262
- if (!e) return !1;
1263
- let t = s();
1264
- if (!t) return !1;
1265
- let n = await t(), r = e.toLowerCase();
1266
- return !!n?.some((e) => e?.toLowerCase() === r);
1267
- }
1268
- async function xt(e, t) {
1269
- if (!t || !Y().modularAccountModuleContract?.trim()) return !1;
1270
- let n = e.signer?.address;
1271
- if (!n || n.toLowerCase() === t.toLowerCase()) return !1;
1272
- try {
1273
- let { isAutomationSessionActive: e } = await import("./ensureAutomationSessionKey-CClLVX2w.js").then((e) => e.n);
1274
- return await e(t, n);
1275
- } catch {
1276
- return !1;
1277
- }
1278
- }
1279
- async function St(e) {
1280
- let { seedLocalId: t, seedUid: n, seedSchemaUid: a } = e;
1281
- await i(), await yt();
1282
- let s = await o({
1283
- seedLocalId: t,
1284
- seedUid: n
1285
- });
1286
- if (await bt(s)) throw Error("Revocation not supported for items attested by the Seed executor module: the executor has no revoke and is the only attester that could revoke them.");
1287
- let u = L();
1288
- if (!u) try {
1289
- let { getConnectedAccount: e } = await import("./publishAuthorization-CxBkijU6.js").then((e) => e.V), { resolveRevokeAccount: t } = await import("./resolveRevokeAccount-S-2WXkNh.js"), n = await e();
1290
- if (!n) throw Error("No wallet connected. Connect a wallet to revoke attestations.");
1291
- u = G(await t({
1292
- account: n,
1293
- attester: s
1294
- }));
1295
- } catch (e) {
1296
- throw e instanceof Error && e.message.includes("No wallet connected") || e instanceof Error && e.message.includes("Revocation not supported") ? e : Error("No wallet connected. Use useSeedWallet / setPublishWallet, or @seedprotocol/publish/thirdweb ConnectButton.", { cause: e });
1297
- }
1298
- let d = u.txSender;
1299
- if (await xt(u, s)) throw Error("Automation session keys cannot revoke attestations. Revoking is owner-only: connect the account that published this item.");
1300
- let [te, f] = await Promise.all([ee(n), c(n)]), p = te.map((e) => e.uid).filter((e) => l(e)), m = /* @__PURE__ */ new Map();
1301
- for (let { uid: e, schemaUid: t } of f) {
1302
- if (!l(e)) continue;
1303
- let n = m.get(t) ?? [];
1304
- n.push(e), m.set(t, n);
1305
- }
1306
- let h = [];
1307
- for (let [e, t] of m) t.length > 0 && h.push({
1308
- schema: e,
1309
- data: t.map((e) => ({ uid: e }))
1310
- });
1311
- p.length > 0 && h.push({
1312
- schema: r,
1313
- data: p.map((e) => ({ uid: e }))
1314
- }), h.push({
1315
- schema: a,
1316
- data: [{ uid: n }]
1317
- });
1318
- for (let e of h) {
1319
- if (e.data.length === 0) continue;
1320
- let t = F([e]);
1321
- try {
1322
- await O((await d.sendTransaction(t)).transactionHash);
1323
- } catch (e) {
1324
- let t = e instanceof Error ? e.message : String(e);
1325
- if (t.includes("AccessDenied") || t.includes("0x4ca88867")) throw Error("Only the original attester can revoke attestations. Connect the wallet that published this item.");
1326
- if (t.includes("AlreadyRevoked")) continue;
1327
- throw e;
1328
- }
1329
- }
1330
- let g = Math.floor(Date.now() / 1e3);
1331
- await ne({
1332
- seedLocalId: t,
1333
- revokedAt: g
1334
- });
1335
- }
1336
- //#endregion
1337
- //#region src/config.ts
1338
- le("publish");
1339
- var J = null;
1340
- function Ct(e) {
1341
- J = e;
1342
- }
1343
- function wt() {
1344
- return J;
1345
- }
1346
- function Tt(e) {
1347
- let t = X(e);
1348
- ce("publish", {
1349
- chainId: t.chainId,
1350
- indexerUrl: t.indexerUrl
1351
- }), Ct(e), d(async () => {
1352
- let e = L();
1353
- if (e?.publisherAddress) return e.publisherAddress;
1354
- if (e?.signer?.address) return e.signer.address;
1355
- }), te(St), import("./worker-ZL4Wg19t.js").then((e) => {
1356
- e.startArweaveL1FinalizeWorker();
1357
- }), u(async () => e.useModularExecutor && e.modularAccountModuleContract ? [e.modularAccountModuleContract] : []);
1358
- }
1359
- var Et = Tt;
1360
- function Dt(e) {
1361
- let t = e?.thirdweb ?? {};
1362
- return {
1363
- bundlerUrl: t.bundlerUrl?.trim() || void 0,
1364
- sponsorGas: t.sponsorGas ?? !0,
1365
- modularWalletMode: t.modularWalletMode ?? "EIP7702"
1366
- };
1367
- }
1368
- function Y() {
1369
- let e = J;
1370
- if (!e) throw Error("@seedprotocol/publish: Call initPublish() or ensure PublishProvider is mounted with config before using the publish package");
1371
- let t = e.useArweaveBundler ?? !1, r = e.arweaveUploadVerificationBaseUrl ?? e.uploadApiBaseUrl, i = e.arweaveGraphqlUrl ?? n, a = e.useModularExecutor ?? !1, o = e.chain ?? _, s = X(e), c = e.accountMode ?? (e.bundlerUrl ? "eip7702" : "eoa");
1372
- return {
1373
- ...e,
1374
- thirdwebAccountFactoryAddress: e.managedAccountFactoryAddress ?? fe[o.id],
1375
- easContractAddress: s.easContractAddress,
1376
- schemaRegistryAddress: s.schemaRegistryAddress,
1377
- easChain: s,
1378
- useIntegerLocalIds: e.useIntegerLocalIds ?? !1,
1379
- useDirectEas: e.useDirectEas ?? !1,
1380
- modularAccountModuleData: e.modularAccountModuleData ?? "0x",
1381
- useModularExecutor: a,
1382
- useArweaveBundler: t,
1383
- arweaveUploadVerificationBaseUrl: r,
1384
- arweaveGraphqlUrl: i,
1385
- autoDeployManagedAccount: e.autoDeployManagedAccount ?? !1,
1386
- autoDeployEip7702ModularAccount: Ot(e, a),
1387
- chain: o,
1388
- accountMode: c,
1389
- thirdweb: Dt(e)
1390
- };
1391
- }
1392
- function X(e) {
1393
- let t = e.chain ?? _;
1394
- try {
1395
- return ue(t.id, {
1396
- name: t.name,
1397
- easContractAddress: e.easContractAddress,
1398
- schemaRegistryAddress: e.schemaRegistryAddress
1399
- });
1400
- } catch (e) {
1401
- throw Error(`@seedprotocol/publish: ${t.name} (chain ${t.id}) has no known EAS deployment. Pass easContractAddress and schemaRegistryAddress in initPublish / PublishProvider config.`, { cause: e });
1402
- }
1403
- }
1404
- function Z() {
1405
- let { thirdwebAccountFactoryAddress: e, chain: t } = Y();
1406
- if (!e) throw Error(`@seedprotocol/publish: no ManagedAccount factory is known for ${t.name} (chain ${t.id}). Pass managedAccountFactoryAddress in publish config, or use the EOA / direct EAS path.`);
1407
- return e;
1408
- }
1409
- function Ot(e, t) {
1410
- return e.autoDeployEip7702ModularAccount === !0 || e.autoDeployEip7702ModularAccount !== !1 && t;
1411
- }
1412
- //#endregion
1413
- //#region src/helpers/chainConfig.ts
1414
- function Q() {
1415
- try {
1416
- return Y().chain ?? _;
1417
- } catch {
1418
- return _;
1419
- }
1420
- }
1421
- function $() {
1422
- let e = Y();
1423
- if (e.rpcUrl) return e.rpcUrl;
1424
- if (e.thirdwebClientId) return `https://${(e.chain ?? _).id}.rpc.thirdweb.com/${e.thirdwebClientId}`;
1425
- throw Error("@seedprotocol/publish: rpcUrl is required when thirdwebClientId is not set. A thirdwebSecretKey authenticates Thirdweb RPC but does not build this URL. Pass rpcUrl or thirdwebClientId in initPublish / PublishProvider config.");
1426
- }
1427
- function kt() {
1428
- return Q().name;
1429
- }
1430
- //#endregion
1431
- export { Ve as $, tt as A, A as B, B as C, H as D, V as E, P as F, je as G, M as H, Xe as I, ze as J, Me as K, Ze as L, N as M, Qe as N, nt as O, $e as P, Be as Q, F as R, z as S, U as T, Ne as U, j as V, Re as W, Pe as X, Fe as Y, Ue as Z, ut as _, pe as _t, wt as a, D as at, st as b, me as bt, Z as c, O as ct, K as d, Se as dt, He as et, yt as f, v as ft, pt as g, fe as gt, G as h, ge as ht, Et as i, De as it, Ye as j, L as k, X as l, Ce as lt, mt as m, de as mt, $ as n, Le as nt, Y as o, k as ot, ht as p, _ as pt, Je as q, Q as r, Ie as rt, Tt as s, Ae as st, kt as t, qe as tt, Dt as u, S as ut, ft as v, _e as vt, ot as w, ct as x, lt as y, he as yt, We as z };
1432
-
1433
- //# sourceMappingURL=chainConfig-BYm5OXpk.js.map