@meteora-ag/cp-amm-sdk 1.0.0 → 1.0.1-1.rc-0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (975) hide show
  1. package/dist/index.d.mts +1266 -332
  2. package/dist/index.d.ts +1266 -332
  3. package/dist/index.js +1231 -362
  4. package/dist/index.js.map +1 -1
  5. package/dist/index.mjs +1248 -379
  6. package/dist/index.mjs.map +1 -1
  7. package/node_modules/@babel/runtime/helpers/esm/interopRequireWildcard.js +19 -24
  8. package/node_modules/@babel/runtime/helpers/esm/regeneratorRuntime.js +178 -210
  9. package/node_modules/@babel/runtime/helpers/interopRequireWildcard.js +19 -24
  10. package/node_modules/@babel/runtime/helpers/regeneratorRuntime.js +178 -210
  11. package/node_modules/@babel/runtime/package.json +1 -4
  12. package/node_modules/@coral-xyz/anchor/dist/browser/index.js +11 -12
  13. package/node_modules/@coral-xyz/anchor/dist/browser/index.js.map +1 -1
  14. package/node_modules/@coral-xyz/anchor/dist/browser/src/coder/borsh/idl.d.ts.map +1 -1
  15. package/node_modules/@coral-xyz/anchor/dist/cjs/coder/borsh/idl.d.ts.map +1 -1
  16. package/node_modules/@coral-xyz/anchor/dist/cjs/coder/borsh/idl.js +8 -9
  17. package/node_modules/@coral-xyz/anchor/dist/cjs/coder/borsh/idl.js.map +1 -1
  18. package/node_modules/@coral-xyz/anchor/dist/cjs/program/accounts-resolver.js +3 -3
  19. package/node_modules/@coral-xyz/anchor/dist/cjs/program/accounts-resolver.js.map +1 -1
  20. package/node_modules/@coral-xyz/anchor/dist/esm/coder/borsh/idl.d.ts.map +1 -1
  21. package/node_modules/@coral-xyz/anchor/dist/esm/coder/borsh/idl.js +8 -9
  22. package/node_modules/@coral-xyz/anchor/dist/esm/coder/borsh/idl.js.map +1 -1
  23. package/node_modules/@coral-xyz/anchor/dist/esm/program/accounts-resolver.js +3 -3
  24. package/node_modules/@coral-xyz/anchor/dist/esm/program/accounts-resolver.js.map +1 -1
  25. package/node_modules/@coral-xyz/anchor/dist/tsconfig.cjs.tsbuildinfo +1 -1
  26. package/node_modules/@coral-xyz/anchor/dist/tsconfig.tsbuildinfo +1 -1
  27. package/node_modules/@coral-xyz/anchor/package.json +3 -3
  28. package/node_modules/@coral-xyz/anchor-errors/package.json +1 -1
  29. package/node_modules/@coral-xyz/borsh/package.json +1 -1
  30. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/README.md +321 -436
  31. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/_shortw_utils.d.ts +2 -2
  32. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/_shortw_utils.js +2 -2
  33. package/node_modules/{@solana/web3.js/node_modules/@noble/curves/esm → @noble/curves}/abstract/bls.d.ts +5 -5
  34. package/node_modules/@noble/curves/abstract/bls.d.ts.map +1 -0
  35. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/abstract/bls.js +15 -16
  36. package/node_modules/@noble/curves/abstract/bls.js.map +1 -0
  37. package/node_modules/{@solana/web3.js/node_modules/@noble/curves/esm → @noble/curves}/abstract/curve.d.ts +11 -3
  38. package/node_modules/@noble/curves/abstract/curve.d.ts.map +1 -0
  39. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/abstract/curve.js +93 -81
  40. package/node_modules/@noble/curves/abstract/curve.js.map +1 -0
  41. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/abstract/edwards.d.ts +2 -2
  42. package/node_modules/@noble/curves/abstract/edwards.d.ts.map +1 -0
  43. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/abstract/edwards.js +72 -72
  44. package/node_modules/@noble/curves/abstract/edwards.js.map +1 -0
  45. package/node_modules/@noble/curves/abstract/fft.d.ts +120 -0
  46. package/node_modules/@noble/curves/abstract/fft.d.ts.map +1 -0
  47. package/node_modules/@noble/curves/abstract/fft.js +439 -0
  48. package/node_modules/@noble/curves/abstract/fft.js.map +1 -0
  49. package/node_modules/{@solana/web3.js/node_modules/@noble/curves/esm → @noble/curves}/abstract/hash-to-curve.d.ts +15 -9
  50. package/node_modules/@noble/curves/abstract/hash-to-curve.d.ts.map +1 -0
  51. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/abstract/hash-to-curve.js +49 -39
  52. package/node_modules/@noble/curves/abstract/hash-to-curve.js.map +1 -0
  53. package/node_modules/{@solana/web3.js/node_modules/@noble/curves/esm → @noble/curves}/abstract/modular.d.ts +13 -12
  54. package/node_modules/@noble/curves/abstract/modular.d.ts.map +1 -0
  55. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/abstract/modular.js +167 -167
  56. package/node_modules/@noble/curves/abstract/modular.js.map +1 -0
  57. package/node_modules/{@solana/web3.js/node_modules/@noble/curves/esm → @noble/curves}/abstract/montgomery.d.ts +4 -9
  58. package/node_modules/@noble/curves/abstract/montgomery.d.ts.map +1 -0
  59. package/node_modules/@noble/curves/abstract/montgomery.js +140 -0
  60. package/node_modules/@noble/curves/abstract/montgomery.js.map +1 -0
  61. package/node_modules/@noble/curves/abstract/poseidon.d.ts +76 -0
  62. package/node_modules/@noble/curves/abstract/poseidon.d.ts.map +1 -0
  63. package/node_modules/@noble/curves/abstract/poseidon.js +300 -0
  64. package/node_modules/@noble/curves/abstract/poseidon.js.map +1 -0
  65. package/node_modules/{@solana/web3.js/node_modules/@noble/curves/esm → @noble/curves}/abstract/tower.d.ts +2 -2
  66. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/abstract/tower.d.ts.map +1 -1
  67. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/abstract/tower.js +17 -18
  68. package/node_modules/@noble/curves/abstract/tower.js.map +1 -0
  69. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/abstract/utils.d.ts +5 -2
  70. package/node_modules/@noble/curves/abstract/utils.d.ts.map +1 -0
  71. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/abstract/utils.js +27 -14
  72. package/node_modules/@noble/curves/abstract/utils.js.map +1 -0
  73. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/abstract/weierstrass.d.ts +45 -10
  74. package/node_modules/@noble/curves/abstract/weierstrass.d.ts.map +1 -0
  75. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/abstract/weierstrass.js +153 -117
  76. package/node_modules/@noble/curves/abstract/weierstrass.js.map +1 -0
  77. package/node_modules/{@solana/web3.js/node_modules/@noble/curves/esm → @noble/curves}/bls12-381.d.ts +1 -1
  78. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/bls12-381.d.ts.map +1 -1
  79. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/bls12-381.js +50 -64
  80. package/node_modules/@noble/curves/bls12-381.js.map +1 -0
  81. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/bn254.d.ts +3 -2
  82. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/bn254.d.ts.map +1 -1
  83. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/bn254.js +39 -29
  84. package/node_modules/@noble/curves/bn254.js.map +1 -0
  85. package/node_modules/{@solana/web3.js/node_modules/@noble/curves/esm → @noble/curves}/ed25519.d.ts +26 -10
  86. package/node_modules/@noble/curves/ed25519.d.ts.map +1 -0
  87. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/ed25519.js +93 -83
  88. package/node_modules/@noble/curves/ed25519.js.map +1 -0
  89. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/ed448.d.ts +26 -10
  90. package/node_modules/@noble/curves/ed448.d.ts.map +1 -0
  91. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/ed448.js +92 -82
  92. package/node_modules/@noble/curves/ed448.js.map +1 -0
  93. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/_shortw_utils.d.ts +2 -2
  94. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/_shortw_utils.js +1 -1
  95. package/node_modules/{@solana/web3.js/node_modules/@noble/curves → @noble/curves/esm}/abstract/bls.d.ts +5 -5
  96. package/node_modules/@noble/curves/esm/abstract/bls.d.ts.map +1 -0
  97. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/abstract/bls.js +6 -7
  98. package/node_modules/@noble/curves/esm/abstract/bls.js.map +1 -0
  99. package/node_modules/{@solana/web3.js/node_modules/@noble/curves → @noble/curves/esm}/abstract/curve.d.ts +11 -3
  100. package/node_modules/@noble/curves/esm/abstract/curve.d.ts.map +1 -0
  101. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/abstract/curve.js +90 -78
  102. package/node_modules/@noble/curves/esm/abstract/curve.js.map +1 -0
  103. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/abstract/edwards.d.ts +2 -2
  104. package/node_modules/@noble/curves/esm/abstract/edwards.d.ts.map +1 -0
  105. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/abstract/edwards.js +53 -53
  106. package/node_modules/@noble/curves/esm/abstract/edwards.js.map +1 -0
  107. package/node_modules/@noble/curves/esm/abstract/fft.d.ts +120 -0
  108. package/node_modules/@noble/curves/esm/abstract/fft.d.ts.map +1 -0
  109. package/node_modules/@noble/curves/esm/abstract/fft.js +426 -0
  110. package/node_modules/@noble/curves/esm/abstract/fft.js.map +1 -0
  111. package/node_modules/{@solana/web3.js/node_modules/@noble/curves → @noble/curves/esm}/abstract/hash-to-curve.d.ts +15 -9
  112. package/node_modules/@noble/curves/esm/abstract/hash-to-curve.d.ts.map +1 -0
  113. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/abstract/hash-to-curve.js +33 -23
  114. package/node_modules/@noble/curves/esm/abstract/hash-to-curve.js.map +1 -0
  115. package/node_modules/{@solana/web3.js/node_modules/@noble/curves → @noble/curves/esm}/abstract/modular.d.ts +13 -12
  116. package/node_modules/@noble/curves/esm/abstract/modular.d.ts.map +1 -0
  117. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/abstract/modular.js +159 -159
  118. package/node_modules/@noble/curves/esm/abstract/modular.js.map +1 -0
  119. package/node_modules/{@solana/web3.js/node_modules/@noble/curves → @noble/curves/esm}/abstract/montgomery.d.ts +4 -9
  120. package/node_modules/@noble/curves/esm/abstract/montgomery.d.ts.map +1 -0
  121. package/node_modules/@noble/curves/esm/abstract/montgomery.js +137 -0
  122. package/node_modules/@noble/curves/esm/abstract/montgomery.js.map +1 -0
  123. package/node_modules/@noble/curves/esm/abstract/poseidon.d.ts +76 -0
  124. package/node_modules/@noble/curves/esm/abstract/poseidon.d.ts.map +1 -0
  125. package/node_modules/@noble/curves/esm/abstract/poseidon.js +291 -0
  126. package/node_modules/@noble/curves/esm/abstract/poseidon.js.map +1 -0
  127. package/node_modules/{@solana/web3.js/node_modules/@noble/curves → @noble/curves/esm}/abstract/tower.d.ts +2 -2
  128. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/abstract/tower.d.ts.map +1 -1
  129. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/abstract/tower.js +9 -10
  130. package/node_modules/@noble/curves/esm/abstract/tower.js.map +1 -0
  131. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/abstract/utils.d.ts +5 -2
  132. package/node_modules/@noble/curves/esm/abstract/utils.d.ts.map +1 -0
  133. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/abstract/utils.js +26 -13
  134. package/node_modules/@noble/curves/esm/abstract/utils.js.map +1 -0
  135. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/abstract/weierstrass.d.ts +45 -10
  136. package/node_modules/@noble/curves/esm/abstract/weierstrass.d.ts.map +1 -0
  137. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/abstract/weierstrass.js +127 -91
  138. package/node_modules/@noble/curves/esm/abstract/weierstrass.js.map +1 -0
  139. package/node_modules/{@solana/web3.js/node_modules/@noble/curves → @noble/curves/esm}/bls12-381.d.ts +1 -1
  140. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/bls12-381.d.ts.map +1 -1
  141. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/bls12-381.js +18 -32
  142. package/node_modules/@noble/curves/esm/bls12-381.js.map +1 -0
  143. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/bn254.d.ts +3 -2
  144. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/bn254.d.ts.map +1 -1
  145. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/bn254.js +17 -7
  146. package/node_modules/@noble/curves/esm/bn254.js.map +1 -0
  147. package/node_modules/{@solana/web3.js/node_modules/@noble/curves → @noble/curves/esm}/ed25519.d.ts +26 -10
  148. package/node_modules/@noble/curves/esm/ed25519.d.ts.map +1 -0
  149. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/ed25519.js +48 -38
  150. package/node_modules/@noble/curves/esm/ed25519.js.map +1 -0
  151. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/ed448.d.ts +26 -10
  152. package/node_modules/@noble/curves/esm/ed448.d.ts.map +1 -0
  153. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/ed448.js +59 -49
  154. package/node_modules/@noble/curves/esm/ed448.js.map +1 -0
  155. package/node_modules/@noble/curves/esm/jubjub.d.ts +12 -0
  156. package/node_modules/@noble/curves/esm/jubjub.d.ts.map +1 -0
  157. package/node_modules/@noble/curves/esm/jubjub.js +12 -0
  158. package/node_modules/@noble/curves/esm/jubjub.js.map +1 -0
  159. package/node_modules/@noble/curves/esm/misc.d.ts +21 -0
  160. package/node_modules/@noble/curves/esm/misc.d.ts.map +1 -0
  161. package/node_modules/@noble/curves/esm/misc.js +107 -0
  162. package/node_modules/@noble/curves/esm/misc.js.map +1 -0
  163. package/node_modules/@noble/curves/esm/nist.d.ts +30 -0
  164. package/node_modules/@noble/curves/esm/nist.d.ts.map +1 -0
  165. package/node_modules/@noble/curves/esm/nist.js +121 -0
  166. package/node_modules/@noble/curves/esm/nist.js.map +1 -0
  167. package/node_modules/@noble/curves/esm/p256.d.ts +12 -0
  168. package/node_modules/@noble/curves/esm/p256.d.ts.map +1 -0
  169. package/node_modules/@noble/curves/esm/p256.js +12 -0
  170. package/node_modules/@noble/curves/esm/p256.js.map +1 -0
  171. package/node_modules/@noble/curves/esm/p384.d.ts +13 -0
  172. package/node_modules/@noble/curves/esm/p384.d.ts.map +1 -0
  173. package/node_modules/@noble/curves/esm/p384.js +13 -0
  174. package/node_modules/@noble/curves/esm/p384.js.map +1 -0
  175. package/node_modules/@noble/curves/esm/p521.d.ts +12 -0
  176. package/node_modules/@noble/curves/esm/p521.d.ts.map +1 -0
  177. package/node_modules/@noble/curves/esm/p521.js +12 -0
  178. package/node_modules/@noble/curves/esm/p521.js.map +1 -0
  179. package/node_modules/@noble/curves/esm/pasta.d.ts +10 -0
  180. package/node_modules/@noble/curves/esm/pasta.d.ts.map +1 -0
  181. package/node_modules/@noble/curves/esm/pasta.js +10 -0
  182. package/node_modules/@noble/curves/esm/pasta.js.map +1 -0
  183. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/secp256k1.d.ts +15 -10
  184. package/node_modules/@noble/curves/esm/secp256k1.d.ts.map +1 -0
  185. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/secp256k1.js +23 -20
  186. package/node_modules/@noble/curves/esm/secp256k1.js.map +1 -0
  187. package/node_modules/@noble/curves/jubjub.d.ts +12 -0
  188. package/node_modules/@noble/curves/jubjub.d.ts.map +1 -0
  189. package/node_modules/@noble/curves/jubjub.js +15 -0
  190. package/node_modules/@noble/curves/jubjub.js.map +1 -0
  191. package/node_modules/@noble/curves/misc.d.ts +21 -0
  192. package/node_modules/@noble/curves/misc.d.ts.map +1 -0
  193. package/node_modules/@noble/curves/misc.js +112 -0
  194. package/node_modules/@noble/curves/misc.js.map +1 -0
  195. package/node_modules/@noble/curves/nist.d.ts +30 -0
  196. package/node_modules/@noble/curves/nist.d.ts.map +1 -0
  197. package/node_modules/@noble/curves/nist.js +124 -0
  198. package/node_modules/@noble/curves/nist.js.map +1 -0
  199. package/node_modules/@noble/curves/p256.d.ts +12 -0
  200. package/node_modules/@noble/curves/p256.d.ts.map +1 -0
  201. package/node_modules/@noble/curves/p256.js +9 -0
  202. package/node_modules/@noble/curves/p256.js.map +1 -0
  203. package/node_modules/@noble/curves/p384.d.ts +13 -0
  204. package/node_modules/@noble/curves/p384.d.ts.map +1 -0
  205. package/node_modules/@noble/curves/p384.js +10 -0
  206. package/node_modules/@noble/curves/p384.js.map +1 -0
  207. package/node_modules/@noble/curves/p521.d.ts +12 -0
  208. package/node_modules/@noble/curves/p521.d.ts.map +1 -0
  209. package/node_modules/@noble/curves/p521.js +9 -0
  210. package/node_modules/@noble/curves/p521.js.map +1 -0
  211. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/package.json +126 -13
  212. package/node_modules/@noble/curves/pasta.d.ts +10 -0
  213. package/node_modules/@noble/curves/pasta.d.ts.map +1 -0
  214. package/node_modules/@noble/curves/pasta.js +13 -0
  215. package/node_modules/@noble/curves/pasta.js.map +1 -0
  216. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/secp256k1.d.ts +15 -10
  217. package/node_modules/@noble/curves/secp256k1.d.ts.map +1 -0
  218. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/secp256k1.js +62 -59
  219. package/node_modules/@noble/curves/secp256k1.js.map +1 -0
  220. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/_shortw_utils.ts +2 -2
  221. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/abstract/bls.ts +10 -10
  222. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/abstract/curve.ts +99 -85
  223. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/abstract/edwards.ts +71 -64
  224. package/node_modules/@noble/curves/src/abstract/fft.ts +508 -0
  225. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/abstract/hash-to-curve.ts +49 -39
  226. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/abstract/modular.ts +155 -154
  227. package/node_modules/@noble/curves/src/abstract/montgomery.ts +165 -0
  228. package/node_modules/@noble/curves/src/abstract/poseidon.ts +331 -0
  229. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/abstract/tower.ts +10 -11
  230. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/abstract/utils.ts +28 -15
  231. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/abstract/weierstrass.ts +182 -120
  232. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/bls12-381.ts +21 -37
  233. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/bn254.ts +18 -8
  234. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/ed25519.ts +55 -40
  235. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/ed448.ts +105 -88
  236. package/node_modules/@noble/curves/src/jubjub.ts +12 -0
  237. package/node_modules/@noble/curves/src/misc.ts +123 -0
  238. package/node_modules/@noble/curves/src/nist.ts +155 -0
  239. package/node_modules/@noble/curves/src/p256.ts +11 -0
  240. package/node_modules/@noble/curves/src/p384.ts +13 -0
  241. package/node_modules/@noble/curves/src/p521.ts +11 -0
  242. package/node_modules/@noble/curves/src/pasta.ts +9 -0
  243. package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/secp256k1.ts +27 -22
  244. package/node_modules/@noble/hashes/README.md +217 -268
  245. package/node_modules/@noble/hashes/_assert.d.ts +12 -18
  246. package/node_modules/@noble/hashes/_assert.d.ts.map +1 -1
  247. package/node_modules/@noble/hashes/_assert.js +12 -44
  248. package/node_modules/@noble/hashes/_assert.js.map +1 -1
  249. package/node_modules/@noble/hashes/_blake.d.ts +8 -28
  250. package/node_modules/@noble/hashes/_blake.d.ts.map +1 -1
  251. package/node_modules/@noble/hashes/_blake.js +19 -106
  252. package/node_modules/@noble/hashes/_blake.js.map +1 -1
  253. package/node_modules/@noble/hashes/_md.d.ts +22 -5
  254. package/node_modules/@noble/hashes/_md.d.ts.map +1 -1
  255. package/node_modules/@noble/hashes/_md.js +43 -18
  256. package/node_modules/@noble/hashes/_md.js.map +1 -1
  257. package/node_modules/@noble/hashes/_u64.d.ts +1 -1
  258. package/node_modules/@noble/hashes/_u64.d.ts.map +1 -1
  259. package/node_modules/@noble/hashes/_u64.js +6 -5
  260. package/node_modules/@noble/hashes/_u64.js.map +1 -1
  261. package/node_modules/@noble/hashes/argon2.d.ts +9 -9
  262. package/node_modules/@noble/hashes/argon2.d.ts.map +1 -1
  263. package/node_modules/@noble/hashes/argon2.js +62 -57
  264. package/node_modules/@noble/hashes/argon2.js.map +1 -1
  265. package/node_modules/@noble/hashes/blake1.d.ts +19 -39
  266. package/node_modules/@noble/hashes/blake1.d.ts.map +1 -1
  267. package/node_modules/@noble/hashes/blake1.js +107 -119
  268. package/node_modules/@noble/hashes/blake1.js.map +1 -1
  269. package/node_modules/@noble/hashes/blake2.d.ts +116 -0
  270. package/node_modules/@noble/hashes/blake2.d.ts.map +1 -0
  271. package/node_modules/@noble/hashes/blake2.js +420 -0
  272. package/node_modules/@noble/hashes/blake2.js.map +1 -0
  273. package/node_modules/@noble/hashes/blake2b.d.ts +6 -48
  274. package/node_modules/@noble/hashes/blake2b.d.ts.map +1 -1
  275. package/node_modules/@noble/hashes/blake2b.js +6 -189
  276. package/node_modules/@noble/hashes/blake2b.js.map +1 -1
  277. package/node_modules/@noble/hashes/blake2s.d.ts +14 -55
  278. package/node_modules/@noble/hashes/blake2s.d.ts.map +1 -1
  279. package/node_modules/@noble/hashes/blake2s.js +17 -125
  280. package/node_modules/@noble/hashes/blake2s.js.map +1 -1
  281. package/node_modules/@noble/hashes/blake3.d.ts +6 -6
  282. package/node_modules/@noble/hashes/blake3.d.ts.map +1 -1
  283. package/node_modules/@noble/hashes/blake3.js +62 -62
  284. package/node_modules/@noble/hashes/blake3.js.map +1 -1
  285. package/node_modules/@noble/hashes/eskdf.d.ts.map +1 -1
  286. package/node_modules/@noble/hashes/eskdf.js +18 -20
  287. package/node_modules/@noble/hashes/eskdf.js.map +1 -1
  288. package/node_modules/@noble/hashes/esm/_assert.d.ts +12 -18
  289. package/node_modules/@noble/hashes/esm/_assert.d.ts.map +1 -1
  290. package/node_modules/@noble/hashes/esm/_assert.js +10 -39
  291. package/node_modules/@noble/hashes/esm/_assert.js.map +1 -1
  292. package/node_modules/@noble/hashes/esm/_blake.d.ts +8 -28
  293. package/node_modules/@noble/hashes/esm/_blake.d.ts.map +1 -1
  294. package/node_modules/@noble/hashes/esm/_blake.js +16 -104
  295. package/node_modules/@noble/hashes/esm/_blake.js.map +1 -1
  296. package/node_modules/@noble/hashes/esm/_md.d.ts +22 -5
  297. package/node_modules/@noble/hashes/esm/_md.d.ts.map +1 -1
  298. package/node_modules/@noble/hashes/esm/_md.js +35 -10
  299. package/node_modules/@noble/hashes/esm/_md.js.map +1 -1
  300. package/node_modules/@noble/hashes/esm/_u64.d.ts +1 -1
  301. package/node_modules/@noble/hashes/esm/_u64.d.ts.map +1 -1
  302. package/node_modules/@noble/hashes/esm/_u64.js +5 -4
  303. package/node_modules/@noble/hashes/esm/_u64.js.map +1 -1
  304. package/node_modules/@noble/hashes/esm/argon2.d.ts +9 -9
  305. package/node_modules/@noble/hashes/esm/argon2.d.ts.map +1 -1
  306. package/node_modules/@noble/hashes/esm/argon2.js +44 -39
  307. package/node_modules/@noble/hashes/esm/argon2.js.map +1 -1
  308. package/node_modules/@noble/hashes/esm/blake1.d.ts +19 -39
  309. package/node_modules/@noble/hashes/esm/blake1.d.ts.map +1 -1
  310. package/node_modules/@noble/hashes/esm/blake1.js +84 -96
  311. package/node_modules/@noble/hashes/esm/blake1.js.map +1 -1
  312. package/node_modules/@noble/hashes/esm/blake2.d.ts +116 -0
  313. package/node_modules/@noble/hashes/esm/blake2.d.ts.map +1 -0
  314. package/node_modules/@noble/hashes/esm/blake2.js +413 -0
  315. package/node_modules/@noble/hashes/esm/blake2.js.map +1 -0
  316. package/node_modules/@noble/hashes/esm/blake2b.d.ts +6 -48
  317. package/node_modules/@noble/hashes/esm/blake2b.d.ts.map +1 -1
  318. package/node_modules/@noble/hashes/esm/blake2b.js +6 -188
  319. package/node_modules/@noble/hashes/esm/blake2b.js.map +1 -1
  320. package/node_modules/@noble/hashes/esm/blake2s.d.ts +14 -55
  321. package/node_modules/@noble/hashes/esm/blake2s.d.ts.map +1 -1
  322. package/node_modules/@noble/hashes/esm/blake2s.js +16 -120
  323. package/node_modules/@noble/hashes/esm/blake2s.js.map +1 -1
  324. package/node_modules/@noble/hashes/esm/blake3.d.ts +6 -6
  325. package/node_modules/@noble/hashes/esm/blake3.d.ts.map +1 -1
  326. package/node_modules/@noble/hashes/esm/blake3.js +46 -57
  327. package/node_modules/@noble/hashes/esm/blake3.js.map +1 -1
  328. package/node_modules/@noble/hashes/esm/eskdf.d.ts.map +1 -1
  329. package/node_modules/@noble/hashes/esm/eskdf.js +9 -11
  330. package/node_modules/@noble/hashes/esm/eskdf.js.map +1 -1
  331. package/node_modules/@noble/hashes/esm/hkdf.d.ts +1 -1
  332. package/node_modules/@noble/hashes/esm/hkdf.d.ts.map +1 -1
  333. package/node_modules/@noble/hashes/esm/hkdf.js +10 -11
  334. package/node_modules/@noble/hashes/esm/hkdf.js.map +1 -1
  335. package/node_modules/@noble/hashes/esm/hmac.d.ts +6 -1
  336. package/node_modules/@noble/hashes/esm/hmac.d.ts.map +1 -1
  337. package/node_modules/@noble/hashes/esm/hmac.js +5 -3
  338. package/node_modules/@noble/hashes/esm/hmac.js.map +1 -1
  339. package/node_modules/@noble/hashes/esm/index.js +3 -5
  340. package/node_modules/@noble/hashes/esm/index.js.map +1 -1
  341. package/node_modules/@noble/hashes/esm/legacy.d.ts +71 -0
  342. package/node_modules/@noble/hashes/esm/legacy.d.ts.map +1 -0
  343. package/node_modules/@noble/hashes/esm/legacy.js +281 -0
  344. package/node_modules/@noble/hashes/esm/legacy.js.map +1 -0
  345. package/node_modules/@noble/hashes/esm/pbkdf2.d.ts +4 -4
  346. package/node_modules/@noble/hashes/esm/pbkdf2.d.ts.map +1 -1
  347. package/node_modules/@noble/hashes/esm/pbkdf2.js +8 -8
  348. package/node_modules/@noble/hashes/esm/pbkdf2.js.map +1 -1
  349. package/node_modules/@noble/hashes/esm/ripemd160.d.ts +6 -17
  350. package/node_modules/@noble/hashes/esm/ripemd160.d.ts.map +1 -1
  351. package/node_modules/@noble/hashes/esm/ripemd160.js +6 -96
  352. package/node_modules/@noble/hashes/esm/ripemd160.js.map +1 -1
  353. package/node_modules/@noble/hashes/esm/scrypt.d.ts +3 -3
  354. package/node_modules/@noble/hashes/esm/scrypt.d.ts.map +1 -1
  355. package/node_modules/@noble/hashes/esm/scrypt.js +14 -19
  356. package/node_modules/@noble/hashes/esm/scrypt.js.map +1 -1
  357. package/node_modules/@noble/hashes/esm/sha1.d.ts +6 -17
  358. package/node_modules/@noble/hashes/esm/sha1.d.ts.map +1 -1
  359. package/node_modules/@noble/hashes/esm/sha1.js +6 -79
  360. package/node_modules/@noble/hashes/esm/sha1.js.map +1 -1
  361. package/node_modules/@noble/hashes/esm/sha2.d.ts +155 -3
  362. package/node_modules/@noble/hashes/esm/sha2.d.ts.map +1 -1
  363. package/node_modules/@noble/hashes/esm/sha2.js +371 -4
  364. package/node_modules/@noble/hashes/esm/sha2.js.map +1 -1
  365. package/node_modules/@noble/hashes/esm/sha256.d.ts +10 -22
  366. package/node_modules/@noble/hashes/esm/sha256.d.ts.map +1 -1
  367. package/node_modules/@noble/hashes/esm/sha256.js +10 -120
  368. package/node_modules/@noble/hashes/esm/sha256.js.map +1 -1
  369. package/node_modules/@noble/hashes/esm/sha3-addons.d.ts +16 -4
  370. package/node_modules/@noble/hashes/esm/sha3-addons.d.ts.map +1 -1
  371. package/node_modules/@noble/hashes/esm/sha3-addons.js +27 -21
  372. package/node_modules/@noble/hashes/esm/sha3-addons.js.map +1 -1
  373. package/node_modules/@noble/hashes/esm/sha3.d.ts +7 -6
  374. package/node_modules/@noble/hashes/esm/sha3.d.ts.map +1 -1
  375. package/node_modules/@noble/hashes/esm/sha3.js +42 -35
  376. package/node_modules/@noble/hashes/esm/sha3.js.map +1 -1
  377. package/node_modules/@noble/hashes/esm/sha512.d.ts +18 -108
  378. package/node_modules/@noble/hashes/esm/sha512.d.ts.map +1 -1
  379. package/node_modules/@noble/hashes/esm/sha512.js +18 -234
  380. package/node_modules/@noble/hashes/esm/sha512.js.map +1 -1
  381. package/node_modules/@noble/hashes/esm/utils.d.ts +60 -19
  382. package/node_modules/@noble/hashes/esm/utils.d.ts.map +1 -1
  383. package/node_modules/@noble/hashes/esm/utils.js +94 -25
  384. package/node_modules/@noble/hashes/esm/utils.js.map +1 -1
  385. package/node_modules/@noble/hashes/hkdf.d.ts +1 -1
  386. package/node_modules/@noble/hashes/hkdf.d.ts.map +1 -1
  387. package/node_modules/@noble/hashes/hkdf.js +15 -16
  388. package/node_modules/@noble/hashes/hkdf.js.map +1 -1
  389. package/node_modules/@noble/hashes/hmac.d.ts +6 -1
  390. package/node_modules/@noble/hashes/hmac.d.ts.map +1 -1
  391. package/node_modules/@noble/hashes/hmac.js +11 -9
  392. package/node_modules/@noble/hashes/hmac.js.map +1 -1
  393. package/node_modules/@noble/hashes/index.js +3 -5
  394. package/node_modules/@noble/hashes/index.js.map +1 -1
  395. package/node_modules/@noble/hashes/legacy.d.ts +71 -0
  396. package/node_modules/@noble/hashes/legacy.d.ts.map +1 -0
  397. package/node_modules/@noble/hashes/legacy.js +287 -0
  398. package/node_modules/@noble/hashes/legacy.js.map +1 -0
  399. package/node_modules/@noble/hashes/package.json +104 -6
  400. package/node_modules/@noble/hashes/pbkdf2.d.ts +4 -4
  401. package/node_modules/@noble/hashes/pbkdf2.d.ts.map +1 -1
  402. package/node_modules/@noble/hashes/pbkdf2.js +17 -17
  403. package/node_modules/@noble/hashes/pbkdf2.js.map +1 -1
  404. package/node_modules/@noble/hashes/ripemd160.d.ts +6 -17
  405. package/node_modules/@noble/hashes/ripemd160.d.ts.map +1 -1
  406. package/node_modules/@noble/hashes/ripemd160.js +6 -97
  407. package/node_modules/@noble/hashes/ripemd160.js.map +1 -1
  408. package/node_modules/@noble/hashes/scrypt.d.ts +3 -3
  409. package/node_modules/@noble/hashes/scrypt.d.ts.map +1 -1
  410. package/node_modules/@noble/hashes/scrypt.js +60 -65
  411. package/node_modules/@noble/hashes/scrypt.js.map +1 -1
  412. package/node_modules/@noble/hashes/sha1.d.ts +6 -17
  413. package/node_modules/@noble/hashes/sha1.d.ts.map +1 -1
  414. package/node_modules/@noble/hashes/sha1.js +6 -80
  415. package/node_modules/@noble/hashes/sha1.js.map +1 -1
  416. package/node_modules/@noble/hashes/sha2.d.ts +155 -3
  417. package/node_modules/@noble/hashes/sha2.d.ts.map +1 -1
  418. package/node_modules/@noble/hashes/sha2.js +378 -11
  419. package/node_modules/@noble/hashes/sha2.js.map +1 -1
  420. package/node_modules/@noble/hashes/sha256.d.ts +10 -22
  421. package/node_modules/@noble/hashes/sha256.d.ts.map +1 -1
  422. package/node_modules/@noble/hashes/sha256.js +11 -122
  423. package/node_modules/@noble/hashes/sha256.js.map +1 -1
  424. package/node_modules/@noble/hashes/sha3-addons.d.ts +16 -4
  425. package/node_modules/@noble/hashes/sha3-addons.d.ts.map +1 -1
  426. package/node_modules/@noble/hashes/sha3-addons.js +41 -35
  427. package/node_modules/@noble/hashes/sha3-addons.js.map +1 -1
  428. package/node_modules/@noble/hashes/sha3.d.ts +7 -6
  429. package/node_modules/@noble/hashes/sha3.d.ts.map +1 -1
  430. package/node_modules/@noble/hashes/sha3.js +52 -45
  431. package/node_modules/@noble/hashes/sha3.js.map +1 -1
  432. package/node_modules/@noble/hashes/sha512.d.ts +18 -108
  433. package/node_modules/@noble/hashes/sha512.d.ts.map +1 -1
  434. package/node_modules/@noble/hashes/sha512.js +19 -239
  435. package/node_modules/@noble/hashes/sha512.js.map +1 -1
  436. package/node_modules/@noble/hashes/src/_assert.ts +18 -50
  437. package/node_modules/@noble/hashes/src/_blake.ts +18 -115
  438. package/node_modules/@noble/hashes/src/_md.ts +47 -12
  439. package/node_modules/@noble/hashes/src/_u64.ts +5 -9
  440. package/node_modules/@noble/hashes/src/argon2.ts +60 -49
  441. package/node_modules/@noble/hashes/src/blake1.ts +112 -126
  442. package/node_modules/@noble/hashes/src/blake2.ts +486 -0
  443. package/node_modules/@noble/hashes/src/blake2b.ts +6 -205
  444. package/node_modules/@noble/hashes/src/blake2s.ts +16 -150
  445. package/node_modules/@noble/hashes/src/blake3.ts +53 -62
  446. package/node_modules/@noble/hashes/src/eskdf.ts +9 -11
  447. package/node_modules/@noble/hashes/src/hkdf.ts +10 -11
  448. package/node_modules/@noble/hashes/src/hmac.ts +5 -3
  449. package/node_modules/@noble/hashes/src/index.ts +3 -5
  450. package/node_modules/@noble/hashes/src/legacy.ts +293 -0
  451. package/node_modules/@noble/hashes/src/pbkdf2.ts +20 -18
  452. package/node_modules/@noble/hashes/src/ripemd160.ts +6 -103
  453. package/node_modules/@noble/hashes/src/scrypt.ts +25 -20
  454. package/node_modules/@noble/hashes/src/sha1.ts +6 -79
  455. package/node_modules/@noble/hashes/src/sha2.ts +399 -4
  456. package/node_modules/@noble/hashes/src/sha256.ts +15 -127
  457. package/node_modules/@noble/hashes/src/sha3-addons.ts +34 -23
  458. package/node_modules/@noble/hashes/src/sha3.ts +59 -45
  459. package/node_modules/@noble/hashes/src/sha512.ts +27 -250
  460. package/node_modules/@noble/hashes/src/utils.ts +132 -42
  461. package/node_modules/@noble/hashes/utils.d.ts +60 -19
  462. package/node_modules/@noble/hashes/utils.d.ts.map +1 -1
  463. package/node_modules/@noble/hashes/utils.js +110 -33
  464. package/node_modules/@noble/hashes/utils.js.map +1 -1
  465. package/node_modules/{file-uri-to-path → @solana/codecs-core}/LICENSE +8 -8
  466. package/node_modules/@solana/codecs-core/README.md +662 -0
  467. package/node_modules/@solana/codecs-core/dist/index.browser.cjs +504 -0
  468. package/node_modules/@solana/codecs-core/dist/index.browser.cjs.map +1 -0
  469. package/node_modules/@solana/codecs-core/dist/index.browser.mjs +460 -0
  470. package/node_modules/@solana/codecs-core/dist/index.browser.mjs.map +1 -0
  471. package/node_modules/@solana/codecs-core/dist/index.native.mjs +460 -0
  472. package/node_modules/@solana/codecs-core/dist/index.native.mjs.map +1 -0
  473. package/node_modules/@solana/codecs-core/dist/index.node.cjs +504 -0
  474. package/node_modules/@solana/codecs-core/dist/index.node.cjs.map +1 -0
  475. package/node_modules/@solana/codecs-core/dist/index.node.mjs +460 -0
  476. package/node_modules/@solana/codecs-core/dist/index.node.mjs.map +1 -0
  477. package/node_modules/@solana/codecs-core/dist/types/add-codec-sentinel.d.ts +70 -0
  478. package/node_modules/@solana/codecs-core/dist/types/add-codec-sentinel.d.ts.map +1 -0
  479. package/node_modules/@solana/codecs-core/dist/types/add-codec-size-prefix.d.ts +67 -0
  480. package/node_modules/@solana/codecs-core/dist/types/add-codec-size-prefix.d.ts.map +1 -0
  481. package/node_modules/@solana/codecs-core/dist/types/assertions.d.ts +62 -0
  482. package/node_modules/@solana/codecs-core/dist/types/assertions.d.ts.map +1 -0
  483. package/node_modules/@solana/codecs-core/dist/types/bytes.d.ts +92 -0
  484. package/node_modules/@solana/codecs-core/dist/types/bytes.d.ts.map +1 -0
  485. package/node_modules/@solana/codecs-core/dist/types/codec.d.ts +827 -0
  486. package/node_modules/@solana/codecs-core/dist/types/codec.d.ts.map +1 -0
  487. package/node_modules/@solana/codecs-core/dist/types/combine-codec.d.ts +75 -0
  488. package/node_modules/@solana/codecs-core/dist/types/combine-codec.d.ts.map +1 -0
  489. package/node_modules/@solana/codecs-core/dist/types/fix-codec-size.d.ts +111 -0
  490. package/node_modules/@solana/codecs-core/dist/types/fix-codec-size.d.ts.map +1 -0
  491. package/node_modules/@solana/codecs-core/dist/types/index.d.ts +667 -0
  492. package/node_modules/@solana/codecs-core/dist/types/index.d.ts.map +1 -0
  493. package/node_modules/@solana/codecs-core/dist/types/offset-codec.d.ts +328 -0
  494. package/node_modules/@solana/codecs-core/dist/types/offset-codec.d.ts.map +1 -0
  495. package/node_modules/@solana/codecs-core/dist/types/pad-codec.d.ts +162 -0
  496. package/node_modules/@solana/codecs-core/dist/types/pad-codec.d.ts.map +1 -0
  497. package/node_modules/@solana/codecs-core/dist/types/readonly-uint8array.d.ts +19 -0
  498. package/node_modules/@solana/codecs-core/dist/types/readonly-uint8array.d.ts.map +1 -0
  499. package/node_modules/@solana/codecs-core/dist/types/resize-codec.d.ts +129 -0
  500. package/node_modules/@solana/codecs-core/dist/types/resize-codec.d.ts.map +1 -0
  501. package/node_modules/@solana/codecs-core/dist/types/reverse-codec.d.ts +92 -0
  502. package/node_modules/@solana/codecs-core/dist/types/reverse-codec.d.ts.map +1 -0
  503. package/node_modules/@solana/codecs-core/dist/types/transform-codec.d.ts +114 -0
  504. package/node_modules/@solana/codecs-core/dist/types/transform-codec.d.ts.map +1 -0
  505. package/node_modules/@solana/codecs-core/package.json +83 -0
  506. package/node_modules/@solana/codecs-numbers/LICENSE +20 -0
  507. package/node_modules/@solana/codecs-numbers/README.md +130 -0
  508. package/node_modules/@solana/codecs-numbers/dist/index.browser.cjs +331 -0
  509. package/node_modules/@solana/codecs-numbers/dist/index.browser.cjs.map +1 -0
  510. package/node_modules/@solana/codecs-numbers/dist/index.browser.mjs +289 -0
  511. package/node_modules/@solana/codecs-numbers/dist/index.browser.mjs.map +1 -0
  512. package/node_modules/@solana/codecs-numbers/dist/index.native.mjs +289 -0
  513. package/node_modules/@solana/codecs-numbers/dist/index.native.mjs.map +1 -0
  514. package/node_modules/@solana/codecs-numbers/dist/index.node.cjs +331 -0
  515. package/node_modules/@solana/codecs-numbers/dist/index.node.cjs.map +1 -0
  516. package/node_modules/@solana/codecs-numbers/dist/index.node.mjs +289 -0
  517. package/node_modules/@solana/codecs-numbers/dist/index.node.mjs.map +1 -0
  518. package/node_modules/@solana/codecs-numbers/dist/types/assertions.d.ts +27 -0
  519. package/node_modules/@solana/codecs-numbers/dist/types/assertions.d.ts.map +1 -0
  520. package/node_modules/@solana/codecs-numbers/dist/types/common.d.ts +84 -0
  521. package/node_modules/@solana/codecs-numbers/dist/types/common.d.ts.map +1 -0
  522. package/node_modules/@solana/codecs-numbers/dist/types/f32.d.ts +87 -0
  523. package/node_modules/@solana/codecs-numbers/dist/types/f32.d.ts.map +1 -0
  524. package/node_modules/@solana/codecs-numbers/dist/types/f64.d.ts +87 -0
  525. package/node_modules/@solana/codecs-numbers/dist/types/f64.d.ts.map +1 -0
  526. package/node_modules/@solana/codecs-numbers/dist/types/i128.d.ts +91 -0
  527. package/node_modules/@solana/codecs-numbers/dist/types/i128.d.ts.map +1 -0
  528. package/node_modules/@solana/codecs-numbers/dist/types/i16.d.ts +87 -0
  529. package/node_modules/@solana/codecs-numbers/dist/types/i16.d.ts.map +1 -0
  530. package/node_modules/@solana/codecs-numbers/dist/types/i32.d.ts +87 -0
  531. package/node_modules/@solana/codecs-numbers/dist/types/i32.d.ts.map +1 -0
  532. package/node_modules/@solana/codecs-numbers/dist/types/i64.d.ts +90 -0
  533. package/node_modules/@solana/codecs-numbers/dist/types/i64.d.ts.map +1 -0
  534. package/node_modules/@solana/codecs-numbers/dist/types/i8.d.ts +75 -0
  535. package/node_modules/@solana/codecs-numbers/dist/types/i8.d.ts.map +1 -0
  536. package/node_modules/@solana/codecs-numbers/dist/types/index.d.ts +26 -0
  537. package/node_modules/@solana/codecs-numbers/dist/types/index.d.ts.map +1 -0
  538. package/node_modules/@solana/codecs-numbers/dist/types/short-u16.d.ts +96 -0
  539. package/node_modules/@solana/codecs-numbers/dist/types/short-u16.d.ts.map +1 -0
  540. package/node_modules/@solana/codecs-numbers/dist/types/u128.d.ts +87 -0
  541. package/node_modules/@solana/codecs-numbers/dist/types/u128.d.ts.map +1 -0
  542. package/node_modules/@solana/codecs-numbers/dist/types/u16.d.ts +85 -0
  543. package/node_modules/@solana/codecs-numbers/dist/types/u16.d.ts.map +1 -0
  544. package/node_modules/@solana/codecs-numbers/dist/types/u32.d.ts +85 -0
  545. package/node_modules/@solana/codecs-numbers/dist/types/u32.d.ts.map +1 -0
  546. package/node_modules/@solana/codecs-numbers/dist/types/u64.d.ts +88 -0
  547. package/node_modules/@solana/codecs-numbers/dist/types/u64.d.ts.map +1 -0
  548. package/node_modules/@solana/codecs-numbers/dist/types/u8.d.ts +71 -0
  549. package/node_modules/@solana/codecs-numbers/dist/types/u8.d.ts.map +1 -0
  550. package/node_modules/@solana/codecs-numbers/dist/types/utils.d.ts +18 -0
  551. package/node_modules/@solana/codecs-numbers/dist/types/utils.d.ts.map +1 -0
  552. package/node_modules/@solana/codecs-numbers/package.json +83 -0
  553. package/node_modules/@solana/errors/LICENSE +20 -0
  554. package/node_modules/@solana/errors/README.md +87 -0
  555. package/node_modules/@solana/errors/bin/cli.mjs +7 -0
  556. package/node_modules/@solana/errors/dist/cli.mjs +570 -0
  557. package/node_modules/@solana/errors/dist/index.browser.cjs +1084 -0
  558. package/node_modules/@solana/errors/dist/index.browser.cjs.map +1 -0
  559. package/node_modules/@solana/errors/dist/index.browser.mjs +852 -0
  560. package/node_modules/@solana/errors/dist/index.browser.mjs.map +1 -0
  561. package/node_modules/@solana/errors/dist/index.native.mjs +852 -0
  562. package/node_modules/@solana/errors/dist/index.native.mjs.map +1 -0
  563. package/node_modules/@solana/errors/dist/index.node.cjs +1084 -0
  564. package/node_modules/@solana/errors/dist/index.node.cjs.map +1 -0
  565. package/node_modules/@solana/errors/dist/index.node.mjs +852 -0
  566. package/node_modules/@solana/errors/dist/index.node.mjs.map +1 -0
  567. package/node_modules/@solana/errors/dist/types/codes.d.ts +275 -0
  568. package/node_modules/@solana/errors/dist/types/codes.d.ts.map +1 -0
  569. package/node_modules/@solana/errors/dist/types/context.d.ts +398 -0
  570. package/node_modules/@solana/errors/dist/types/context.d.ts.map +1 -0
  571. package/node_modules/@solana/errors/dist/types/error.d.ts +75 -0
  572. package/node_modules/@solana/errors/dist/types/error.d.ts.map +1 -0
  573. package/node_modules/@solana/errors/dist/types/index.d.ts +72 -0
  574. package/node_modules/@solana/errors/dist/types/index.d.ts.map +1 -0
  575. package/node_modules/@solana/errors/dist/types/instruction-error.d.ts +9 -0
  576. package/node_modules/@solana/errors/dist/types/instruction-error.d.ts.map +1 -0
  577. package/node_modules/@solana/errors/dist/types/json-rpc-error.d.ts +51 -0
  578. package/node_modules/@solana/errors/dist/types/json-rpc-error.d.ts.map +1 -0
  579. package/node_modules/@solana/errors/dist/types/message-formatter.d.ts +4 -0
  580. package/node_modules/@solana/errors/dist/types/message-formatter.d.ts.map +1 -0
  581. package/node_modules/@solana/errors/dist/types/messages.d.ts +16 -0
  582. package/node_modules/@solana/errors/dist/types/messages.d.ts.map +1 -0
  583. package/node_modules/@solana/errors/dist/types/rpc-enum-errors.d.ts +31 -0
  584. package/node_modules/@solana/errors/dist/types/rpc-enum-errors.d.ts.map +1 -0
  585. package/node_modules/@solana/errors/dist/types/stack-trace.d.ts +2 -0
  586. package/node_modules/@solana/errors/dist/types/stack-trace.d.ts.map +1 -0
  587. package/node_modules/@solana/errors/dist/types/transaction-error.d.ts +5 -0
  588. package/node_modules/@solana/errors/dist/types/transaction-error.d.ts.map +1 -0
  589. package/node_modules/@solana/errors/node_modules/chalk/package.json +83 -0
  590. package/node_modules/@solana/errors/node_modules/chalk/readme.md +297 -0
  591. package/node_modules/@solana/errors/node_modules/chalk/source/index.d.ts +325 -0
  592. package/node_modules/@solana/errors/node_modules/chalk/source/index.js +225 -0
  593. package/node_modules/@solana/errors/node_modules/chalk/source/utilities.js +33 -0
  594. package/node_modules/@solana/errors/node_modules/chalk/source/vendor/ansi-styles/index.d.ts +236 -0
  595. package/node_modules/@solana/errors/node_modules/chalk/source/vendor/ansi-styles/index.js +223 -0
  596. package/node_modules/@solana/errors/node_modules/chalk/source/vendor/supports-color/browser.d.ts +1 -0
  597. package/node_modules/@solana/errors/node_modules/chalk/source/vendor/supports-color/browser.js +34 -0
  598. package/node_modules/@solana/errors/node_modules/chalk/source/vendor/supports-color/index.d.ts +55 -0
  599. package/node_modules/@solana/errors/node_modules/chalk/source/vendor/supports-color/index.js +182 -0
  600. package/node_modules/{bindings/LICENSE.md → @solana/errors/node_modules/commander/LICENSE} +1 -1
  601. package/node_modules/@solana/errors/node_modules/commander/Readme.md +1149 -0
  602. package/node_modules/@solana/errors/node_modules/commander/esm.mjs +16 -0
  603. package/node_modules/@solana/errors/node_modules/commander/index.js +24 -0
  604. package/node_modules/@solana/errors/node_modules/commander/lib/argument.js +149 -0
  605. package/node_modules/@solana/errors/node_modules/commander/lib/command.js +2662 -0
  606. package/node_modules/@solana/errors/node_modules/commander/lib/error.js +39 -0
  607. package/node_modules/@solana/errors/node_modules/commander/lib/help.js +709 -0
  608. package/node_modules/@solana/errors/node_modules/commander/lib/option.js +367 -0
  609. package/node_modules/@solana/errors/node_modules/commander/lib/suggestSimilar.js +101 -0
  610. package/node_modules/@solana/errors/node_modules/commander/package-support.json +16 -0
  611. package/node_modules/@solana/errors/node_modules/commander/package.json +82 -0
  612. package/node_modules/@solana/errors/node_modules/commander/typings/esm.d.mts +3 -0
  613. package/node_modules/@solana/errors/node_modules/commander/typings/index.d.ts +1045 -0
  614. package/node_modules/@solana/errors/package.json +84 -0
  615. package/node_modules/@solana/web3.js/README.md +4 -4
  616. package/node_modules/@solana/web3.js/lib/index.browser.cjs.js +10 -20
  617. package/node_modules/@solana/web3.js/lib/index.browser.cjs.js.map +1 -1
  618. package/node_modules/@solana/web3.js/lib/index.browser.esm.js +8 -18
  619. package/node_modules/@solana/web3.js/lib/index.browser.esm.js.map +1 -1
  620. package/node_modules/@solana/web3.js/lib/index.cjs.js +10 -20
  621. package/node_modules/@solana/web3.js/lib/index.cjs.js.map +1 -1
  622. package/node_modules/@solana/web3.js/lib/index.esm.js +8 -18
  623. package/node_modules/@solana/web3.js/lib/index.esm.js.map +1 -1
  624. package/node_modules/@solana/web3.js/lib/index.iife.js +213 -88
  625. package/node_modules/@solana/web3.js/lib/index.iife.js.map +1 -1
  626. package/node_modules/@solana/web3.js/lib/index.iife.min.js +2 -2
  627. package/node_modules/@solana/web3.js/lib/index.iife.min.js.map +1 -1
  628. package/node_modules/@solana/web3.js/lib/index.native.js +10 -20
  629. package/node_modules/@solana/web3.js/lib/index.native.js.map +1 -1
  630. package/node_modules/@solana/web3.js/package.json +5 -5
  631. package/node_modules/@solana/web3.js/src/programs/address-lookup-table/index.ts +5 -2
  632. package/node_modules/@solana/web3.js/src/utils/bigint.ts +14 -33
  633. package/node_modules/@swc/helpers/_/_overload_yield/package.json +4 -0
  634. package/node_modules/@swc/helpers/cjs/_async_generator.cjs +10 -12
  635. package/node_modules/@swc/helpers/cjs/_async_generator_delegate.cjs +11 -7
  636. package/node_modules/@swc/helpers/cjs/_await_async_generator.cjs +2 -2
  637. package/node_modules/@swc/helpers/cjs/_overload_yield.cjs +8 -0
  638. package/node_modules/@swc/helpers/cjs/index.cjs +4 -0
  639. package/node_modules/@swc/helpers/esm/_async_generator.js +10 -12
  640. package/node_modules/@swc/helpers/esm/_async_generator_delegate.js +11 -7
  641. package/node_modules/@swc/helpers/esm/_await_async_generator.js +2 -2
  642. package/node_modules/@swc/helpers/esm/_overload_yield.js +6 -0
  643. package/node_modules/@swc/helpers/esm/index.js +1 -0
  644. package/node_modules/@swc/helpers/package.json +219 -1
  645. package/node_modules/@swc/helpers/scripts/build.js +15 -3
  646. package/node_modules/@swc/helpers/src/_overload_yield.mjs +1 -0
  647. package/node_modules/@types/node/README.md +2 -2
  648. package/node_modules/@types/node/assert.d.ts +7 -48
  649. package/node_modules/@types/node/async_hooks.d.ts +64 -2
  650. package/node_modules/@types/node/buffer.buffer.d.ts +3 -0
  651. package/node_modules/@types/node/buffer.d.ts +2 -2
  652. package/node_modules/@types/node/cluster.d.ts +1 -1
  653. package/node_modules/@types/node/crypto.d.ts +8 -9
  654. package/node_modules/@types/node/diagnostics_channel.d.ts +20 -1
  655. package/node_modules/@types/node/fs/promises.d.ts +21 -24
  656. package/node_modules/@types/node/fs.d.ts +93 -9
  657. package/node_modules/@types/node/globals.d.ts +141 -281
  658. package/node_modules/@types/node/http.d.ts +22 -1
  659. package/node_modules/@types/node/http2.d.ts +3 -4
  660. package/node_modules/@types/node/inspector.d.ts +36 -0
  661. package/node_modules/@types/node/module.d.ts +25 -0
  662. package/node_modules/@types/node/net.d.ts +14 -8
  663. package/node_modules/@types/node/package.json +7 -2
  664. package/node_modules/@types/node/process.d.ts +22 -0
  665. package/node_modules/@types/node/querystring.d.ts +2 -3
  666. package/node_modules/@types/node/readline.d.ts +6 -1
  667. package/node_modules/@types/node/sqlite.d.ts +36 -13
  668. package/node_modules/@types/node/stream/web.d.ts +3 -3
  669. package/node_modules/@types/node/test.d.ts +54 -6
  670. package/node_modules/@types/node/tls.d.ts +34 -1
  671. package/node_modules/@types/node/ts5.6/buffer.buffer.d.ts +3 -0
  672. package/node_modules/@types/node/util.d.ts +232 -94
  673. package/node_modules/@types/node/v8.d.ts +81 -0
  674. package/node_modules/@types/node/vm.d.ts +20 -5
  675. package/node_modules/@types/node/zlib.d.ts +167 -36
  676. package/node_modules/bn.js/README.md +2 -2
  677. package/node_modules/bn.js/lib/bn.js +1 -0
  678. package/node_modules/bn.js/package.json +1 -1
  679. package/node_modules/{jsonparse/README.markdown → camelcase/license} +2 -4
  680. package/node_modules/jayson/lib/utils.js +11 -8
  681. package/node_modules/jayson/package.json +10 -7
  682. package/node_modules/rpc-websockets/node_modules/ws/lib/permessage-deflate.js +14 -0
  683. package/node_modules/rpc-websockets/node_modules/ws/lib/websocket.js +1 -1
  684. package/node_modules/rpc-websockets/node_modules/ws/package.json +2 -2
  685. package/node_modules/stream-chain/LICENSE +11 -0
  686. package/node_modules/stream-chain/README.md +334 -0
  687. package/node_modules/stream-chain/defs.js +22 -0
  688. package/node_modules/stream-chain/index.js +203 -0
  689. package/node_modules/stream-chain/package.json +31 -0
  690. package/node_modules/stream-chain/utils/FromIterable.js +94 -0
  691. package/node_modules/stream-chain/utils/Reduce.js +40 -0
  692. package/node_modules/stream-chain/utils/asFun.js +85 -0
  693. package/node_modules/stream-chain/utils/asGen.js +77 -0
  694. package/node_modules/stream-chain/utils/comp.js +20 -0
  695. package/node_modules/stream-chain/utils/fold.js +43 -0
  696. package/node_modules/stream-chain/utils/gen.js +24 -0
  697. package/node_modules/stream-chain/utils/scan.js +41 -0
  698. package/node_modules/stream-chain/utils/skip.js +32 -0
  699. package/node_modules/stream-chain/utils/skipWhile.js +46 -0
  700. package/node_modules/stream-chain/utils/take.js +39 -0
  701. package/node_modules/stream-chain/utils/takeWhile.js +47 -0
  702. package/node_modules/stream-json/Assembler.js +154 -0
  703. package/node_modules/stream-json/Disassembler.js +209 -0
  704. package/node_modules/stream-json/Emitter.js +22 -0
  705. package/node_modules/stream-json/LICENSE +34 -0
  706. package/node_modules/stream-json/Parser.js +545 -0
  707. package/node_modules/stream-json/README.md +128 -0
  708. package/node_modules/stream-json/Stringer.js +153 -0
  709. package/node_modules/stream-json/filters/Filter.js +130 -0
  710. package/node_modules/stream-json/filters/FilterBase.js +201 -0
  711. package/node_modules/stream-json/filters/Ignore.js +24 -0
  712. package/node_modules/stream-json/filters/Pick.js +58 -0
  713. package/node_modules/stream-json/filters/Replace.js +115 -0
  714. package/node_modules/stream-json/index.js +11 -0
  715. package/node_modules/stream-json/jsonl/Parser.js +131 -0
  716. package/node_modules/stream-json/jsonl/Stringer.js +29 -0
  717. package/node_modules/stream-json/package.json +45 -0
  718. package/node_modules/stream-json/streamers/StreamArray.js +44 -0
  719. package/node_modules/stream-json/streamers/StreamBase.js +101 -0
  720. package/node_modules/stream-json/streamers/StreamObject.js +43 -0
  721. package/node_modules/stream-json/streamers/StreamValues.js +33 -0
  722. package/node_modules/stream-json/utils/Batch.js +44 -0
  723. package/node_modules/stream-json/utils/Utf8Stream.js +53 -0
  724. package/node_modules/stream-json/utils/Verifier.js +485 -0
  725. package/node_modules/stream-json/utils/emit.js +5 -0
  726. package/node_modules/stream-json/utils/withParser.js +10 -0
  727. package/package.json +2 -1
  728. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/bls.d.ts.map +0 -1
  729. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/bls.js.map +0 -1
  730. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/curve.d.ts.map +0 -1
  731. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/curve.js.map +0 -1
  732. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/edwards.d.ts.map +0 -1
  733. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/edwards.js.map +0 -1
  734. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/hash-to-curve.d.ts.map +0 -1
  735. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/hash-to-curve.js.map +0 -1
  736. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/modular.d.ts.map +0 -1
  737. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/modular.js.map +0 -1
  738. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/montgomery.d.ts.map +0 -1
  739. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/montgomery.js +0 -160
  740. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/montgomery.js.map +0 -1
  741. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/poseidon.d.ts +0 -39
  742. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/poseidon.d.ts.map +0 -1
  743. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/poseidon.js +0 -121
  744. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/poseidon.js.map +0 -1
  745. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/tower.js.map +0 -1
  746. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/utils.d.ts.map +0 -1
  747. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/utils.js.map +0 -1
  748. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/weierstrass.d.ts.map +0 -1
  749. package/node_modules/@solana/web3.js/node_modules/@noble/curves/abstract/weierstrass.js.map +0 -1
  750. package/node_modules/@solana/web3.js/node_modules/@noble/curves/bls12-381.js.map +0 -1
  751. package/node_modules/@solana/web3.js/node_modules/@noble/curves/bn254.js.map +0 -1
  752. package/node_modules/@solana/web3.js/node_modules/@noble/curves/ed25519.d.ts.map +0 -1
  753. package/node_modules/@solana/web3.js/node_modules/@noble/curves/ed25519.js.map +0 -1
  754. package/node_modules/@solana/web3.js/node_modules/@noble/curves/ed448.d.ts.map +0 -1
  755. package/node_modules/@solana/web3.js/node_modules/@noble/curves/ed448.js.map +0 -1
  756. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/bls.d.ts.map +0 -1
  757. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/bls.js.map +0 -1
  758. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/curve.d.ts.map +0 -1
  759. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/curve.js.map +0 -1
  760. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/edwards.d.ts.map +0 -1
  761. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/edwards.js.map +0 -1
  762. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/hash-to-curve.d.ts.map +0 -1
  763. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/hash-to-curve.js.map +0 -1
  764. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/modular.d.ts.map +0 -1
  765. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/modular.js.map +0 -1
  766. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/montgomery.d.ts.map +0 -1
  767. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/montgomery.js +0 -157
  768. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/montgomery.js.map +0 -1
  769. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/poseidon.d.ts +0 -39
  770. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/poseidon.d.ts.map +0 -1
  771. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/poseidon.js +0 -116
  772. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/poseidon.js.map +0 -1
  773. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/tower.js.map +0 -1
  774. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/utils.d.ts.map +0 -1
  775. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/utils.js.map +0 -1
  776. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/weierstrass.d.ts.map +0 -1
  777. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/abstract/weierstrass.js.map +0 -1
  778. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/bls12-381.js.map +0 -1
  779. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/bn254.js.map +0 -1
  780. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/ed25519.d.ts.map +0 -1
  781. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/ed25519.js.map +0 -1
  782. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/ed448.d.ts.map +0 -1
  783. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/ed448.js.map +0 -1
  784. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/jubjub.d.ts +0 -5
  785. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/jubjub.d.ts.map +0 -1
  786. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/jubjub.js +0 -61
  787. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/jubjub.js.map +0 -1
  788. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/p256.d.ts +0 -11
  789. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/p256.d.ts.map +0 -1
  790. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/p256.js +0 -49
  791. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/p256.js.map +0 -1
  792. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/p384.d.ts +0 -11
  793. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/p384.d.ts.map +0 -1
  794. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/p384.js +0 -53
  795. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/p384.js.map +0 -1
  796. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/p521.d.ts +0 -12
  797. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/p521.d.ts.map +0 -1
  798. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/p521.js +0 -61
  799. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/p521.js.map +0 -1
  800. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/pasta.d.ts +0 -8
  801. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/pasta.d.ts.map +0 -1
  802. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/pasta.js +0 -34
  803. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/pasta.js.map +0 -1
  804. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/secp256k1.d.ts.map +0 -1
  805. package/node_modules/@solana/web3.js/node_modules/@noble/curves/esm/secp256k1.js.map +0 -1
  806. package/node_modules/@solana/web3.js/node_modules/@noble/curves/jubjub.d.ts +0 -5
  807. package/node_modules/@solana/web3.js/node_modules/@noble/curves/jubjub.d.ts.map +0 -1
  808. package/node_modules/@solana/web3.js/node_modules/@noble/curves/jubjub.js +0 -66
  809. package/node_modules/@solana/web3.js/node_modules/@noble/curves/jubjub.js.map +0 -1
  810. package/node_modules/@solana/web3.js/node_modules/@noble/curves/p256.d.ts +0 -11
  811. package/node_modules/@solana/web3.js/node_modules/@noble/curves/p256.d.ts.map +0 -1
  812. package/node_modules/@solana/web3.js/node_modules/@noble/curves/p256.js +0 -52
  813. package/node_modules/@solana/web3.js/node_modules/@noble/curves/p256.js.map +0 -1
  814. package/node_modules/@solana/web3.js/node_modules/@noble/curves/p384.d.ts +0 -11
  815. package/node_modules/@solana/web3.js/node_modules/@noble/curves/p384.d.ts.map +0 -1
  816. package/node_modules/@solana/web3.js/node_modules/@noble/curves/p384.js +0 -56
  817. package/node_modules/@solana/web3.js/node_modules/@noble/curves/p384.js.map +0 -1
  818. package/node_modules/@solana/web3.js/node_modules/@noble/curves/p521.d.ts +0 -12
  819. package/node_modules/@solana/web3.js/node_modules/@noble/curves/p521.d.ts.map +0 -1
  820. package/node_modules/@solana/web3.js/node_modules/@noble/curves/p521.js +0 -64
  821. package/node_modules/@solana/web3.js/node_modules/@noble/curves/p521.js.map +0 -1
  822. package/node_modules/@solana/web3.js/node_modules/@noble/curves/pasta.d.ts +0 -8
  823. package/node_modules/@solana/web3.js/node_modules/@noble/curves/pasta.d.ts.map +0 -1
  824. package/node_modules/@solana/web3.js/node_modules/@noble/curves/pasta.js +0 -37
  825. package/node_modules/@solana/web3.js/node_modules/@noble/curves/pasta.js.map +0 -1
  826. package/node_modules/@solana/web3.js/node_modules/@noble/curves/secp256k1.d.ts.map +0 -1
  827. package/node_modules/@solana/web3.js/node_modules/@noble/curves/secp256k1.js.map +0 -1
  828. package/node_modules/@solana/web3.js/node_modules/@noble/curves/src/abstract/montgomery.ts +0 -196
  829. package/node_modules/@solana/web3.js/node_modules/@noble/curves/src/abstract/poseidon.ts +0 -136
  830. package/node_modules/@solana/web3.js/node_modules/@noble/curves/src/jubjub.ts +0 -63
  831. package/node_modules/@solana/web3.js/node_modules/@noble/curves/src/p256.ts +0 -54
  832. package/node_modules/@solana/web3.js/node_modules/@noble/curves/src/p384.ts +0 -58
  833. package/node_modules/@solana/web3.js/node_modules/@noble/curves/src/p521.ts +0 -75
  834. package/node_modules/@solana/web3.js/node_modules/@noble/curves/src/pasta.ts +0 -39
  835. package/node_modules/JSONStream/.travis.yml +0 -8
  836. package/node_modules/JSONStream/LICENSE.APACHE2 +0 -15
  837. package/node_modules/JSONStream/LICENSE.MIT +0 -24
  838. package/node_modules/JSONStream/bin.js +0 -12
  839. package/node_modules/JSONStream/examples/all_docs.js +0 -13
  840. package/node_modules/JSONStream/index.js +0 -247
  841. package/node_modules/JSONStream/package.json +0 -40
  842. package/node_modules/JSONStream/readme.markdown +0 -207
  843. package/node_modules/JSONStream/test/bool.js +0 -41
  844. package/node_modules/JSONStream/test/browser.js +0 -18
  845. package/node_modules/JSONStream/test/destroy_missing.js +0 -27
  846. package/node_modules/JSONStream/test/doubledot1.js +0 -29
  847. package/node_modules/JSONStream/test/doubledot2.js +0 -30
  848. package/node_modules/JSONStream/test/empty.js +0 -44
  849. package/node_modules/JSONStream/test/error_contents.js +0 -45
  850. package/node_modules/JSONStream/test/fixtures/all_npm.json +0 -4030
  851. package/node_modules/JSONStream/test/fixtures/couch_sample.json +0 -18
  852. package/node_modules/JSONStream/test/fixtures/depth.json +0 -15
  853. package/node_modules/JSONStream/test/fixtures/error.json +0 -1
  854. package/node_modules/JSONStream/test/fixtures/header_footer.json +0 -19
  855. package/node_modules/JSONStream/test/fn.js +0 -39
  856. package/node_modules/JSONStream/test/gen.js +0 -135
  857. package/node_modules/JSONStream/test/header_footer.js +0 -55
  858. package/node_modules/JSONStream/test/issues.js +0 -34
  859. package/node_modules/JSONStream/test/keys.js +0 -105
  860. package/node_modules/JSONStream/test/map.js +0 -40
  861. package/node_modules/JSONStream/test/multiple_objects.js +0 -36
  862. package/node_modules/JSONStream/test/multiple_objects_error.js +0 -29
  863. package/node_modules/JSONStream/test/null.js +0 -28
  864. package/node_modules/JSONStream/test/parsejson.js +0 -29
  865. package/node_modules/JSONStream/test/run.js +0 -13
  866. package/node_modules/JSONStream/test/stringify.js +0 -41
  867. package/node_modules/JSONStream/test/stringify_object.js +0 -47
  868. package/node_modules/JSONStream/test/test.js +0 -35
  869. package/node_modules/JSONStream/test/test2.js +0 -29
  870. package/node_modules/JSONStream/test/two-ways.js +0 -41
  871. package/node_modules/bigint-buffer/.travis.yml +0 -51
  872. package/node_modules/bigint-buffer/LICENSE +0 -202
  873. package/node_modules/bigint-buffer/README.md +0 -121
  874. package/node_modules/bigint-buffer/binding.gyp +0 -8
  875. package/node_modules/bigint-buffer/build/Makefile +0 -347
  876. package/node_modules/bigint-buffer/build/Release/.deps/Release/bigint_buffer.node.d +0 -1
  877. package/node_modules/bigint-buffer/build/Release/.deps/Release/obj.target/bigint_buffer/src/bigint-buffer.o.d +0 -12
  878. package/node_modules/bigint-buffer/build/Release/bigint_buffer.node +0 -0
  879. package/node_modules/bigint-buffer/build/Release/obj.target/bigint_buffer/src/bigint-buffer.o +0 -0
  880. package/node_modules/bigint-buffer/build/bigint_buffer.target.mk +0 -180
  881. package/node_modules/bigint-buffer/build/binding.Makefile +0 -6
  882. package/node_modules/bigint-buffer/build/config.gypi +0 -450
  883. package/node_modules/bigint-buffer/build/gyp-mac-tool +0 -772
  884. package/node_modules/bigint-buffer/dist/browser.js +0 -69
  885. package/node_modules/bigint-buffer/dist/index.bench.d.ts +0 -1
  886. package/node_modules/bigint-buffer/dist/index.d.ts +0 -27
  887. package/node_modules/bigint-buffer/dist/index.spec.d.ts +0 -1
  888. package/node_modules/bigint-buffer/dist/node.js +0 -77
  889. package/node_modules/bigint-buffer/helper/bigint.d.ts +0 -3
  890. package/node_modules/bigint-buffer/karma.conf.js +0 -62
  891. package/node_modules/bigint-buffer/package.json +0 -89
  892. package/node_modules/bigint-buffer/rollup.config.js +0 -13
  893. package/node_modules/bigint-buffer/src/bigint-buffer.c +0 -203
  894. package/node_modules/bigint-buffer/src/index.bench.ts +0 -207
  895. package/node_modules/bigint-buffer/src/index.spec.ts +0 -288
  896. package/node_modules/bigint-buffer/src/index.ts +0 -84
  897. package/node_modules/bigint-buffer/tsconfig.json +0 -19
  898. package/node_modules/bindings/README.md +0 -98
  899. package/node_modules/bindings/bindings.js +0 -221
  900. package/node_modules/bindings/package.json +0 -28
  901. package/node_modules/file-uri-to-path/.npmignore +0 -1
  902. package/node_modules/file-uri-to-path/.travis.yml +0 -30
  903. package/node_modules/file-uri-to-path/History.md +0 -21
  904. package/node_modules/file-uri-to-path/README.md +0 -74
  905. package/node_modules/file-uri-to-path/index.d.ts +0 -2
  906. package/node_modules/file-uri-to-path/index.js +0 -66
  907. package/node_modules/file-uri-to-path/package.json +0 -32
  908. package/node_modules/file-uri-to-path/test/test.js +0 -24
  909. package/node_modules/file-uri-to-path/test/tests.json +0 -13
  910. package/node_modules/jsonparse/.npmignore +0 -1
  911. package/node_modules/jsonparse/LICENSE +0 -24
  912. package/node_modules/jsonparse/bench.js +0 -26
  913. package/node_modules/jsonparse/examples/twitterfeed.js +0 -30
  914. package/node_modules/jsonparse/jsonparse.js +0 -413
  915. package/node_modules/jsonparse/package.json +0 -22
  916. package/node_modules/jsonparse/samplejson/basic.json +0 -167
  917. package/node_modules/jsonparse/samplejson/basic2.json +0 -180
  918. package/node_modules/jsonparse/test/big-token.js +0 -24
  919. package/node_modules/jsonparse/test/boundary.js +0 -110
  920. package/node_modules/jsonparse/test/offset.js +0 -67
  921. package/node_modules/jsonparse/test/primitives.js +0 -57
  922. package/node_modules/jsonparse/test/surrogate.js +0 -26
  923. package/node_modules/jsonparse/test/unvalid.js +0 -15
  924. package/node_modules/jsonparse/test/utf8.js +0 -38
  925. package/node_modules/regenerator-runtime/LICENSE +0 -21
  926. package/node_modules/regenerator-runtime/README.md +0 -31
  927. package/node_modules/regenerator-runtime/package.json +0 -19
  928. package/node_modules/regenerator-runtime/path.js +0 -11
  929. package/node_modules/regenerator-runtime/runtime.js +0 -761
  930. package/node_modules/through/.travis.yml +0 -5
  931. package/node_modules/through/LICENSE.APACHE2 +0 -15
  932. package/node_modules/through/LICENSE.MIT +0 -24
  933. package/node_modules/through/index.js +0 -108
  934. package/node_modules/through/package.json +0 -36
  935. package/node_modules/through/readme.markdown +0 -64
  936. package/node_modules/through/test/async.js +0 -28
  937. package/node_modules/through/test/auto-destroy.js +0 -30
  938. package/node_modules/through/test/buffering.js +0 -71
  939. package/node_modules/through/test/end.js +0 -45
  940. package/node_modules/through/test/index.js +0 -133
  941. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/LICENSE +0 -0
  942. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/_shortw_utils.d.ts.map +0 -0
  943. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/_shortw_utils.js.map +0 -0
  944. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/_shortw_utils.d.ts.map +0 -0
  945. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/_shortw_utils.js.map +0 -0
  946. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/index.d.ts +0 -0
  947. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/index.d.ts.map +0 -0
  948. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/index.js +0 -0
  949. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/index.js.map +0 -0
  950. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/esm/package.json +0 -0
  951. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/index.d.ts +0 -0
  952. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/index.d.ts.map +0 -0
  953. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/index.js +0 -0
  954. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/index.js.map +0 -0
  955. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/index.ts +0 -0
  956. /package/node_modules/{@solana/web3.js/node_modules/@noble → @noble}/curves/src/package.json +0 -0
  957. /package/node_modules/{@coral-xyz/anchor/node_modules/camelcase → @solana/errors/node_modules/chalk}/license +0 -0
  958. /package/node_modules/{@coral-xyz/anchor/node_modules/camelcase → camelcase}/index.d.ts +0 -0
  959. /package/node_modules/{@coral-xyz/anchor/node_modules/camelcase → camelcase}/index.js +0 -0
  960. /package/node_modules/{@coral-xyz/anchor/node_modules/camelcase → camelcase}/package.json +0 -0
  961. /package/node_modules/{@coral-xyz/anchor/node_modules/camelcase → camelcase}/readme.md +0 -0
  962. /package/node_modules/{@swc/helpers/node_modules/tslib → tslib}/CopyrightNotice.txt +0 -0
  963. /package/node_modules/{@swc/helpers/node_modules/tslib → tslib}/LICENSE.txt +0 -0
  964. /package/node_modules/{@swc/helpers/node_modules/tslib → tslib}/README.md +0 -0
  965. /package/node_modules/{@swc/helpers/node_modules/tslib → tslib}/SECURITY.md +0 -0
  966. /package/node_modules/{@swc/helpers/node_modules/tslib → tslib}/modules/index.d.ts +0 -0
  967. /package/node_modules/{@swc/helpers/node_modules/tslib → tslib}/modules/index.js +0 -0
  968. /package/node_modules/{@swc/helpers/node_modules/tslib → tslib}/modules/package.json +0 -0
  969. /package/node_modules/{@swc/helpers/node_modules/tslib → tslib}/package.json +0 -0
  970. /package/node_modules/{@swc/helpers/node_modules/tslib → tslib}/tslib.d.ts +0 -0
  971. /package/node_modules/{@swc/helpers/node_modules/tslib → tslib}/tslib.es6.html +0 -0
  972. /package/node_modules/{@swc/helpers/node_modules/tslib → tslib}/tslib.es6.js +0 -0
  973. /package/node_modules/{@swc/helpers/node_modules/tslib → tslib}/tslib.es6.mjs +0 -0
  974. /package/node_modules/{@swc/helpers/node_modules/tslib → tslib}/tslib.html +0 -0
  975. /package/node_modules/{@swc/helpers/node_modules/tslib → tslib}/tslib.js +0 -0
package/dist/index.js CHANGED
@@ -30,7 +30,7 @@ var cp_amm_default = {
30
30
  address: "cpamdpZCGKUy5JxQXB4dcpGPiikHawvSWAd6mEn1sGG",
31
31
  metadata: {
32
32
  name: "cp_amm",
33
- version: "0.1.0",
33
+ version: "0.1.1",
34
34
  spec: "0.1.0",
35
35
  description: "Created with Anchor"
36
36
  },
@@ -591,38 +591,38 @@ var cp_amm_default = {
591
591
  {
592
592
  kind: "const",
593
593
  value: [
594
- 153,
595
- 10,
596
- 107,
597
- 154,
598
- 255,
599
- 249,
600
- 210,
594
+ 48,
595
+ 9,
596
+ 89,
597
+ 123,
598
+ 106,
599
+ 114,
600
+ 131,
601
+ 251,
602
+ 50,
601
603
  173,
602
- 176,
603
- 67,
604
- 220,
605
- 214,
606
- 152,
607
- 71,
608
- 46,
609
- 146,
610
- 161,
611
- 33,
604
+ 254,
605
+ 250,
606
+ 10,
607
+ 80,
608
+ 160,
609
+ 84,
610
+ 143,
611
+ 100,
612
612
  81,
613
- 148,
613
+ 249,
614
+ 134,
615
+ 112,
616
+ 30,
617
+ 213,
618
+ 50,
614
619
  166,
615
- 119,
616
- 5,
617
- 189,
618
- 142,
619
- 11,
620
- 57,
621
- 68,
622
- 162,
623
- 70,
624
- 126,
625
- 100
620
+ 239,
621
+ 78,
622
+ 53,
623
+ 175,
624
+ 188,
625
+ 85
626
626
  ]
627
627
  },
628
628
  {
@@ -684,38 +684,38 @@ var cp_amm_default = {
684
684
  {
685
685
  kind: "const",
686
686
  value: [
687
- 153,
688
- 10,
689
- 107,
690
- 154,
691
- 255,
692
- 249,
693
- 210,
687
+ 48,
688
+ 9,
689
+ 89,
690
+ 123,
691
+ 106,
692
+ 114,
693
+ 131,
694
+ 251,
695
+ 50,
694
696
  173,
695
- 176,
696
- 67,
697
- 220,
698
- 214,
699
- 152,
700
- 71,
701
- 46,
702
- 146,
703
- 161,
704
- 33,
697
+ 254,
698
+ 250,
699
+ 10,
700
+ 80,
701
+ 160,
702
+ 84,
703
+ 143,
704
+ 100,
705
705
  81,
706
- 148,
706
+ 249,
707
+ 134,
708
+ 112,
709
+ 30,
710
+ 213,
711
+ 50,
707
712
  166,
708
- 119,
709
- 5,
710
- 189,
711
- 142,
712
- 11,
713
- 57,
714
- 68,
715
- 162,
716
- 70,
717
- 126,
718
- 100
713
+ 239,
714
+ 78,
715
+ 53,
716
+ 175,
717
+ 188,
718
+ 85
719
719
  ]
720
720
  },
721
721
  {
@@ -1309,7 +1309,100 @@ var cp_amm_default = {
1309
1309
  },
1310
1310
  {
1311
1311
  kind: "arg",
1312
- path: "config_parameters.index"
1312
+ path: "index"
1313
+ }
1314
+ ]
1315
+ }
1316
+ },
1317
+ {
1318
+ name: "admin",
1319
+ writable: true,
1320
+ signer: true
1321
+ },
1322
+ {
1323
+ name: "system_program",
1324
+ address: "11111111111111111111111111111111"
1325
+ },
1326
+ {
1327
+ name: "event_authority",
1328
+ pda: {
1329
+ seeds: [
1330
+ {
1331
+ kind: "const",
1332
+ value: [
1333
+ 95,
1334
+ 95,
1335
+ 101,
1336
+ 118,
1337
+ 101,
1338
+ 110,
1339
+ 116,
1340
+ 95,
1341
+ 97,
1342
+ 117,
1343
+ 116,
1344
+ 104,
1345
+ 111,
1346
+ 114,
1347
+ 105,
1348
+ 116,
1349
+ 121
1350
+ ]
1351
+ }
1352
+ ]
1353
+ }
1354
+ },
1355
+ {
1356
+ name: "program"
1357
+ }
1358
+ ],
1359
+ args: [
1360
+ {
1361
+ name: "index",
1362
+ type: "u64"
1363
+ },
1364
+ {
1365
+ name: "config_parameters",
1366
+ type: {
1367
+ defined: {
1368
+ name: "StaticConfigParameters"
1369
+ }
1370
+ }
1371
+ }
1372
+ ]
1373
+ },
1374
+ {
1375
+ name: "create_dynamic_config",
1376
+ discriminator: [
1377
+ 81,
1378
+ 251,
1379
+ 122,
1380
+ 78,
1381
+ 66,
1382
+ 57,
1383
+ 208,
1384
+ 82
1385
+ ],
1386
+ accounts: [
1387
+ {
1388
+ name: "config",
1389
+ writable: true,
1390
+ pda: {
1391
+ seeds: [
1392
+ {
1393
+ kind: "const",
1394
+ value: [
1395
+ 99,
1396
+ 111,
1397
+ 110,
1398
+ 102,
1399
+ 105,
1400
+ 103
1401
+ ]
1402
+ },
1403
+ {
1404
+ kind: "arg",
1405
+ path: "index"
1313
1406
  }
1314
1407
  ]
1315
1408
  }
@@ -1357,11 +1450,15 @@ var cp_amm_default = {
1357
1450
  }
1358
1451
  ],
1359
1452
  args: [
1453
+ {
1454
+ name: "index",
1455
+ type: "u64"
1456
+ },
1360
1457
  {
1361
1458
  name: "config_parameters",
1362
1459
  type: {
1363
1460
  defined: {
1364
- name: "ConfigParameters"
1461
+ name: "DynamicConfigParameters"
1365
1462
  }
1366
1463
  }
1367
1464
  }
@@ -2307,18 +2404,90 @@ var cp_amm_default = {
2307
2404
  ]
2308
2405
  },
2309
2406
  {
2310
- name: "initialize_reward",
2407
+ name: "initialize_pool_with_dynamic_config",
2311
2408
  discriminator: [
2312
- 95,
2313
- 135,
2314
- 192,
2315
- 196,
2316
- 242,
2317
- 129,
2318
- 230,
2319
- 68
2409
+ 149,
2410
+ 82,
2411
+ 72,
2412
+ 197,
2413
+ 253,
2414
+ 252,
2415
+ 68,
2416
+ 15
2320
2417
  ],
2321
2418
  accounts: [
2419
+ {
2420
+ name: "creator"
2421
+ },
2422
+ {
2423
+ name: "position_nft_mint",
2424
+ docs: [
2425
+ "position_nft_mint"
2426
+ ],
2427
+ writable: true,
2428
+ signer: true
2429
+ },
2430
+ {
2431
+ name: "position_nft_account",
2432
+ docs: [
2433
+ "position nft account"
2434
+ ],
2435
+ writable: true,
2436
+ pda: {
2437
+ seeds: [
2438
+ {
2439
+ kind: "const",
2440
+ value: [
2441
+ 112,
2442
+ 111,
2443
+ 115,
2444
+ 105,
2445
+ 116,
2446
+ 105,
2447
+ 111,
2448
+ 110,
2449
+ 95,
2450
+ 110,
2451
+ 102,
2452
+ 116,
2453
+ 95,
2454
+ 97,
2455
+ 99,
2456
+ 99,
2457
+ 111,
2458
+ 117,
2459
+ 110,
2460
+ 116
2461
+ ]
2462
+ },
2463
+ {
2464
+ kind: "account",
2465
+ path: "position_nft_mint"
2466
+ }
2467
+ ]
2468
+ }
2469
+ },
2470
+ {
2471
+ name: "payer",
2472
+ docs: [
2473
+ "Address paying to create the pool. Can be anyone"
2474
+ ],
2475
+ writable: true,
2476
+ signer: true
2477
+ },
2478
+ {
2479
+ name: "pool_creator_authority",
2480
+ signer: true,
2481
+ relations: [
2482
+ "config"
2483
+ ]
2484
+ },
2485
+ {
2486
+ name: "config",
2487
+ docs: [
2488
+ "Which config the pool belongs to."
2489
+ ]
2490
+ },
2322
2491
  {
2323
2492
  name: "pool_authority",
2324
2493
  pda: {
@@ -2347,67 +2516,301 @@ var cp_amm_default = {
2347
2516
  },
2348
2517
  {
2349
2518
  name: "pool",
2519
+ docs: [
2520
+ "Initialize an account to store the pool state"
2521
+ ],
2350
2522
  writable: true
2351
2523
  },
2352
2524
  {
2353
- name: "reward_vault",
2525
+ name: "position",
2354
2526
  writable: true,
2355
2527
  pda: {
2356
2528
  seeds: [
2357
2529
  {
2358
2530
  kind: "const",
2359
2531
  value: [
2360
- 114,
2361
- 101,
2362
- 119,
2363
- 97,
2364
- 114,
2365
- 100,
2366
- 95,
2367
- 118,
2368
- 97,
2369
- 117,
2370
- 108,
2371
- 116
2532
+ 112,
2533
+ 111,
2534
+ 115,
2535
+ 105,
2536
+ 116,
2537
+ 105,
2538
+ 111,
2539
+ 110
2372
2540
  ]
2373
2541
  },
2374
2542
  {
2375
2543
  kind: "account",
2376
- path: "pool"
2377
- },
2378
- {
2379
- kind: "arg",
2380
- path: "reward_index"
2544
+ path: "position_nft_mint"
2381
2545
  }
2382
2546
  ]
2383
2547
  }
2384
2548
  },
2385
2549
  {
2386
- name: "reward_mint"
2387
- },
2388
- {
2389
- name: "admin",
2390
- writable: true,
2391
- signer: true
2392
- },
2393
- {
2394
- name: "token_program"
2550
+ name: "token_a_mint",
2551
+ docs: [
2552
+ "Token a mint"
2553
+ ]
2395
2554
  },
2396
2555
  {
2397
- name: "system_program",
2398
- address: "11111111111111111111111111111111"
2556
+ name: "token_b_mint",
2557
+ docs: [
2558
+ "Token b mint"
2559
+ ]
2399
2560
  },
2400
2561
  {
2401
- name: "event_authority",
2562
+ name: "token_a_vault",
2563
+ docs: [
2564
+ "Token a vault for the pool"
2565
+ ],
2566
+ writable: true,
2402
2567
  pda: {
2403
2568
  seeds: [
2404
2569
  {
2405
2570
  kind: "const",
2406
2571
  value: [
2407
- 95,
2408
- 95,
2409
- 101,
2410
- 118,
2572
+ 116,
2573
+ 111,
2574
+ 107,
2575
+ 101,
2576
+ 110,
2577
+ 95,
2578
+ 118,
2579
+ 97,
2580
+ 117,
2581
+ 108,
2582
+ 116
2583
+ ]
2584
+ },
2585
+ {
2586
+ kind: "account",
2587
+ path: "token_a_mint"
2588
+ },
2589
+ {
2590
+ kind: "account",
2591
+ path: "pool"
2592
+ }
2593
+ ]
2594
+ }
2595
+ },
2596
+ {
2597
+ name: "token_b_vault",
2598
+ docs: [
2599
+ "Token b vault for the pool"
2600
+ ],
2601
+ writable: true,
2602
+ pda: {
2603
+ seeds: [
2604
+ {
2605
+ kind: "const",
2606
+ value: [
2607
+ 116,
2608
+ 111,
2609
+ 107,
2610
+ 101,
2611
+ 110,
2612
+ 95,
2613
+ 118,
2614
+ 97,
2615
+ 117,
2616
+ 108,
2617
+ 116
2618
+ ]
2619
+ },
2620
+ {
2621
+ kind: "account",
2622
+ path: "token_b_mint"
2623
+ },
2624
+ {
2625
+ kind: "account",
2626
+ path: "pool"
2627
+ }
2628
+ ]
2629
+ }
2630
+ },
2631
+ {
2632
+ name: "payer_token_a",
2633
+ docs: [
2634
+ "payer token a account"
2635
+ ],
2636
+ writable: true
2637
+ },
2638
+ {
2639
+ name: "payer_token_b",
2640
+ docs: [
2641
+ "creator token b account"
2642
+ ],
2643
+ writable: true
2644
+ },
2645
+ {
2646
+ name: "token_a_program",
2647
+ docs: [
2648
+ "Program to create mint account and mint tokens"
2649
+ ]
2650
+ },
2651
+ {
2652
+ name: "token_b_program",
2653
+ docs: [
2654
+ "Program to create mint account and mint tokens"
2655
+ ]
2656
+ },
2657
+ {
2658
+ name: "token_2022_program",
2659
+ docs: [
2660
+ "Program to create NFT mint/token account and transfer for token22 account"
2661
+ ],
2662
+ address: "TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb"
2663
+ },
2664
+ {
2665
+ name: "system_program",
2666
+ address: "11111111111111111111111111111111"
2667
+ },
2668
+ {
2669
+ name: "event_authority",
2670
+ pda: {
2671
+ seeds: [
2672
+ {
2673
+ kind: "const",
2674
+ value: [
2675
+ 95,
2676
+ 95,
2677
+ 101,
2678
+ 118,
2679
+ 101,
2680
+ 110,
2681
+ 116,
2682
+ 95,
2683
+ 97,
2684
+ 117,
2685
+ 116,
2686
+ 104,
2687
+ 111,
2688
+ 114,
2689
+ 105,
2690
+ 116,
2691
+ 121
2692
+ ]
2693
+ }
2694
+ ]
2695
+ }
2696
+ },
2697
+ {
2698
+ name: "program"
2699
+ }
2700
+ ],
2701
+ args: [
2702
+ {
2703
+ name: "params",
2704
+ type: {
2705
+ defined: {
2706
+ name: "InitializeCustomizablePoolParameters"
2707
+ }
2708
+ }
2709
+ }
2710
+ ]
2711
+ },
2712
+ {
2713
+ name: "initialize_reward",
2714
+ discriminator: [
2715
+ 95,
2716
+ 135,
2717
+ 192,
2718
+ 196,
2719
+ 242,
2720
+ 129,
2721
+ 230,
2722
+ 68
2723
+ ],
2724
+ accounts: [
2725
+ {
2726
+ name: "pool_authority",
2727
+ pda: {
2728
+ seeds: [
2729
+ {
2730
+ kind: "const",
2731
+ value: [
2732
+ 112,
2733
+ 111,
2734
+ 111,
2735
+ 108,
2736
+ 95,
2737
+ 97,
2738
+ 117,
2739
+ 116,
2740
+ 104,
2741
+ 111,
2742
+ 114,
2743
+ 105,
2744
+ 116,
2745
+ 121
2746
+ ]
2747
+ }
2748
+ ]
2749
+ }
2750
+ },
2751
+ {
2752
+ name: "pool",
2753
+ writable: true
2754
+ },
2755
+ {
2756
+ name: "reward_vault",
2757
+ writable: true,
2758
+ pda: {
2759
+ seeds: [
2760
+ {
2761
+ kind: "const",
2762
+ value: [
2763
+ 114,
2764
+ 101,
2765
+ 119,
2766
+ 97,
2767
+ 114,
2768
+ 100,
2769
+ 95,
2770
+ 118,
2771
+ 97,
2772
+ 117,
2773
+ 108,
2774
+ 116
2775
+ ]
2776
+ },
2777
+ {
2778
+ kind: "account",
2779
+ path: "pool"
2780
+ },
2781
+ {
2782
+ kind: "arg",
2783
+ path: "reward_index"
2784
+ }
2785
+ ]
2786
+ }
2787
+ },
2788
+ {
2789
+ name: "reward_mint"
2790
+ },
2791
+ {
2792
+ name: "admin",
2793
+ writable: true,
2794
+ signer: true
2795
+ },
2796
+ {
2797
+ name: "token_program"
2798
+ },
2799
+ {
2800
+ name: "system_program",
2801
+ address: "11111111111111111111111111111111"
2802
+ },
2803
+ {
2804
+ name: "event_authority",
2805
+ pda: {
2806
+ seeds: [
2807
+ {
2808
+ kind: "const",
2809
+ value: [
2810
+ 95,
2811
+ 95,
2812
+ 101,
2813
+ 118,
2411
2814
  101,
2412
2815
  110,
2413
2816
  116,
@@ -3660,6 +4063,19 @@ var cp_amm_default = {
3660
4063
  54
3661
4064
  ]
3662
4065
  },
4066
+ {
4067
+ name: "EvtCreateDynamicConfig",
4068
+ discriminator: [
4069
+ 231,
4070
+ 197,
4071
+ 13,
4072
+ 164,
4073
+ 248,
4074
+ 213,
4075
+ 133,
4076
+ 152
4077
+ ]
4078
+ },
3663
4079
  {
3664
4080
  name: "EvtCreatePosition",
3665
4081
  discriminator: [
@@ -4030,6 +4446,16 @@ var cp_amm_default = {
4030
4446
  code: 6039,
4031
4447
  name: "PositionIsNotEmpty",
4032
4448
  msg: "Position is not empty"
4449
+ },
4450
+ {
4451
+ code: 6040,
4452
+ name: "InvalidPoolCreatorAuthority",
4453
+ msg: "Invalid pool creator authority"
4454
+ },
4455
+ {
4456
+ code: 6041,
4457
+ name: "InvalidConfigType",
4458
+ msg: "Invalid config type"
4033
4459
  }
4034
4460
  ],
4035
4461
  types: [
@@ -4259,14 +4685,21 @@ var cp_amm_default = {
4259
4685
  type: "u8"
4260
4686
  },
4261
4687
  {
4262
- name: "_padding_0",
4688
+ name: "config_type",
4263
4689
  docs: [
4264
- "padding 0"
4690
+ "Config type mode, 0 for static, 1 for dynamic"
4265
4691
  ],
4266
- type: {
4692
+ type: "u8"
4693
+ },
4694
+ {
4695
+ name: "_padding_0",
4696
+ docs: [
4697
+ "padding 0"
4698
+ ],
4699
+ type: {
4267
4700
  array: [
4268
4701
  "u8",
4269
- 6
4702
+ 5
4270
4703
  ]
4271
4704
  }
4272
4705
  },
@@ -4308,45 +4741,13 @@ var cp_amm_default = {
4308
4741
  }
4309
4742
  },
4310
4743
  {
4311
- name: "ConfigParameters",
4744
+ name: "DynamicConfigParameters",
4312
4745
  type: {
4313
4746
  kind: "struct",
4314
4747
  fields: [
4315
- {
4316
- name: "pool_fees",
4317
- type: {
4318
- defined: {
4319
- name: "PoolFeeParameters"
4320
- }
4321
- }
4322
- },
4323
- {
4324
- name: "sqrt_min_price",
4325
- type: "u128"
4326
- },
4327
- {
4328
- name: "sqrt_max_price",
4329
- type: "u128"
4330
- },
4331
- {
4332
- name: "vault_config_key",
4333
- type: "pubkey"
4334
- },
4335
4748
  {
4336
4749
  name: "pool_creator_authority",
4337
4750
  type: "pubkey"
4338
- },
4339
- {
4340
- name: "activation_type",
4341
- type: "u8"
4342
- },
4343
- {
4344
- name: "collect_fee_mode",
4345
- type: "u8"
4346
- },
4347
- {
4348
- name: "index",
4349
- type: "u64"
4350
4751
  }
4351
4752
  ]
4352
4753
  }
@@ -4748,7 +5149,7 @@ var cp_amm_default = {
4748
5149
  {
4749
5150
  name: "EvtCreateConfig",
4750
5151
  docs: [
4751
- "Create config"
5152
+ "Create static config"
4752
5153
  ],
4753
5154
  type: {
4754
5155
  kind: "struct",
@@ -4796,6 +5197,29 @@ var cp_amm_default = {
4796
5197
  ]
4797
5198
  }
4798
5199
  },
5200
+ {
5201
+ name: "EvtCreateDynamicConfig",
5202
+ docs: [
5203
+ "Create dynamic config"
5204
+ ],
5205
+ type: {
5206
+ kind: "struct",
5207
+ fields: [
5208
+ {
5209
+ name: "config",
5210
+ type: "pubkey"
5211
+ },
5212
+ {
5213
+ name: "pool_creator_authority",
5214
+ type: "pubkey"
5215
+ },
5216
+ {
5217
+ name: "index",
5218
+ type: "u64"
5219
+ }
5220
+ ]
5221
+ }
5222
+ },
4799
5223
  {
4800
5224
  name: "EvtCreatePosition",
4801
5225
  type: {
@@ -5401,18 +5825,11 @@ var cp_amm_default = {
5401
5825
  type: "u128"
5402
5826
  },
5403
5827
  {
5404
- name: "token_a_reserve",
5405
- docs: [
5406
- "token a reserve"
5407
- ],
5408
- type: "u64"
5409
- },
5410
- {
5411
- name: "token_b_reserve",
5828
+ name: "_padding",
5412
5829
  docs: [
5413
- "token b reserve"
5830
+ "padding, previous reserve amount, be careful to use that field"
5414
5831
  ],
5415
- type: "u64"
5832
+ type: "u128"
5416
5833
  },
5417
5834
  {
5418
5835
  name: "protocol_a_fee",
@@ -6135,6 +6552,46 @@ var cp_amm_default = {
6135
6552
  ]
6136
6553
  }
6137
6554
  },
6555
+ {
6556
+ name: "StaticConfigParameters",
6557
+ type: {
6558
+ kind: "struct",
6559
+ fields: [
6560
+ {
6561
+ name: "pool_fees",
6562
+ type: {
6563
+ defined: {
6564
+ name: "PoolFeeParameters"
6565
+ }
6566
+ }
6567
+ },
6568
+ {
6569
+ name: "sqrt_min_price",
6570
+ type: "u128"
6571
+ },
6572
+ {
6573
+ name: "sqrt_max_price",
6574
+ type: "u128"
6575
+ },
6576
+ {
6577
+ name: "vault_config_key",
6578
+ type: "pubkey"
6579
+ },
6580
+ {
6581
+ name: "pool_creator_authority",
6582
+ type: "pubkey"
6583
+ },
6584
+ {
6585
+ name: "activation_type",
6586
+ type: "u8"
6587
+ },
6588
+ {
6589
+ name: "collect_fee_mode",
6590
+ type: "u8"
6591
+ }
6592
+ ]
6593
+ }
6594
+ },
6138
6595
  {
6139
6596
  name: "SwapParameters",
6140
6597
  type: {
@@ -6405,6 +6862,12 @@ var MIN_SQRT_PRICE = new (0, _anchor.BN)("4295048016");
6405
6862
  var MAX_SQRT_PRICE = new (0, _anchor.BN)("79226673521066979257578248091");
6406
6863
  var MIN_CU_BUFFER = 5e4;
6407
6864
  var MAX_CU_BUFFER = 2e5;
6865
+ var DYNAMIC_FEE_FILTER_PERIOD_DEFAULT = 10;
6866
+ var DYNAMIC_FEE_DECAY_PERIOD_DEFAULT = 120;
6867
+ var DYNAMIC_FEE_REDUCTION_FACTOR_DEFAULT = 5e3;
6868
+ var BIN_STEP_BPS_DEFAULT = 1;
6869
+ var BIN_STEP_BPS_U128_DEFAULT = new (0, _anchor.BN)("1844674407370955");
6870
+ var MAX_PRICE_CHANGE_BPS_DEFAULT = 1500;
6408
6871
 
6409
6872
  // src/pda.ts
6410
6873
  function getFirstKey(key1, key2) {
@@ -6515,10 +6978,10 @@ var _bytes = require('@coral-xyz/anchor/dist/cjs/utils/bytes');
6515
6978
  function getTokenProgram(flag) {
6516
6979
  return flag == 0 ? _spltoken.TOKEN_PROGRAM_ID : _spltoken.TOKEN_2022_PROGRAM_ID;
6517
6980
  }
6518
- var getTokenDecimals = (connection, mint) => __async(void 0, null, function* () {
6981
+ var getTokenDecimals = (connection, mint) => __async(null, null, function* () {
6519
6982
  return (yield _spltoken.getMint.call(void 0, connection, mint)).decimals;
6520
6983
  });
6521
- var getOrCreateATAInstruction = (_0, _1, _2, ..._3) => __async(void 0, [_0, _1, _2, ..._3], function* (connection, tokenMint, owner, payer = owner, allowOwnerOffCurve = true, tokenProgram) {
6984
+ var getOrCreateATAInstruction = (_0, _1, _2, ..._3) => __async(null, [_0, _1, _2, ..._3], function* (connection, tokenMint, owner, payer = owner, allowOwnerOffCurve = true, tokenProgram) {
6522
6985
  const toAccount = _spltoken.getAssociatedTokenAddressSync.call(void 0,
6523
6986
  tokenMint,
6524
6987
  owner,
@@ -6564,7 +7027,7 @@ var wrapSOLInstruction = (from, to, amount) => {
6564
7027
  })
6565
7028
  ];
6566
7029
  };
6567
- var unwrapSOLInstruction = (owner, allowOwnerOffCurve = true) => __async(void 0, null, function* () {
7030
+ var unwrapSOLInstruction = (_0, ..._1) => __async(null, [_0, ..._1], function* (owner, receiver = owner, allowOwnerOffCurve = true) {
6568
7031
  const wSolATAAccount = _spltoken.getAssociatedTokenAddressSync.call(void 0,
6569
7032
  _spltoken.NATIVE_MINT,
6570
7033
  owner,
@@ -6573,7 +7036,7 @@ var unwrapSOLInstruction = (owner, allowOwnerOffCurve = true) => __async(void 0,
6573
7036
  if (wSolATAAccount) {
6574
7037
  const closedWrappedSolInstruction = _spltoken.createCloseAccountInstruction.call(void 0,
6575
7038
  wSolATAAccount,
6576
- owner,
7039
+ receiver,
6577
7040
  owner,
6578
7041
  [],
6579
7042
  _spltoken.TOKEN_PROGRAM_ID
@@ -6803,6 +7266,7 @@ function getAmountBFromLiquidityDelta(liquidity, currentSqrtPrice, minSqrtPrice,
6803
7266
  }
6804
7267
 
6805
7268
  // src/helpers/fee.ts
7269
+
6806
7270
  function getBaseFeeNumerator(feeSchedulerMode, cliffFeeNumerator, period, reductionFactor) {
6807
7271
  let feeNumerator;
6808
7272
  if (feeSchedulerMode == 0 /* Linear */) {
@@ -6824,10 +7288,10 @@ function getDynamicFeeNumerator(volatilityAccumulator, binStep, variableFeeContr
6824
7288
  return vFee.add(new (0, _anchor.BN)(99999999999)).div(new (0, _anchor.BN)(1e11));
6825
7289
  }
6826
7290
  function getFeeNumerator(currentPoint, activationPoint, numberOfPeriod, periodFrequency, feeSchedulerMode, cliffFeeNumerator, reductionFactor, dynamicFeeParams) {
6827
- if (Number(periodFrequency) == 0) {
7291
+ if (Number(periodFrequency) == 0 || new (0, _anchor.BN)(currentPoint).lt(activationPoint)) {
6828
7292
  return cliffFeeNumerator;
6829
7293
  }
6830
- const period = new (0, _anchor.BN)(currentPoint).lt(activationPoint) ? new (0, _anchor.BN)(numberOfPeriod) : _anchor.BN.min(
7294
+ const period = _anchor.BN.min(
6831
7295
  new (0, _anchor.BN)(numberOfPeriod),
6832
7296
  new (0, _anchor.BN)(currentPoint).sub(activationPoint).div(periodFrequency)
6833
7297
  );
@@ -6872,19 +7336,111 @@ function getSwapAmount(inAmount, sqrtPrice, liquidity, tradeFeeNumerator, aToB,
6872
7336
  totalFee = getTotalFeeOnAmount(inAmount, tradeFeeNumerator);
6873
7337
  actualInAmount = inAmount.sub(totalFee);
6874
7338
  }
7339
+ const nextSqrtPrice = getNextSqrtPrice(
7340
+ actualInAmount,
7341
+ sqrtPrice,
7342
+ liquidity,
7343
+ aToB
7344
+ );
6875
7345
  const outAmount = aToB ? getAmountBFromLiquidityDelta(
6876
7346
  liquidity,
6877
7347
  sqrtPrice,
6878
- getNextSqrtPrice(actualInAmount, sqrtPrice, liquidity, true),
7348
+ nextSqrtPrice,
6879
7349
  1 /* Down */
6880
7350
  ) : getAmountAFromLiquidityDelta(
6881
7351
  liquidity,
6882
7352
  sqrtPrice,
6883
- getNextSqrtPrice(actualInAmount, sqrtPrice, liquidity, false),
7353
+ nextSqrtPrice,
6884
7354
  1 /* Down */
6885
7355
  );
6886
7356
  const amountOut = feeMode.feeOnInput ? outAmount : (totalFee = getTotalFeeOnAmount(outAmount, tradeFeeNumerator), outAmount.sub(totalFee));
6887
- return { amountOut, totalFee };
7357
+ return { amountOut, totalFee, nextSqrtPrice };
7358
+ }
7359
+ function bpsToFeeNumerator(bps) {
7360
+ return new (0, _anchor.BN)(bps * FEE_DENOMINATOR).divn(BASIS_POINT_MAX);
7361
+ }
7362
+ function feeNumeratorToBps(feeNumerator) {
7363
+ return feeNumerator.muln(BASIS_POINT_MAX).div(new (0, _anchor.BN)(FEE_DENOMINATOR)).toNumber();
7364
+ }
7365
+ function getBaseFeeParams(maxBaseFeeBps, minBaseFeeBps, feeSchedulerMode, numberOfPeriod, totalDuration) {
7366
+ if (maxBaseFeeBps == minBaseFeeBps) {
7367
+ if (numberOfPeriod != 0 || totalDuration != 0) {
7368
+ throw new Error("numberOfPeriod and totalDuration must both be zero");
7369
+ }
7370
+ return {
7371
+ cliffFeeNumerator: bpsToFeeNumerator(maxBaseFeeBps),
7372
+ numberOfPeriod: 0,
7373
+ periodFrequency: new (0, _anchor.BN)(0),
7374
+ reductionFactor: new (0, _anchor.BN)(0),
7375
+ feeSchedulerMode: 0
7376
+ };
7377
+ }
7378
+ if (numberOfPeriod <= 0) {
7379
+ throw new Error("Total periods must be greater than zero");
7380
+ }
7381
+ if (maxBaseFeeBps > feeNumeratorToBps(new (0, _anchor.BN)(MAX_FEE_NUMERATOR))) {
7382
+ throw new Error(
7383
+ `maxBaseFeeBps (${maxBaseFeeBps} bps) exceeds maximum allowed value of ${feeNumeratorToBps(
7384
+ new (0, _anchor.BN)(MAX_FEE_NUMERATOR)
7385
+ )} bps`
7386
+ );
7387
+ }
7388
+ if (minBaseFeeBps > maxBaseFeeBps) {
7389
+ throw new Error(
7390
+ "minBaseFee bps must be less than or equal to maxBaseFee bps"
7391
+ );
7392
+ }
7393
+ if (numberOfPeriod == 0 || totalDuration == 0) {
7394
+ throw new Error(
7395
+ "numberOfPeriod and totalDuration must both greater than zero"
7396
+ );
7397
+ }
7398
+ const maxBaseFeeNumerator = bpsToFeeNumerator(maxBaseFeeBps);
7399
+ const minBaseFeeNumerator = bpsToFeeNumerator(minBaseFeeBps);
7400
+ const periodFrequency = new (0, _anchor.BN)(totalDuration / numberOfPeriod);
7401
+ let reductionFactor;
7402
+ if (feeSchedulerMode == 0 /* Linear */) {
7403
+ const totalReduction = maxBaseFeeNumerator.sub(minBaseFeeNumerator);
7404
+ reductionFactor = totalReduction.divn(numberOfPeriod);
7405
+ } else {
7406
+ const ratio = minBaseFeeNumerator.toNumber() / maxBaseFeeNumerator.toNumber();
7407
+ const decayBase = Math.pow(ratio, 1 / numberOfPeriod);
7408
+ reductionFactor = new (0, _anchor.BN)(BASIS_POINT_MAX * (1 - decayBase));
7409
+ }
7410
+ return {
7411
+ cliffFeeNumerator: maxBaseFeeNumerator,
7412
+ numberOfPeriod,
7413
+ periodFrequency,
7414
+ reductionFactor,
7415
+ feeSchedulerMode
7416
+ };
7417
+ }
7418
+ function getDynamicFeeParams(baseFeeBps, maxPriceChangeBps = MAX_PRICE_CHANGE_BPS_DEFAULT) {
7419
+ if (maxPriceChangeBps > MAX_PRICE_CHANGE_BPS_DEFAULT) {
7420
+ throw new Error(
7421
+ `maxPriceChangeBps (${maxPriceChangeBps} bps) must be less than or equal to ${MAX_PRICE_CHANGE_BPS_DEFAULT}`
7422
+ );
7423
+ }
7424
+ const priceRatio = maxPriceChangeBps / BASIS_POINT_MAX + 1;
7425
+ const sqrtPriceRatioQ64 = new (0, _anchor.BN)(
7426
+ _decimaljs2.default.sqrt(priceRatio.toString()).mul(_decimaljs2.default.pow(2, 64)).floor().toFixed()
7427
+ );
7428
+ const deltaBinId = sqrtPriceRatioQ64.sub(ONE).div(BIN_STEP_BPS_U128_DEFAULT).muln(2);
7429
+ const maxVolatilityAccumulator = new (0, _anchor.BN)(deltaBinId.muln(BASIS_POINT_MAX));
7430
+ const squareVfaBin = maxVolatilityAccumulator.mul(new (0, _anchor.BN)(BIN_STEP_BPS_DEFAULT)).pow(new (0, _anchor.BN)(2));
7431
+ const baseFeeNumerator = new (0, _anchor.BN)(bpsToFeeNumerator(baseFeeBps));
7432
+ const maxDynamicFeeNumerator = baseFeeNumerator.muln(20).divn(100);
7433
+ const vFee = maxDynamicFeeNumerator.mul(new (0, _anchor.BN)(1e11)).sub(new (0, _anchor.BN)(99999999999));
7434
+ const variableFeeControl = vFee.div(squareVfaBin);
7435
+ return {
7436
+ binStep: BIN_STEP_BPS_DEFAULT,
7437
+ binStepU128: BIN_STEP_BPS_U128_DEFAULT,
7438
+ filterPeriod: DYNAMIC_FEE_FILTER_PERIOD_DEFAULT,
7439
+ decayPeriod: DYNAMIC_FEE_DECAY_PERIOD_DEFAULT,
7440
+ reductionFactor: DYNAMIC_FEE_REDUCTION_FACTOR_DEFAULT,
7441
+ maxVolatilityAccumulator: maxVolatilityAccumulator.toNumber(),
7442
+ variableFeeControl: variableFeeControl.toNumber()
7443
+ };
6888
7444
  }
6889
7445
 
6890
7446
  // src/helpers/computeUnits.ts
@@ -6894,7 +7450,7 @@ function getSwapAmount(inAmount, sqrtPrice, liquidity, tradeFeeNumerator, aToB,
6894
7450
 
6895
7451
 
6896
7452
 
6897
- var getSimulationComputeUnits = (connection, instructions, payer, lookupTables, commitment = "confirmed") => __async(void 0, null, function* () {
7453
+ var getSimulationComputeUnits = (connection, instructions, payer, lookupTables, commitment = "confirmed") => __async(null, null, function* () {
6898
7454
  var _a, _b, _c;
6899
7455
  const testInstructions = [
6900
7456
  // Set an arbitrarily high number in simulation
@@ -6926,7 +7482,7 @@ var getSimulationComputeUnits = (connection, instructions, payer, lookupTables,
6926
7482
  }
6927
7483
  return rpcResponse.value.unitsConsumed || null;
6928
7484
  });
6929
- var getEstimatedComputeUnitUsageWithBuffer = (connection, instructions, feePayer, buffer) => __async(void 0, null, function* () {
7485
+ var getEstimatedComputeUnitUsageWithBuffer = (connection, instructions, feePayer, buffer) => __async(null, null, function* () {
6930
7486
  if (!buffer) {
6931
7487
  buffer = 0.1;
6932
7488
  }
@@ -6949,7 +7505,7 @@ var getEstimatedComputeUnitUsageWithBuffer = (connection, instructions, feePayer
6949
7505
  }
6950
7506
  return estimatedComputeUnitUsage + extraComputeUnitBuffer;
6951
7507
  });
6952
- var getEstimatedComputeUnitIxWithBuffer = (connection, instructions, feePayer, buffer) => __async(void 0, null, function* () {
7508
+ var getEstimatedComputeUnitIxWithBuffer = (connection, instructions, feePayer, buffer) => __async(null, null, function* () {
6953
7509
  const units = yield getEstimatedComputeUnitUsageWithBuffer(
6954
7510
  connection,
6955
7511
  instructions,
@@ -6973,9 +7529,9 @@ var getMinAmountWithSlippage = (amount, rate) => {
6973
7529
  const slippage = (100 - rate) / 100 * BASIS_POINT_MAX;
6974
7530
  return amount.mul(new (0, _anchor.BN)(slippage)).div(new (0, _anchor.BN)(BASIS_POINT_MAX));
6975
7531
  };
6976
- var getPriceImpact = (actualAmount, idealAmount) => {
6977
- const diff = idealAmount.sub(actualAmount);
6978
- return new (0, _decimaljs2.default)(diff.toString()).div(new (0, _decimaljs2.default)(idealAmount.toString())).mul(100).toNumber();
7532
+ var getPriceImpact = (nextSqrtPrice, currentSqrtPrice) => {
7533
+ const diff = nextSqrtPrice.pow(new (0, _anchor.BN)(2)).sub(currentSqrtPrice.pow(new (0, _anchor.BN)(2))).abs();
7534
+ return new (0, _decimaljs2.default)(diff.toString()).div(new (0, _decimaljs2.default)(currentSqrtPrice.pow(new (0, _anchor.BN)(2)).toString())).mul(100).toNumber();
6979
7535
  };
6980
7536
  var getPriceFromSqrtPrice = (sqrtPrice, tokenADecimal, tokenBDecimal) => {
6981
7537
  const decimalSqrtPrice = new (0, _decimaljs2.default)(sqrtPrice.toString());
@@ -7185,13 +7741,7 @@ var CpAmm = class {
7185
7741
  });
7186
7742
  this.poolAuthority = derivePoolAuthority();
7187
7743
  }
7188
- /**
7189
- * Returns the Anchor program instance.
7190
- * @returns The AmmProgram instance.
7191
- */
7192
- getProgram() {
7193
- return this._program;
7194
- }
7744
+ //// ANCHOR: PRIVATE FUNCTIONS //////
7195
7745
  /**
7196
7746
  * Prepares token accounts for a transaction by retrieving or creating associated token accounts.
7197
7747
  * @private
@@ -7203,8 +7753,17 @@ var CpAmm = class {
7203
7753
  * @returns {Promise<{tokenAAta: PublicKey, tokenBAta: PublicKey, instructions: TransactionInstruction[]}>}
7204
7754
  * The token account addresses and any instructions needed to create them
7205
7755
  */
7206
- prepareTokenAccounts(owner, tokenAMint, tokenBMint, tokenAProgram, tokenBProgram) {
7756
+ prepareTokenAccounts(params) {
7207
7757
  return __async(this, null, function* () {
7758
+ const {
7759
+ payer,
7760
+ tokenAOwner,
7761
+ tokenBOwner,
7762
+ tokenAMint,
7763
+ tokenBMint,
7764
+ tokenAProgram,
7765
+ tokenBProgram
7766
+ } = params;
7208
7767
  const instructions = [];
7209
7768
  const [
7210
7769
  { ataPubkey: tokenAAta, ix: createInputTokenAccountIx },
@@ -7213,16 +7772,16 @@ var CpAmm = class {
7213
7772
  getOrCreateATAInstruction(
7214
7773
  this._program.provider.connection,
7215
7774
  tokenAMint,
7216
- owner,
7217
- owner,
7775
+ tokenAOwner,
7776
+ payer,
7218
7777
  true,
7219
7778
  tokenAProgram
7220
7779
  ),
7221
7780
  getOrCreateATAInstruction(
7222
7781
  this._program.provider.connection,
7223
7782
  tokenBMint,
7224
- owner,
7225
- owner,
7783
+ tokenBOwner,
7784
+ payer,
7226
7785
  true,
7227
7786
  tokenBProgram
7228
7787
  )
@@ -7532,6 +8091,132 @@ var CpAmm = class {
7532
8091
  };
7533
8092
  });
7534
8093
  }
8094
+ /**
8095
+ * Private helper method to prepare common customizable pool creation logic
8096
+ * @param {PrepareCustomizablePoolParams} params - Common parameters for pool creation
8097
+ * @returns Prepared transaction data including instructions and accounts
8098
+ */
8099
+ prepareCreatePoolParams(params) {
8100
+ return __async(this, null, function* () {
8101
+ const {
8102
+ pool,
8103
+ tokenAMint,
8104
+ tokenBMint,
8105
+ tokenAAmount,
8106
+ tokenBAmount,
8107
+ payer,
8108
+ positionNft,
8109
+ tokenAProgram,
8110
+ tokenBProgram
8111
+ } = params;
8112
+ const position = derivePositionAddress(positionNft);
8113
+ const positionNftAccount = derivePositionNftAccount(positionNft);
8114
+ const tokenAVault = deriveTokenVaultAddress(tokenAMint, pool);
8115
+ const tokenBVault = deriveTokenVaultAddress(tokenBMint, pool);
8116
+ const {
8117
+ tokenAAta: payerTokenA,
8118
+ tokenBAta: payerTokenB,
8119
+ instructions: preInstructions
8120
+ } = yield this.prepareTokenAccounts({
8121
+ payer,
8122
+ tokenAOwner: payer,
8123
+ tokenBOwner: payer,
8124
+ tokenAMint,
8125
+ tokenBMint,
8126
+ tokenAProgram,
8127
+ tokenBProgram
8128
+ });
8129
+ if (tokenAMint.equals(_spltoken.NATIVE_MINT)) {
8130
+ const wrapSOLIx = wrapSOLInstruction(
8131
+ payer,
8132
+ payerTokenA,
8133
+ BigInt(tokenAAmount.toString())
8134
+ );
8135
+ preInstructions.push(...wrapSOLIx);
8136
+ }
8137
+ if (tokenBMint.equals(_spltoken.NATIVE_MINT)) {
8138
+ const wrapSOLIx = wrapSOLInstruction(
8139
+ payer,
8140
+ payerTokenB,
8141
+ BigInt(tokenBAmount.toString())
8142
+ );
8143
+ preInstructions.push(...wrapSOLIx);
8144
+ }
8145
+ const tokenBadgeAccounts = this.getTokenBadgeAccounts(
8146
+ tokenAMint,
8147
+ tokenBMint
8148
+ );
8149
+ return {
8150
+ position,
8151
+ positionNftAccount,
8152
+ tokenAVault,
8153
+ tokenBVault,
8154
+ payerTokenA,
8155
+ payerTokenB,
8156
+ preInstructions,
8157
+ tokenBadgeAccounts
8158
+ };
8159
+ });
8160
+ }
8161
+ /**
8162
+ * Sets up token accounts and instructions for fee claim operations.
8163
+ * @private
8164
+ * @param {SetupFeeClaimAccountsParams} params - Parameters for setting up fee claim accounts.
8165
+ * @returns Token accounts and instructions for fee claiming.
8166
+ */
8167
+ setupFeeClaimAccounts(params) {
8168
+ return __async(this, null, function* () {
8169
+ const {
8170
+ payer,
8171
+ owner,
8172
+ tokenAMint,
8173
+ tokenBMint,
8174
+ tokenAProgram,
8175
+ tokenBProgram,
8176
+ receiver,
8177
+ tempWSolAccount
8178
+ } = params;
8179
+ const tokenAIsSOL = tokenAMint.equals(_spltoken.NATIVE_MINT);
8180
+ const tokenBIsSOL = tokenBMint.equals(_spltoken.NATIVE_MINT);
8181
+ const hasSolToken = tokenAIsSOL || tokenBIsSOL;
8182
+ const preInstructions = [];
8183
+ const postInstructions = [];
8184
+ let tokenAAccount;
8185
+ let tokenBAccount;
8186
+ let tokenAOwner = owner;
8187
+ let tokenBOwner = owner;
8188
+ if (receiver) {
8189
+ tokenAOwner = tokenAIsSOL ? tempWSolAccount : receiver;
8190
+ tokenBOwner = tokenBIsSOL ? tempWSolAccount : receiver;
8191
+ }
8192
+ const { tokenAAta, tokenBAta, instructions } = yield this.prepareTokenAccounts({
8193
+ payer,
8194
+ tokenAOwner,
8195
+ tokenBOwner,
8196
+ tokenAMint,
8197
+ tokenBMint,
8198
+ tokenAProgram,
8199
+ tokenBProgram
8200
+ });
8201
+ tokenAAccount = tokenAAta;
8202
+ tokenBAccount = tokenBAta;
8203
+ preInstructions.push(...instructions);
8204
+ if (hasSolToken) {
8205
+ const closeWrappedSOLIx = yield unwrapSOLInstruction(
8206
+ tempWSolAccount != null ? tempWSolAccount : owner,
8207
+ receiver != null ? receiver : owner
8208
+ );
8209
+ closeWrappedSOLIx && postInstructions.push(closeWrappedSOLIx);
8210
+ }
8211
+ return {
8212
+ tokenAAccount,
8213
+ tokenBAccount,
8214
+ preInstructions,
8215
+ postInstructions
8216
+ };
8217
+ });
8218
+ }
8219
+ //// ANCHOR: GETTER/FETCHER FUNCTIONS //////
7535
8220
  /**
7536
8221
  * Fetches the Config state of the program.
7537
8222
  * @param config - Public key of the config account.
@@ -7806,7 +8491,7 @@ var CpAmm = class {
7806
8491
  reductionFactor,
7807
8492
  dynamicFeeParams
7808
8493
  );
7809
- const { amountOut, totalFee } = getSwapAmount(
8494
+ const { amountOut, totalFee, nextSqrtPrice } = getSwapAmount(
7810
8495
  actualAmountIn,
7811
8496
  sqrtPriceQ64,
7812
8497
  liquidityQ64,
@@ -7832,7 +8517,7 @@ var CpAmm = class {
7832
8517
  swapOutAmount: actualAmountOut,
7833
8518
  minSwapOutAmount,
7834
8519
  totalFee,
7835
- priceImpact: getPriceImpact(minSwapOutAmount, actualAmountOut)
8520
+ priceImpact: getPriceImpact(nextSqrtPrice, sqrtPriceQ64)
7836
8521
  };
7837
8522
  }
7838
8523
  /**
@@ -7855,13 +8540,11 @@ var CpAmm = class {
7855
8540
  maxSqrtPrice,
7856
8541
  sqrtPrice
7857
8542
  } = params;
7858
- const actualAmountIn = inputTokenInfo ? inAmount.sub(
7859
- calculateTransferFeeIncludedAmount(
7860
- inAmount,
7861
- inputTokenInfo.mint,
7862
- inputTokenInfo.currentEpoch
7863
- ).transferFee
7864
- ) : inAmount;
8543
+ const actualAmountIn = inputTokenInfo ? calculateTransferFeeExcludedAmount(
8544
+ inAmount,
8545
+ inputTokenInfo.mint,
8546
+ inputTokenInfo.currentEpoch
8547
+ ).amount : inAmount;
7865
8548
  const { liquidityDelta, rawAmount } = isTokenA ? {
7866
8549
  liquidityDelta: getLiquidityDeltaFromAmountA(
7867
8550
  actualAmountIn,
@@ -8036,6 +8719,7 @@ var CpAmm = class {
8036
8719
  liquidityDelta
8037
8720
  };
8038
8721
  }
8722
+ //// ANCHOR: MAIN ENDPOINT //////
8039
8723
  /**
8040
8724
  * Builds a transaction to create a permissionless pool.
8041
8725
  * @param params - Parameters for pool creation.
@@ -8056,44 +8740,40 @@ var CpAmm = class {
8056
8740
  tokenAAmount,
8057
8741
  tokenBAmount,
8058
8742
  tokenAProgram,
8059
- tokenBProgram
8743
+ tokenBProgram,
8744
+ isLockLiquidity
8060
8745
  } = params;
8061
8746
  const pool = derivePoolAddress(config, tokenAMint, tokenBMint);
8062
- const position = derivePositionAddress(positionNft);
8063
- const positionNftAccount = derivePositionNftAccount(positionNft);
8064
- const tokenAVault = deriveTokenVaultAddress(tokenAMint, pool);
8065
- const tokenBVault = deriveTokenVaultAddress(tokenBMint, pool);
8066
8747
  const {
8067
- tokenAAta: payerTokenA,
8068
- tokenBAta: payerTokenB,
8069
- instructions: preInstructions
8070
- } = yield this.prepareTokenAccounts(
8071
- payer,
8748
+ position,
8749
+ positionNftAccount,
8750
+ tokenAVault,
8751
+ tokenBVault,
8752
+ payerTokenA,
8753
+ payerTokenB,
8754
+ preInstructions,
8755
+ tokenBadgeAccounts
8756
+ } = yield this.prepareCreatePoolParams({
8757
+ pool,
8072
8758
  tokenAMint,
8073
8759
  tokenBMint,
8760
+ tokenAAmount,
8761
+ tokenBAmount,
8762
+ payer,
8763
+ positionNft,
8074
8764
  tokenAProgram,
8075
8765
  tokenBProgram
8076
- );
8077
- if (tokenAMint.equals(_spltoken.NATIVE_MINT)) {
8078
- const wrapSOLIx = wrapSOLInstruction(
8079
- payer,
8080
- payerTokenA,
8081
- BigInt(tokenAAmount.toString())
8082
- );
8083
- preInstructions.push(...wrapSOLIx);
8084
- }
8085
- if (tokenBMint.equals(_spltoken.NATIVE_MINT)) {
8086
- const wrapSOLIx = wrapSOLInstruction(
8087
- payer,
8088
- payerTokenB,
8089
- BigInt(tokenBAmount.toString())
8090
- );
8091
- preInstructions.push(...wrapSOLIx);
8766
+ });
8767
+ const postInstruction = [];
8768
+ if (isLockLiquidity) {
8769
+ const permanentLockIx = yield this._program.methods.permanentLockPosition(liquidityDelta).accountsPartial({
8770
+ position,
8771
+ positionNftAccount,
8772
+ pool,
8773
+ owner: creator
8774
+ }).instruction();
8775
+ postInstruction.push(permanentLockIx);
8092
8776
  }
8093
- const tokenBadgeAccounts = this.getTokenBadgeAccounts(
8094
- tokenAMint,
8095
- tokenBMint
8096
- );
8097
8777
  const tx = yield this._program.methods.initializePool({
8098
8778
  liquidity: liquidityDelta,
8099
8779
  sqrtPrice: initSqrtPrice,
@@ -8117,7 +8797,7 @@ var CpAmm = class {
8117
8797
  tokenAProgram,
8118
8798
  tokenBProgram,
8119
8799
  systemProgram: _web3js.SystemProgram.programId
8120
- }).preInstructions(preInstructions).remainingAccounts(tokenBadgeAccounts).transaction();
8800
+ }).preInstructions(preInstructions).postInstructions(postInstruction).remainingAccounts(tokenBadgeAccounts).transaction();
8121
8801
  return tx;
8122
8802
  });
8123
8803
  }
@@ -8146,45 +8826,40 @@ var CpAmm = class {
8146
8826
  activationPoint,
8147
8827
  activationType,
8148
8828
  tokenAProgram,
8149
- tokenBProgram
8829
+ tokenBProgram,
8830
+ isLockLiquidity
8150
8831
  } = params;
8151
8832
  const pool = deriveCustomizablePoolAddress(tokenAMint, tokenBMint);
8152
- const position = derivePositionAddress(positionNft);
8153
- const positionNftAccount = derivePositionNftAccount(positionNft);
8154
- const tokenAVault = deriveTokenVaultAddress(tokenAMint, pool);
8155
- const tokenBVault = deriveTokenVaultAddress(tokenBMint, pool);
8156
8833
  const {
8157
- tokenAAta: payerTokenA,
8158
- tokenBAta: payerTokenB,
8159
- instructions: preInstructions
8160
- } = yield this.prepareTokenAccounts(
8161
- payer,
8834
+ position,
8835
+ positionNftAccount,
8836
+ tokenAVault,
8837
+ tokenBVault,
8838
+ payerTokenA,
8839
+ payerTokenB,
8840
+ preInstructions,
8841
+ tokenBadgeAccounts
8842
+ } = yield this.prepareCreatePoolParams({
8843
+ pool,
8162
8844
  tokenAMint,
8163
8845
  tokenBMint,
8846
+ tokenAAmount,
8847
+ tokenBAmount: tokenBMint.equals(_spltoken.NATIVE_MINT) ? _bnjs.max.call(void 0, tokenBAmount, new (0, _anchor.BN)(1)) : tokenBAmount,
8848
+ payer,
8849
+ positionNft,
8164
8850
  tokenAProgram,
8165
8851
  tokenBProgram
8166
- );
8167
- if (tokenAMint.equals(_spltoken.NATIVE_MINT)) {
8168
- const wrapSOLIx = wrapSOLInstruction(
8169
- payer,
8170
- payerTokenA,
8171
- BigInt(tokenAAmount.toString())
8172
- );
8173
- preInstructions.push(...wrapSOLIx);
8174
- }
8175
- if (tokenBMint.equals(_spltoken.NATIVE_MINT)) {
8176
- const lamports = tokenBAmount.eq(new (0, _anchor.BN)(0)) ? new (0, _anchor.BN)(1) : tokenBAmount;
8177
- const wrapSOLIx = wrapSOLInstruction(
8178
- payer,
8179
- payerTokenB,
8180
- BigInt(lamports.toString())
8181
- );
8182
- preInstructions.push(...wrapSOLIx);
8852
+ });
8853
+ const postInstruction = [];
8854
+ if (isLockLiquidity) {
8855
+ const permanentLockIx = yield this._program.methods.permanentLockPosition(liquidityDelta).accountsPartial({
8856
+ position,
8857
+ positionNftAccount,
8858
+ pool,
8859
+ owner: creator
8860
+ }).instruction();
8861
+ postInstruction.push(permanentLockIx);
8183
8862
  }
8184
- const tokenBadgeAccounts = this.getTokenBadgeAccounts(
8185
- tokenAMint,
8186
- tokenBMint
8187
- );
8188
8863
  const transaction = yield this._program.methods.initializeCustomizablePool({
8189
8864
  poolFees,
8190
8865
  sqrtMinPrice,
@@ -8213,7 +8888,97 @@ var CpAmm = class {
8213
8888
  tokenAProgram,
8214
8889
  tokenBProgram,
8215
8890
  systemProgram: _web3js.SystemProgram.programId
8216
- }).preInstructions(preInstructions).remainingAccounts(tokenBadgeAccounts).transaction();
8891
+ }).preInstructions(preInstructions).postInstructions(postInstruction).remainingAccounts(tokenBadgeAccounts).transaction();
8892
+ return { tx: transaction, pool, position };
8893
+ });
8894
+ }
8895
+ createCustomPoolWithDynamicConfig(params) {
8896
+ return __async(this, null, function* () {
8897
+ const {
8898
+ tokenAMint,
8899
+ tokenBMint,
8900
+ tokenAAmount,
8901
+ tokenBAmount,
8902
+ sqrtMinPrice,
8903
+ sqrtMaxPrice,
8904
+ liquidityDelta,
8905
+ initSqrtPrice,
8906
+ payer,
8907
+ config,
8908
+ poolCreatorAuthority,
8909
+ creator,
8910
+ positionNft,
8911
+ poolFees,
8912
+ hasAlphaVault,
8913
+ collectFeeMode,
8914
+ activationPoint,
8915
+ activationType,
8916
+ tokenAProgram,
8917
+ tokenBProgram,
8918
+ isLockLiquidity
8919
+ } = params;
8920
+ const pool = derivePoolAddress(config, tokenAMint, tokenBMint);
8921
+ const {
8922
+ position,
8923
+ positionNftAccount,
8924
+ tokenAVault,
8925
+ tokenBVault,
8926
+ payerTokenA,
8927
+ payerTokenB,
8928
+ preInstructions,
8929
+ tokenBadgeAccounts
8930
+ } = yield this.prepareCreatePoolParams({
8931
+ pool,
8932
+ tokenAMint,
8933
+ tokenBMint,
8934
+ tokenAAmount,
8935
+ tokenBAmount,
8936
+ payer,
8937
+ positionNft,
8938
+ tokenAProgram,
8939
+ tokenBProgram
8940
+ });
8941
+ const postInstruction = [];
8942
+ if (isLockLiquidity) {
8943
+ const permanentLockIx = yield this._program.methods.permanentLockPosition(liquidityDelta).accountsPartial({
8944
+ position,
8945
+ positionNftAccount,
8946
+ pool,
8947
+ owner: creator
8948
+ }).instruction();
8949
+ postInstruction.push(permanentLockIx);
8950
+ }
8951
+ const transaction = yield this._program.methods.initializePoolWithDynamicConfig({
8952
+ poolFees,
8953
+ sqrtMinPrice,
8954
+ sqrtMaxPrice,
8955
+ hasAlphaVault,
8956
+ liquidity: liquidityDelta,
8957
+ sqrtPrice: initSqrtPrice,
8958
+ activationType,
8959
+ collectFeeMode,
8960
+ activationPoint
8961
+ }).accountsPartial({
8962
+ creator,
8963
+ positionNftAccount,
8964
+ positionNftMint: positionNft,
8965
+ payer,
8966
+ poolAuthority: this.poolAuthority,
8967
+ pool,
8968
+ position,
8969
+ poolCreatorAuthority,
8970
+ config,
8971
+ tokenAMint,
8972
+ tokenBMint,
8973
+ tokenAVault,
8974
+ tokenBVault,
8975
+ payerTokenA,
8976
+ payerTokenB,
8977
+ token2022Program: _spltoken.TOKEN_2022_PROGRAM_ID,
8978
+ tokenAProgram,
8979
+ tokenBProgram,
8980
+ systemProgram: _web3js.SystemProgram.programId
8981
+ }).preInstructions(preInstructions).postInstructions(postInstruction).remainingAccounts(tokenBadgeAccounts).transaction();
8217
8982
  return { tx: transaction, pool, position };
8218
8983
  });
8219
8984
  }
@@ -8256,13 +9021,15 @@ var CpAmm = class {
8256
9021
  tokenAAta: tokenAAccount,
8257
9022
  tokenBAta: tokenBAccount,
8258
9023
  instructions: preInstructions
8259
- } = yield this.prepareTokenAccounts(
8260
- owner,
9024
+ } = yield this.prepareTokenAccounts({
9025
+ payer: owner,
9026
+ tokenAOwner: owner,
9027
+ tokenBOwner: owner,
8261
9028
  tokenAMint,
8262
9029
  tokenBMint,
8263
9030
  tokenAProgram,
8264
9031
  tokenBProgram
8265
- );
9032
+ });
8266
9033
  if (tokenAMint.equals(_spltoken.NATIVE_MINT)) {
8267
9034
  const wrapSOLIx = wrapSOLInstruction(
8268
9035
  owner,
@@ -8334,8 +9101,6 @@ var CpAmm = class {
8334
9101
  tokenBAmountThreshold,
8335
9102
  tokenAMint,
8336
9103
  tokenBMint,
8337
- tokenAVault,
8338
- tokenBVault,
8339
9104
  tokenAProgram,
8340
9105
  tokenBProgram
8341
9106
  } = params;
@@ -8343,13 +9108,17 @@ var CpAmm = class {
8343
9108
  tokenAAta: tokenAAccount,
8344
9109
  tokenBAta: tokenBAccount,
8345
9110
  instructions: preInstructions
8346
- } = yield this.prepareTokenAccounts(
8347
- owner,
9111
+ } = yield this.prepareTokenAccounts({
9112
+ payer: owner,
9113
+ tokenAOwner: owner,
9114
+ tokenBOwner: owner,
8348
9115
  tokenAMint,
8349
9116
  tokenBMint,
8350
9117
  tokenAProgram,
8351
9118
  tokenBProgram
8352
- );
9119
+ });
9120
+ const tokenAVault = deriveTokenVaultAddress(tokenAMint, pool);
9121
+ const tokenBVault = deriveTokenVaultAddress(tokenBMint, pool);
8353
9122
  if (tokenAMint.equals(_spltoken.NATIVE_MINT)) {
8354
9123
  const wrapSOLIx = wrapSOLInstruction(
8355
9124
  owner,
@@ -8437,13 +9206,15 @@ var CpAmm = class {
8437
9206
  tokenAAta: tokenAAccount,
8438
9207
  tokenBAta: tokenBAccount,
8439
9208
  instructions: preInstructions
8440
- } = yield this.prepareTokenAccounts(
8441
- owner,
9209
+ } = yield this.prepareTokenAccounts({
9210
+ payer: owner,
9211
+ tokenAOwner: owner,
9212
+ tokenBOwner: owner,
8442
9213
  tokenAMint,
8443
9214
  tokenBMint,
8444
9215
  tokenAProgram,
8445
9216
  tokenBProgram
8446
- );
9217
+ });
8447
9218
  const postInstructions = [];
8448
9219
  if ([tokenAMint.toBase58(), tokenBMint.toBase58()].includes(
8449
9220
  _spltoken.NATIVE_MINT.toBase58()
@@ -8508,13 +9279,15 @@ var CpAmm = class {
8508
9279
  tokenAAta: tokenAAccount,
8509
9280
  tokenBAta: tokenBAccount,
8510
9281
  instructions: preInstructions
8511
- } = yield this.prepareTokenAccounts(
8512
- owner,
9282
+ } = yield this.prepareTokenAccounts({
9283
+ payer: owner,
9284
+ tokenAOwner: owner,
9285
+ tokenBOwner: owner,
8513
9286
  tokenAMint,
8514
9287
  tokenBMint,
8515
9288
  tokenAProgram,
8516
9289
  tokenBProgram
8517
- );
9290
+ });
8518
9291
  const postInstructions = [];
8519
9292
  if ([tokenAMint.toBase58(), tokenBMint.toBase58()].includes(
8520
9293
  _spltoken.NATIVE_MINT.toBase58()
@@ -8587,13 +9360,15 @@ var CpAmm = class {
8587
9360
  tokenAAta: inputTokenAccount,
8588
9361
  tokenBAta: outputTokenAccount,
8589
9362
  instructions: preInstructions
8590
- } = yield this.prepareTokenAccounts(
9363
+ } = yield this.prepareTokenAccounts({
8591
9364
  payer,
8592
- inputTokenMint,
8593
- outputTokenMint,
8594
- inputTokenProgram,
8595
- outputTokenProgram
8596
- );
9365
+ tokenAOwner: payer,
9366
+ tokenBOwner: payer,
9367
+ tokenAMint: inputTokenMint,
9368
+ tokenBMint: outputTokenMint,
9369
+ tokenAProgram: inputTokenProgram,
9370
+ tokenBProgram: outputTokenProgram
9371
+ });
8597
9372
  if (inputTokenMint.equals(_spltoken.NATIVE_MINT)) {
8598
9373
  const wrapSOLIx = wrapSOLInstruction(
8599
9374
  payer,
@@ -8693,67 +9468,6 @@ var CpAmm = class {
8693
9468
  return new (0, _web3js.Transaction)().add(instruction);
8694
9469
  });
8695
9470
  }
8696
- /**
8697
- * Builds a transaction to claim position fee rewards.
8698
- * @param {ClaimPositionFeeParams} params - Parameters for claiming position fee.
8699
- * @returns Transaction builder.
8700
- */
8701
- claimPositionFee(params) {
8702
- return __async(this, null, function* () {
8703
- const {
8704
- owner,
8705
- pool,
8706
- position,
8707
- positionNftAccount,
8708
- tokenAVault,
8709
- tokenBVault,
8710
- tokenAMint,
8711
- tokenBMint,
8712
- tokenAProgram,
8713
- tokenBProgram
8714
- } = params;
8715
- const {
8716
- tokenAAta: tokenAAccount,
8717
- tokenBAta: tokenBAccount,
8718
- instructions: preInstructions
8719
- } = yield this.prepareTokenAccounts(
8720
- owner,
8721
- tokenAMint,
8722
- tokenBMint,
8723
- tokenAProgram,
8724
- tokenBProgram
8725
- );
8726
- const postInstructions = [];
8727
- if ([tokenAMint.toBase58(), tokenBMint.toBase58()].includes(
8728
- _spltoken.NATIVE_MINT.toBase58()
8729
- )) {
8730
- const closeWrappedSOLIx = yield unwrapSOLInstruction(owner);
8731
- closeWrappedSOLIx && postInstructions.push(closeWrappedSOLIx);
8732
- }
8733
- const claimPositionFeeInstruction = yield this.buildClaimPositionFeeInstruction({
8734
- owner,
8735
- poolAuthority: this.poolAuthority,
8736
- pool,
8737
- position,
8738
- positionNftAccount,
8739
- tokenAAccount,
8740
- tokenBAccount,
8741
- tokenAVault,
8742
- tokenBVault,
8743
- tokenAMint,
8744
- tokenBMint,
8745
- tokenAProgram,
8746
- tokenBProgram
8747
- });
8748
- const transaction = new (0, _web3js.Transaction)();
8749
- transaction.add(
8750
- ...preInstructions.length > 0 ? preInstructions : [],
8751
- claimPositionFeeInstruction,
8752
- ...postInstructions.length > 0 ? postInstructions : []
8753
- );
8754
- return transaction;
8755
- });
8756
- }
8757
9471
  closePosition(params) {
8758
9472
  return __async(this, null, function* () {
8759
9473
  const { owner, pool, position, positionNftMint, positionNftAccount } = params;
@@ -8808,13 +9522,15 @@ var CpAmm = class {
8808
9522
  tokenAAta: tokenAAccount,
8809
9523
  tokenBAta: tokenBAccount,
8810
9524
  instructions: preInstructions
8811
- } = yield this.prepareTokenAccounts(
8812
- owner,
9525
+ } = yield this.prepareTokenAccounts({
9526
+ payer: owner,
9527
+ tokenAOwner: owner,
9528
+ tokenBOwner: owner,
8813
9529
  tokenAMint,
8814
9530
  tokenBMint,
8815
9531
  tokenAProgram,
8816
9532
  tokenBProgram
8817
- );
9533
+ });
8818
9534
  const postInstructions = [];
8819
9535
  if ([tokenAMint.toBase58(), tokenBMint.toBase58()].includes(
8820
9536
  _spltoken.NATIVE_MINT.toBase58()
@@ -8899,13 +9615,15 @@ var CpAmm = class {
8899
9615
  tokenAAta: tokenAAccount,
8900
9616
  tokenBAta: tokenBAccount,
8901
9617
  instructions: preInstructions
8902
- } = yield this.prepareTokenAccounts(
8903
- owner,
9618
+ } = yield this.prepareTokenAccounts({
9619
+ payer: owner,
9620
+ tokenAOwner: owner,
9621
+ tokenBOwner: owner,
8904
9622
  tokenAMint,
8905
9623
  tokenBMint,
8906
9624
  tokenAProgram,
8907
9625
  tokenBProgram
8908
- );
9626
+ });
8909
9627
  let positionBLiquidityDelta = positionBState.unlockedLiquidity;
8910
9628
  if (positionBVestings.length > 0) {
8911
9629
  const totalAvailableVestingLiquidity = positionBVestings.reduce(
@@ -8930,15 +9648,26 @@ var CpAmm = class {
8930
9648
  });
8931
9649
  refreshVestingInstruction && preInstructions.push(refreshVestingInstruction);
8932
9650
  }
9651
+ const tokenAWithdrawAmount = getAmountAFromLiquidityDelta(
9652
+ positionBLiquidityDelta,
9653
+ poolState.sqrtPrice,
9654
+ poolState.sqrtMaxPrice,
9655
+ 1 /* Down */
9656
+ );
9657
+ const tokenBWithdrawAmount = getAmountBFromLiquidityDelta(
9658
+ positionBLiquidityDelta,
9659
+ poolState.sqrtPrice,
9660
+ poolState.sqrtMinPrice,
9661
+ 1 /* Down */
9662
+ );
9663
+ const newLiquidityDelta = this.getLiquidityDelta({
9664
+ maxAmountTokenA: tokenAWithdrawAmount,
9665
+ maxAmountTokenB: tokenBWithdrawAmount,
9666
+ sqrtMaxPrice: poolState.sqrtMaxPrice,
9667
+ sqrtMinPrice: poolState.sqrtMinPrice,
9668
+ sqrtPrice: poolState.sqrtPrice
9669
+ });
8933
9670
  const transaction = new (0, _web3js.Transaction)();
8934
- if (poolState.tokenAMint.equals(_spltoken.NATIVE_MINT)) {
8935
- const wrapSOLIx = wrapSOLInstruction(owner, tokenAAccount, BigInt(1));
8936
- preInstructions.push(...wrapSOLIx);
8937
- }
8938
- if (poolState.tokenBMint.equals(_spltoken.NATIVE_MINT)) {
8939
- const wrapSOLIx = wrapSOLInstruction(owner, tokenBAccount, BigInt(1));
8940
- preInstructions.push(...wrapSOLIx);
8941
- }
8942
9671
  if (preInstructions.length > 0) {
8943
9672
  transaction.add(...preInstructions);
8944
9673
  }
@@ -8967,7 +9696,7 @@ var CpAmm = class {
8967
9696
  tokenBVault,
8968
9697
  tokenAProgram,
8969
9698
  tokenBProgram,
8970
- liquidityDelta: positionBLiquidityDelta,
9699
+ liquidityDelta: newLiquidityDelta,
8971
9700
  tokenAAmountThreshold: tokenAAmountAddLiquidityThreshold,
8972
9701
  tokenBAmountThreshold: tokenBAmountAddLiquidityThreshold
8973
9702
  });
@@ -9094,7 +9823,15 @@ var CpAmm = class {
9094
9823
  */
9095
9824
  claimPartnerFee(params) {
9096
9825
  return __async(this, null, function* () {
9097
- const { partner, pool, maxAmountA, maxAmountB } = params;
9826
+ const {
9827
+ feePayer,
9828
+ receiver,
9829
+ tempWSolAccount,
9830
+ partner,
9831
+ pool,
9832
+ maxAmountA,
9833
+ maxAmountB
9834
+ } = params;
9098
9835
  const poolState = yield this.fetchPoolState(pool);
9099
9836
  const {
9100
9837
  tokenAVault,
@@ -9106,38 +9843,159 @@ var CpAmm = class {
9106
9843
  } = poolState;
9107
9844
  const tokenAProgram = getTokenProgram(tokenAFlag);
9108
9845
  const tokenBProgram = getTokenProgram(tokenBFlag);
9846
+ const payer = feePayer != null ? feePayer : partner;
9847
+ const { tokenAAccount, tokenBAccount, preInstructions, postInstructions } = yield this.setupFeeClaimAccounts({
9848
+ payer,
9849
+ owner: partner,
9850
+ tokenAMint,
9851
+ tokenBMint,
9852
+ tokenAProgram,
9853
+ tokenBProgram,
9854
+ receiver,
9855
+ tempWSolAccount
9856
+ });
9857
+ return yield this._program.methods.claimPartnerFee(maxAmountA, maxAmountB).accountsPartial({
9858
+ poolAuthority: this.poolAuthority,
9859
+ pool,
9860
+ tokenAAccount,
9861
+ tokenBAccount,
9862
+ tokenAVault,
9863
+ tokenBVault,
9864
+ tokenAMint,
9865
+ tokenBMint,
9866
+ partner,
9867
+ tokenAProgram,
9868
+ tokenBProgram
9869
+ }).preInstructions(preInstructions).postInstructions(postInstructions).transaction();
9870
+ });
9871
+ }
9872
+ /**
9873
+ * Builds a transaction to claim position fee rewards.
9874
+ * @param {ClaimPositionFeeParams} params - Parameters for claiming position fee.
9875
+ * @returns Transaction builder.
9876
+ */
9877
+ claimPositionFee(params) {
9878
+ return __async(this, null, function* () {
9879
+ const {
9880
+ receiver,
9881
+ tempWSolAccount,
9882
+ feePayer,
9883
+ owner,
9884
+ pool,
9885
+ position,
9886
+ positionNftAccount,
9887
+ tokenAVault,
9888
+ tokenBVault,
9889
+ tokenAMint,
9890
+ tokenBMint,
9891
+ tokenAProgram,
9892
+ tokenBProgram
9893
+ } = params;
9894
+ const payer = feePayer != null ? feePayer : owner;
9895
+ const { tokenAAccount, tokenBAccount, preInstructions, postInstructions } = yield this.setupFeeClaimAccounts({
9896
+ payer,
9897
+ owner,
9898
+ tokenAMint,
9899
+ tokenBMint,
9900
+ tokenAProgram,
9901
+ tokenBProgram,
9902
+ receiver,
9903
+ tempWSolAccount
9904
+ });
9905
+ const claimPositionFeeInstruction = yield this.buildClaimPositionFeeInstruction({
9906
+ owner,
9907
+ poolAuthority: this.poolAuthority,
9908
+ pool,
9909
+ position,
9910
+ positionNftAccount,
9911
+ tokenAAccount,
9912
+ tokenBAccount,
9913
+ tokenAVault,
9914
+ tokenBVault,
9915
+ tokenAMint,
9916
+ tokenBMint,
9917
+ tokenAProgram,
9918
+ tokenBProgram
9919
+ });
9920
+ const transaction = new (0, _web3js.Transaction)();
9921
+ transaction.add(
9922
+ ...preInstructions.length > 0 ? preInstructions : [],
9923
+ claimPositionFeeInstruction,
9924
+ ...postInstructions.length > 0 ? postInstructions : []
9925
+ );
9926
+ return transaction;
9927
+ });
9928
+ }
9929
+ /**
9930
+ * Builds a transaction to claim position fee rewards.
9931
+ * @param {ClaimPositionFeeParams2} params - Parameters for claiming position fee.
9932
+ * @returns Transaction builder.
9933
+ */
9934
+ claimPositionFee2(params) {
9935
+ return __async(this, null, function* () {
9936
+ const {
9937
+ receiver,
9938
+ feePayer,
9939
+ owner,
9940
+ pool,
9941
+ position,
9942
+ positionNftAccount,
9943
+ tokenAVault,
9944
+ tokenBVault,
9945
+ tokenAMint,
9946
+ tokenBMint,
9947
+ tokenAProgram,
9948
+ tokenBProgram
9949
+ } = params;
9950
+ const payer = feePayer != null ? feePayer : owner;
9951
+ let tokenAOwner = receiver;
9952
+ let tokenBOwner = receiver;
9953
+ if (tokenAMint.equals(_spltoken.NATIVE_MINT)) {
9954
+ tokenAOwner = owner;
9955
+ }
9956
+ if (tokenBMint.equals(_spltoken.NATIVE_MINT)) {
9957
+ tokenBOwner = owner;
9958
+ }
9109
9959
  const {
9110
9960
  tokenAAta: tokenAAccount,
9111
9961
  tokenBAta: tokenBAccount,
9112
- instructions: preInstructions
9113
- } = yield this.prepareTokenAccounts(
9114
- partner,
9962
+ instructions: preInstruction
9963
+ } = yield this.prepareTokenAccounts({
9964
+ payer,
9965
+ tokenAOwner,
9966
+ tokenBOwner,
9115
9967
  tokenAMint,
9116
9968
  tokenBMint,
9117
9969
  tokenAProgram,
9118
9970
  tokenBProgram
9119
- );
9971
+ });
9120
9972
  const postInstructions = [];
9121
- if ([
9122
- poolState.tokenAMint.toBase58(),
9123
- poolState.tokenBMint.toBase58()
9124
- ].includes(_spltoken.NATIVE_MINT.toBase58())) {
9125
- const closeWrappedSOLIx = yield unwrapSOLInstruction(partner);
9973
+ if (tokenAMint.equals(_spltoken.NATIVE_MINT) || tokenBMint.equals(_spltoken.NATIVE_MINT)) {
9974
+ const closeWrappedSOLIx = yield unwrapSOLInstruction(owner, receiver);
9126
9975
  closeWrappedSOLIx && postInstructions.push(closeWrappedSOLIx);
9127
9976
  }
9128
- return yield this._program.methods.claimPartnerFee(maxAmountA, maxAmountB).accountsPartial({
9977
+ const claimPositionFeeInstruction = yield this.buildClaimPositionFeeInstruction({
9978
+ owner,
9129
9979
  poolAuthority: this.poolAuthority,
9130
9980
  pool,
9981
+ position,
9982
+ positionNftAccount,
9131
9983
  tokenAAccount,
9132
9984
  tokenBAccount,
9133
9985
  tokenAVault,
9134
9986
  tokenBVault,
9135
9987
  tokenAMint,
9136
9988
  tokenBMint,
9137
- partner,
9138
9989
  tokenAProgram,
9139
9990
  tokenBProgram
9140
- }).preInstructions(preInstructions).postInstructions(postInstructions).transaction();
9991
+ });
9992
+ const transaction = new (0, _web3js.Transaction)();
9993
+ transaction.add(
9994
+ ...preInstruction.length > 0 ? preInstruction : [],
9995
+ claimPositionFeeInstruction,
9996
+ ...postInstructions.length > 0 ? postInstructions : []
9997
+ );
9998
+ return transaction;
9141
9999
  });
9142
10000
  }
9143
10001
  /**
@@ -9148,6 +10006,7 @@ var CpAmm = class {
9148
10006
  claimReward(params) {
9149
10007
  return __async(this, null, function* () {
9150
10008
  const {
10009
+ feePayer,
9151
10010
  user,
9152
10011
  position,
9153
10012
  positionNftAccount,
@@ -9163,7 +10022,7 @@ var CpAmm = class {
9163
10022
  this._program.provider.connection,
9164
10023
  rewardInfo.mint,
9165
10024
  user,
9166
- user,
10025
+ feePayer != null ? feePayer : user,
9167
10026
  true,
9168
10027
  tokenProgram
9169
10028
  );
@@ -9258,5 +10117,15 @@ var index_default = cp_amm_default;
9258
10117
 
9259
10118
 
9260
10119
 
9261
- exports.ActivationPoint = ActivationPoint; exports.ActivationType = ActivationType; exports.BASIS_POINT_MAX = BASIS_POINT_MAX; exports.CP_AMM_PROGRAM_ID = CP_AMM_PROGRAM_ID; exports.CollectFeeMode = CollectFeeMode; exports.CpAmm = CpAmm; exports.FEE_DENOMINATOR = FEE_DENOMINATOR; exports.FeeSchedulerMode = FeeSchedulerMode; exports.LIQUIDITY_SCALE = LIQUIDITY_SCALE; exports.MAX_CU_BUFFER = MAX_CU_BUFFER; exports.MAX_FEE_NUMERATOR = MAX_FEE_NUMERATOR; exports.MAX_SQRT_PRICE = MAX_SQRT_PRICE; exports.MIN_CU_BUFFER = MIN_CU_BUFFER; exports.MIN_SQRT_PRICE = MIN_SQRT_PRICE; exports.ONE = ONE; exports.Rounding = Rounding; exports.SCALE_OFFSET = SCALE_OFFSET; exports.TradeDirection = TradeDirection; exports.calculateInitSqrtPrice = calculateInitSqrtPrice; exports.calculateTransferFeeExcludedAmount = calculateTransferFeeExcludedAmount; exports.calculateTransferFeeIncludedAmount = calculateTransferFeeIncludedAmount; exports.decimalToQ64 = decimalToQ64; exports.default = index_default; exports.deriveClaimFeeOperatorAddress = deriveClaimFeeOperatorAddress; exports.deriveConfigAddress = deriveConfigAddress; exports.deriveCustomizablePoolAddress = deriveCustomizablePoolAddress; exports.derivePoolAddress = derivePoolAddress; exports.derivePoolAuthority = derivePoolAuthority; exports.derivePositionAddress = derivePositionAddress; exports.derivePositionNftAccount = derivePositionNftAccount; exports.deriveRewardVaultAddress = deriveRewardVaultAddress; exports.deriveTokenBadgeAddress = deriveTokenBadgeAddress; exports.deriveTokenVaultAddress = deriveTokenVaultAddress; exports.getAllPositionNftAccountByOwner = getAllPositionNftAccountByOwner; exports.getAllUserPositionNftAccount = getAllUserPositionNftAccount; exports.getAmountAFromLiquidityDelta = getAmountAFromLiquidityDelta; exports.getAmountBFromLiquidityDelta = getAmountBFromLiquidityDelta; exports.getAvailableVestingLiquidity = getAvailableVestingLiquidity; exports.getBaseFeeNumerator = getBaseFeeNumerator; exports.getDynamicFeeNumerator = getDynamicFeeNumerator; exports.getEstimatedComputeUnitIxWithBuffer = getEstimatedComputeUnitIxWithBuffer; exports.getEstimatedComputeUnitUsageWithBuffer = getEstimatedComputeUnitUsageWithBuffer; exports.getFeeNumerator = getFeeNumerator; exports.getFirstKey = getFirstKey; exports.getLiquidityDeltaFromAmountA = getLiquidityDeltaFromAmountA; exports.getLiquidityDeltaFromAmountB = getLiquidityDeltaFromAmountB; exports.getMaxAmountWithSlippage = getMaxAmountWithSlippage; exports.getMinAmountWithSlippage = getMinAmountWithSlippage; exports.getNextSqrtPrice = getNextSqrtPrice; exports.getOrCreateATAInstruction = getOrCreateATAInstruction; exports.getPriceFromSqrtPrice = getPriceFromSqrtPrice; exports.getPriceImpact = getPriceImpact; exports.getSecondKey = getSecondKey; exports.getSimulationComputeUnits = getSimulationComputeUnits; exports.getSqrtPriceFromPrice = getSqrtPriceFromPrice; exports.getSwapAmount = getSwapAmount; exports.getTokenDecimals = getTokenDecimals; exports.getTokenProgram = getTokenProgram; exports.getTotalLockedLiquidity = getTotalLockedLiquidity; exports.getUnClaimReward = getUnClaimReward; exports.isVestingComplete = isVestingComplete; exports.mulDiv = mulDiv; exports.positionByPoolFilter = positionByPoolFilter; exports.pow = pow; exports.q64ToDecimal = q64ToDecimal; exports.unwrapSOLInstruction = unwrapSOLInstruction; exports.vestingByPositionFilter = vestingByPositionFilter; exports.wrapSOLInstruction = wrapSOLInstruction;
10120
+
10121
+
10122
+
10123
+
10124
+
10125
+
10126
+
10127
+
10128
+
10129
+
10130
+ exports.ActivationPoint = ActivationPoint; exports.ActivationType = ActivationType; exports.BASIS_POINT_MAX = BASIS_POINT_MAX; exports.BIN_STEP_BPS_DEFAULT = BIN_STEP_BPS_DEFAULT; exports.BIN_STEP_BPS_U128_DEFAULT = BIN_STEP_BPS_U128_DEFAULT; exports.CP_AMM_PROGRAM_ID = CP_AMM_PROGRAM_ID; exports.CollectFeeMode = CollectFeeMode; exports.CpAmm = CpAmm; exports.DYNAMIC_FEE_DECAY_PERIOD_DEFAULT = DYNAMIC_FEE_DECAY_PERIOD_DEFAULT; exports.DYNAMIC_FEE_FILTER_PERIOD_DEFAULT = DYNAMIC_FEE_FILTER_PERIOD_DEFAULT; exports.DYNAMIC_FEE_REDUCTION_FACTOR_DEFAULT = DYNAMIC_FEE_REDUCTION_FACTOR_DEFAULT; exports.FEE_DENOMINATOR = FEE_DENOMINATOR; exports.FeeSchedulerMode = FeeSchedulerMode; exports.LIQUIDITY_SCALE = LIQUIDITY_SCALE; exports.MAX_CU_BUFFER = MAX_CU_BUFFER; exports.MAX_FEE_NUMERATOR = MAX_FEE_NUMERATOR; exports.MAX_PRICE_CHANGE_BPS_DEFAULT = MAX_PRICE_CHANGE_BPS_DEFAULT; exports.MAX_SQRT_PRICE = MAX_SQRT_PRICE; exports.MIN_CU_BUFFER = MIN_CU_BUFFER; exports.MIN_SQRT_PRICE = MIN_SQRT_PRICE; exports.ONE = ONE; exports.Rounding = Rounding; exports.SCALE_OFFSET = SCALE_OFFSET; exports.TradeDirection = TradeDirection; exports.bpsToFeeNumerator = bpsToFeeNumerator; exports.calculateInitSqrtPrice = calculateInitSqrtPrice; exports.calculateTransferFeeExcludedAmount = calculateTransferFeeExcludedAmount; exports.calculateTransferFeeIncludedAmount = calculateTransferFeeIncludedAmount; exports.decimalToQ64 = decimalToQ64; exports.default = index_default; exports.deriveClaimFeeOperatorAddress = deriveClaimFeeOperatorAddress; exports.deriveConfigAddress = deriveConfigAddress; exports.deriveCustomizablePoolAddress = deriveCustomizablePoolAddress; exports.derivePoolAddress = derivePoolAddress; exports.derivePoolAuthority = derivePoolAuthority; exports.derivePositionAddress = derivePositionAddress; exports.derivePositionNftAccount = derivePositionNftAccount; exports.deriveRewardVaultAddress = deriveRewardVaultAddress; exports.deriveTokenBadgeAddress = deriveTokenBadgeAddress; exports.deriveTokenVaultAddress = deriveTokenVaultAddress; exports.feeNumeratorToBps = feeNumeratorToBps; exports.getAllPositionNftAccountByOwner = getAllPositionNftAccountByOwner; exports.getAllUserPositionNftAccount = getAllUserPositionNftAccount; exports.getAmountAFromLiquidityDelta = getAmountAFromLiquidityDelta; exports.getAmountBFromLiquidityDelta = getAmountBFromLiquidityDelta; exports.getAvailableVestingLiquidity = getAvailableVestingLiquidity; exports.getBaseFeeNumerator = getBaseFeeNumerator; exports.getBaseFeeParams = getBaseFeeParams; exports.getDynamicFeeNumerator = getDynamicFeeNumerator; exports.getDynamicFeeParams = getDynamicFeeParams; exports.getEstimatedComputeUnitIxWithBuffer = getEstimatedComputeUnitIxWithBuffer; exports.getEstimatedComputeUnitUsageWithBuffer = getEstimatedComputeUnitUsageWithBuffer; exports.getFeeNumerator = getFeeNumerator; exports.getFirstKey = getFirstKey; exports.getLiquidityDeltaFromAmountA = getLiquidityDeltaFromAmountA; exports.getLiquidityDeltaFromAmountB = getLiquidityDeltaFromAmountB; exports.getMaxAmountWithSlippage = getMaxAmountWithSlippage; exports.getMinAmountWithSlippage = getMinAmountWithSlippage; exports.getNextSqrtPrice = getNextSqrtPrice; exports.getOrCreateATAInstruction = getOrCreateATAInstruction; exports.getPriceFromSqrtPrice = getPriceFromSqrtPrice; exports.getPriceImpact = getPriceImpact; exports.getSecondKey = getSecondKey; exports.getSimulationComputeUnits = getSimulationComputeUnits; exports.getSqrtPriceFromPrice = getSqrtPriceFromPrice; exports.getSwapAmount = getSwapAmount; exports.getTokenDecimals = getTokenDecimals; exports.getTokenProgram = getTokenProgram; exports.getTotalLockedLiquidity = getTotalLockedLiquidity; exports.getUnClaimReward = getUnClaimReward; exports.isVestingComplete = isVestingComplete; exports.mulDiv = mulDiv; exports.positionByPoolFilter = positionByPoolFilter; exports.pow = pow; exports.q64ToDecimal = q64ToDecimal; exports.unwrapSOLInstruction = unwrapSOLInstruction; exports.vestingByPositionFilter = vestingByPositionFilter; exports.wrapSOLInstruction = wrapSOLInstruction;
9262
10131
  //# sourceMappingURL=index.js.map