@virtuals-protocol/acp-node-v2 0.1.3 → 0.1.5

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 (271) hide show
  1. package/dist/clientFactory.d.ts +1 -2
  2. package/dist/clientFactory.d.ts.map +1 -1
  3. package/dist/clientFactory.js +1 -5
  4. package/dist/clientFactory.js.map +1 -1
  5. package/dist/core/constants.d.ts +4 -0
  6. package/dist/core/constants.d.ts.map +1 -1
  7. package/dist/core/constants.js +13 -0
  8. package/dist/core/constants.js.map +1 -1
  9. package/dist/core/solana/constants.d.ts +5 -0
  10. package/dist/core/solana/constants.d.ts.map +1 -0
  11. package/dist/core/solana/constants.js +5 -0
  12. package/dist/core/solana/constants.js.map +1 -0
  13. package/dist/core/solana/generated/acp/accounts/acpState.d.ts +60 -0
  14. package/dist/core/solana/generated/acp/accounts/acpState.d.ts.map +1 -0
  15. package/dist/core/solana/generated/acp/accounts/acpState.js +68 -0
  16. package/dist/core/solana/generated/acp/accounts/acpState.js.map +1 -0
  17. package/dist/core/solana/generated/acp/accounts/hookWhitelist.d.ts +37 -0
  18. package/dist/core/solana/generated/acp/accounts/hookWhitelist.d.ts.map +1 -0
  19. package/dist/core/solana/generated/acp/accounts/hookWhitelist.js +59 -0
  20. package/dist/core/solana/generated/acp/accounts/hookWhitelist.js.map +1 -0
  21. package/dist/core/solana/generated/acp/accounts/index.d.ts +11 -0
  22. package/dist/core/solana/generated/acp/accounts/index.d.ts.map +1 -0
  23. package/dist/core/solana/generated/acp/accounts/index.js +11 -0
  24. package/dist/core/solana/generated/acp/accounts/index.js.map +1 -0
  25. package/dist/core/solana/generated/acp/accounts/job.d.ts +89 -0
  26. package/dist/core/solana/generated/acp/accounts/job.d.ts.map +1 -0
  27. package/dist/core/solana/generated/acp/accounts/job.js +83 -0
  28. package/dist/core/solana/generated/acp/accounts/job.js.map +1 -0
  29. package/dist/core/solana/generated/acp/errors/agenticCommerceV3.d.ts +94 -0
  30. package/dist/core/solana/generated/acp/errors/agenticCommerceV3.d.ts.map +1 -0
  31. package/dist/core/solana/generated/acp/errors/agenticCommerceV3.js +135 -0
  32. package/dist/core/solana/generated/acp/errors/agenticCommerceV3.js.map +1 -0
  33. package/dist/core/solana/generated/acp/errors/index.d.ts +9 -0
  34. package/dist/core/solana/generated/acp/errors/index.d.ts.map +1 -0
  35. package/dist/core/solana/generated/acp/errors/index.js +9 -0
  36. package/dist/core/solana/generated/acp/errors/index.js.map +1 -0
  37. package/dist/core/solana/generated/acp/index.d.ts +14 -0
  38. package/dist/core/solana/generated/acp/index.d.ts.map +1 -0
  39. package/dist/core/solana/generated/acp/index.js +14 -0
  40. package/dist/core/solana/generated/acp/index.js.map +1 -0
  41. package/dist/core/solana/generated/acp/instructions/acceptAuthority.d.ts +47 -0
  42. package/dist/core/solana/generated/acp/instructions/acceptAuthority.d.ts.map +1 -0
  43. package/dist/core/solana/generated/acp/instructions/acceptAuthority.js +88 -0
  44. package/dist/core/solana/generated/acp/instructions/acceptAuthority.js.map +1 -0
  45. package/dist/core/solana/generated/acp/instructions/addHookWhitelist.d.ts +64 -0
  46. package/dist/core/solana/generated/acp/instructions/addHookWhitelist.d.ts.map +1 -0
  47. package/dist/core/solana/generated/acp/instructions/addHookWhitelist.js +140 -0
  48. package/dist/core/solana/generated/acp/instructions/addHookWhitelist.js.map +1 -0
  49. package/dist/core/solana/generated/acp/instructions/claimRefund.d.ts +74 -0
  50. package/dist/core/solana/generated/acp/instructions/claimRefund.d.ts.map +1 -0
  51. package/dist/core/solana/generated/acp/instructions/claimRefund.js +142 -0
  52. package/dist/core/solana/generated/acp/instructions/claimRefund.js.map +1 -0
  53. package/dist/core/solana/generated/acp/instructions/complete.d.ts +108 -0
  54. package/dist/core/solana/generated/acp/instructions/complete.d.ts.map +1 -0
  55. package/dist/core/solana/generated/acp/instructions/complete.js +190 -0
  56. package/dist/core/solana/generated/acp/instructions/complete.js.map +1 -0
  57. package/dist/core/solana/generated/acp/instructions/createJob.d.ts +83 -0
  58. package/dist/core/solana/generated/acp/instructions/createJob.d.ts.map +1 -0
  59. package/dist/core/solana/generated/acp/instructions/createJob.js +137 -0
  60. package/dist/core/solana/generated/acp/instructions/createJob.js.map +1 -0
  61. package/dist/core/solana/generated/acp/instructions/fund.d.ts +99 -0
  62. package/dist/core/solana/generated/acp/instructions/fund.d.ts.map +1 -0
  63. package/dist/core/solana/generated/acp/instructions/fund.js +126 -0
  64. package/dist/core/solana/generated/acp/instructions/fund.js.map +1 -0
  65. package/dist/core/solana/generated/acp/instructions/index.d.ts +23 -0
  66. package/dist/core/solana/generated/acp/instructions/index.d.ts.map +1 -0
  67. package/dist/core/solana/generated/acp/instructions/index.js +23 -0
  68. package/dist/core/solana/generated/acp/instructions/index.js.map +1 -0
  69. package/dist/core/solana/generated/acp/instructions/initialize.d.ts +76 -0
  70. package/dist/core/solana/generated/acp/instructions/initialize.d.ts.map +1 -0
  71. package/dist/core/solana/generated/acp/instructions/initialize.js +141 -0
  72. package/dist/core/solana/generated/acp/instructions/initialize.js.map +1 -0
  73. package/dist/core/solana/generated/acp/instructions/nominateAuthority.d.ts +52 -0
  74. package/dist/core/solana/generated/acp/instructions/nominateAuthority.d.ts.map +1 -0
  75. package/dist/core/solana/generated/acp/instructions/nominateAuthority.js +96 -0
  76. package/dist/core/solana/generated/acp/instructions/nominateAuthority.js.map +1 -0
  77. package/dist/core/solana/generated/acp/instructions/reject.d.ts +88 -0
  78. package/dist/core/solana/generated/acp/instructions/reject.d.ts.map +1 -0
  79. package/dist/core/solana/generated/acp/instructions/reject.js +168 -0
  80. package/dist/core/solana/generated/acp/instructions/reject.js.map +1 -0
  81. package/dist/core/solana/generated/acp/instructions/removeHookWhitelist.d.ts +56 -0
  82. package/dist/core/solana/generated/acp/instructions/removeHookWhitelist.d.ts.map +1 -0
  83. package/dist/core/solana/generated/acp/instructions/removeHookWhitelist.js +112 -0
  84. package/dist/core/solana/generated/acp/instructions/removeHookWhitelist.js.map +1 -0
  85. package/dist/core/solana/generated/acp/instructions/setBudget.d.ts +56 -0
  86. package/dist/core/solana/generated/acp/instructions/setBudget.d.ts.map +1 -0
  87. package/dist/core/solana/generated/acp/instructions/setBudget.js +90 -0
  88. package/dist/core/solana/generated/acp/instructions/setBudget.js.map +1 -0
  89. package/dist/core/solana/generated/acp/instructions/setEvaluatorFee.d.ts +52 -0
  90. package/dist/core/solana/generated/acp/instructions/setEvaluatorFee.d.ts.map +1 -0
  91. package/dist/core/solana/generated/acp/instructions/setEvaluatorFee.js +96 -0
  92. package/dist/core/solana/generated/acp/instructions/setEvaluatorFee.js.map +1 -0
  93. package/dist/core/solana/generated/acp/instructions/setPlatformFee.d.ts +56 -0
  94. package/dist/core/solana/generated/acp/instructions/setPlatformFee.d.ts.map +1 -0
  95. package/dist/core/solana/generated/acp/instructions/setPlatformFee.js +98 -0
  96. package/dist/core/solana/generated/acp/instructions/setPlatformFee.js.map +1 -0
  97. package/dist/core/solana/generated/acp/instructions/setProvider.d.ts +50 -0
  98. package/dist/core/solana/generated/acp/instructions/setProvider.d.ts.map +1 -0
  99. package/dist/core/solana/generated/acp/instructions/setProvider.js +85 -0
  100. package/dist/core/solana/generated/acp/instructions/setProvider.js.map +1 -0
  101. package/dist/core/solana/generated/acp/instructions/submit.d.ts +150 -0
  102. package/dist/core/solana/generated/acp/instructions/submit.d.ts.map +1 -0
  103. package/dist/core/solana/generated/acp/instructions/submit.js +214 -0
  104. package/dist/core/solana/generated/acp/instructions/submit.js.map +1 -0
  105. package/dist/core/solana/generated/acp/pdas/acpState.d.ts +12 -0
  106. package/dist/core/solana/generated/acp/pdas/acpState.d.ts.map +1 -0
  107. package/dist/core/solana/generated/acp/pdas/acpState.js +18 -0
  108. package/dist/core/solana/generated/acp/pdas/acpState.js.map +1 -0
  109. package/dist/core/solana/generated/acp/pdas/hookWhitelist.d.ts +15 -0
  110. package/dist/core/solana/generated/acp/pdas/hookWhitelist.d.ts.map +1 -0
  111. package/dist/core/solana/generated/acp/pdas/hookWhitelist.js +21 -0
  112. package/dist/core/solana/generated/acp/pdas/hookWhitelist.js.map +1 -0
  113. package/dist/core/solana/generated/acp/pdas/index.d.ts +10 -0
  114. package/dist/core/solana/generated/acp/pdas/index.d.ts.map +1 -0
  115. package/dist/core/solana/generated/acp/pdas/index.js +10 -0
  116. package/dist/core/solana/generated/acp/pdas/index.js.map +1 -0
  117. package/dist/core/solana/generated/acp/programs/agenticCommerceV3.d.ts +71 -0
  118. package/dist/core/solana/generated/acp/programs/agenticCommerceV3.d.ts.map +1 -0
  119. package/dist/core/solana/generated/acp/programs/agenticCommerceV3.js +209 -0
  120. package/dist/core/solana/generated/acp/programs/agenticCommerceV3.js.map +1 -0
  121. package/dist/core/solana/generated/acp/programs/index.d.ts +9 -0
  122. package/dist/core/solana/generated/acp/programs/index.d.ts.map +1 -0
  123. package/dist/core/solana/generated/acp/programs/index.js +9 -0
  124. package/dist/core/solana/generated/acp/programs/index.js.map +1 -0
  125. package/dist/core/solana/generated/acp/shared/index.d.ts +50 -0
  126. package/dist/core/solana/generated/acp/shared/index.d.ts.map +1 -0
  127. package/dist/core/solana/generated/acp/shared/index.js +87 -0
  128. package/dist/core/solana/generated/acp/shared/index.js.map +1 -0
  129. package/dist/core/solana/generated/acp/types/index.d.ts +9 -0
  130. package/dist/core/solana/generated/acp/types/index.d.ts.map +1 -0
  131. package/dist/core/solana/generated/acp/types/index.js +9 -0
  132. package/dist/core/solana/generated/acp/types/index.js.map +1 -0
  133. package/dist/core/solana/generated/acp/types/jobCreated.d.ts +11 -0
  134. package/dist/core/solana/generated/acp/types/jobCreated.d.ts.map +1 -0
  135. package/dist/core/solana/generated/acp/types/jobCreated.js +12 -0
  136. package/dist/core/solana/generated/acp/types/jobCreated.js.map +1 -0
  137. package/dist/core/solana/generated/acp/types/jobState.d.ts +27 -0
  138. package/dist/core/solana/generated/acp/types/jobState.d.ts.map +1 -0
  139. package/dist/core/solana/generated/acp/types/jobState.js +33 -0
  140. package/dist/core/solana/generated/acp/types/jobState.js.map +1 -0
  141. package/dist/core/solana/generated/fund-transfer-hook/accounts/fundRequestIntentId.d.ts +35 -0
  142. package/dist/core/solana/generated/fund-transfer-hook/accounts/fundRequestIntentId.d.ts.map +1 -0
  143. package/dist/core/solana/generated/fund-transfer-hook/accounts/fundRequestIntentId.js +64 -0
  144. package/dist/core/solana/generated/fund-transfer-hook/accounts/fundRequestIntentId.js.map +1 -0
  145. package/dist/core/solana/generated/fund-transfer-hook/accounts/hookMetadata.d.ts +33 -0
  146. package/dist/core/solana/generated/fund-transfer-hook/accounts/hookMetadata.d.ts.map +1 -0
  147. package/dist/core/solana/generated/fund-transfer-hook/accounts/hookMetadata.js +59 -0
  148. package/dist/core/solana/generated/fund-transfer-hook/accounts/hookMetadata.js.map +1 -0
  149. package/dist/core/solana/generated/fund-transfer-hook/accounts/hookState.d.ts +38 -0
  150. package/dist/core/solana/generated/fund-transfer-hook/accounts/hookState.d.ts.map +1 -0
  151. package/dist/core/solana/generated/fund-transfer-hook/accounts/hookState.js +62 -0
  152. package/dist/core/solana/generated/fund-transfer-hook/accounts/hookState.js.map +1 -0
  153. package/dist/core/solana/generated/fund-transfer-hook/accounts/index.d.ts +13 -0
  154. package/dist/core/solana/generated/fund-transfer-hook/accounts/index.d.ts.map +1 -0
  155. package/dist/core/solana/generated/fund-transfer-hook/accounts/index.js +13 -0
  156. package/dist/core/solana/generated/fund-transfer-hook/accounts/index.js.map +1 -0
  157. package/dist/core/solana/generated/fund-transfer-hook/accounts/intent.d.ts +61 -0
  158. package/dist/core/solana/generated/fund-transfer-hook/accounts/intent.d.ts.map +1 -0
  159. package/dist/core/solana/generated/fund-transfer-hook/accounts/intent.js +77 -0
  160. package/dist/core/solana/generated/fund-transfer-hook/accounts/intent.js.map +1 -0
  161. package/dist/core/solana/generated/fund-transfer-hook/accounts/providerEscrowIntentId.d.ts +35 -0
  162. package/dist/core/solana/generated/fund-transfer-hook/accounts/providerEscrowIntentId.d.ts.map +1 -0
  163. package/dist/core/solana/generated/fund-transfer-hook/accounts/providerEscrowIntentId.js +64 -0
  164. package/dist/core/solana/generated/fund-transfer-hook/accounts/providerEscrowIntentId.js.map +1 -0
  165. package/dist/core/solana/generated/fund-transfer-hook/index.d.ts +12 -0
  166. package/dist/core/solana/generated/fund-transfer-hook/index.d.ts.map +1 -0
  167. package/dist/core/solana/generated/fund-transfer-hook/index.js +12 -0
  168. package/dist/core/solana/generated/fund-transfer-hook/index.js.map +1 -0
  169. package/dist/core/solana/generated/fund-transfer-hook/instructions/acceptAuthority.d.ts +47 -0
  170. package/dist/core/solana/generated/fund-transfer-hook/instructions/acceptAuthority.d.ts.map +1 -0
  171. package/dist/core/solana/generated/fund-transfer-hook/instructions/acceptAuthority.js +88 -0
  172. package/dist/core/solana/generated/fund-transfer-hook/instructions/acceptAuthority.js.map +1 -0
  173. package/dist/core/solana/generated/fund-transfer-hook/instructions/afterAction.d.ts +56 -0
  174. package/dist/core/solana/generated/fund-transfer-hook/instructions/afterAction.d.ts.map +1 -0
  175. package/dist/core/solana/generated/fund-transfer-hook/instructions/afterAction.js +92 -0
  176. package/dist/core/solana/generated/fund-transfer-hook/instructions/afterAction.js.map +1 -0
  177. package/dist/core/solana/generated/fund-transfer-hook/instructions/beforeAction.d.ts +52 -0
  178. package/dist/core/solana/generated/fund-transfer-hook/instructions/beforeAction.d.ts.map +1 -0
  179. package/dist/core/solana/generated/fund-transfer-hook/instructions/beforeAction.js +90 -0
  180. package/dist/core/solana/generated/fund-transfer-hook/instructions/beforeAction.js.map +1 -0
  181. package/dist/core/solana/generated/fund-transfer-hook/instructions/claimEscrowRefund.d.ts +86 -0
  182. package/dist/core/solana/generated/fund-transfer-hook/instructions/claimEscrowRefund.d.ts.map +1 -0
  183. package/dist/core/solana/generated/fund-transfer-hook/instructions/claimEscrowRefund.js +169 -0
  184. package/dist/core/solana/generated/fund-transfer-hook/instructions/claimEscrowRefund.js.map +1 -0
  185. package/dist/core/solana/generated/fund-transfer-hook/instructions/closeIntent.d.ts +114 -0
  186. package/dist/core/solana/generated/fund-transfer-hook/instructions/closeIntent.d.ts.map +1 -0
  187. package/dist/core/solana/generated/fund-transfer-hook/instructions/closeIntent.js +120 -0
  188. package/dist/core/solana/generated/fund-transfer-hook/instructions/closeIntent.js.map +1 -0
  189. package/dist/core/solana/generated/fund-transfer-hook/instructions/index.d.ts +15 -0
  190. package/dist/core/solana/generated/fund-transfer-hook/instructions/index.d.ts.map +1 -0
  191. package/dist/core/solana/generated/fund-transfer-hook/instructions/index.js +15 -0
  192. package/dist/core/solana/generated/fund-transfer-hook/instructions/index.js.map +1 -0
  193. package/dist/core/solana/generated/fund-transfer-hook/instructions/initialize.d.ts +67 -0
  194. package/dist/core/solana/generated/fund-transfer-hook/instructions/initialize.d.ts.map +1 -0
  195. package/dist/core/solana/generated/fund-transfer-hook/instructions/initialize.js +138 -0
  196. package/dist/core/solana/generated/fund-transfer-hook/instructions/initialize.js.map +1 -0
  197. package/dist/core/solana/generated/fund-transfer-hook/instructions/nominateAuthority.d.ts +52 -0
  198. package/dist/core/solana/generated/fund-transfer-hook/instructions/nominateAuthority.d.ts.map +1 -0
  199. package/dist/core/solana/generated/fund-transfer-hook/instructions/nominateAuthority.js +96 -0
  200. package/dist/core/solana/generated/fund-transfer-hook/instructions/nominateAuthority.js.map +1 -0
  201. package/dist/core/solana/generated/fund-transfer-hook/pdas/escrowAuthority.d.ts +15 -0
  202. package/dist/core/solana/generated/fund-transfer-hook/pdas/escrowAuthority.d.ts.map +1 -0
  203. package/dist/core/solana/generated/fund-transfer-hook/pdas/escrowAuthority.js +22 -0
  204. package/dist/core/solana/generated/fund-transfer-hook/pdas/escrowAuthority.js.map +1 -0
  205. package/dist/core/solana/generated/fund-transfer-hook/pdas/hookMetadata.d.ts +12 -0
  206. package/dist/core/solana/generated/fund-transfer-hook/pdas/hookMetadata.d.ts.map +1 -0
  207. package/dist/core/solana/generated/fund-transfer-hook/pdas/hookMetadata.js +20 -0
  208. package/dist/core/solana/generated/fund-transfer-hook/pdas/hookMetadata.js.map +1 -0
  209. package/dist/core/solana/generated/fund-transfer-hook/pdas/hookState.d.ts +12 -0
  210. package/dist/core/solana/generated/fund-transfer-hook/pdas/hookState.d.ts.map +1 -0
  211. package/dist/core/solana/generated/fund-transfer-hook/pdas/hookState.js +18 -0
  212. package/dist/core/solana/generated/fund-transfer-hook/pdas/hookState.js.map +1 -0
  213. package/dist/core/solana/generated/fund-transfer-hook/pdas/index.d.ts +13 -0
  214. package/dist/core/solana/generated/fund-transfer-hook/pdas/index.d.ts.map +1 -0
  215. package/dist/core/solana/generated/fund-transfer-hook/pdas/index.js +13 -0
  216. package/dist/core/solana/generated/fund-transfer-hook/pdas/index.js.map +1 -0
  217. package/dist/core/solana/generated/fund-transfer-hook/pdas/intent.d.ts +15 -0
  218. package/dist/core/solana/generated/fund-transfer-hook/pdas/intent.d.ts.map +1 -0
  219. package/dist/core/solana/generated/fund-transfer-hook/pdas/intent.js +19 -0
  220. package/dist/core/solana/generated/fund-transfer-hook/pdas/intent.js.map +1 -0
  221. package/dist/core/solana/generated/fund-transfer-hook/pdas/providerEscrowIntentId.d.ts +15 -0
  222. package/dist/core/solana/generated/fund-transfer-hook/pdas/providerEscrowIntentId.d.ts.map +1 -0
  223. package/dist/core/solana/generated/fund-transfer-hook/pdas/providerEscrowIntentId.js +22 -0
  224. package/dist/core/solana/generated/fund-transfer-hook/pdas/providerEscrowIntentId.js.map +1 -0
  225. package/dist/core/solana/generated/fund-transfer-hook/programs/fundTransferHook.d.ts +49 -0
  226. package/dist/core/solana/generated/fund-transfer-hook/programs/fundTransferHook.d.ts.map +1 -0
  227. package/dist/core/solana/generated/fund-transfer-hook/programs/fundTransferHook.js +129 -0
  228. package/dist/core/solana/generated/fund-transfer-hook/programs/fundTransferHook.js.map +1 -0
  229. package/dist/core/solana/generated/fund-transfer-hook/programs/index.d.ts +9 -0
  230. package/dist/core/solana/generated/fund-transfer-hook/programs/index.d.ts.map +1 -0
  231. package/dist/core/solana/generated/fund-transfer-hook/programs/index.js +9 -0
  232. package/dist/core/solana/generated/fund-transfer-hook/programs/index.js.map +1 -0
  233. package/dist/core/solana/generated/fund-transfer-hook/shared/index.d.ts +50 -0
  234. package/dist/core/solana/generated/fund-transfer-hook/shared/index.d.ts.map +1 -0
  235. package/dist/core/solana/generated/fund-transfer-hook/shared/index.js +87 -0
  236. package/dist/core/solana/generated/fund-transfer-hook/shared/index.js.map +1 -0
  237. package/dist/core/solana/wallet.d.ts +49 -0
  238. package/dist/core/solana/wallet.d.ts.map +1 -0
  239. package/dist/core/solana/wallet.js +119 -0
  240. package/dist/core/solana/wallet.js.map +1 -0
  241. package/dist/events/socketTransport.d.ts +18 -0
  242. package/dist/events/socketTransport.d.ts.map +1 -0
  243. package/dist/events/socketTransport.js +117 -0
  244. package/dist/events/socketTransport.js.map +1 -0
  245. package/dist/index.d.ts +4 -1
  246. package/dist/index.d.ts.map +1 -1
  247. package/dist/index.js +5 -1
  248. package/dist/index.js.map +1 -1
  249. package/dist/providers/evm/privyAlchemyEvmProviderAdapter.js +1 -1
  250. package/dist/providers/evm/privyAlchemyEvmProviderAdapter.js.map +1 -1
  251. package/dist/providers/providerAuthClient.d.ts +8 -2
  252. package/dist/providers/providerAuthClient.d.ts.map +1 -1
  253. package/dist/providers/providerAuthClient.js +6 -12
  254. package/dist/providers/providerAuthClient.js.map +1 -1
  255. package/dist/providers/solana/keypairSolanaProviderAdapter.d.ts +16 -0
  256. package/dist/providers/solana/keypairSolanaProviderAdapter.d.ts.map +1 -0
  257. package/dist/providers/solana/keypairSolanaProviderAdapter.js +68 -0
  258. package/dist/providers/solana/keypairSolanaProviderAdapter.js.map +1 -0
  259. package/dist/providers/solana/privySolanaProviderAdapter.d.ts +54 -0
  260. package/dist/providers/solana/privySolanaProviderAdapter.d.ts.map +1 -0
  261. package/dist/providers/solana/privySolanaProviderAdapter.js +357 -0
  262. package/dist/providers/solana/privySolanaProviderAdapter.js.map +1 -0
  263. package/dist/providers/solana/solanaProviderAdapter.d.ts +5 -1
  264. package/dist/providers/solana/solanaProviderAdapter.d.ts.map +1 -1
  265. package/dist/providers/solana/solanaProviderAdapter.js +17 -1
  266. package/dist/providers/solana/solanaProviderAdapter.js.map +1 -1
  267. package/dist/providers/types.d.ts +11 -6
  268. package/dist/providers/types.d.ts.map +1 -1
  269. package/dist/providers/types.js +1 -1
  270. package/dist/providers/types.js.map +1 -1
  271. package/package.json +3 -2
@@ -0,0 +1,88 @@
1
+ /**
2
+ * This code was AUTOGENERATED using the Codama library.
3
+ * Please DO NOT EDIT THIS FILE, instead use visitors
4
+ * to add features, then rerun Codama to update it.
5
+ *
6
+ * @see https://github.com/codama-idl/codama
7
+ */
8
+ import { type AccountMeta, type AccountSignerMeta, type Address, type Codec, type Decoder, type Encoder, type Instruction, type InstructionWithAccounts, type InstructionWithData, type ReadonlyAccount, type ReadonlySignerAccount, type ReadonlyUint8Array, type TransactionSigner, type WritableAccount } from "@solana/kit";
9
+ import { AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS } from "../programs/index.js";
10
+ export declare const REJECT_DISCRIMINATOR: Uint8Array<ArrayBuffer>;
11
+ export declare function getRejectDiscriminatorBytes(): ReadonlyUint8Array;
12
+ export type RejectInstruction<TProgram extends string = typeof AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS, TAccountCaller extends string | AccountMeta<string> = string, TAccountAcpState extends string | AccountMeta<string> = string, TAccountJob extends string | AccountMeta<string> = string, TAccountVault extends string | AccountMeta<string> = string, TAccountVaultAuthority extends string | AccountMeta<string> = string, TAccountClientTokenAccount extends string | AccountMeta<string> = string, TAccountPlatformTreasury extends string | AccountMeta<string> = string, TAccountTokenProgram extends string | AccountMeta<string> = "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA", TAccountHookProgram extends string | AccountMeta<string> = string, TAccountHookWhitelist extends string | AccountMeta<string> = string, TRemainingAccounts extends readonly AccountMeta<string>[] = []> = Instruction<TProgram> & InstructionWithData<ReadonlyUint8Array> & InstructionWithAccounts<[
13
+ TAccountCaller extends string ? ReadonlySignerAccount<TAccountCaller> & AccountSignerMeta<TAccountCaller> : TAccountCaller,
14
+ TAccountAcpState extends string ? ReadonlyAccount<TAccountAcpState> : TAccountAcpState,
15
+ TAccountJob extends string ? WritableAccount<TAccountJob> : TAccountJob,
16
+ TAccountVault extends string ? WritableAccount<TAccountVault> : TAccountVault,
17
+ TAccountVaultAuthority extends string ? ReadonlyAccount<TAccountVaultAuthority> : TAccountVaultAuthority,
18
+ TAccountClientTokenAccount extends string ? WritableAccount<TAccountClientTokenAccount> : TAccountClientTokenAccount,
19
+ TAccountPlatformTreasury extends string ? WritableAccount<TAccountPlatformTreasury> : TAccountPlatformTreasury,
20
+ TAccountTokenProgram extends string ? ReadonlyAccount<TAccountTokenProgram> : TAccountTokenProgram,
21
+ TAccountHookProgram extends string ? ReadonlyAccount<TAccountHookProgram> : TAccountHookProgram,
22
+ TAccountHookWhitelist extends string ? ReadonlyAccount<TAccountHookWhitelist> : TAccountHookWhitelist,
23
+ ...TRemainingAccounts
24
+ ]>;
25
+ export type RejectInstructionData = {
26
+ discriminator: ReadonlyUint8Array;
27
+ reason: ReadonlyUint8Array;
28
+ optParams: ReadonlyUint8Array;
29
+ };
30
+ export type RejectInstructionDataArgs = {
31
+ reason: ReadonlyUint8Array;
32
+ optParams: ReadonlyUint8Array;
33
+ };
34
+ export declare function getRejectInstructionDataEncoder(): Encoder<RejectInstructionDataArgs>;
35
+ export declare function getRejectInstructionDataDecoder(): Decoder<RejectInstructionData>;
36
+ export declare function getRejectInstructionDataCodec(): Codec<RejectInstructionDataArgs, RejectInstructionData>;
37
+ export type RejectAsyncInput<TAccountCaller extends string = string, TAccountAcpState extends string = string, TAccountJob extends string = string, TAccountVault extends string = string, TAccountVaultAuthority extends string = string, TAccountClientTokenAccount extends string = string, TAccountPlatformTreasury extends string = string, TAccountTokenProgram extends string = string, TAccountHookProgram extends string = string, TAccountHookWhitelist extends string = string> = {
38
+ caller: TransactionSigner<TAccountCaller>;
39
+ acpState?: Address<TAccountAcpState>;
40
+ job: Address<TAccountJob>;
41
+ vault?: Address<TAccountVault>;
42
+ vaultAuthority?: Address<TAccountVaultAuthority>;
43
+ clientTokenAccount?: Address<TAccountClientTokenAccount>;
44
+ platformTreasury?: Address<TAccountPlatformTreasury>;
45
+ tokenProgram?: Address<TAccountTokenProgram>;
46
+ hookProgram?: Address<TAccountHookProgram>;
47
+ hookWhitelist?: Address<TAccountHookWhitelist>;
48
+ reason: RejectInstructionDataArgs["reason"];
49
+ optParams: RejectInstructionDataArgs["optParams"];
50
+ };
51
+ export declare function getRejectInstructionAsync<TAccountCaller extends string, TAccountAcpState extends string, TAccountJob extends string, TAccountVault extends string, TAccountVaultAuthority extends string, TAccountClientTokenAccount extends string, TAccountPlatformTreasury extends string, TAccountTokenProgram extends string, TAccountHookProgram extends string, TAccountHookWhitelist extends string, TProgramAddress extends Address = typeof AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS>(input: RejectAsyncInput<TAccountCaller, TAccountAcpState, TAccountJob, TAccountVault, TAccountVaultAuthority, TAccountClientTokenAccount, TAccountPlatformTreasury, TAccountTokenProgram, TAccountHookProgram, TAccountHookWhitelist>, config?: {
52
+ programAddress?: TProgramAddress;
53
+ }): Promise<RejectInstruction<TProgramAddress, TAccountCaller, TAccountAcpState, TAccountJob, TAccountVault, TAccountVaultAuthority, TAccountClientTokenAccount, TAccountPlatformTreasury, TAccountTokenProgram, TAccountHookProgram, TAccountHookWhitelist>>;
54
+ export type RejectInput<TAccountCaller extends string = string, TAccountAcpState extends string = string, TAccountJob extends string = string, TAccountVault extends string = string, TAccountVaultAuthority extends string = string, TAccountClientTokenAccount extends string = string, TAccountPlatformTreasury extends string = string, TAccountTokenProgram extends string = string, TAccountHookProgram extends string = string, TAccountHookWhitelist extends string = string> = {
55
+ caller: TransactionSigner<TAccountCaller>;
56
+ acpState: Address<TAccountAcpState>;
57
+ job: Address<TAccountJob>;
58
+ vault?: Address<TAccountVault>;
59
+ vaultAuthority?: Address<TAccountVaultAuthority>;
60
+ clientTokenAccount?: Address<TAccountClientTokenAccount>;
61
+ platformTreasury?: Address<TAccountPlatformTreasury>;
62
+ tokenProgram?: Address<TAccountTokenProgram>;
63
+ hookProgram?: Address<TAccountHookProgram>;
64
+ hookWhitelist?: Address<TAccountHookWhitelist>;
65
+ reason: RejectInstructionDataArgs["reason"];
66
+ optParams: RejectInstructionDataArgs["optParams"];
67
+ };
68
+ export declare function getRejectInstruction<TAccountCaller extends string, TAccountAcpState extends string, TAccountJob extends string, TAccountVault extends string, TAccountVaultAuthority extends string, TAccountClientTokenAccount extends string, TAccountPlatformTreasury extends string, TAccountTokenProgram extends string, TAccountHookProgram extends string, TAccountHookWhitelist extends string, TProgramAddress extends Address = typeof AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS>(input: RejectInput<TAccountCaller, TAccountAcpState, TAccountJob, TAccountVault, TAccountVaultAuthority, TAccountClientTokenAccount, TAccountPlatformTreasury, TAccountTokenProgram, TAccountHookProgram, TAccountHookWhitelist>, config?: {
69
+ programAddress?: TProgramAddress;
70
+ }): RejectInstruction<TProgramAddress, TAccountCaller, TAccountAcpState, TAccountJob, TAccountVault, TAccountVaultAuthority, TAccountClientTokenAccount, TAccountPlatformTreasury, TAccountTokenProgram, TAccountHookProgram, TAccountHookWhitelist>;
71
+ export type ParsedRejectInstruction<TProgram extends string = typeof AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS, TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[]> = {
72
+ programAddress: Address<TProgram>;
73
+ accounts: {
74
+ caller: TAccountMetas[0];
75
+ acpState: TAccountMetas[1];
76
+ job: TAccountMetas[2];
77
+ vault?: TAccountMetas[3] | undefined;
78
+ vaultAuthority?: TAccountMetas[4] | undefined;
79
+ clientTokenAccount?: TAccountMetas[5] | undefined;
80
+ platformTreasury?: TAccountMetas[6] | undefined;
81
+ tokenProgram?: TAccountMetas[7] | undefined;
82
+ hookProgram?: TAccountMetas[8] | undefined;
83
+ hookWhitelist?: TAccountMetas[9] | undefined;
84
+ };
85
+ data: RejectInstructionData;
86
+ };
87
+ export declare function parseRejectInstruction<TProgram extends string, TAccountMetas extends readonly AccountMeta[]>(instruction: Instruction<TProgram> & InstructionWithAccounts<TAccountMetas> & InstructionWithData<ReadonlyUint8Array>): ParsedRejectInstruction<TProgram, TAccountMetas>;
88
+ //# sourceMappingURL=reject.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"reject.d.ts","sourceRoot":"","sources":["../../../../../../src/core/solana/generated/acp/instructions/reject.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAaL,KAAK,WAAW,EAChB,KAAK,iBAAiB,EACtB,KAAK,OAAO,EACZ,KAAK,KAAK,EACV,KAAK,OAAO,EACZ,KAAK,OAAO,EACZ,KAAK,WAAW,EAChB,KAAK,uBAAuB,EAC5B,KAAK,mBAAmB,EACxB,KAAK,eAAe,EACpB,KAAK,qBAAqB,EAC1B,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,eAAe,EACrB,MAAM,aAAa,CAAC;AAErB,OAAO,EAAE,mCAAmC,EAAE,MAAM,sBAAsB,CAAC;AAG3E,eAAO,MAAM,oBAAoB,yBAE/B,CAAC;AAEH,wBAAgB,2BAA2B,uBAE1C;AAED,MAAM,MAAM,iBAAiB,CAC3B,QAAQ,SAAS,MAAM,GAAG,OAAO,mCAAmC,EACpE,cAAc,SAAS,MAAM,GAAG,WAAW,CAAC,MAAM,CAAC,GAAG,MAAM,EAC5D,gBAAgB,SAAS,MAAM,GAAG,WAAW,CAAC,MAAM,CAAC,GAAG,MAAM,EAC9D,WAAW,SAAS,MAAM,GAAG,WAAW,CAAC,MAAM,CAAC,GAAG,MAAM,EACzD,aAAa,SAAS,MAAM,GAAG,WAAW,CAAC,MAAM,CAAC,GAAG,MAAM,EAC3D,sBAAsB,SAAS,MAAM,GAAG,WAAW,CAA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C,CAAC,CAAC,GAAG,SAAS,CAAC;QAC3C,aAAa,CAAC,EAAE,aAAa,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC;KAC9C,CAAC;IACF,IAAI,EAAE,qBAAqB,CAAC;CAC7B,CAAC;AAEF,wBAAgB,sBAAsB,CACpC,QAAQ,SAAS,MAAM,EACvB,aAAa,SAAS,SAAS,WAAW,EAAE,EAE5C,WAAW,EAAE,WAAW,CAAC,QAAQ,CAAC,GAChC,uBAAuB,CAAC,aAAa,CAAC,GACtC,mBAAmB,CAAC,kBAAkB,CAAC,GACxC,uBAAuB,CAAC,QAAQ,EAAE,aAAa,CAAC,CAiClD"}
@@ -0,0 +1,168 @@
1
+ /**
2
+ * This code was AUTOGENERATED using the Codama library.
3
+ * Please DO NOT EDIT THIS FILE, instead use visitors
4
+ * to add features, then rerun Codama to update it.
5
+ *
6
+ * @see https://github.com/codama-idl/codama
7
+ */
8
+ import { addDecoderSizePrefix, addEncoderSizePrefix, combineCodec, fixDecoderSize, fixEncoderSize, getBytesDecoder, getBytesEncoder, getStructDecoder, getStructEncoder, getU32Decoder, getU32Encoder, transformEncoder, } from "@solana/kit";
9
+ import { findAcpStatePda } from "../pdas/index.js";
10
+ import { AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS } from "../programs/index.js";
11
+ import { getAccountMetaFactory } from "../shared/index.js";
12
+ export const REJECT_DISCRIMINATOR = new Uint8Array([
13
+ 135, 7, 63, 85, 131, 114, 111, 224,
14
+ ]);
15
+ export function getRejectDiscriminatorBytes() {
16
+ return fixEncoderSize(getBytesEncoder(), 8).encode(REJECT_DISCRIMINATOR);
17
+ }
18
+ export function getRejectInstructionDataEncoder() {
19
+ return transformEncoder(getStructEncoder([
20
+ ["discriminator", fixEncoderSize(getBytesEncoder(), 8)],
21
+ ["reason", fixEncoderSize(getBytesEncoder(), 32)],
22
+ ["optParams", addEncoderSizePrefix(getBytesEncoder(), getU32Encoder())],
23
+ ]), (value) => ({ ...value, discriminator: REJECT_DISCRIMINATOR }));
24
+ }
25
+ export function getRejectInstructionDataDecoder() {
26
+ return getStructDecoder([
27
+ ["discriminator", fixDecoderSize(getBytesDecoder(), 8)],
28
+ ["reason", fixDecoderSize(getBytesDecoder(), 32)],
29
+ ["optParams", addDecoderSizePrefix(getBytesDecoder(), getU32Decoder())],
30
+ ]);
31
+ }
32
+ export function getRejectInstructionDataCodec() {
33
+ return combineCodec(getRejectInstructionDataEncoder(), getRejectInstructionDataDecoder());
34
+ }
35
+ export async function getRejectInstructionAsync(input, config) {
36
+ // Program address.
37
+ const programAddress = config?.programAddress ?? AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS;
38
+ // Original accounts.
39
+ const originalAccounts = {
40
+ caller: { value: input.caller ?? null, isWritable: false },
41
+ acpState: { value: input.acpState ?? null, isWritable: false },
42
+ job: { value: input.job ?? null, isWritable: true },
43
+ vault: { value: input.vault ?? null, isWritable: true },
44
+ vaultAuthority: { value: input.vaultAuthority ?? null, isWritable: false },
45
+ clientTokenAccount: {
46
+ value: input.clientTokenAccount ?? null,
47
+ isWritable: true,
48
+ },
49
+ platformTreasury: {
50
+ value: input.platformTreasury ?? null,
51
+ isWritable: true,
52
+ },
53
+ tokenProgram: { value: input.tokenProgram ?? null, isWritable: false },
54
+ hookProgram: { value: input.hookProgram ?? null, isWritable: false },
55
+ hookWhitelist: { value: input.hookWhitelist ?? null, isWritable: false },
56
+ };
57
+ const accounts = originalAccounts;
58
+ // Original args.
59
+ const args = { ...input };
60
+ // Resolve default values.
61
+ if (!accounts.acpState.value) {
62
+ accounts.acpState.value = await findAcpStatePda();
63
+ }
64
+ if (!accounts.tokenProgram.value) {
65
+ accounts.tokenProgram.value =
66
+ "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
67
+ }
68
+ const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
69
+ return Object.freeze({
70
+ accounts: [
71
+ getAccountMeta(accounts.caller),
72
+ getAccountMeta(accounts.acpState),
73
+ getAccountMeta(accounts.job),
74
+ getAccountMeta(accounts.vault),
75
+ getAccountMeta(accounts.vaultAuthority),
76
+ getAccountMeta(accounts.clientTokenAccount),
77
+ getAccountMeta(accounts.platformTreasury),
78
+ getAccountMeta(accounts.tokenProgram),
79
+ getAccountMeta(accounts.hookProgram),
80
+ getAccountMeta(accounts.hookWhitelist),
81
+ ],
82
+ data: getRejectInstructionDataEncoder().encode(args),
83
+ programAddress,
84
+ });
85
+ }
86
+ export function getRejectInstruction(input, config) {
87
+ // Program address.
88
+ const programAddress = config?.programAddress ?? AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS;
89
+ // Original accounts.
90
+ const originalAccounts = {
91
+ caller: { value: input.caller ?? null, isWritable: false },
92
+ acpState: { value: input.acpState ?? null, isWritable: false },
93
+ job: { value: input.job ?? null, isWritable: true },
94
+ vault: { value: input.vault ?? null, isWritable: true },
95
+ vaultAuthority: { value: input.vaultAuthority ?? null, isWritable: false },
96
+ clientTokenAccount: {
97
+ value: input.clientTokenAccount ?? null,
98
+ isWritable: true,
99
+ },
100
+ platformTreasury: {
101
+ value: input.platformTreasury ?? null,
102
+ isWritable: true,
103
+ },
104
+ tokenProgram: { value: input.tokenProgram ?? null, isWritable: false },
105
+ hookProgram: { value: input.hookProgram ?? null, isWritable: false },
106
+ hookWhitelist: { value: input.hookWhitelist ?? null, isWritable: false },
107
+ };
108
+ const accounts = originalAccounts;
109
+ // Original args.
110
+ const args = { ...input };
111
+ // Resolve default values.
112
+ if (!accounts.tokenProgram.value) {
113
+ accounts.tokenProgram.value =
114
+ "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
115
+ }
116
+ const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
117
+ return Object.freeze({
118
+ accounts: [
119
+ getAccountMeta(accounts.caller),
120
+ getAccountMeta(accounts.acpState),
121
+ getAccountMeta(accounts.job),
122
+ getAccountMeta(accounts.vault),
123
+ getAccountMeta(accounts.vaultAuthority),
124
+ getAccountMeta(accounts.clientTokenAccount),
125
+ getAccountMeta(accounts.platformTreasury),
126
+ getAccountMeta(accounts.tokenProgram),
127
+ getAccountMeta(accounts.hookProgram),
128
+ getAccountMeta(accounts.hookWhitelist),
129
+ ],
130
+ data: getRejectInstructionDataEncoder().encode(args),
131
+ programAddress,
132
+ });
133
+ }
134
+ export function parseRejectInstruction(instruction) {
135
+ if (instruction.accounts.length < 10) {
136
+ // TODO: Coded error.
137
+ throw new Error("Not enough accounts");
138
+ }
139
+ let accountIndex = 0;
140
+ const getNextAccount = () => {
141
+ const accountMeta = instruction.accounts[accountIndex];
142
+ accountIndex += 1;
143
+ return accountMeta;
144
+ };
145
+ const getNextOptionalAccount = () => {
146
+ const accountMeta = getNextAccount();
147
+ return accountMeta.address === AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS
148
+ ? undefined
149
+ : accountMeta;
150
+ };
151
+ return {
152
+ programAddress: instruction.programAddress,
153
+ accounts: {
154
+ caller: getNextAccount(),
155
+ acpState: getNextAccount(),
156
+ job: getNextAccount(),
157
+ vault: getNextOptionalAccount(),
158
+ vaultAuthority: getNextOptionalAccount(),
159
+ clientTokenAccount: getNextOptionalAccount(),
160
+ platformTreasury: getNextOptionalAccount(),
161
+ tokenProgram: getNextOptionalAccount(),
162
+ hookProgram: getNextOptionalAccount(),
163
+ hookWhitelist: getNextOptionalAccount(),
164
+ },
165
+ data: getRejectInstructionDataDecoder().decode(instruction.data),
166
+ };
167
+ }
168
+ //# sourceMappingURL=reject.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"reject.js","sourceRoot":"","sources":["../../../../../../src/core/solana/generated/acp/instructions/reject.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EACL,oBAAoB,EACpB,oBAAoB,EACpB,YAAY,EACZ,cAAc,EACd,cAAc,EACd,eAAe,EACf,eAAe,EACf,gBAAgB,EAChB,gBAAgB,EAChB,aAAa,EACb,aAAa,EACb,gBAAgB,GAejB,MAAM,aAA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AC,OAAO,KAAK,mCAAmC;YAChE,CAAC,CAAC,SAAS;YACX,CAAC,CAAC,WAAW,CAAC;IAClB,CAAC,CAAC;IACF,OAAO;QACL,cAAc,EAAE,WAAW,CAAC,cAAc;QAC1C,QAAQ,EAAE;YACR,MAAM,EAAE,cAAc,EAAE;YACxB,QAAQ,EAAE,cAAc,EAAE;YAC1B,GAAG,EAAE,cAAc,EAAE;YACrB,KAAK,EAAE,sBAAsB,EAAE;YAC/B,cAAc,EAAE,sBAAsB,EAAE;YACxC,kBAAkB,EAAE,sBAAsB,EAAE;YAC5C,gBAAgB,EAAE,sBAAsB,EAAE;YAC1C,YAAY,EAAE,sBAAsB,EAAE;YACtC,WAAW,EAAE,sBAAsB,EAAE;YACrC,aAAa,EAAE,sBAAsB,EAAE;SACxC;QACD,IAAI,EAAE,+BAA+B,EAAE,CAAC,MAAM,CAAC,WAAW,CAAC,IAAI,CAAC;KACjE,CAAC;AACJ,CAAC"}
@@ -0,0 +1,56 @@
1
+ /**
2
+ * This code was AUTOGENERATED using the Codama library.
3
+ * Please DO NOT EDIT THIS FILE, instead use visitors
4
+ * to add features, then rerun Codama to update it.
5
+ *
6
+ * @see https://github.com/codama-idl/codama
7
+ */
8
+ import { type AccountMeta, type AccountSignerMeta, type Address, type FixedSizeCodec, type FixedSizeDecoder, type FixedSizeEncoder, type Instruction, type InstructionWithAccounts, type InstructionWithData, type ReadonlyAccount, type ReadonlyUint8Array, type TransactionSigner, type WritableAccount, type WritableSignerAccount } from "@solana/kit";
9
+ import { AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS } from "../programs/index.js";
10
+ export declare const REMOVE_HOOK_WHITELIST_DISCRIMINATOR: Uint8Array<ArrayBuffer>;
11
+ export declare function getRemoveHookWhitelistDiscriminatorBytes(): ReadonlyUint8Array;
12
+ export type RemoveHookWhitelistInstruction<TProgram extends string = typeof AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS, TAccountAuthority extends string | AccountMeta<string> = string, TAccountAcpState extends string | AccountMeta<string> = string, TAccountHookWhitelist extends string | AccountMeta<string> = string, TRemainingAccounts extends readonly AccountMeta<string>[] = []> = Instruction<TProgram> & InstructionWithData<ReadonlyUint8Array> & InstructionWithAccounts<[
13
+ TAccountAuthority extends string ? WritableSignerAccount<TAccountAuthority> & AccountSignerMeta<TAccountAuthority> : TAccountAuthority,
14
+ TAccountAcpState extends string ? ReadonlyAccount<TAccountAcpState> : TAccountAcpState,
15
+ TAccountHookWhitelist extends string ? WritableAccount<TAccountHookWhitelist> : TAccountHookWhitelist,
16
+ ...TRemainingAccounts
17
+ ]>;
18
+ export type RemoveHookWhitelistInstructionData = {
19
+ discriminator: ReadonlyUint8Array;
20
+ hook: Address;
21
+ };
22
+ export type RemoveHookWhitelistInstructionDataArgs = {
23
+ hook: Address;
24
+ };
25
+ export declare function getRemoveHookWhitelistInstructionDataEncoder(): FixedSizeEncoder<RemoveHookWhitelistInstructionDataArgs>;
26
+ export declare function getRemoveHookWhitelistInstructionDataDecoder(): FixedSizeDecoder<RemoveHookWhitelistInstructionData>;
27
+ export declare function getRemoveHookWhitelistInstructionDataCodec(): FixedSizeCodec<RemoveHookWhitelistInstructionDataArgs, RemoveHookWhitelistInstructionData>;
28
+ export type RemoveHookWhitelistAsyncInput<TAccountAuthority extends string = string, TAccountAcpState extends string = string, TAccountHookWhitelist extends string = string> = {
29
+ authority: TransactionSigner<TAccountAuthority>;
30
+ acpState?: Address<TAccountAcpState>;
31
+ hookWhitelist?: Address<TAccountHookWhitelist>;
32
+ hook: RemoveHookWhitelistInstructionDataArgs["hook"];
33
+ };
34
+ export declare function getRemoveHookWhitelistInstructionAsync<TAccountAuthority extends string, TAccountAcpState extends string, TAccountHookWhitelist extends string, TProgramAddress extends Address = typeof AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS>(input: RemoveHookWhitelistAsyncInput<TAccountAuthority, TAccountAcpState, TAccountHookWhitelist>, config?: {
35
+ programAddress?: TProgramAddress;
36
+ }): Promise<RemoveHookWhitelistInstruction<TProgramAddress, TAccountAuthority, TAccountAcpState, TAccountHookWhitelist>>;
37
+ export type RemoveHookWhitelistInput<TAccountAuthority extends string = string, TAccountAcpState extends string = string, TAccountHookWhitelist extends string = string> = {
38
+ authority: TransactionSigner<TAccountAuthority>;
39
+ acpState: Address<TAccountAcpState>;
40
+ hookWhitelist: Address<TAccountHookWhitelist>;
41
+ hook: RemoveHookWhitelistInstructionDataArgs["hook"];
42
+ };
43
+ export declare function getRemoveHookWhitelistInstruction<TAccountAuthority extends string, TAccountAcpState extends string, TAccountHookWhitelist extends string, TProgramAddress extends Address = typeof AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS>(input: RemoveHookWhitelistInput<TAccountAuthority, TAccountAcpState, TAccountHookWhitelist>, config?: {
44
+ programAddress?: TProgramAddress;
45
+ }): RemoveHookWhitelistInstruction<TProgramAddress, TAccountAuthority, TAccountAcpState, TAccountHookWhitelist>;
46
+ export type ParsedRemoveHookWhitelistInstruction<TProgram extends string = typeof AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS, TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[]> = {
47
+ programAddress: Address<TProgram>;
48
+ accounts: {
49
+ authority: TAccountMetas[0];
50
+ acpState: TAccountMetas[1];
51
+ hookWhitelist: TAccountMetas[2];
52
+ };
53
+ data: RemoveHookWhitelistInstructionData;
54
+ };
55
+ export declare function parseRemoveHookWhitelistInstruction<TProgram extends string, TAccountMetas extends readonly AccountMeta[]>(instruction: Instruction<TProgram> & InstructionWithAccounts<TAccountMetas> & InstructionWithData<ReadonlyUint8Array>): ParsedRemoveHookWhitelistInstruction<TProgram, TAccountMetas>;
56
+ //# sourceMappingURL=removeHookWhitelist.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"removeHookWhitelist.d.ts","sourceRoot":"","sources":["../../../../../../src/core/solana/generated/acp/instructions/removeHookWhitelist.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAWL,KAAK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CAsB/D"}
@@ -0,0 +1,112 @@
1
+ /**
2
+ * This code was AUTOGENERATED using the Codama library.
3
+ * Please DO NOT EDIT THIS FILE, instead use visitors
4
+ * to add features, then rerun Codama to update it.
5
+ *
6
+ * @see https://github.com/codama-idl/codama
7
+ */
8
+ import { combineCodec, fixDecoderSize, fixEncoderSize, getAddressDecoder, getAddressEncoder, getBytesDecoder, getBytesEncoder, getStructDecoder, getStructEncoder, transformEncoder, } from "@solana/kit";
9
+ import { findAcpStatePda, findHookWhitelistPda } from "../pdas/index.js";
10
+ import { AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS } from "../programs/index.js";
11
+ import { expectSome, getAccountMetaFactory, } from "../shared/index.js";
12
+ export const REMOVE_HOOK_WHITELIST_DISCRIMINATOR = new Uint8Array([
13
+ 110, 220, 154, 1, 141, 191, 150, 74,
14
+ ]);
15
+ export function getRemoveHookWhitelistDiscriminatorBytes() {
16
+ return fixEncoderSize(getBytesEncoder(), 8).encode(REMOVE_HOOK_WHITELIST_DISCRIMINATOR);
17
+ }
18
+ export function getRemoveHookWhitelistInstructionDataEncoder() {
19
+ return transformEncoder(getStructEncoder([
20
+ ["discriminator", fixEncoderSize(getBytesEncoder(), 8)],
21
+ ["hook", getAddressEncoder()],
22
+ ]), (value) => ({
23
+ ...value,
24
+ discriminator: REMOVE_HOOK_WHITELIST_DISCRIMINATOR,
25
+ }));
26
+ }
27
+ export function getRemoveHookWhitelistInstructionDataDecoder() {
28
+ return getStructDecoder([
29
+ ["discriminator", fixDecoderSize(getBytesDecoder(), 8)],
30
+ ["hook", getAddressDecoder()],
31
+ ]);
32
+ }
33
+ export function getRemoveHookWhitelistInstructionDataCodec() {
34
+ return combineCodec(getRemoveHookWhitelistInstructionDataEncoder(), getRemoveHookWhitelistInstructionDataDecoder());
35
+ }
36
+ export async function getRemoveHookWhitelistInstructionAsync(input, config) {
37
+ // Program address.
38
+ const programAddress = config?.programAddress ?? AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS;
39
+ // Original accounts.
40
+ const originalAccounts = {
41
+ authority: { value: input.authority ?? null, isWritable: true },
42
+ acpState: { value: input.acpState ?? null, isWritable: false },
43
+ hookWhitelist: { value: input.hookWhitelist ?? null, isWritable: true },
44
+ };
45
+ const accounts = originalAccounts;
46
+ // Original args.
47
+ const args = { ...input };
48
+ // Resolve default values.
49
+ if (!accounts.acpState.value) {
50
+ accounts.acpState.value = await findAcpStatePda();
51
+ }
52
+ if (!accounts.hookWhitelist.value) {
53
+ accounts.hookWhitelist.value = await findHookWhitelistPda({
54
+ hook: expectSome(args.hook),
55
+ });
56
+ }
57
+ const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
58
+ return Object.freeze({
59
+ accounts: [
60
+ getAccountMeta(accounts.authority),
61
+ getAccountMeta(accounts.acpState),
62
+ getAccountMeta(accounts.hookWhitelist),
63
+ ],
64
+ data: getRemoveHookWhitelistInstructionDataEncoder().encode(args),
65
+ programAddress,
66
+ });
67
+ }
68
+ export function getRemoveHookWhitelistInstruction(input, config) {
69
+ // Program address.
70
+ const programAddress = config?.programAddress ?? AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS;
71
+ // Original accounts.
72
+ const originalAccounts = {
73
+ authority: { value: input.authority ?? null, isWritable: true },
74
+ acpState: { value: input.acpState ?? null, isWritable: false },
75
+ hookWhitelist: { value: input.hookWhitelist ?? null, isWritable: true },
76
+ };
77
+ const accounts = originalAccounts;
78
+ // Original args.
79
+ const args = { ...input };
80
+ const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
81
+ return Object.freeze({
82
+ accounts: [
83
+ getAccountMeta(accounts.authority),
84
+ getAccountMeta(accounts.acpState),
85
+ getAccountMeta(accounts.hookWhitelist),
86
+ ],
87
+ data: getRemoveHookWhitelistInstructionDataEncoder().encode(args),
88
+ programAddress,
89
+ });
90
+ }
91
+ export function parseRemoveHookWhitelistInstruction(instruction) {
92
+ if (instruction.accounts.length < 3) {
93
+ // TODO: Coded error.
94
+ throw new Error("Not enough accounts");
95
+ }
96
+ let accountIndex = 0;
97
+ const getNextAccount = () => {
98
+ const accountMeta = instruction.accounts[accountIndex];
99
+ accountIndex += 1;
100
+ return accountMeta;
101
+ };
102
+ return {
103
+ programAddress: instruction.programAddress,
104
+ accounts: {
105
+ authority: getNextAccount(),
106
+ acpState: getNextAccount(),
107
+ hookWhitelist: getNextAccount(),
108
+ },
109
+ data: getRemoveHookWhitelistInstructionDataDecoder().decode(instruction.data),
110
+ };
111
+ }
112
+ //# sourceMappingURL=removeHookWhitelist.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"removeHookWhitelist.js","sourceRoot":"","sources":["../../../../../../src/core/solana/generated/acp/instructions/removeHookWhitelist.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EACL,YAAY,EACZ,cAAc,EACd,cAAc,EACd,iBAAiB,EACjB,iBAAiB,EACjB,eAAe,EACf,eAAe,EACf,gBAAgB,EAChB,gBAAgB,EAChB,gBAAgB,GAejB,MAAM,aAAa,CAAC;AACrB,OAAO,EAAE,eAAe,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AACzE,OAAO,EAAE,mCAAmC,EAAE,MAAM,sBAAsB,CAAC;AAC3E,OAAO,EACL,UAAU,EACV,qBAAqB,GAEtB,MAAM,oBAAoB,CAAC;AAE5B,MAAM,CAAC,MAAM,mCAAmC,GAAG,IAAI,UAAU,CAAC;IAChE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,EAAE;CACpC,CAAC,CAAC;AAEH,MAAM,UAAU,wCAAwC;IACtD,OAAO,cAAc,CAAC,eAAe,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,CAChD,mCAAmC,CACpC,CAAC;AACJ,CAAC;AAiCD,MAAM,UAAU,4CAA4C;IAC1D,OAAO,gBAAgB,CACrB,gBAAgB,CAAC;QACf,CAAC,eAAe,EAAE,cAAc,CAAC,eAAe,E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CAAC,cAAc,EAAE,WAAW,CAAC,CAAC;IAC1E,OAAO,MAAM,CAAC,MAAM,CAAC;QACnB,QAAQ,EAAE;YACR,cAAc,CAAC,QAAQ,CAAC,SAAS,CAAC;YAClC,cAAc,CAAC,QAAQ,CAAC,QAAQ,CAAC;YACjC,cAAc,CAAC,QAAQ,CAAC,aAAa,CAAC;SACvC;QACD,IAAI,EAAE,4CAA4C,EAAE,CAAC,MAAM,CACzD,IAA8C,CAC/C;QACD,cAAc;KAMf,CAAC,CAAC;AACL,CAAC;AAeD,MAAM,UAAU,mCAAmC,CAIjD,WAEyC;IAEzC,IAAI,WAAW,CAAC,QAAQ,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACpC,qBAAqB;QACrB,MAAM,IAAI,KAAK,CAAC,qBAAqB,CAAC,CAAC;IACzC,CAAC;IACD,IAAI,YAAY,GAAG,CAAC,CAAC;IACrB,MAAM,cAAc,GAAG,GAAG,EAAE;QAC1B,MAAM,WAAW,GAAI,WAAW,CAAC,QAA0B,CAAC,YAAY,CAAE,CAAC;QAC3E,YAAY,IAAI,CAAC,CAAC;QAClB,OAAO,WAAW,CAAC;IACrB,CAAC,CAAC;IACF,OAAO;QACL,cAAc,EAAE,WAAW,CAAC,cAAc;QAC1C,QAAQ,EAAE;YACR,SAAS,EAAE,cAAc,EAAE;YAC3B,QAAQ,EAAE,cAAc,EAAE;YAC1B,aAAa,EAAE,cAAc,EAAE;SAChC;QACD,IAAI,EAAE,4CAA4C,EAAE,CAAC,MAAM,CACzD,WAAW,CAAC,IAAI,CACjB;KACF,CAAC;AACJ,CAAC"}
@@ -0,0 +1,56 @@
1
+ /**
2
+ * This code was AUTOGENERATED using the Codama library.
3
+ * Please DO NOT EDIT THIS FILE, instead use visitors
4
+ * to add features, then rerun Codama to update it.
5
+ *
6
+ * @see https://github.com/codama-idl/codama
7
+ */
8
+ import { type AccountMeta, type AccountSignerMeta, type Address, type Codec, type Decoder, type Encoder, type Instruction, type InstructionWithAccounts, type InstructionWithData, type ReadonlyAccount, type ReadonlySignerAccount, type ReadonlyUint8Array, type TransactionSigner, type WritableAccount } from "@solana/kit";
9
+ import { AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS } from "../programs/index.js";
10
+ export declare const SET_BUDGET_DISCRIMINATOR: Uint8Array<ArrayBuffer>;
11
+ export declare function getSetBudgetDiscriminatorBytes(): ReadonlyUint8Array;
12
+ export type SetBudgetInstruction<TProgram extends string = typeof AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS, TAccountCaller extends string | AccountMeta<string> = string, TAccountJob extends string | AccountMeta<string> = string, TAccountBudgetMint extends string | AccountMeta<string> = string, TAccountHookProgram extends string | AccountMeta<string> = string, TAccountHookWhitelist extends string | AccountMeta<string> = string, TRemainingAccounts extends readonly AccountMeta<string>[] = []> = Instruction<TProgram> & InstructionWithData<ReadonlyUint8Array> & InstructionWithAccounts<[
13
+ TAccountCaller extends string ? ReadonlySignerAccount<TAccountCaller> & AccountSignerMeta<TAccountCaller> : TAccountCaller,
14
+ TAccountJob extends string ? WritableAccount<TAccountJob> : TAccountJob,
15
+ TAccountBudgetMint extends string ? ReadonlyAccount<TAccountBudgetMint> : TAccountBudgetMint,
16
+ TAccountHookProgram extends string ? ReadonlyAccount<TAccountHookProgram> : TAccountHookProgram,
17
+ TAccountHookWhitelist extends string ? ReadonlyAccount<TAccountHookWhitelist> : TAccountHookWhitelist,
18
+ ...TRemainingAccounts
19
+ ]>;
20
+ export type SetBudgetInstructionData = {
21
+ discriminator: ReadonlyUint8Array;
22
+ amount: bigint;
23
+ optParams: ReadonlyUint8Array;
24
+ };
25
+ export type SetBudgetInstructionDataArgs = {
26
+ amount: number | bigint;
27
+ optParams: ReadonlyUint8Array;
28
+ };
29
+ export declare function getSetBudgetInstructionDataEncoder(): Encoder<SetBudgetInstructionDataArgs>;
30
+ export declare function getSetBudgetInstructionDataDecoder(): Decoder<SetBudgetInstructionData>;
31
+ export declare function getSetBudgetInstructionDataCodec(): Codec<SetBudgetInstructionDataArgs, SetBudgetInstructionData>;
32
+ export type SetBudgetInput<TAccountCaller extends string = string, TAccountJob extends string = string, TAccountBudgetMint extends string = string, TAccountHookProgram extends string = string, TAccountHookWhitelist extends string = string> = {
33
+ caller: TransactionSigner<TAccountCaller>;
34
+ job: Address<TAccountJob>;
35
+ budgetMint: Address<TAccountBudgetMint>;
36
+ hookProgram?: Address<TAccountHookProgram>;
37
+ hookWhitelist?: Address<TAccountHookWhitelist>;
38
+ amount: SetBudgetInstructionDataArgs["amount"];
39
+ optParams: SetBudgetInstructionDataArgs["optParams"];
40
+ };
41
+ export declare function getSetBudgetInstruction<TAccountCaller extends string, TAccountJob extends string, TAccountBudgetMint extends string, TAccountHookProgram extends string, TAccountHookWhitelist extends string, TProgramAddress extends Address = typeof AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS>(input: SetBudgetInput<TAccountCaller, TAccountJob, TAccountBudgetMint, TAccountHookProgram, TAccountHookWhitelist>, config?: {
42
+ programAddress?: TProgramAddress;
43
+ }): SetBudgetInstruction<TProgramAddress, TAccountCaller, TAccountJob, TAccountBudgetMint, TAccountHookProgram, TAccountHookWhitelist>;
44
+ export type ParsedSetBudgetInstruction<TProgram extends string = typeof AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS, TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[]> = {
45
+ programAddress: Address<TProgram>;
46
+ accounts: {
47
+ caller: TAccountMetas[0];
48
+ job: TAccountMetas[1];
49
+ budgetMint: TAccountMetas[2];
50
+ hookProgram?: TAccountMetas[3] | undefined;
51
+ hookWhitelist?: TAccountMetas[4] | undefined;
52
+ };
53
+ data: SetBudgetInstructionData;
54
+ };
55
+ export declare function parseSetBudgetInstruction<TProgram extends string, TAccountMetas extends readonly AccountMeta[]>(instruction: Instruction<TProgram> & InstructionWithAccounts<TAccountMetas> & InstructionWithData<ReadonlyUint8Array>): ParsedSetBudgetInstruction<TProgram, TAccountMetas>;
56
+ //# sourceMappingURL=setBudget.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"setBudget.d.ts","sourceRoot":"","sources":["../../../../../../src/core/solana/generated/acp/instructions/setBudget.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAeL,KAAK,WAAW,EAChB,KAAK,iBAAiB,EACtB,KAAK,OAAO,EACZ,KAAK,KAAK,EACV,KAAK,OAAO,EACZ,KAAK,OAAO,EACZ,KAAK,WAAW,EAChB,KAAK,uBAAuB,EAC5B,KAAK,mBAAmB,EACxB,KAAK,eAAe,EACpB,KAAK,qBAAqB,EAC1B,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,eAAe,EACrB,MAAM,aAAa,CAAC;AACrB,OAAO,EAAE,mCAAmC,EAAE,MAAM,sBAAsB,CAAC;AAG3E,eAAO,MAAM,wBAAwB,yBAEnC,CAAC;AAEH,wBAAgB,8BAA8B,uBAE7C;AAED,MAAM,MAAM,oBAAoB,CAC9B,QAAQ,SAAS,MAAM,GAAG,OAAO,mCAAmC,EACpE,cAAc,SAAS,MAAM,GAAG,WAAW,CAAC,MAAM,CAAC,GAAG,MAAM,EAC5D,WAAW,SAAS,MAAM,GAAG,WAAW,CAAC,MAAM,CAAC,GAAG,MAAM,EACzD,kBAAkB,SAAS,MAAM,GAAG,WAAW,CAAC,MAAM,CAAC,GAAG,MAAM,EAChE,mBAAmB,SAAS,MAAM,GAAG,WAAW,CAAC,MAAM,CAAC,GAAG,MAAM,EACjE,qBAAqB,SAAS,MAAM,GAAG,WAAW,CAAC,MAAM,CAAC,GAAG,MAAM,EACnE,kBAAkB,SAAS,SAAS,WAAW,CAAC,MAAM,CAAC,EAAE,GAAG,EAAE,IAC5D,WAAW,CAAC,QAAQ,CAAC,GACvB,mBAAmB,CAAC,kBAAkB,CAAC,GACvC,uBAAuB,CACrB;IACE,cAAc,SAAS,MAAM,GACzB,qBAAqB,CAAC,cAAc,CAAC,GACnC,iBAAiB,CAAC,cAAc,CAAC,GACnC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SAAS,WAAW,EAAE,EAE5C,WAAW,EAAE,WAAW,CAAC,QAAQ,CAAC,GAChC,uBAAuB,CAAC,aAAa,CAAC,GACtC,mBAAmB,CAAC,kBAAkB,CAAC,GACxC,0BAA0B,CAAC,QAAQ,EAAE,aAAa,CAAC,CA4BrD"}
@@ -0,0 +1,90 @@
1
+ /**
2
+ * This code was AUTOGENERATED using the Codama library.
3
+ * Please DO NOT EDIT THIS FILE, instead use visitors
4
+ * to add features, then rerun Codama to update it.
5
+ *
6
+ * @see https://github.com/codama-idl/codama
7
+ */
8
+ import { addDecoderSizePrefix, addEncoderSizePrefix, combineCodec, fixDecoderSize, fixEncoderSize, getBytesDecoder, getBytesEncoder, getStructDecoder, getStructEncoder, getU32Decoder, getU32Encoder, getU64Decoder, getU64Encoder, transformEncoder, } from "@solana/kit";
9
+ import { AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS } from "../programs/index.js";
10
+ import { getAccountMetaFactory } from "../shared/index.js";
11
+ export const SET_BUDGET_DISCRIMINATOR = new Uint8Array([
12
+ 148, 121, 226, 12, 183, 120, 26, 227,
13
+ ]);
14
+ export function getSetBudgetDiscriminatorBytes() {
15
+ return fixEncoderSize(getBytesEncoder(), 8).encode(SET_BUDGET_DISCRIMINATOR);
16
+ }
17
+ export function getSetBudgetInstructionDataEncoder() {
18
+ return transformEncoder(getStructEncoder([
19
+ ["discriminator", fixEncoderSize(getBytesEncoder(), 8)],
20
+ ["amount", getU64Encoder()],
21
+ ["optParams", addEncoderSizePrefix(getBytesEncoder(), getU32Encoder())],
22
+ ]), (value) => ({ ...value, discriminator: SET_BUDGET_DISCRIMINATOR }));
23
+ }
24
+ export function getSetBudgetInstructionDataDecoder() {
25
+ return getStructDecoder([
26
+ ["discriminator", fixDecoderSize(getBytesDecoder(), 8)],
27
+ ["amount", getU64Decoder()],
28
+ ["optParams", addDecoderSizePrefix(getBytesDecoder(), getU32Decoder())],
29
+ ]);
30
+ }
31
+ export function getSetBudgetInstructionDataCodec() {
32
+ return combineCodec(getSetBudgetInstructionDataEncoder(), getSetBudgetInstructionDataDecoder());
33
+ }
34
+ export function getSetBudgetInstruction(input, config) {
35
+ // Program address.
36
+ const programAddress = config?.programAddress ?? AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS;
37
+ // Original accounts.
38
+ const originalAccounts = {
39
+ caller: { value: input.caller ?? null, isWritable: false },
40
+ job: { value: input.job ?? null, isWritable: true },
41
+ budgetMint: { value: input.budgetMint ?? null, isWritable: false },
42
+ hookProgram: { value: input.hookProgram ?? null, isWritable: false },
43
+ hookWhitelist: { value: input.hookWhitelist ?? null, isWritable: false },
44
+ };
45
+ const accounts = originalAccounts;
46
+ // Original args.
47
+ const args = { ...input };
48
+ const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
49
+ return Object.freeze({
50
+ accounts: [
51
+ getAccountMeta(accounts.caller),
52
+ getAccountMeta(accounts.job),
53
+ getAccountMeta(accounts.budgetMint),
54
+ getAccountMeta(accounts.hookProgram),
55
+ getAccountMeta(accounts.hookWhitelist),
56
+ ],
57
+ data: getSetBudgetInstructionDataEncoder().encode(args),
58
+ programAddress,
59
+ });
60
+ }
61
+ export function parseSetBudgetInstruction(instruction) {
62
+ if (instruction.accounts.length < 5) {
63
+ // TODO: Coded error.
64
+ throw new Error("Not enough accounts");
65
+ }
66
+ let accountIndex = 0;
67
+ const getNextAccount = () => {
68
+ const accountMeta = instruction.accounts[accountIndex];
69
+ accountIndex += 1;
70
+ return accountMeta;
71
+ };
72
+ const getNextOptionalAccount = () => {
73
+ const accountMeta = getNextAccount();
74
+ return accountMeta.address === AGENTIC_COMMERCE_V3_PROGRAM_ADDRESS
75
+ ? undefined
76
+ : accountMeta;
77
+ };
78
+ return {
79
+ programAddress: instruction.programAddress,
80
+ accounts: {
81
+ caller: getNextAccount(),
82
+ job: getNextAccount(),
83
+ budgetMint: getNextAccount(),
84
+ hookProgram: getNextOptionalAccount(),
85
+ hookWhitelist: getNextOptionalAccount(),
86
+ },
87
+ data: getSetBudgetInstructionDataDecoder().decode(instruction.data),
88
+ };
89
+ }
90
+ //# sourceMappingURL=setBudget.js.map