@elizaos/plugin-wallet 2.0.0-beta.1 → 2.0.3-beta.6

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 (356) hide show
  1. package/README.md +70 -45
  2. package/auto-enable.ts +1 -1
  3. package/dist/actions/failure-codes.d.ts +12 -0
  4. package/dist/actions/index.d.ts +1 -0
  5. package/dist/analytics/birdeye/actions/wallet-search-address.d.ts +7 -0
  6. package/dist/analytics/birdeye/birdeye-task.d.ts +27 -0
  7. package/dist/analytics/birdeye/birdeye.d.ts +140 -0
  8. package/dist/analytics/birdeye/constants.d.ts +68 -0
  9. package/dist/analytics/birdeye/providers/agent-portfolio-provider.d.ts +8 -0
  10. package/dist/analytics/birdeye/providers/market.d.ts +18 -0
  11. package/dist/analytics/birdeye/providers/portfolio-factory.d.ts +10 -0
  12. package/dist/analytics/birdeye/providers/trending.d.ts +19 -0
  13. package/dist/analytics/birdeye/providers/wallet.d.ts +5 -0
  14. package/dist/analytics/birdeye/search-category.d.ts +52 -0
  15. package/dist/analytics/birdeye/service.d.ts +94 -0
  16. package/dist/analytics/birdeye/types/api/common.d.ts +199 -0
  17. package/dist/analytics/birdeye/types/api/defi.d.ts +187 -0
  18. package/dist/analytics/birdeye/types/api/pair.d.ts +182 -0
  19. package/dist/analytics/birdeye/types/api/search.d.ts +64 -0
  20. package/dist/analytics/birdeye/types/api/token.d.ts +580 -0
  21. package/dist/analytics/birdeye/types/api/trader.d.ts +70 -0
  22. package/dist/analytics/birdeye/types/api/wallet.d.ts +161 -0
  23. package/dist/analytics/birdeye/types/shared.d.ts +83 -0
  24. package/dist/analytics/birdeye/utils.d.ts +74 -0
  25. package/dist/analytics/dexscreener/errors.d.ts +2 -0
  26. package/dist/analytics/dexscreener/index.d.ts +3 -0
  27. package/dist/analytics/dexscreener/search-category.d.ts +3 -0
  28. package/dist/analytics/dexscreener/service.d.ts +34 -0
  29. package/dist/analytics/dexscreener/types.d.ts +131 -0
  30. package/dist/analytics/lpinfo/index.d.ts +31 -0
  31. package/dist/analytics/lpinfo/kamino/index.d.ts +7 -0
  32. package/dist/analytics/lpinfo/kamino/providers/kaminoLiquidityProvider.d.ts +6 -0
  33. package/dist/analytics/lpinfo/kamino/providers/kaminoPoolProvider.d.ts +6 -0
  34. package/dist/analytics/lpinfo/kamino/providers/kaminoProvider.d.ts +6 -0
  35. package/dist/analytics/lpinfo/kamino/services/kaminoLiquidityService.d.ts +203 -0
  36. package/dist/analytics/lpinfo/kamino/services/kaminoService.d.ts +171 -0
  37. package/dist/analytics/lpinfo/steer/index.d.ts +7 -0
  38. package/dist/analytics/lpinfo/steer/providers/steerLiquidityProvider.d.ts +6 -0
  39. package/dist/analytics/lpinfo/steer/services/steerLiquidityService.d.ts +208 -0
  40. package/dist/analytics/lpinfo/steer/steer-display-types.d.ts +97 -0
  41. package/dist/analytics/news/index.d.ts +32 -0
  42. package/dist/analytics/news/interfaces/types.d.ts +177 -0
  43. package/dist/analytics/news/providers/defiNewsProvider.d.ts +106 -0
  44. package/dist/analytics/news/services/newsDataService.d.ts +72 -0
  45. package/dist/analytics/news/utils/formatters.d.ts +54 -0
  46. package/dist/analytics/token-info/action.d.ts +6 -0
  47. package/dist/analytics/token-info/index.d.ts +3 -0
  48. package/dist/analytics/token-info/params.d.ts +10 -0
  49. package/dist/analytics/token-info/providers.d.ts +4 -0
  50. package/dist/analytics/token-info/service.d.ts +19 -0
  51. package/dist/analytics/token-info/types.d.ts +45 -0
  52. package/dist/api/wallet-routes.d.ts +100 -0
  53. package/dist/audit/audit-log.d.ts +29 -0
  54. package/dist/browser-shim/build-shim.d.ts +31 -0
  55. package/dist/browser-shim/index.d.ts +1 -0
  56. package/dist/chains/evm/actions/helpers.d.ts +31 -0
  57. package/dist/chains/evm/actions/swap.d.ts +53 -0
  58. package/dist/chains/evm/actions/transfer.d.ts +10 -0
  59. package/dist/chains/evm/bridge-router.d.ts +44 -0
  60. package/dist/chains/evm/build.d.ts +2 -0
  61. package/dist/chains/evm/chain-handler.d.ts +37 -0
  62. package/dist/chains/evm/constants.d.ts +16 -0
  63. package/dist/chains/evm/dex/aerodrome/index.d.ts +6 -0
  64. package/dist/chains/evm/dex/aerodrome/services/AerodromeLpService.d.ts +27 -0
  65. package/dist/chains/evm/dex/aerodrome/types.d.ts +435 -0
  66. package/dist/chains/evm/dex/pancakeswp/index.d.ts +6 -0
  67. package/dist/chains/evm/dex/pancakeswp/services/PancakeSwapV3LpService.d.ts +28 -0
  68. package/dist/chains/evm/dex/pancakeswp/types.d.ts +19 -0
  69. package/dist/chains/evm/dex/uniswap/index.d.ts +6 -0
  70. package/dist/chains/evm/dex/uniswap/services/UniswapV3LpService.d.ts +28 -0
  71. package/dist/chains/evm/dex/uniswap/types.d.ts +458 -0
  72. package/dist/chains/evm/generated/specs/spec-helpers.d.ts +35 -0
  73. package/dist/chains/evm/generated/specs/specs.d.ts +99 -0
  74. package/dist/chains/evm/gov-router.d.ts +6 -0
  75. package/dist/chains/evm/index.browser.d.ts +3 -0
  76. package/dist/chains/evm/index.d.ts +6 -0
  77. package/dist/chains/evm/prompts.d.ts +24 -0
  78. package/dist/chains/evm/providers/get-balance.d.ts +2 -0
  79. package/dist/chains/evm/providers/wallet.d.ts +35 -0
  80. package/dist/chains/evm/routes/sign.d.ts +13 -0
  81. package/dist/chains/evm/rpc-providers.d.ts +26 -0
  82. package/dist/chains/evm/service.d.ts +26 -0
  83. package/dist/chains/evm/templates/index.d.ts +1 -0
  84. package/dist/chains/evm/types/index.d.ts +296 -0
  85. package/dist/chains/evm/vitest.config.d.ts +2 -0
  86. package/dist/chains/registry.d.ts +3 -0
  87. package/dist/chains/solana/actions/confirmation.d.ts +9 -0
  88. package/dist/chains/solana/bn.d.ts +6 -0
  89. package/dist/chains/solana/build.d.ts +2 -0
  90. package/dist/chains/solana/constants.d.ts +2 -0
  91. package/dist/chains/solana/dex/meteora/e2e/scenarios.d.ts +10 -0
  92. package/dist/chains/solana/dex/meteora/e2e/test-utils.d.ts +28 -0
  93. package/dist/chains/solana/dex/meteora/index.d.ts +3 -0
  94. package/dist/chains/solana/dex/meteora/providers/positionProvider.d.ts +9 -0
  95. package/dist/chains/solana/dex/meteora/services/MeteoraLpService.d.ts +37 -0
  96. package/dist/chains/solana/dex/meteora/utils/dlmm.d.ts +6 -0
  97. package/dist/chains/solana/dex/meteora/utils/loadWallet.d.ts +14 -0
  98. package/dist/chains/solana/dex/meteora/utils/sendTransaction.d.ts +2 -0
  99. package/dist/chains/solana/dex/orca/index.d.ts +6 -0
  100. package/dist/chains/solana/dex/orca/providers/positionProvider.d.ts +10 -0
  101. package/dist/chains/solana/dex/orca/services/srv_orca.d.ts +10 -0
  102. package/dist/chains/solana/dex/orca/types.d.ts +61 -0
  103. package/dist/chains/solana/dex/orca/utils/loadWallet.d.ts +1 -0
  104. package/dist/chains/solana/dex/orca/utils/sendTransaction.d.ts +2 -0
  105. package/dist/chains/solana/dex/raydium/index.d.ts +6 -0
  106. package/dist/chains/solana/dex/raydium/providers/positionProvider.d.ts +10 -0
  107. package/dist/chains/solana/dex/raydium/services/srv_raydium.d.ts +104 -0
  108. package/dist/chains/solana/dex/raydium/types.d.ts +42 -0
  109. package/dist/chains/solana/environment.d.ts +15 -0
  110. package/dist/chains/solana/generated/specs/spec-helpers.d.ts +35 -0
  111. package/dist/chains/solana/generated/specs/specs.d.ts +73 -0
  112. package/dist/chains/solana/index.browser.d.ts +3 -0
  113. package/dist/chains/solana/index.d.ts +7 -0
  114. package/dist/chains/solana/keypairUtils.d.ts +7 -0
  115. package/dist/chains/solana/prompts.d.ts +12 -0
  116. package/dist/chains/solana/providers/wallet.d.ts +2 -0
  117. package/dist/chains/solana/routes/index.d.ts +2 -0
  118. package/dist/chains/solana/routes/sign.d.ts +16 -0
  119. package/dist/chains/solana/service.d.ts +237 -0
  120. package/dist/chains/solana/types.d.ts +377 -0
  121. package/dist/chains/solana/vitest.config.d.ts +2 -0
  122. package/dist/chains/wallet-action.d.ts +3 -0
  123. package/dist/contracts.d.ts +58 -0
  124. package/dist/core-augmentation.d.ts +9 -0
  125. package/dist/index.d.mts +27 -34727
  126. package/dist/index.d.ts +27 -0
  127. package/dist/index.mjs +28246 -21186
  128. package/dist/index.mjs.map +153 -0
  129. package/dist/lib/server-wallet-trade.d.ts +22 -0
  130. package/dist/lib/server-wallet-trade.js +333 -0
  131. package/dist/lib/server-wallet-trade.js.map +11 -0
  132. package/dist/lib/wallet-export-guard.d.ts +45 -0
  133. package/dist/lp/actions/liquidity.d.ts +2 -0
  134. package/dist/lp/e2e/real-token-tests.d.ts +6 -0
  135. package/dist/lp/e2e/scenarios.d.ts +9 -0
  136. package/dist/lp/e2e/test-utils.d.ts +28 -0
  137. package/dist/lp/lp-manager-entry.d.ts +18 -0
  138. package/dist/lp/services/ConcentratedLiquidityService.d.ts +32 -0
  139. package/dist/lp/services/DexInteractionService.d.ts +34 -0
  140. package/dist/lp/services/LpManagementService.d.ts +116 -0
  141. package/dist/lp/services/UserLpProfileService.d.ts +18 -0
  142. package/dist/lp/services/VaultService.d.ts +21 -0
  143. package/dist/lp/services/YieldOptimizationService.d.ts +59 -0
  144. package/dist/lp/services/__tests__/MockLpService.d.ts +17 -0
  145. package/dist/lp/types.d.ts +439 -0
  146. package/dist/lp/utils/solanaClient.d.ts +26 -0
  147. package/dist/plugin.d.ts +7 -0
  148. package/dist/policy/policy.d.ts +14 -0
  149. package/dist/providers/canonical-provider.d.ts +19 -0
  150. package/dist/providers/wallet-provider.d.ts +5 -0
  151. package/dist/register-routes.d.ts +1 -0
  152. package/dist/routes/plugin.d.ts +14 -0
  153. package/dist/routes/wallet-market-overview-route.d.ts +7 -0
  154. package/dist/sdk/abi.d.ts +396 -0
  155. package/dist/sdk/bridge/abis.d.ts +63 -0
  156. package/dist/sdk/bridge/client.d.ts +48 -0
  157. package/dist/sdk/bridge/index.d.ts +14 -0
  158. package/dist/sdk/bridge/solana.d.ts +131 -0
  159. package/dist/sdk/bridge/types.d.ts +92 -0
  160. package/dist/sdk/convenience.d.ts +104 -0
  161. package/dist/sdk/escrow/MutualStakeEscrow.d.ts +75 -0
  162. package/dist/sdk/escrow/types.d.ts +58 -0
  163. package/dist/sdk/escrow/verifiers.d.ts +25 -0
  164. package/dist/sdk/identity/erc8004.d.ts +304 -0
  165. package/dist/sdk/identity/reputation.d.ts +317 -0
  166. package/dist/sdk/identity/uaid.d.ts +192 -0
  167. package/dist/sdk/identity/validation.d.ts +282 -0
  168. package/dist/sdk/index.d.ts +133 -0
  169. package/dist/sdk/index.js +5284 -0
  170. package/dist/sdk/index.js.map +40 -0
  171. package/dist/sdk/policy/SpendingPolicy.d.ts +105 -0
  172. package/dist/sdk/policy/UptoBillingPolicy.d.ts +87 -0
  173. package/dist/sdk/router/PaymentRouter.d.ts +77 -0
  174. package/dist/sdk/router/index.d.ts +2 -0
  175. package/dist/sdk/swap/SwapModule.d.ts +47 -0
  176. package/dist/sdk/swap/abi.d.ts +50 -0
  177. package/dist/sdk/swap/index.d.ts +11 -0
  178. package/dist/sdk/swap/types.d.ts +101 -0
  179. package/dist/sdk/tokens/decimals.d.ts +64 -0
  180. package/dist/sdk/tokens/registry.d.ts +81 -0
  181. package/dist/sdk/tokens/solana.d.ts +107 -0
  182. package/dist/sdk/tokens/transfers.d.ts +94 -0
  183. package/dist/sdk/types.d.ts +129 -0
  184. package/dist/sdk/wallet-core.d.ts +29450 -0
  185. package/dist/sdk/x402/budget.d.ts +51 -0
  186. package/dist/sdk/x402/chains/abstract/index.d.ts +134 -0
  187. package/dist/sdk/x402/client.d.ts +66 -0
  188. package/dist/sdk/x402/index.d.ts +8 -0
  189. package/dist/sdk/x402/middleware.d.ts +37 -0
  190. package/dist/sdk/x402/multi-asset.d.ts +53 -0
  191. package/dist/sdk/x402/types.d.ts +109 -0
  192. package/dist/security/wallet-context-safety.d.ts +7 -0
  193. package/dist/security/wallet-financial-confirmation.d.ts +23 -0
  194. package/dist/services/wallet-backend-service.d.ts +39 -0
  195. package/dist/types/wallet-router.d.ts +130 -0
  196. package/dist/utils/intent-trajectory.d.ts +34 -0
  197. package/dist/wallet/backend.d.ts +41 -0
  198. package/dist/wallet/errors.d.ts +17 -0
  199. package/dist/wallet/index.d.ts +6 -0
  200. package/dist/wallet/local-eoa-backend.d.ts +37 -0
  201. package/dist/wallet/pending.d.ts +47 -0
  202. package/dist/wallet/select-backend.d.ts +11 -0
  203. package/dist/wallet/steward-backend.d.ts +22 -0
  204. package/dist/wallet-action.d.ts +1 -0
  205. package/dist/wallet-action.js +6292 -0
  206. package/dist/wallet-action.js.map +44 -0
  207. package/package.json +35 -21
  208. package/registry-entry.json +134 -0
  209. package/src/analytics/birdeye/actions/wallet-search-address.ts +85 -5
  210. package/src/analytics/birdeye/birdeye-task.ts +25 -9
  211. package/src/analytics/birdeye/birdeye.ts +6 -7
  212. package/src/analytics/birdeye/constants.ts +0 -1
  213. package/src/analytics/birdeye/providers/agent-portfolio-provider.ts +0 -1
  214. package/src/analytics/birdeye/providers/market.ts +51 -45
  215. package/src/analytics/birdeye/providers/portfolio-factory.ts +79 -38
  216. package/src/analytics/birdeye/providers/trending.ts +43 -46
  217. package/src/analytics/birdeye/providers/wallet.ts +0 -1
  218. package/src/analytics/birdeye/search-category.test.ts +1 -1
  219. package/src/analytics/birdeye/search-category.ts +77 -12
  220. package/src/analytics/birdeye/service.test.ts +146 -0
  221. package/src/analytics/birdeye/service.ts +220 -105
  222. package/src/analytics/birdeye/types/api/common.ts +0 -1
  223. package/src/analytics/birdeye/types/api/defi.ts +0 -1
  224. package/src/analytics/birdeye/types/api/pair.ts +0 -1
  225. package/src/analytics/birdeye/types/api/search.ts +0 -1
  226. package/src/analytics/birdeye/types/api/token.ts +0 -1
  227. package/src/analytics/birdeye/types/api/trader.ts +0 -1
  228. package/src/analytics/birdeye/types/api/wallet.ts +0 -1
  229. package/src/analytics/birdeye/types/shared.ts +0 -11
  230. package/src/analytics/birdeye/utils.test.ts +69 -0
  231. package/src/analytics/birdeye/utils.ts +11 -8
  232. package/src/analytics/dexscreener/search-category.ts +0 -1
  233. package/src/analytics/dexscreener/service.ts +7 -12
  234. package/src/analytics/dexscreener/types.ts +0 -1
  235. package/src/analytics/lpinfo/index.ts +5 -2
  236. package/src/analytics/lpinfo/kamino/README.md +2 -2
  237. package/src/analytics/lpinfo/kamino/index.ts +9 -2
  238. package/src/analytics/lpinfo/kamino/providers/kaminoLiquidityProvider.ts +6 -26
  239. package/src/analytics/lpinfo/kamino/providers/kaminoPoolProvider.ts +11 -12
  240. package/src/analytics/lpinfo/kamino/providers/kaminoProvider.ts +76 -32
  241. package/src/analytics/lpinfo/kamino/services/kaminoLiquidityService.ts +78 -38
  242. package/src/analytics/lpinfo/kamino/services/kaminoService.ts +71 -31
  243. package/src/analytics/lpinfo/steer/index.ts +7 -2
  244. package/src/analytics/lpinfo/steer/providers/steerLiquidityProvider.ts +25 -26
  245. package/src/analytics/lpinfo/steer/services/steerLiquidityService.ts +367 -149
  246. package/src/analytics/news/index.ts +7 -2
  247. package/src/analytics/news/interfaces/types.ts +0 -1
  248. package/src/analytics/news/providers/defiNewsProvider.ts +17 -44
  249. package/src/analytics/news/services/newsDataService.ts +1 -22
  250. package/src/analytics/news/utils/formatters.test.ts +60 -0
  251. package/src/analytics/news/utils/formatters.ts +0 -1
  252. package/src/analytics/token-info/action.ts +52 -212
  253. package/src/analytics/token-info/index.ts +1 -1
  254. package/src/analytics/token-info/params.test.ts +69 -0
  255. package/src/analytics/token-info/params.ts +13 -11
  256. package/src/analytics/token-info/providers.ts +46 -17
  257. package/src/analytics/token-info/service.ts +3 -3
  258. package/src/analytics/token-info/types.ts +2 -2
  259. package/src/api/wallet-routes.test.ts +56 -0
  260. package/src/api/wallet-routes.ts +1728 -0
  261. package/src/audit/audit-log.ts +57 -2
  262. package/src/browser-shim/build-shim.ts +1 -1
  263. package/src/browser-shim/shim.template.js +107 -117
  264. package/src/chains/{wallet-router.test.ts → __tests__/wallet-router.test.ts} +57 -10
  265. package/src/chains/evm/actions/helpers.ts +9 -7
  266. package/src/chains/evm/actions/swap.ts +176 -22
  267. package/src/chains/evm/actions/transfer.ts +29 -22
  268. package/src/chains/evm/biome.json +1 -1
  269. package/src/chains/evm/build.ts +6 -1
  270. package/src/chains/evm/constants.ts +19 -0
  271. package/src/chains/evm/contracts/artifacts/OZGovernor.json +25 -1682
  272. package/src/chains/evm/dex/aerodrome/index.ts +6 -1
  273. package/src/chains/evm/dex/aerodrome/services/AerodromeLpService.ts +41 -15
  274. package/src/chains/evm/dex/aerodrome/types.ts +1 -2
  275. package/src/chains/evm/dex/pancakeswp/index.ts +6 -1
  276. package/src/chains/evm/dex/pancakeswp/services/PancakeSwapV3LpService.ts +54 -17
  277. package/src/chains/evm/dex/pancakeswp/types.ts +1 -2
  278. package/src/chains/evm/dex/uniswap/index.ts +6 -1
  279. package/src/chains/evm/dex/uniswap/services/UniswapV3LpService.ts +20 -9
  280. package/src/chains/evm/dex/uniswap/types.ts +1 -2
  281. package/src/chains/evm/gov-router.ts +3 -1
  282. package/src/chains/evm/index.browser.ts +1 -1
  283. package/src/chains/evm/index.ts +5 -1
  284. package/src/chains/evm/prompts.ts +5 -0
  285. package/src/chains/evm/providers/get-balance.ts +1 -1
  286. package/src/chains/evm/providers/wallet.ts +80 -9
  287. package/src/chains/evm/routes/sign.ts +35 -26
  288. package/src/chains/evm/rpc-providers.ts +1 -1
  289. package/src/chains/evm/types/index.ts +22 -2
  290. package/src/chains/registry.ts +1 -1
  291. package/src/chains/wallet-action.ts +301 -91
  292. package/src/index.ts +9 -5
  293. package/src/lib/wallet-export-guard.test.ts +233 -0
  294. package/src/lib/wallet-export-guard.ts +1 -1
  295. package/src/lp/actions/liquidity.ts +53 -26
  296. package/src/lp/e2e/real-token-tests.ts +0 -1
  297. package/src/lp/e2e/scenarios.ts +1 -2
  298. package/src/lp/e2e/test-utils.ts +20 -7
  299. package/src/lp/lp-manager-entry.ts +2 -5
  300. package/src/lp/services/ConcentratedLiquidityService.ts +3 -10
  301. package/src/lp/services/DexInteractionService.ts +1 -2
  302. package/src/lp/services/LpManagementService.test.ts +0 -1
  303. package/src/lp/services/LpManagementService.ts +75 -35
  304. package/src/lp/services/UserLpProfileService.ts +2 -3
  305. package/src/lp/services/VaultService.ts +10 -4
  306. package/src/lp/services/YieldOptimizationService.ts +29 -13
  307. package/src/lp/services/__tests__/MockLpService.ts +1 -2
  308. package/src/lp/types.ts +9 -13
  309. package/src/lp/utils/solanaClient.ts +4 -2
  310. package/src/plugin.routes.test.ts +24 -0
  311. package/src/plugin.ts +30 -13
  312. package/src/providers/canonical-provider.ts +1 -1
  313. package/src/providers/{unified-wallet-provider.ts → wallet-provider.ts} +3 -3
  314. package/src/routes/__fixtures__/coingecko-markets.recorded.json +97 -0
  315. package/src/routes/wallet-market-overview-route.ts +1 -1
  316. package/src/routes/wallet-market-overview.contract.test.ts +139 -0
  317. package/src/routes/wallet-market-overview.real.test.ts +83 -0
  318. package/src/sdk/escrow/MutualStakeEscrow.ts +1 -2
  319. package/src/sdk/identity/erc8004.ts +1 -1
  320. package/src/sdk/identity/validation.ts +3 -4
  321. package/src/sdk/index.ts +2 -2
  322. package/src/sdk/policy/SpendingPolicy.ts +1 -1
  323. package/src/sdk/router/PaymentRouter.ts +8 -11
  324. package/src/sdk/swap/SwapModule.ts +1 -1
  325. package/src/sdk/tokens/registry.ts +1 -1
  326. package/src/sdk/x402/middleware.ts +2 -8
  327. package/src/security/__tests__/wallet-context-safety.test.ts +79 -0
  328. package/src/security/__tests__/wallet-financial-confirmation.test.ts +88 -0
  329. package/src/security/wallet-context-safety.ts +128 -0
  330. package/src/security/wallet-financial-confirmation.ts +150 -0
  331. package/src/services/wallet-backend-service.ts +15 -1
  332. package/src/utils/intent-trajectory.ts +2 -2
  333. package/src/wallet/steward-backend.ts +4 -4
  334. package/dist/LpManagementService-BWrQ5-cO.mjs +0 -353
  335. package/dist/MockLpService-D_Apn4Fd.mjs +0 -99
  336. package/dist/aerodrome-CfnESC32.mjs +0 -890
  337. package/dist/chunk-hT5z_Zn9.mjs +0 -35
  338. package/dist/lib/server-wallet-trade.d.mts +0 -34
  339. package/dist/lib/server-wallet-trade.mjs +0 -306
  340. package/dist/meteora-BPX39hZo.mjs +0 -22640
  341. package/dist/orca-Bybp1HXO.mjs +0 -249
  342. package/dist/pancakeswp-CkEXlXti.mjs +0 -604
  343. package/dist/plugin-ZO_MTyd0.mjs +0 -529
  344. package/dist/raydium-rfaM9yEf.mjs +0 -539
  345. package/dist/sdk/index.d.mts +0 -32492
  346. package/dist/sdk/index.mjs +0 -6415
  347. package/dist/types-D5252NZk.mjs +0 -487
  348. package/dist/uniswap-CReXgXVN.mjs +0 -573
  349. package/dist/wallet-action.d.mts +0 -6
  350. package/dist/wallet-action.mjs +0 -820
  351. package/src/analytics/birdeye/tasks/birdeye.ts +0 -232
  352. package/src/analytics/lpinfo/index.d.ts +0 -7
  353. package/src/chains/evm/contracts/artifacts/TimelockController.json +0 -1007
  354. package/src/chains/evm/contracts/artifacts/VoteToken.json +0 -895
  355. package/src/lp/tasks/LpAutoRebalanceTask.ts +0 -117
  356. package/src/lp/tasks/__tests__/LpAutoRebalanceTask.test.ts +0 -370
@@ -0,0 +1,2 @@
1
+ declare const _default: import("vite").UserConfig;
2
+ export default _default;
@@ -0,0 +1,3 @@
1
+ import type { IAgentRuntime } from "@elizaos/core";
2
+ import type { WalletBackendService } from "../services/wallet-backend-service.js";
3
+ export declare function registerDefaultWalletChainHandlers(service: WalletBackendService, runtime: IAgentRuntime): void;
@@ -0,0 +1,9 @@
1
+ import type { ActionResult, HandlerCallback } from "@elizaos/core";
2
+ /** LLM-supplied confirmed flags are never trusted (GHSA-rqm7-f4jc-84x3). */
3
+ export declare function isConfirmed(_options?: Record<string, unknown>): boolean;
4
+ export declare function confirmationRequired(params: {
5
+ actionName: string;
6
+ preview: string;
7
+ parameters: object;
8
+ callback?: HandlerCallback;
9
+ }): Promise<ActionResult>;
@@ -0,0 +1,6 @@
1
+ import type { default as BigNumberType } from "bignumber.js";
2
+ import BigNumberLib from "bignumber.js";
3
+ export declare const BN: typeof BigNumberType;
4
+ export default BigNumberLib;
5
+ export type BigNumber = typeof BigNumberLib;
6
+ export declare function toBN(value: string | number | BigNumberType): BigNumberType;
@@ -0,0 +1,2 @@
1
+ #!/usr/bin/env bun
2
+ export {};
@@ -0,0 +1,2 @@
1
+ export declare const SOLANA_SERVICE_NAME = "chain_solana";
2
+ export declare const SOLANA_WALLET_DATA_CACHE_KEY = "solana/walletData";
@@ -0,0 +1,10 @@
1
+ import type { TestSuite } from "@elizaos/core";
2
+ /**
3
+ * Defines a suite of E2E tests for Meteora LP management scenarios.
4
+ *
5
+ * These scenarios test the agent's ability to handle real-world Meteora DEX
6
+ * interactions including pool discovery, liquidity provision, position management,
7
+ * and market data retrieval.
8
+ */
9
+ export declare const meteoraScenarios: TestSuite;
10
+ export default meteoraScenarios;
@@ -0,0 +1,28 @@
1
+ import { type Content, type Entity, type IAgentRuntime, type Room, type World } from "@elizaos/core";
2
+ /**
3
+ * Sets up a standard scenario environment for an E2E test.
4
+ *
5
+ * This function creates a world, a user, and a room, providing an
6
+ * isolated environment for each test case.
7
+ *
8
+ * @param runtime The live IAgentRuntime instance provided by the TestRunner.
9
+ * @returns A promise that resolves to an object containing the created world, user, and room.
10
+ */
11
+ export declare function setupScenario(runtime: IAgentRuntime): Promise<{
12
+ user: Entity;
13
+ room: Room;
14
+ world: World;
15
+ }>;
16
+ /**
17
+ * Simulates a user sending a message and waits for the agent's response.
18
+ *
19
+ * This function abstracts the event-driven nature of the message handler
20
+ * into a simple async function, making tests easier to write and read.
21
+ *
22
+ * @param runtime The live IAgentRuntime instance.
23
+ * @param room The room where the message is sent.
24
+ * @param user The user entity sending the message.
25
+ * @param text The content of the message.
26
+ * @returns A promise that resolves with the agent's response content.
27
+ */
28
+ export declare function sendMessageAndWaitForResponse(runtime: IAgentRuntime, room: Room, user: Entity, text: string): Promise<Content>;
@@ -0,0 +1,3 @@
1
+ import type { Plugin } from "@elizaos/core";
2
+ export declare const meteoraPlugin: Plugin;
3
+ export default meteoraPlugin;
@@ -0,0 +1,9 @@
1
+ import { type Provider } from "@elizaos/core";
2
+ export interface MeteoraPositionStatistics {
3
+ poolAddress: string;
4
+ positionPubKey: string;
5
+ inRange: boolean;
6
+ distanceFromActiveBinBps: number;
7
+ binRange: number;
8
+ }
9
+ export declare const meteoraPositionProvider: Provider;
@@ -0,0 +1,37 @@
1
+ import { type IAgentRuntime, type LpPositionDetails, type PoolInfo, Service, type TokenBalance, type TransactionResult } from "@elizaos/core";
2
+ import { Keypair } from "@solana/web3.js";
3
+ export declare class MeteoraLpService extends Service {
4
+ [key: string]: unknown;
5
+ static readonly serviceType = "meteora-lp";
6
+ readonly capabilityDescription: "Provides standardized access to DEX liquidity pools.";
7
+ private connection;
8
+ private readonly METEORA_API_URL;
9
+ constructor(runtime?: IAgentRuntime);
10
+ static start(runtime: IAgentRuntime): Promise<MeteoraLpService>;
11
+ stop(): Promise<void>;
12
+ getDexName(): string;
13
+ getPools(tokenAMint?: string, tokenBMint?: string): Promise<PoolInfo[]>;
14
+ addLiquidity(params: {
15
+ userVault: Keypair;
16
+ poolId: string;
17
+ tokenAAmountLamports: string;
18
+ tokenBAmountLamports?: string;
19
+ slippageBps: number;
20
+ tickLowerIndex?: number;
21
+ tickUpperIndex?: number;
22
+ tokenAMint?: string;
23
+ }): Promise<TransactionResult & {
24
+ lpTokensReceived?: TokenBalance;
25
+ }>;
26
+ removeLiquidity(params: {
27
+ userVault: Keypair;
28
+ poolId: string;
29
+ lpTokenAmountLamports: string;
30
+ slippageBps: number;
31
+ }): Promise<TransactionResult & {
32
+ tokensReceived?: TokenBalance[];
33
+ }>;
34
+ getLpPositionDetails(userAccountPublicKey: string, poolOrPositionIdentifier: string): Promise<LpPositionDetails | null>;
35
+ getMarketDataForPools(poolIds: string[]): Promise<Record<string, Partial<PoolInfo>>>;
36
+ private getTokenBalance;
37
+ }
@@ -0,0 +1,6 @@
1
+ import type DLMMDefault from "@meteora-ag/dlmm";
2
+ export type { LbPosition } from "@meteora-ag/dlmm";
3
+ type DLMMConstructor = typeof DLMMDefault;
4
+ declare const DLMM: DLMMConstructor;
5
+ declare const autoFillYByStrategy: typeof import("@meteora-ag/dlmm").autoFillYByStrategy, StrategyType: typeof import("@meteora-ag/dlmm").StrategyType;
6
+ export { autoFillYByStrategy, DLMM, StrategyType };
@@ -0,0 +1,14 @@
1
+ import type { IAgentRuntime } from "@elizaos/core";
2
+ import { Connection, Keypair, PublicKey } from "@solana/web3.js";
3
+ export interface WalletResult {
4
+ signer?: Keypair;
5
+ address?: PublicKey;
6
+ connection: Connection;
7
+ }
8
+ /**
9
+ * Gets either a keypair or public key based on TEE mode and runtime settings
10
+ * @param runtime The agent runtime
11
+ * @param requirePrivateKey Whether to return a full keypair (true) or just public key (false)
12
+ * @returns KeypairResult containing either keypair or public key
13
+ */
14
+ export declare function loadWallet(runtime: IAgentRuntime, requirePrivateKey?: boolean): Promise<WalletResult>;
@@ -0,0 +1,2 @@
1
+ import { type Connection, type Keypair, type TransactionInstruction } from "@solana/web3.js";
2
+ export declare function sendTransaction(connection: Connection, instructions: TransactionInstruction[], wallet: Keypair): Promise<string>;
@@ -0,0 +1,6 @@
1
+ import type { Plugin } from "@elizaos/core";
2
+ import { OrcaService } from "./services/srv_orca.ts";
3
+ export declare const orcaPlugin: Plugin;
4
+ export * from "./types.ts";
5
+ export { OrcaService };
6
+ export default orcaPlugin;
@@ -0,0 +1,10 @@
1
+ import { type Provider } from "@elizaos/core";
2
+ import { type PublicKey } from "@solana/web3.js";
3
+ export interface FetchedPositionStatistics {
4
+ whirlpoolAddress: PublicKey;
5
+ positionMint: PublicKey;
6
+ inRange: boolean;
7
+ distanceCenterPositionFromPoolPriceBps: number;
8
+ positionWidthBps: number;
9
+ }
10
+ export declare const positionProvider: Provider;
@@ -0,0 +1,10 @@
1
+ import { type IAgentRuntime, Service } from "@elizaos/core";
2
+ export declare class OrcaService extends Service {
3
+ [key: string]: unknown;
4
+ static serviceType: string;
5
+ capabilityDescription: "Provides standardized access to DEX liquidity pools.";
6
+ constructor(runtime?: IAgentRuntime);
7
+ static start(runtime: IAgentRuntime): Promise<OrcaService>;
8
+ start(): Promise<void>;
9
+ stop(): Promise<void>;
10
+ }
@@ -0,0 +1,61 @@
1
+ export interface LPPosition {
2
+ positionId: string;
3
+ poolAddress: string;
4
+ tokenA: string;
5
+ tokenB: string;
6
+ liquidity: bigint;
7
+ lowerTick: number;
8
+ upperTick: number;
9
+ inRange: boolean;
10
+ }
11
+ export interface PoolStats {
12
+ address: string;
13
+ tvl: number;
14
+ volume24h: number;
15
+ fee24h: number;
16
+ apy: number;
17
+ price: number;
18
+ priceRange: {
19
+ min24h: number;
20
+ max24h: number;
21
+ };
22
+ }
23
+ export interface RebalanceParams {
24
+ position: LPPosition;
25
+ currentPrice: number;
26
+ targetWidth: number;
27
+ slippage: number;
28
+ }
29
+ export interface TradingConfig {
30
+ intervals: {
31
+ priceCheck: number;
32
+ positionSync: number;
33
+ performanceMonitor: number;
34
+ };
35
+ thresholds: {
36
+ minTvl: number;
37
+ minVolume: number;
38
+ minApy: number;
39
+ };
40
+ riskLimits: {
41
+ maxPositionSize: number;
42
+ maxPriceImpact: number;
43
+ minLiquidity: number;
44
+ };
45
+ rebalanceSettings: {
46
+ threshold: number;
47
+ targetWidth: number;
48
+ minInterval: number;
49
+ };
50
+ }
51
+ export interface PositionMetrics {
52
+ fees24h: number;
53
+ apy: number;
54
+ impermanentLoss: number;
55
+ totalValue: number;
56
+ tokenAAmount: number;
57
+ tokenBAmount: number;
58
+ }
59
+ export declare const ServiceTypes: {
60
+ readonly LP_TRADING: "lp_trader";
61
+ };
@@ -0,0 +1 @@
1
+ export { loadWallet, type WalletResult } from "../../../../../lp/utils/solanaClient.ts";
@@ -0,0 +1,2 @@
1
+ import { type Connection, type Keypair, type TransactionInstruction } from "@solana/web3.js";
2
+ export declare function sendTransaction(connection: Connection, instructions: TransactionInstruction[], wallet: Keypair): Promise<string>;
@@ -0,0 +1,6 @@
1
+ import type { Plugin } from "@elizaos/core";
2
+ import { RaydiumService } from "./services/srv_raydium.ts";
3
+ export declare const raydiumPlugin: Plugin;
4
+ export * from "./types.ts";
5
+ export { RaydiumService };
6
+ export default raydiumPlugin;
@@ -0,0 +1,10 @@
1
+ import { type Provider } from "@elizaos/core";
2
+ import { type PublicKey } from "@solana/web3.js";
3
+ export interface FetchedPositionStatistics {
4
+ poolAddress: PublicKey;
5
+ positionNftMint: PublicKey;
6
+ inRange: boolean;
7
+ distanceCenterPositionFromPoolPriceBps: number;
8
+ positionWidthBps: number;
9
+ }
10
+ export declare const raydiumPositionProvider: Provider;
@@ -0,0 +1,104 @@
1
+ import { type IAgentRuntime, Service } from "@elizaos/core";
2
+ import type { Connection, PublicKey } from "@solana/web3.js";
3
+ import type { JupiterQuoteResponse } from "../types.ts";
4
+ type RaydiumRegisteredProvider = {
5
+ name: string;
6
+ };
7
+ type RaydiumPositionInfo = {
8
+ id: PublicKey;
9
+ [key: string]: unknown;
10
+ };
11
+ type ClmmPoolInfo = {
12
+ id: PublicKey;
13
+ tokenAccountA: PublicKey;
14
+ tokenAccountB: PublicKey;
15
+ [key: string]: unknown;
16
+ };
17
+ export declare class RaydiumService extends Service {
18
+ [key: string]: unknown;
19
+ private isRunning;
20
+ private registry;
21
+ static serviceType: string;
22
+ capabilityDescription: "Provides standardized access to DEX liquidity pools.";
23
+ private readonly CONFIRMATION_CONFIG;
24
+ constructor(runtime?: IAgentRuntime);
25
+ registerProvider(provider: RaydiumRegisteredProvider): Promise<number>;
26
+ getQuote({ inputMint, outputMint, amount, slippageBps, }: {
27
+ inputMint: string;
28
+ outputMint: string;
29
+ amount: number;
30
+ slippageBps: number;
31
+ }): Promise<any>;
32
+ executeSwap({ quoteResponse, userPublicKey, slippageBps, }: {
33
+ quoteResponse: JupiterQuoteResponse;
34
+ userPublicKey: string;
35
+ slippageBps: number;
36
+ }): Promise<any>;
37
+ confirmTransaction(connection: Connection, signature: string): Promise<boolean>;
38
+ getTokenPrice(tokenMint: string, quoteMint?: string, inputDecimals?: number): Promise<number>;
39
+ getBestRoute({ inputMint, outputMint, amount, }: {
40
+ inputMint: string;
41
+ outputMint: string;
42
+ amount: number;
43
+ }): Promise<any>;
44
+ getPriceImpact({ inputMint, outputMint, amount, }: {
45
+ inputMint: string;
46
+ outputMint: string;
47
+ amount: number;
48
+ }): Promise<number>;
49
+ getMinimumReceived({ inputMint, outputMint, amount, slippageBps, }: {
50
+ inputMint: string;
51
+ outputMint: string;
52
+ amount: number;
53
+ slippageBps: number;
54
+ }): Promise<number>;
55
+ estimateGasFees({ inputMint, outputMint, amount, }: {
56
+ inputMint: string;
57
+ outputMint: string;
58
+ amount: number;
59
+ }): Promise<{
60
+ lamports: number;
61
+ sol: number;
62
+ }>;
63
+ findBestSlippage({ inputMint, outputMint, amount, }: {
64
+ inputMint: string;
65
+ outputMint: string;
66
+ amount: number;
67
+ }): Promise<number>;
68
+ getTokenPair({ inputMint, outputMint, }: {
69
+ inputMint: string;
70
+ outputMint: string;
71
+ }): Promise<{
72
+ inputToken: Record<string, string | number | boolean | null>;
73
+ outputToken: Record<string, string | number | boolean | null>;
74
+ liquidity: number;
75
+ volume24h: number;
76
+ }>;
77
+ getHistoricalPrices({ inputMint, outputMint, timeframe, }: {
78
+ inputMint: string;
79
+ outputMint: string;
80
+ timeframe?: string;
81
+ }): Promise<Array<{
82
+ timestamp: number;
83
+ price: number;
84
+ }>>;
85
+ findArbitragePaths({ startingMint, amount, maxHops: _maxHops, }: {
86
+ startingMint: string;
87
+ amount: number;
88
+ maxHops?: number;
89
+ }): Promise<Array<{
90
+ path: string[];
91
+ expectedReturn: number;
92
+ priceImpact: number;
93
+ }>>;
94
+ getPositions(connection: Connection, ownerAddress: PublicKey): Promise<RaydiumPositionInfo[]>;
95
+ createPosition(connection: Connection, pool: ClmmPoolInfo, owner: PublicKey, lowerTick: number, upperTick: number, tokenAmountA: bigint, tokenAmountB: bigint): Promise<never>;
96
+ closePosition(connection: Connection, positionInfo: RaydiumPositionInfo, owner: PublicKey): Promise<never>;
97
+ updatePosition(connection: Connection, positionInfo: RaydiumPositionInfo, owner: PublicKey, liquidityDelta: bigint): Promise<never>;
98
+ static start(runtime: IAgentRuntime): Promise<RaydiumService>;
99
+ static stop(runtime: IAgentRuntime): Promise<void>;
100
+ start(): Promise<void>;
101
+ stop(): Promise<void>;
102
+ isServiceRunning(): boolean;
103
+ }
104
+ export {};
@@ -0,0 +1,42 @@
1
+ export interface JupiterQuoteParams {
2
+ inputMint: string;
3
+ outputMint: string;
4
+ amount: number;
5
+ slippageBps: number;
6
+ }
7
+ /** Minimal Jupiter route step shape used by swap quotes */
8
+ export interface JupiterRoutePlanSwapInfo {
9
+ ammKey?: string;
10
+ label?: string;
11
+ inputMint?: string;
12
+ outputMint?: string;
13
+ inAmount?: string;
14
+ outAmount?: string;
15
+ }
16
+ export interface JupiterRoutePlanStep {
17
+ swapInfo?: JupiterRoutePlanSwapInfo;
18
+ percent?: number;
19
+ }
20
+ export interface JupiterQuoteResponse {
21
+ inputMint: string;
22
+ outputMint: string;
23
+ inAmount: string;
24
+ outAmount: string;
25
+ otherAmountThreshold: string;
26
+ swapMode: string;
27
+ slippageBps: number;
28
+ priceImpactPct: string;
29
+ routePlan: JupiterRoutePlanStep[];
30
+ contextSlot: number;
31
+ timeTaken: number;
32
+ }
33
+ export interface JupiterSwapParams {
34
+ quoteResponse: JupiterQuoteResponse;
35
+ userPublicKey: string;
36
+ slippageBps: number;
37
+ }
38
+ export interface JupiterSwapResponse {
39
+ swapTransaction: string;
40
+ lastValidBlockHeight: number;
41
+ prioritizationFeeLamports: number;
42
+ }
@@ -0,0 +1,15 @@
1
+ import type { IAgentRuntime } from "@elizaos/core";
2
+ import { z } from "zod";
3
+ export declare const solanaEnvSchema: z.ZodIntersection<z.ZodIntersection<z.ZodObject<{
4
+ SOLANA_SECRET_SALT: z.ZodOptional<z.ZodString>;
5
+ }, z.core.$strip>, z.ZodUnion<readonly [z.ZodObject<{
6
+ SOLANA_PRIVATE_KEY: z.ZodOptional<z.ZodString>;
7
+ SOLANA_PUBLIC_KEY: z.ZodString;
8
+ }, z.core.$strip>, z.ZodObject<{
9
+ SOLANA_SECRET_SALT: z.ZodOptional<z.ZodString>;
10
+ }, z.core.$strip>]>>, z.ZodObject<{
11
+ SLIPPAGE: z.ZodString;
12
+ SOLANA_RPC_URL: z.ZodString;
13
+ }, z.core.$strip>>;
14
+ export type SolanaConfig = z.infer<typeof solanaEnvSchema>;
15
+ export declare function validateSolanaConfig(runtime: IAgentRuntime): Promise<SolanaConfig>;
@@ -0,0 +1,35 @@
1
+ /**
2
+ * Helper functions to lookup action/provider specs by name.
3
+ * These allow language-specific implementations to import their text content
4
+ * (description, similes, examples) from the centralized specs.
5
+ *
6
+ * DO NOT EDIT the spec data - update prompts/actions.json, prompts/providers.json and regenerate.
7
+ */
8
+ import { type ActionDoc, type ProviderDoc } from "./specs";
9
+ /**
10
+ * Get an action spec by name from the core specs.
11
+ * @param name - The action name
12
+ * @returns The action spec or undefined if not found
13
+ */
14
+ export declare function getActionSpec(name: string): ActionDoc | undefined;
15
+ /**
16
+ * Get an action spec by name, throwing if not found.
17
+ * @param name - The action name
18
+ * @returns The action spec
19
+ * @throws Error if the action is not found
20
+ */
21
+ export declare function requireActionSpec(name: string): ActionDoc;
22
+ /**
23
+ * Get a provider spec by name from the core specs.
24
+ * @param name - The provider name
25
+ * @returns The provider spec or undefined if not found
26
+ */
27
+ export declare function getProviderSpec(name: string): ProviderDoc | undefined;
28
+ /**
29
+ * Get a provider spec by name, throwing if not found.
30
+ * @param name - The provider name
31
+ * @returns The provider spec
32
+ * @throws Error if the provider is not found
33
+ */
34
+ export declare function requireProviderSpec(name: string): ProviderDoc;
35
+ export type { ActionDoc, ProviderDoc };
@@ -0,0 +1,73 @@
1
+ /**
2
+ * Auto-generated canonical action/provider docs for plugin-wallet solana chain.
3
+ * DO NOT EDIT - Generated from prompts/specs/**.
4
+ */
5
+ export type ActionDoc = {
6
+ name: string;
7
+ description: string;
8
+ descriptionCompressed?: string;
9
+ similes?: readonly string[];
10
+ parameters?: readonly unknown[];
11
+ examples?: readonly (readonly unknown[])[];
12
+ };
13
+ export type ProviderDoc = {
14
+ name: string;
15
+ description: string;
16
+ descriptionCompressed?: string;
17
+ position?: number;
18
+ dynamic?: boolean;
19
+ };
20
+ export declare const coreActionsSpec: {
21
+ readonly version: "1.0.0";
22
+ readonly actions: readonly [{
23
+ readonly name: "SOLANA_TRANSFER";
24
+ readonly description: "Transfer SOL or SPL tokens from the agent's Solana wallet to another address";
25
+ readonly descriptionCompressed: "Solana transfer: send SOL or SPL tokens to another address.";
26
+ readonly similes: readonly ["TRANSFER", "SEND_SOL", "SEND_TOKEN", "SEND_TOKENS", "TRANSFER_SOL", "TRANSFER_TOKEN", "TRANSFER_TOKENS", "PAY"];
27
+ readonly parameters: readonly ["subaction", "chain", "fromToken", "amount", "recipient", "mode", "dryRun"];
28
+ }, {
29
+ readonly name: "SOLANA_SWAP";
30
+ readonly description: "Perform a token swap from one token to another on Solana. Works with SOL and SPL tokens.";
31
+ readonly descriptionCompressed: "Solana token swap: SOL or SPL tokens via Jupiter routing.";
32
+ readonly similes: readonly ["SWAP_SOL", "SWAP_SOLANA", "SWAP_TOKENS_SOLANA", "TOKEN_SWAP_SOLANA", "TRADE_TOKENS_SOLANA", "EXCHANGE_TOKENS_SOLANA"];
33
+ readonly parameters: readonly ["subaction", "chain", "fromToken", "toToken", "amount", "slippageBps", "mode", "dryRun"];
34
+ }];
35
+ };
36
+ export declare const allActionsSpec: {
37
+ readonly version: "1.0.0";
38
+ readonly actions: readonly [{
39
+ readonly name: "SOLANA_TRANSFER";
40
+ readonly description: "Transfer SOL or SPL tokens from the agent's Solana wallet to another address";
41
+ readonly descriptionCompressed: "Solana transfer: send SOL or SPL tokens to another address.";
42
+ readonly similes: readonly ["TRANSFER", "SEND_SOL", "SEND_TOKEN", "SEND_TOKENS", "TRANSFER_SOL", "TRANSFER_TOKEN", "TRANSFER_TOKENS", "PAY"];
43
+ readonly parameters: readonly ["subaction", "chain", "fromToken", "amount", "recipient", "mode", "dryRun"];
44
+ }, {
45
+ readonly name: "SOLANA_SWAP";
46
+ readonly description: "Perform a token swap from one token to another on Solana. Works with SOL and SPL tokens.";
47
+ readonly descriptionCompressed: "Solana token swap: SOL or SPL tokens via Jupiter routing.";
48
+ readonly similes: readonly ["SWAP_SOL", "SWAP_SOLANA", "SWAP_TOKENS_SOLANA", "TOKEN_SWAP_SOLANA", "TRADE_TOKENS_SOLANA", "EXCHANGE_TOKENS_SOLANA"];
49
+ readonly parameters: readonly ["subaction", "chain", "fromToken", "toToken", "amount", "slippageBps", "mode", "dryRun"];
50
+ }];
51
+ };
52
+ export declare const coreProvidersSpec: {
53
+ readonly version: "1.0.0";
54
+ readonly providers: readonly [{
55
+ readonly name: "solana-wallet";
56
+ readonly description: "your solana wallet information";
57
+ readonly descriptionCompressed: "Solana wallet address, balances, and SPL holdings.";
58
+ readonly dynamic: true;
59
+ }];
60
+ };
61
+ export declare const allProvidersSpec: {
62
+ readonly version: "1.0.0";
63
+ readonly providers: readonly [{
64
+ readonly name: "solana-wallet";
65
+ readonly description: "your solana wallet information";
66
+ readonly descriptionCompressed: "Solana wallet address, balances, and SPL holdings.";
67
+ readonly dynamic: true;
68
+ }];
69
+ };
70
+ export declare const coreActionDocs: readonly ActionDoc[];
71
+ export declare const allActionDocs: readonly ActionDoc[];
72
+ export declare const coreProviderDocs: readonly ProviderDoc[];
73
+ export declare const allProviderDocs: readonly ProviderDoc[];
@@ -0,0 +1,3 @@
1
+ import type { Plugin } from "@elizaos/core";
2
+ export declare const solanaPlugin: Plugin;
3
+ export default solanaPlugin;
@@ -0,0 +1,7 @@
1
+ import type { Plugin } from "@elizaos/core";
2
+ export declare const solanaPlugin: Plugin;
3
+ export default solanaPlugin;
4
+ export { SOLANA_SERVICE_NAME } from "./constants";
5
+ export type { SolanaService as ISolanaService } from "./service";
6
+ export { SolanaService, SolanaWalletService } from "./service";
7
+ export type { ApiError, ApiResponse, PortfolioTokenResponse, TokenAccountResponse, TokenBalanceResponse, WalletAddressResponse, WalletBalanceResponse, WalletPortfolioResponse, WalletTokensResponse, } from "./types";
@@ -0,0 +1,7 @@
1
+ import { type IAgentRuntime } from "@elizaos/core";
2
+ import { Keypair, PublicKey } from "@solana/web3.js";
3
+ export interface KeypairResult {
4
+ keypair?: Keypair;
5
+ publicKey?: PublicKey;
6
+ }
7
+ export declare function getWalletKey(runtime: IAgentRuntime, requirePrivateKey?: boolean): Promise<KeypairResult>;
@@ -0,0 +1,12 @@
1
+ /**
2
+ * Prompt templates for plugin-wallet Solana actions and providers.
3
+ *
4
+ * These prompts use Handlebars-style template syntax:
5
+ * - {{variableName}} for simple substitution
6
+ * - {{#each items}}...{{/each}} for iteration
7
+ * - {{#if condition}}...{{/if}} for conditionals
8
+ */
9
+ export declare const swapTemplate = "Respond using plain key/value text like this. Use null for any value that cannot be determined.\n\nExample response:\ninputTokenSymbol: SOL\noutputTokenSymbol: USDC\ninputTokenCA: So11111111111111111111111111111111111111112\noutputTokenCA: EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v\namount: 1.5\n\n{{recentMessages}}\n\nGiven the recent messages and wallet information below:\n\n{{walletInfo}}\n\nExtract the following information about the requested token swap:\n- Input token symbol (the token being sold)\n- Output token symbol (the token being bought)\n- Input token contract address if provided\n- Output token contract address if provided\n- Amount to swap\n\nRespond using plain key/value text with only the extracted values. Use null for any value that cannot be determined.\n\nIMPORTANT: Your response must ONLY contain the key/value fields. No preamble or explanation.";
10
+ export declare const SWAP_TEMPLATE = "Respond using plain key/value text like this. Use null for any value that cannot be determined.\n\nExample response:\ninputTokenSymbol: SOL\noutputTokenSymbol: USDC\ninputTokenCA: So11111111111111111111111111111111111111112\noutputTokenCA: EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v\namount: 1.5\n\n{{recentMessages}}\n\nGiven the recent messages and wallet information below:\n\n{{walletInfo}}\n\nExtract the following information about the requested token swap:\n- Input token symbol (the token being sold)\n- Output token symbol (the token being bought)\n- Input token contract address if provided\n- Output token contract address if provided\n- Amount to swap\n\nRespond using plain key/value text with only the extracted values. Use null for any value that cannot be determined.\n\nIMPORTANT: Your response must ONLY contain the key/value fields. No preamble or explanation.";
11
+ export declare const transferTemplate = "Respond using plain key/value text with only the extracted values. Use null for any value that cannot be determined.\n\nExample responses:\nFor SPL tokens:\ntokenAddress: BieefG47jAHCGZBxi2q87RDuHyGZyYC3vAzxpyu8pump\nrecipient: 9jW8FPr6BSSsemWPV22UUCzSqkVdTp6HTyPqeqyuBbCa\namount: 1000\n\nFor SOL:\ntokenAddress: null\nrecipient: 9jW8FPr6BSSsemWPV22UUCzSqkVdTp6HTyPqeqyuBbCa\namount: 1.5\n\n{{recentMessages}}\n\nExtract the following information about the requested transfer:\n- Token contract address (use null for SOL transfers)\n- Recipient wallet address\n- Amount to transfer\n\nIMPORTANT: Your response must ONLY contain the key/value fields. No preamble or explanation.";
12
+ export declare const TRANSFER_TEMPLATE = "Respond using plain key/value text with only the extracted values. Use null for any value that cannot be determined.\n\nExample responses:\nFor SPL tokens:\ntokenAddress: BieefG47jAHCGZBxi2q87RDuHyGZyYC3vAzxpyu8pump\nrecipient: 9jW8FPr6BSSsemWPV22UUCzSqkVdTp6HTyPqeqyuBbCa\namount: 1000\n\nFor SOL:\ntokenAddress: null\nrecipient: 9jW8FPr6BSSsemWPV22UUCzSqkVdTp6HTyPqeqyuBbCa\namount: 1.5\n\n{{recentMessages}}\n\nExtract the following information about the requested transfer:\n- Token contract address (use null for SOL transfers)\n- Recipient wallet address\n- Amount to transfer\n\nIMPORTANT: Your response must ONLY contain the key/value fields. No preamble or explanation.";
@@ -0,0 +1,2 @@
1
+ import type { Provider } from "@elizaos/core";
2
+ export declare const walletProvider: Provider;
@@ -0,0 +1,2 @@
1
+ import type { Route } from "@elizaos/core";
2
+ export declare const solanaRoutes: Route[];
@@ -0,0 +1,16 @@
1
+ /**
2
+ * Browser-facing Solana signing endpoints.
3
+ *
4
+ * These endpoints let an in-browser dApp request a signature from the agent's
5
+ * resident keypair via the wallet backend. They are gated by a single shared
6
+ * bearer token (`WALLET_BROWSER_SIGN_TOKEN`) — without that token set, every
7
+ * route returns 503 so the surface is closed by default.
8
+ *
9
+ * The companion JS shim in `../../../browser-shim/` bakes the token into a
10
+ * registered Wallet-Standard provider and proxies `signTransaction` /
11
+ * `signMessage` / `signAndSendTransaction` to these routes. CORS is permissive
12
+ * (any origin, with the token as the actual auth) because the shim runs inside
13
+ * arbitrary dApp pages whose origin is not knowable in advance.
14
+ */
15
+ import type { Route } from "@elizaos/core";
16
+ export declare const solanaSignRoutes: Route[];