# Swapping

## Buying

1. Within the main menu of Ghobot press **🟢 BUY** to begin a swap.\ <br>

   <figure><img src="/files/KbnYYJgzrXUa1lMthDm8" alt=""><figcaption></figcaption></figure>
2. You will be asked to reply with the contract address of the token. In this example we have entered Shiboo using contract address: \
   \
   **4d7c5ece0a0dfeea697e6e79cbc9d75d589f2046dff701f944295f630825bd3d**\ <br>

   <figure><img src="/files/epkG3ZsGxJOmEcLcV30N" alt=""><figcaption></figcaption></figure>
3. Token information will be displayed with the options available to perform the swap.\
   \
   The wallet with the highest amount of funds will be pre-selected, you can select or change wallet if you have multiple generated by pressing 💳 symbol. \
   \
   Pre-selected amounts to swap are offered or to enter a specific amount press ️**🖋️ x CSPR** and reply with the amount required, in this example we replied with **100**.

<figure><img src="/files/6w1fikX5jxNHWMQfxVWd" alt=""><figcaption></figcaption></figure>

4. Once happy with you options and settings selected press **Submit Swap** to perform the transaction. \
   \
   Successfully submitted swaps will display a message with your transaction hash.

<figure><img src="/files/16hJGPvYYjLT1DD9nEkW" alt=""><figcaption></figcaption></figure>

5. Once the Casper Network has successfully finalised your transaction you will receive a message of confirmation after a short amount of time.

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

## Selling

1. Press **🔴 SELL**, you will be asked to enter the contract address of the token to sell. \
   \
   Using Shiboo again for the example we will enter contract:\
   \
   **4d7c5ece0a0dfeea697e6e79cbc9d75d589f2046dff701f944295f630825bd3d**\ <br>

   <figure><img src="/files/FkL9R6xvApbQz0ujr2O1" alt=""><figcaption></figcaption></figure>
2. This will display the token information, balance of tokens and sell swap options. \
   \
   The process to sell is the same as when buying, select or enter the required amount to sell and check swap settings. \
   \
   Press **Submit Swap** to perform the transactio&#x6E;**.** Confirmation messages will appear for successful swaps.<br>

<figure><img src="/files/0pzsxHzpKVBYrJgAAmT7" alt=""><figcaption></figcaption></figure>

## Swap Settings

#### 🌊 Slippage

Due to how AMM's work many trades may be occurring constantly changing the price of a token. If your swap fails please check the deploy hash for error codes,  error 65527 will indicate you need to increase the slippage. To do so press the **🌊 Max Slippage** button and adjust accordingly, we would suggest increasing by increments 10% if having trouble.

#### ⏳ Deadline

The default time set to 20 minutes is the given amount for the TX to process before failing. We suggest you do not modify this setting unless advised due to heavy network congestion.


---

# 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.friendly.market/products/ghobot-or-your-casper-trading-companion/swapping.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.
