agentleFS
canddao1-dotcomcanddao1-dotcom/flare-agent-skills/skills/swap/SKILL.md

swap

Skill7 starsChanged 9 months agoMITView on GitHub

Token swaps on Flare DEXs. Execute swaps, get quotes, wrap/unwrap FLR. Triggers on "/swap", "swap tokens", "trade", "exchange".

4 other projects use a version of this.

Adopted by

Most recently taken up by

  • Other versions4 projects use a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 4

    1. ethereumdegen/stark-bot★ 45same name
    2. nirholas/agent-payments-sdk★ 9same name
    3. agiterra/crew-claude-code★ 0same name
    4. Phytonking/swap★ 0same name

    How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.

  • In this repository9 other files it gives its agents.

The file

We split this skill into the rules it gives an agent

1 rule. 0 are common, 0 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 4 edited versions we read keep these.

  • 0

    Distinctive

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Default is Enosys V3 — use agg for best-route comparison

    line 170

“Common” is measured: kept by at least 6 in 10 of the 4 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Swap Skill

Unified interface for token swaps on Flare network DEXs.

Quick Command

node skills/swap/scripts/swap.js <from> <to> <amount>

Subcommands

CommandDescription
(default)Enosys V3 swap (most liquidity)
aggAggregator - compares DEXs, routes to best
sparkSparkDex V3.1 swap
v2V2 swap (for BANK token)
quoteGet quote without executing
wrapWrap FLR to WFLR
unwrapUnwrap WFLR to FLR

Aggregator (Best Rates)

The aggregator compares quotes from Enosys V3 and SparkDex V3.1, then routes to the best venue:

# Get aggregated quote
node skills/swap/scripts/aggregator.js quote WFLR FXRP 100

# Execute via best route
node skills/swap/scripts/aggregator.js swap WFLR FXRP 100 --slippage 2

| pools | List available V3 pools |

Usage Examples

# Basic V3 swap (Enosys - default)
/swap WFLR FXRP 100

# Use specific fee tier
/swap WFLR SFLR 50 --fee 500

# SparkDex swap
/swap spark WFLR USDT0 100

# V2 swap for BANK
/swap v2 WFLR BANK 10
/swap v2 BANK WFLR 1

# Get quote only (no execution)
/swap quote WFLR FXRP 100

# Wrap/unwrap FLR
/swap wrap 100
/swap unwrap 100

# With slippage tolerance
/swap WFLR FXRP 100 --slippage 2

Supported Tokens

TokenAddressDecimals
WFLR0x1D80c49BbBCd1C0911346656B529DF9E5c2F783d18
sFLR0x12e605bc104e93B45e1aD99F9e555f659051c2BB18
FXRP0xad552a648c74d49e10027ab8a618a3ad4901c5be6
BANK0x194726F6C2aE988f1Ab5e1C943c17e591a6f605918
USD₮00xe7cd86e13AC4309349F30B3435a9d337750fC82D6
USDC.e0xfbda5f676cb37624f28265a144a48b0d6e87d3b66
CDP0x6Cd3a5Ba46FA254D4d2E3C2B37350ae337E94a0F18

Fee Tiers

TierPercentageBest For
5000.05%Stable pairs (WFLR/sFLR, stablecoins)
30000.3%Standard pairs (default)
100001%Volatile pairs

DEX Comparison

DEXBest ForRouter
Enosys V3Most pairs, highest liquidity0x5FD34090E9b195d8482Ad3CC63dB078534F1b113
SparkDex V3.1WFLR/USDT0, some exclusive pairs0x7a57DF6665B5b4B9f8C555e19502333D0B89aD59
Enosys V2BANK token onlyDirect pair swap

Options

OptionDescriptionDefault
--feePool fee tier (500, 3000, 10000)3000
--slippageSlippage tolerance %1
--dry-runSimulate without executingfalse

Common Workflows

Buy BANK

# 1. Wrap FLR if needed
/swap wrap 100

# 2. Swap via V2 (BANK only on V2)
/swap v2 WFLR BANK 100

Sell BANK

# 1. Swap BANK to WFLR
/swap v2 BANK WFLR 10

# 2. Unwrap if needed
/swap unwrap 100

Stake FLR as sFLR

/swap WFLR SFLR 100 --fee 500

USDT0 — Omnichain Stablecoin on Flare

USD₮0 (0xe7cd86e13AC4309349F30B3435a9d337750fC82D) is the LayerZero-native, omnichain version of Tether's USDT deployed on Flare mainnet. Agents can enter and exit USDT0 positions directly — no bridge step needed.

# Best rate into USDT0 from FLR
/swap agg WFLR USDT0 100

# Exit USDT0 back to FXRP
/swap agg USDT0 FXRP 50

# Check live USDT0 price via FTSO
/price USDT0

# Liquid-stake proceeds: USDT0 → sFLR
/swap agg USDT0 SFLR 100 --slippage 1

SparkDex V3.1 has dedicated WFLR/USDT0 liquidity; the aggregator picks it automatically when rates are better there.

Keystore

Default: ./keystore.json Agent wallet: YOUR_WALLET_ADDRESS


Routing Guide

Don't use when...

  • Bridging cross-chain (use /bridge)
  • Sending tokens without trading (use /send)

Use when...

  • Swapping tokens on Flare DEXs (Enosys, SparkDex, Blazeswap)
  • Getting best-route quotes across Flare DEXs
  • Wrapping/unwrapping FLR ↔ WFLR
  • Trading BANK token (V2 pools)

Edge Cases

  • Default is Enosys V3 — use agg for best-route comparison
  • BANK only trades on V2 pools (/swap v2 WFLR BANK)
  • Slippage default varies by pool — set explicitly for volatile pairs
  • Wrap/unwrap is gasless conversion (no DEX needed)

Success Criteria

  • Quote shows expected output and price impact
  • Swap returns tx hash with actual amounts received
  • Aggregator compares at least 2 DEXs

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.