
Security News
ECMAScript 2025 Finalized with Iterator Helpers, Set Methods, RegExp.escape, and More
ECMAScript 2025 introduces Iterator Helpers, Set methods, JSON modules, and more in its latest spec update approved by Ecma in June 2025.
github.com/yimingWOW/solroute
SolRoute is a Go SDK that serves as the fundamental infrastructure for building DEX routing services on Solana. Unlike solutions that rely on third-party APIs, SolRoute directly interacts with the Solana blockchain.
Protocol Support
675kPX9MHTjS2zt1qfr1NYHuzeLXfQM9H24wFSUt1Mp8
)CPMMoo8L3F4NbTegBCKVNunggL7H1ZpdTHKxQB5qKP1C
)CAMMCzo5YL8w4VFF8KVHrK22GGUsp5VTaW7grrKgrWqK
)pAMMBay6oceH9fJKBRHGP5D4bD4sWpmSwMn52FMfXEA
)Core Functionality
SolRoute's direct blockchain interaction makes it ideal for building:
// Initialize router with supported protocols
router := router.NewSimpleRouter(
protocol.NewPumpAmm(solClient),
protocol.NewRaydiumAmm(solClient),
protocol.NewRaydiumClmm(solClient),
protocol.NewRaydiumCpmm(solClient),
)
// Find best pool and execute swap
bestPool, amountOut, err := router.GetBestPool(ctx, solClient.RpcClient,
"TOKEN0_MINT", "TOKEN1_MINT", amountIn)
if err != nil {
log.Fatal(err)
}
// Build and send transaction
instructions, err := bestPool.BuildSwapInstructions(ctx, solClient.RpcClient,
userPublicKey, "TOKEN0_MINT", amountIn, minAmountOut)
go get github.com/yimingWOW/solroute
solroute/
āāā pkg/
ā āāā api/ # Core interfaces
ā āāā pool/ # Pool implementations
ā āāā protocol/ # DEX implementations
ā āāā router/ # Routing engine
ā āāā sol/ # Solana client
Contributions are welcome! Please feel free to submit a Pull Request.
This project is licensed under the MIT License - see the LICENSE file for details.
FAQs
Unknown package
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
ECMAScript 2025 introduces Iterator Helpers, Set methods, JSON modules, and more in its latest spec update approved by Ecma in June 2025.
Security News
A new Node.js homepage button linking to paid support for EOL versions has sparked a heated discussion among contributors and the wider community.
Research
North Korean threat actors linked to the Contagious Interview campaign return with 35 new malicious npm packages using a stealthy multi-stage malware loader.