> ## Documentation Index
> Fetch the complete documentation index at: https://docs.swaps.xyz/llms.txt
> Use this file to discover all available pages before exploring further.

# Overview

> Integrate Swaps' stableswap protocol at the contract level — route over on-chain liquidity directly, without the API.

Swaps runs a dedicated **stableswap protocol**: stable-pair liquidity with
pricing far tighter than general-purpose AMMs, live on **Solana and five EVM
chains**. The Protocol Reference documents how to integrate it at the
**contract level** — no API in the loop.

This integration pattern is ideal for **DEX aggregators, solvers, and routing
infrastructure** that route over on-chain liquidity directly rather than
integrating via APIs: you quote and execute against the contracts yourself,
keep full control of transaction construction, and plug the stableswap venues
into your own routing graph like any other source.

If you want quotes, routing, transaction construction, and tracking handled
for you, use the [Swap API](/swap-api-reference/overview) instead — it routes
through the stableswap protocol automatically (see the
[Stableswaps guide](/guides/stableswaps)).

## Why route over the stableswap venues

* **Tighter stable pricing.** Fees are set per pair, per direction, and
  refreshed continuously by an off-chain pricing keeper — not by a static
  curve.
* **Gas-free quoting.** Read on-chain fee state (Solana) or call `view` quote
  functions (EVM) — quoting costs nothing and slots into any pricing loop.
* **Permissionless at default rates.** No allowlist, no API key — integrate
  and route today.
* **Custom pricing for partners.** Negotiated rates are delivered through
  Swaps-signed data: an Ed25519 router proof on Solana, per-recipient fee
  lookup on EVM. [Reach out to us](https://console.swaps.xyz) to get set up.
* **One protocol, both VMs.** The same liquidity model on Solana and EVM, so
  one integration story covers six chains.

## API vs protocol integration

|                          | Swap API                                        | Stableswap protocol (this reference)                               |
| ------------------------ | ----------------------------------------------- | ------------------------------------------------------------------ |
| Best for                 | Apps and wallets                                | DEX aggregators, solvers, routers                                  |
| Quoting                  | `getAction` returns a ready transaction         | Read on-chain state / call `view` quote functions                  |
| Routing                  | Swaps picks the best venue across all liquidity | You route over the stableswap venues directly in your own graph    |
| Transaction construction | Done for you                                    | You build and submit                                               |
| Tracking                 | `getStatus` + webhooks                          | Your own infrastructure                                            |
| Pricing                  | Included in the quote                           | Default rates permissionlessly; custom rates via Swaps-signed data |

## Integrate the venues

<Columns cols={2}>
  <Card title="Stableswap on Solana" icon="sun" href="/protocol-reference/stableswap-solana" horizontal>
    The on-chain program: swap instruction, pair-state fees, and router
    proofs for custom pricing.
  </Card>

  <Card title="Stableswap on EVM" icon="ghost" href="/protocol-reference/stableswap-evm" horizontal>
    The GhostExchange contract: a quote-and-swap interface over
    cross-collateral pools on Ethereum, Arbitrum, Base, Polygon, and Binance.
  </Card>
</Columns>
