# Swaps

Swaps in Sonus are different from trades on traditional platforms. Sonus does not use an order book to represent liquidity or determine prices. Sonus uses an automated market maker mechanism to provide instant feedback on rates and slippage.

The automated market making algorithm used by Sonus revolves around the constant product formula x\*y=k, where k is the invariant.

Each pair on Sonus is actually underpinned by a liquidity pool. Liquidity pools are smart contracts that hold balances of two unique tokens and enforces rules around depositing and withdrawing them.

When either token is withdrawn (purchased), a proportional amount of the other must be deposited (sold), in order to maintain the constant.

#### Liquidity provider fees <a href="#liquidity-provider-fees" id="liquidity-provider-fees"></a>

There is a default **0.3%** fee ( this can vary based on the assets in the pair ) for swapping tokens. \
**This fee is distributed in two different ways:**\
**- Staked LP : Fees are added onto the pool's gauge where they will be distributed to gauge veSONUS voters at the end of the epoch;**\
**- Unstaked LP : Fees go straight into the liquidity provider's position when a swap occurs.**

For unstaked LPs this increases the value of liquidity tokens, functioning as a payout to these liquidity providers proportional to their share of the pool.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.sonus.exchange/dex-related/v2-volatile-amm/swaps.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
