SaucerSwap Plugin#1474
Open
DivyanshGoel20 wants to merge 3 commits into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
SaucerSwap Plugin
Summary
Adds a SaucerSwap plugin so you can get swap quotes and execute HBAR ↔ token or token ↔ token swaps on SaucerSwap V2 from the CLI. Supports Hedera mainnet and testnet. You can quote without sending a transaction, then execute with configurable slippage.
Commands
saucerswap quotesaucerswap executeWhy This Plugin?
Swapping on SaucerSwap usually means using the UI or writing custom code against the router and quoter contracts. This plugin lets you quote and execute from the CLI with a payer (operator or
--payer), so you can script swaps or run one-off trades without leaving the terminal.What's Included
10) or tinybar (100t).--slippage(default 0.5%); applies slippage to minimum received.--network); constants for Quoter, Router, WHBAR, and WhbarHelper per network.--payer; execute signs and sends with that account.Architecture
PluginManifest.CommandExecutionResult(ADR-003).api.contract(contract query),api.txExecution(sign and send),api.keyResolver,api.network; plugin provides constants and path-encoding utils.Prerequisites
--payer) for execute.--network mainnetor--network testnet; SaucerSwap is not supported on previewnet/localnet.hcli token associate …).References