LeoDex Beta kullanıyorsunuz. Özellikler kararsız olabilir.
LeoDexLeoDex

Crypto swap API

Swap via API

One free key for everyone. Same routes and fees as leodex.io.

The public key is being set up. Check back shortly.

Three calls. Any wallet.

No wallet to connect and nothing to sign. You send the funds yourself.

  1. 1GET /quote-deposit

    Get a quote

    Pick two assets and an amount. You see the price and fees before anything moves.

  2. 2POST /deposit-address

    Send to the deposit address

    Ask for an address, then send the exact amount to it from any wallet.

  3. 3POST /status

    Track it

    Check every 10 seconds until it says success. If it fails, it's refunded to you.

# 1 Get a quote
curl -s "https://api.leokit.dev/quote-deposit?from_asset=BTC.BTC&to_asset=ETH.ETH&amount=0.01&slippage_bps=300" \
  -H "Api-Key: YOUR_KEY"

# 2 Get a deposit address, then send exactly "amount" to it before "expires_at"
curl -s "https://api.leokit.dev/deposit-address" \
  -H "Api-Key: YOUR_KEY" -H "Content-Type: application/json" \
  -d '{"quote_id":"QUOTE_ID","from_address":"YOUR_BTC_REFUND_ADDRESS","to_address":"YOUR_ETH_ADDRESS"}'

# 3 Track it every 10 seconds until success, failed or refunded
curl -s "https://api.leokit.dev/status" \
  -H "Api-Key: YOUR_KEY" -H "Content-Type: application/json" \
  -d '{"quote_id":"QUOTE_ID"}'

Every route, errors and limits: swap-api.md

Every chain. One key.

Bitcoin, Ethereum, Solana, Zcash and every other chain leodex.io swaps. Your code gets all of them.

  • BitcoinBitcoin
  • EthereumEthereum
  • SolanaSolana
  • ZcashZcash
  • BaseBase
  • ArbitrumArbitrum
  • BNB ChainBNB Chain
  • AvalancheAvalanche
  • TRONTRON
  • XRP LedgerXRP Ledger
  • LitecoinLitecoin
  • DogecoinDogecoin
  • NEARNEAR
  • And more

0.45%

Per swap, the same as leodex.io.

0.02% on stablecoin and same-asset swaps

Same routes as leodex.io

Every quote checks the same providers leodex.io uses and returns the best offer first.

  • Chainflip
  • NEAR Intents
  • Relay
  • THORChain
  • Maya

No account

One public key. No signup, no wallet to connect.

Works right away

Refunds go to you

If a swap fails, the provider returns your funds to your refund address. LeoDex never holds them.

Works with your AI agent

Paste one prompt into any AI agent. It gets a live quote, asks you to confirm, then gives you the address to send to. It never asks for your keys.

Read swap-api.md
Your agentExample run

Swap 0.01 BTC to ETH. Send it to 0x8f3…c21, refunds to bc1q…7x4.

GET /quote-deposit
0.01 BTC →about 0.3412 ETHChainflip has the best rate, after the 0.45% fee. Create the deposit address?

Yes

POST /deposit-address

Send 0.01 BTC from any wallet

POST /statussuccess

About 0.3410 ETH arrived.

Questions

Is there a free crypto swap API?

Yes. The key on this page is free for everyone, with no signup. You only pay the swap fee shown in each quote: 0.45% on most swaps, 0.02% on stablecoin-to-stablecoin and same-asset swaps.

How do I swap Bitcoin to Ethereum with an API?

Call GET /quote-deposit with from_asset=BTC.BTC, to_asset=ETH.ETH and an amount. Then POST /deposit-address with the quote_id and your addresses, and send the BTC to the address it returns. POST /status tells you when the ETH has arrived.

Do I need an account?

No. Everyone uses the same public key shown on this page. Send it as the Api-Key header.

Is it non-custodial?

Yes. You send funds straight to the swap provider's deposit address and receive them at your own address. LeoDex never holds them.

What happens if a swap fails?

The provider refunds to the from_address you gave, and /status shows refunded.

Which coins and chains can I swap?

The same as leodex.io: Bitcoin, Ethereum, Solana, Zcash, Base, Arbitrum, BNB Chain, Avalanche, TRON, XRP, Litecoin, Dogecoin, NEAR and more, through Chainflip, NEAR Intents, Relay, THORChain and Maya. GET /assets lists every asset id.

Can my AI agent use it?

Yes. Paste the prompt from this page, or point your agent at leodex.io/swap-api.md. It gets a live quote and asks you to confirm before creating a deposit address, and it never asks for your keys.

Are there rate limits?

Fair-use limits per visitor stop abuse, and normal use never hits them. A 429 means slow down and retry.

Go further.

  1. 1Non-custodial: you send funds straight to the swap provider. LeoDex never holds them.
  2. 2Don't use this key if you are a sanctioned person or in a sanctioned jurisdiction, or to move proceeds of crime.
  3. 3Providers may screen addresses and refuse or refund swaps.
  4. 4No load testing or limit evasion. We may rotate the key at any time; this page always shows the current one.
  5. 5We don't log IP addresses.