# Swap

**Swap**\
The user can execute their desired trade by swapping. Fill in the desired amount of token to sell \[1], to see the amount of resulting tokens bought \[2]. To switch the token bought, press the switch button \[3].\
\
When swapping, the price impact for the asset you are receiving is shown as a percentage \[4]. If the percentage is green, you're arbitraging. If it's red, you're either trading away from the peg, or overshooting the arbitrage.

<figure><img src="/files/zz6ooG6y6pd2SlgCeIZo" alt=""><figcaption><p>Swapping between XRD and STAB</p></figcaption></figure>

**Manage liquidity**\
Swapping using the XRD/STAB pool relies on users to provide liquidity. This can be profitable, and a Real 7d APY to show whether it is or not \[1]. The total amount of liquidity provided is also shown \[2].\
\
**Adding liquidity** is simple. Go to the correct section of the interface \[3], and choose how much STAB or XRD you want to provide as liquidity \[4]. The interface will calculate the necessary amount for the other token, try it out!

<figure><img src="/files/BZIi9UKD86KCglV3yvXN" alt=""><figcaption><p>Providing XRD/STAB liquidity</p></figcaption></figure>

Providing liquidity will result in <mark style="color:red;">LPSTAB</mark> tokens for the user, which can be used to keep track of the liquidity you've provided and be exchanged in return for the provided liquidity. When you want to **remove liquidity**, go the correct section \[1], and input the amount of LPSTAB tokens \[2] you want to exchange in return for their underlying liquidity.

<figure><img src="/files/ZboEx985TywFoUdFTxDN" alt=""><figcaption><p>Removing XRD/STAB liquidity</p></figcaption></figure>

\
**Statistics**\
On the bottom of the page, some useful statistics are shown. Use them as you see fit!

<figure><img src="/files/jHwl9vrywqAmcVqPSQA6" alt=""><figcaption></figcaption></figure>


---

# 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.ilikeitstable.com/stab-protocol/using-stab-protocol/swap.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.
