feat: add swap auto-slippage option

Co-authored-by: deepfeature <1503768+deepfeature@users.noreply.github.com>
Agent-Logs-Url: https://github.com/GMGNAI/gmgn-skills/sessions/b2089672-9ca8-402c-be14-138b55c1bb98
This commit is contained in:
copilot-swe-agent[bot]
2026-03-26 07:52:26 +00:00
parent 247aaf96f9
commit bd533cb85e
5 changed files with 8 additions and 1 deletions
+2
View File
@@ -388,6 +388,7 @@ npx gmgn-cli swap \
--output-token <output_token_address> \
[--amount <input_amount> | --percent <pct>] \
[--slippage <n>] \
[--auto-slippage] \
[--min-output <amount>] \
[--anti-mev] \
[--priority-fee <sol>] \
@@ -408,6 +409,7 @@ npx gmgn-cli swap \
| `--amount` | No* | Input raw amount in minimal unit (e.g., lamports for SOL); required unless `--percent` is used |
| `--percent` | No* | Input amount as a percentage, e.g. `50` = 50%; required unless `--amount` is used; only valid when input token is not a currency (not SOL/BNB/ETH/USDC) |
| `--slippage` | No | Slippage tolerance, e.g. `0.01` = 1% |
| `--auto-slippage` | No | Enable automatic slippage |
| `--min-output` | No | Minimum output amount (raw amount) |
| `--anti-mev` | No | Enable anti-MEV protection (default true) |
| `--priority-fee` | No | Priority fee in SOL (≥ 0.00001 SOL, SOL only) |