# What is SEGA?

{% hint style="info" %}
SEGA is a decentralized protocol designed to power lightning-fast trades, permissionless pool creation, and innovative yield-earning opportunities, making it the first and most decentralized AMM on Sonic SVM.\
\
With high-performance infrastructure and cutting-edge features, SEGA delivers a seamless, efficient DeFi experience. Built for peer-to-peer market making and swapping of SPL tokens on Sonic SVM, it redefines decentralized trading and liquidity provision.
{% endhint %}

#### **Why is SEGA Different?**

* **Faster and Cheaper:** Built on Sonic SVM, SEGA offers transaction speeds that outpace Solana with far lower gas fees.
* **Permissionless Pool Creation:** Users and projects can easily create pools for any asset, unlocking seamless liquidity provision.&#x20;
* **Ecosystem Rewards:** Add token incentives to any pair or pool to boost yields for liquidity providers and grow a thriving ecosystem.

#### **What Can I Do on SEGA?**

* **Trade and Swap:** SEGA’s intuitive swap feature lets you instantly exchange any two tokens in supported liquidity pools with ease.
* **Create a Pool:** Set up a liquidity pool for any asset in a few clicks, it’s tradeable and integrated into the Sonic SVM ecosystem.
* **Earn Trading Fees:** Provide liquidity to SEGA pools and earn a share of fees from every swap, building a passive income stream.

#### **Power Your Project with SEGA**

SEGA equips your project with a powerful, permissionless toolkit for managing liquidity, distributing tokens, or boosting growth. Its versatile features let you innovate and scale effortlessly in the decentralized space.


# Quickstart

{% hint style="info" %}
Welcome to SEGA! To get started and interact with SEGA easily, follow these simple steps:
{% endhint %}

#### Step 1: Set Up Your Wallet on Sonic SVM Mainnet

To interact with the SEGA protocol, **you’ll need a wallet that supports Sonic SVM Mainnet and** **ensure your wallet is configured to the Sonic SVM Mainnet.**&#x20;

Currently, native support for Sonic SVM Mainnet is available in the following wallets(you could also check Sonic SVM's Official doc [here](https://docs.sonic.game/users/readme/setting-up-your-wallet)):

* [OKX Web3 Wallet](https://mirrorworldfun.notion.site/Sonic-SVM-Mainnet-Network-Setting-OKX-Wallet-1a62d67d7b5f80b3ab45d1680a2ebf63)
* [Bybit Web3 Wallet](https://mirrorworldfun.notion.site/Sonic-SVM-Mainnet-Network-Setting-Bybit-Wallet-1a72d67d7b5f80f89fd7fb735f8fb7c0)
* [Nightly Wallet](https://mirrorworldfun.notion.site/1a62d67d7b5f8094b3bdf92dec32b9e8?pvs=25)
* Backpack Wallet

To switch to the Sonic SVM Mainnet, simply navigate to the network selection entry in your wallet and choose Sonic SVM. Once selected, your wallet will be connected to the correct network, allowing you to interact with SEGA.

#### Step 2: Ensure Sufficient Gas and Assets

Before interacting with SEGA, **make sure your wallet contains enough gas(SOL) and the relevant trading pair assets**. If you don’t have the necessary assets, you can easily bridge them using the [HyperGrid Bridge](https://bridge.sonic.game/), which supports seamless cross-chain transfers. You may refer to the [Bridge guide](https://mirrorworldfun.notion.site/HyperGrid-Bridge-Guide-1a62d67d7b5f8087a189da3cdfa78868).

Once you’ve completed these two steps, you’re ready to start interacting with SEGA! Enjoy lightning-fast trades, permissionless pool creation, and innovative yield-earning opportunities at your fingertips.


# Swapping

Steps to Swap

Swapping tokens on the SEGA protocol is a seamless and straightforward process, allowing you to quickly exchange assets and take advantage of lightning-fast trades. Below, you’ll find step-by-step instructions on how to perform a swap, as well as important considerations to ensure a smooth and successful transaction.

#### **Step1.** **Navigate to the Swap Page:**

Redirect to the **Swap** page from the navigation bar.

<figure><img src="https://3555825233-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFh7yHhIZBfvcedBz9Z4f%2Fuploads%2FXxM7MHadXj36nCkUpHnJ%2F26921740558424_.pic.jpg?alt=media&amp;token=03eeff03-b1ca-4f43-8270-e91f461a084c" alt=""><figcaption></figcaption></figure>

#### **Step2. Connect Your Wallet:**

Click the **Connect Wallet** button to link your web3 wallet to SEGA. Ensure that your wallet is set to the Sonic SVM Mainnet. If you haven’t already, refer to the [Quickstart](/getting-started/quickstart#step-1-set-up-your-wallet-on-sonic-svm-mainnet) section to get started.

<figure><img src="https://3555825233-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFh7yHhIZBfvcedBz9Z4f%2Fuploads%2F9YFSi3w00wbljStn9tlL%2F26931740558478_.pic.jpg?alt=media&amp;token=8a85a839-21c7-4655-ac9e-e082e08948fa" alt=""><figcaption></figcaption></figure>

#### **Step3. Select Tokens and Enter Amount:**

* On the SEGA interface, select the token you want to swap from and the token you want to receive.
* Make sure that both tokens are part of a supported trading pair on the SEGA protocol.
* Enter the amount of the token you wish to swap. The system will automatically calculate the equivalent amount of the token you will receive based on the current exchange rate.
* You can also search by token name or paste the Smart Contract address to locate the token.

<figure><img src="https://3555825233-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFh7yHhIZBfvcedBz9Z4f%2Fuploads%2FelqIDucyL50NDjxhYM4O%2F26941740558611_.pic.jpg?alt=media&amp;token=4d1d3362-3b8a-4dec-ba32-767869309255" alt=""><figcaption></figcaption></figure>

#### **Step4. Confirm the Swap:**

* Before confirming the swap, carefully review the transaction details, including the amount, the tokens involved, and the gas fees.
* Once you’re satisfied with the details, confirm the swap in your wallet. The transaction will be processed on the Sonic SVM network, and you’ll receive your swapped tokens shortly after.

#### Notes:

* **Slippage Tolerance**: Depending on the liquidity of the trading pair, there may be slight variations in the expected swap amount. Make sure to check the slippage tolerance settings, which will help avoid significant price differences during the swap.
* **Gas Fees**: Swapping assets on SEGA involves a small gas fee, which is required to process your transaction on the Sonic SVM network. Ensure you have enough gas(SOL) in your wallet to cover these fees.
* **Asset Availability:** Make sure the tokens you’re swapping are available and supported on the SEGA protocol. If you’re unsure, check the supported assets list or visit the SEGA platform for further details.
* **Transaction Speed:** Thanks to the Sonic SVM network’s speed, swaps are processed almost instantly. However, transaction times may vary slightly depending on network congestion or other factors.<br>


# Swap FAQ

Swap Common Questions

To help you better understand the basics of swapping on SEGA, here are some common questions and answers:

<details>

<summary>What Is a Swap?</summary>

A swap is the exchange of one token for another. SEGA executes swaps via smart contracts on SonicSVM, using liquidity from depositors’ pools. Unlike custodial exchanges, no intermediaries are involved. The exchange rate follows predefined mathematical formulas (viewable on GitHub) and adjusts based on token availability in the pools.

</details>

<details>

<summary>What Is Liquidity?</summary>

SEGA’s liquidity is sourced from its own pools. The SEGA routing engine optimizes swaps by navigating multiple pools to secure the best execution price and minimize slippage.

</details>

<details>

<summary>What Is Token Lising?</summary>

SEGA operates as a decentralized protocol with permissionless token listing. Any project or team can create a pool and list their token. Always verify the contract address before swapping to ensure token legitimacy.

</details>

<details>

<summary>What Are the Fees?</summary>

Swapping in SEGA liquidity pools incurs 0.25% fees.

</details>

<details>

<summary>What Is Price Impact?</summary>

Price impact is the difference between a token’s current market price and the price you receive after a swap. It’s driven by your trade size relative to the pool’s liquidity. Larger trades in low-liquidity pools increase token prices, resulting in unfavorable price impact. For better rates, reduce your trade size or choose a pool with higher liquidity.

</details>

<details>

<summary>What Is Slippage Tolerance?</summary>

Slippage is the variance between a swap’s expected price and its final execution price. SEGA lets you set a slippage tolerance, defining the maximum acceptable price difference. If slippage exceeds this limit, the swap fails. A higher tolerance may lead to less favorable pricing, so adjust carefully.

</details>

<details>

<summary>Why Did My Transaction Fail? </summary>

Common reasons include:

* **Insufficient SOL:** Network fees (gas) require SOL—keep at least 0.05 SOL in your wallet.
* **Slippage Tolerance:** If pool prices shift beyond your set tolerance, the transaction fails. Increase it on the swap interface
* **Pending Approvals:** A “Making Transaction” notice means your SPL wallet needs approval—confirm it promptly.

</details>

<details>

<summary>Can I Swap On Mobile?</summary>

Yes, use your SPL mobile wallet’s built-in browser to access SEGA and swap tokens seamlessly.

</details>

<details>

<summary>Still Have Questions?</summary>

Join the SEGA [Discord](https://discord.com/invite/sk8mGwb4A4) or follow us on [X](https://x.com/Sega_so) for 24/7 support. Our community managers are ready to assist!

</details>


# Provide Liquidity

Steps to Add Liquidity

SEGA’s liquidity pools enable anyone to provide liquidity by depositing their assets into a pool. Here, we use the **USDC-USDT** pool as an example.

#### **Step1. Navigate to the Liquidity Page:**

Go to the **Liquidity** page and locate the **USDC-USDT** pool. Click **"Deposit"** next to it.

<figure><img src="https://3555825233-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFh7yHhIZBfvcedBz9Z4f%2Fuploads%2FXksqjIdh0tJbQdSVeiqq%2F26951740558867_.pic.jpg?alt=media&amp;token=bbd94f3f-4ca2-47e4-a373-693c8c6bf157" alt=""><figcaption></figcaption></figure>

#### **Step2. Enter Deposit Amount:**

* Specify the amount you wish to deposit.
* Click **"Enter Token Amount"** to proceed.

<figure><img src="https://3555825233-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFh7yHhIZBfvcedBz9Z4f%2Fuploads%2FY9oselLztcZH43x64wIl%2F26961740559038_.pic.jpg?alt=media&amp;token=269c7354-3e99-4482-8720-a6ae59c1ff88" alt=""><figcaption></figcaption></figure>

#### **Step3. Confirm the Transaction:**

* Approve the transaction in your wallet when prompted.
* Ensure your wallet has sufficient balance to cover the deposit and any associated gas fees.

***

#### Success!

By completing the steps above, you have successfully added liquidity to SEGA!


# LP FAQ

LP Common Questions

To help you better understand Liquidity Pools (LP) and how to provide liquidity on SEGA, here are some common questions and answers:

<details>

<summary><strong>What’s APR All About?</strong></summary>

APR (Annual Percentage Rate) on SEGA reflects pool and farm yields, calculated from daily (default), weekly, or monthly performance. These figures are just snapshots—past gains don’t guarantee future wins.

</details>

<details>

<summary><strong>Where Does the Yield Come From?</strong></summary>

SEGA’s yield flows from two main streams:

**--Maker Fees:** Collected from swaps in the pool.&#x20;

\--**Eco Rewards:** Ecosystem partners contribution

</details>

<details>

<summary><strong>Why Provide Liquidity to SEGA AMM Pools?</strong></summary>

Liquidity providers score big:

* **Swap Fees:** Each pool trade takes a 0.25% fee—84% goes back to the pool for LPs, 16% fuels SEGA Ecosystem & protocol.

*New to impermanent loss? Peek at this primer to get the basics*, [reviewing this article](https://blog.bancor.network/beginners-guide-to-getting-rekt-by-impermanent-loss-7c9510cb2f22) for a basic understanding is highly recommended.

</details>

<details>

<summary><strong>What Are LP Tokens?</strong></summary>

LP (Liquidity Provider) tokens are your proof of ownership in a pool. Drop SOL and SEGA into the SOL-SEGA pool, and you’ll snag SOL-SEGA LP tokens, visible in your Sonic SVM wallet.

</details>

<details>

<summary>Why Did My Transaction Fail? </summary>

Common reasons include:

* **Insufficient SOL:** Network fees (gas) require SOL—keep at least 0.05 SOL in your wallet.
* **Slippage Tolerance:** If pool prices shift beyond your set tolerance, the transaction fails. Increase it on the swap interface
* **Pending Approvals:** A “Making Transaction” notice means your SPL wallet needs approval—confirm it promptly.

</details>

<details>

<summary>Your question is not answered in this FAQ? </summary>

Join the SEGA [Discord](https://discord.com/invite/sk8mGwb4A4) or follow us on [X](https://x.com/Sega_so) for 24/7 support. Our community managers are ready to assist!

</details>

<br>


# Creating a Pool

Steps to Create a Liquidity Pool

Creating a liquidity pool on SEGA allows you to provide assets to the protocol, enabling seamless token swaps while earning rewards. Setting up a pool is a straightforward process, but it’s important to follow the correct steps and understand the key considerations to ensure its success:

#### **Step1. Navigate to the Create Pool Page:**

Click **Liquidity** in the navigation bar, then click **Create** in the top-right corner.

<figure><img src="https://3555825233-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFh7yHhIZBfvcedBz9Z4f%2Fuploads%2FjwvmEYe6ByM2T5lu1ZpD%2F26981740559646_.pic.jpg?alt=media&amp;token=e67bc242-1f91-4a08-a305-5e01d07c9ace" alt=""><figcaption></figcaption></figure>

#### **Step2.** **Initialize the Liquidity Pool:**

\- **Set the Starting Price for the Base Token:**

Specify the number of Quote Tokens required to purchase 1 Base Token.

\- **Set Initial Liquidity for Base and Quote Tokens:**

Enter the amount for one token, and the corresponding amount for the other token will be calculated based on the starting price of the Base Token.

\- **Ensure Sufficient Funds:**

Confirm you have enough funds in your wallet to cover the initial liquidity, then click **"Initialize Liquidity Pool"**.

**IMPORTANT:** Once the pool is confirmed and initialized, the starting price, liquidity, and start time cannot be modified.

<figure><img src="https://3555825233-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFh7yHhIZBfvcedBz9Z4f%2Fuploads%2FnlnxNFuLHqT6IJ1S8e5Q%2F26991740559775_.pic.jpg?alt=media&amp;token=cc3d5156-5090-4d88-b95d-01f5143e08b4" alt=""><figcaption></figcaption></figure>

#### **Step3. Approve the Transaction:**

\- After clicking **"Confirm"**, approve the transaction in your wallet.

\- This step will initialize the pool, create the AMM account and ID, and allocate liquidity.

#### **Step4. Final Steps:**

\- Once the transaction is confirmed, your new liquidity pool (LP) will be created.

\- You will receive the AMM ID, and the pool will launch at the specified start time.

***

#### Review Your Created Pools <a href="#review-your-created-pools" id="review-your-created-pools"></a>

You can return to the **Create Pool** page anytime to review the liquidity pools you’ve previously created and check their AMM IDs.


# SEGA Pool Creation & Ecosystem FAQ

Pool Creation Common Question

To help you better understand the process of creating a liquidity pool on SEGA, here are some common questions and answers:

<details>

<summary>Can I Lock My LP Tokens?</summary>

SEGA doesn’t currently offer a built-in feature to lock Liquidity Provider (LP) tokens. If you want to permanently secure your liquidity in a pool, you can burn your LP tokens or the associated token account. Be aware: these actions are irreversible, and you won’t be able to recover the deposited liquidity. SEGA cannot be held liable for any losses resulting from burning LP tokens

</details>

<details>

<summary>How Are AMM Token Vaults Credited When New Pools Are Created?</summary>

When a new pool is created, a small fraction of the initial liquidity( $$10^{\text{lpdecimals}}$$) is credited to the asset vaults, so that the initialized pool liquidity is:

$$liquidity\_{\text{init}} = liquidity - 10^{\text{lpdecimals}}$$\
\
This mechanism preserves pool integrity and supports seamless operation on SonicSVM.

</details>

<details>

<summary>Why Can’t I See My Pool?</summary>

It may take a few minutes for your newly created pool to appear on SEGA’s interface. If you set up the pool with a timer, check its status on the swap page: entering the base and quote tokens will show a countdown instead of the swap button. Share this timer with your community to build excitement!&#x20;

*<mark style="color:red;">**Pro tip: Quickly filter for your pools by selecting “Show Created” at the top of the list.**</mark>*

</details>

<details>

<summary><strong>“Pool Already Created” Error</strong></summary>

This message means a pool for your token pair already exists on SEGA. No need to create a new one—just add liquidity to the existing pool to join the action.

</details>

<details>

<summary>“Token Verify Error” or “Freeze Authority Enabled”</summary>

This error signals that your token’s freeze authority is active. You can disable it through code or use a no-code SPL manager like Squads to resolve it.

</details>

<details>

<summary><strong>Other Issues or Unanswered Questions?</strong></summary>

If you hit a snag or your query isn’t covered here, connect with SEGA’s support on [Discord](https://discord.com/invite/sk8mGwb4A4) or [X](https://x.com/Sega_so). Our team is available 24/7 to assist!

</details>


# Pool Creation Fees - 待确认gas费，地址

CPMM Pools The following fees apply when creating CPMM pools: 1) Sonic Network fees: Creating the pool accounts and signing the transaction amounts for 0.1 Sonic +? (priority fees set by the user) 2)

CPMM Pools

The following fees apply when creating CPMM pools: 1) Sonic Network fees: Creating the pool accounts and signing the transaction amounts for <mark style="color:red;">0.1 Sonic</mark> +? (priority fees set by the user)

2\) Creating the LP token account (ATA)\*: 0.00203928 SOL

3\) [Protocol Fee](https://docs.raydium.io/raydium/protocol/the-ray-token/protocol-fees): <mark style="color:red;">1 Sonic - 5 Sonic ?</mark> is collected for CP-Swap (CPMM) pools during pool creation to deter pool spamming and ensure protocol sustainability. CP-Swap (CPMM) pool creation fees are collected by: <mark style="color:red;">DNX\*\*\*RAdNC8?</mark> Fees are controlled by SEGA protocol multisig, and reserved for protocol infrastructure costs.

Note that it is impossible to close a pool once created. None of the fees mentioned above are refundable.

**Pool Creation Fees on SEGA Dex**

Creating a liquidity pool on SEGA Dex is designed to be simple and accessible, but it does involve certain fees to ensure the sustainability and security of the platform. These fees are used to support the ecosystem, maintain infrastructure, and incentivize network participants.

***

**What Are Pool Creation Fees?**

When you create a new liquidity pool on SEGA Dex, a small fee is charged to cover the costs associated with initializing and maintaining the pool. This fee is typically deducted from the initial liquidity you provide.

***

**How Pool Creation Fees Work**

1. **Fee Structure**:
   * The fee is calculated as a percentage of the initial liquidity provided.
   * For example, if the fee is **0.25%** and you provide **100,000 units** of liquidity, the fee would be 250 **units**.
2. **Fee Distribution**:
   * A portion of the fee may go to the ecosystem or protocol treasury to support development and maintenance.
   * Another portion may be distributed as rewards to stakers or liquidity providers in the ecosystem.
3. <mark style="color:red;">**Transparency**</mark><mark style="color:red;">:</mark>
   * <mark style="color:red;">All fees are clearly displayed during the pool creation process, so you know exactly what you’re paying.</mark>
   * <mark style="color:red;">Fees are recorded on-chain, ensuring complete transparency.</mark>

***

**Why Are Pool Creation Fees Necessary?**

* **Sustainability**: Fees help fund the ongoing development and maintenance of SEGA.
* **Security**: Fees discourage spam and ensure that only serious participants create pools.
* **Ecosystem Growth**: A portion of the fees is reinvested into the ecosystem to incentivize users and grow the platform.

***

**How to Minimize Pool Creation Fees**

* **Plan Ahead**: Ensure you have sufficient liquidity to cover both the pool creation and the fees.
* **Choose Popular Pairs**: Creating pools for high-demand tokens can help you earn back the fees through trading volume.
* **Monitor Fee Updates**: SEGA may adjust fees over time, so stay informed to optimize your costs.

***

#### **Example of Pool Creation Fees**

Let’s say you want to create a new pool with **10,000 units** of liquidity, and the pool creation fee is **0.25%**:

1. **Fee Calculation**:

   Fee=10,000×0.25%=25 units
2. **Initial Liquidity After Fee**:

   Initial Liquidity=10,000−25=9,975 units

***

#### **Conclusion**

Pool creation fees are a small but essential part of the SEGA ecosystem, ensuring the platform remains sustainable, secure, and vibrant. By understanding and planning for these fees, you can maximize your returns and contribute to the growth of decentralized finance.

[<br>](https://docs.raydium.io/raydium/pool-creation/burn-and-earn)


# SEGA Protocol

### SEGA: A Unique AMM Platform <a href="#sega-a-unique-amm-platform" id="sega-a-unique-amm-platform"></a>

SEGA is a decentralized protocol designed to power lightning-fast trades, permissionless pool creation, and innovative yield-earning opportunities, making it the first and most decentralized AMM on Sonic SVM.<br>

Unlike traditional AMM platforms, SEGA operates as an AMM V2, providing on-chain liquidity that enhances the overall trading experience. This integration allows SEGA’s users and liquidity pools to access deeper liquidity and faster transactions. Powered by Sonic SVM, SEGA ensures improved execution efficiency, making it a superior choice for users seeking seamless and efficient trading.

***

#### Liquidity Model: Constant Function K = Y \* X <a href="#liquidity-model-constant-function-k-y-x" id="liquidity-model-constant-function-k-y-x"></a>

SEGA currently employs the constant function **K = Y \* X**, which has the unique property of being stateless. This means that given any two tokens, without requiring information about their relative prices or values, SEGA can provide “infinite” liquidity to traders.

When users exchange token 𝑥  for token 𝑦 , the actual amount of 𝑦  received is:

$$
y\_{\text{final}} = \frac{y \times \Delta x}{x + \Delta x}
$$

where Δ𝑥 is the amount of token 𝑥  paid by the user.

***

**Liquidity Provision and LP Tokens**

* **Liquidity Injection**: Users provide two tokens (e.g., Token Sega and Token USDC) in proportion and deposit them into the pool.
* **LP Tokens**: Liquidity providers (LPs) receive LP tokens representing their share in the pool. These LP tokens can be redeemed for the principal and earned fees.
* **Impermanent Loss Management**: Like Uniswap V2, LPs may face impermanent loss risks when the prices of tokens in the pool fluctuate.

***

#### Incentives for Liquidity Providers <a href="#incentives-for-liquidity-providers" id="incentives-for-liquidity-providers"></a>

* **Trading Fee Rewards:** Liquidity providers earn rewards from trading fees by contributing liquidity to SEGA pools.
* **Farming Rewards (coming):** Key liquidity pools are incentivized with farming rewards to attract more participation.
* **Customizable Rewards:** Projects can add additional reward tokens to encourage liquidity provision.

***

#### Empowering New Projects <a href="#empowering-new-projects" id="empowering-new-projects"></a>

New projects can use SEGA to:

* **Create Trading Markets:** Launch new trading markets effortlessly.
* **Provide Immediate Liquidity:** Ensure their tokens have liquidity from day one, enabling traders to buy in easily.

By utilizing SEGA, projects can quickly establish a functional market and attract users, creating a seamless experience for both liquidity providers and traders.

***

#### Powered by Sonic <a href="#powered-by-solana" id="powered-by-solana"></a>

The underlying Sonic SVM enhances SEGA’s capabilities with its unmatched speed and efficiency, ensuring a smooth and cost-effective trading experience for all users.


# Protocol Fees

When interacting with the SEGA protocol, there are two primary types of fees to be aware of: trading fees and pool creation fees. These fees are designed to support the ecosystem and reward liquidity providers.

### Trading Fees on SEGA <a href="#trading-fees-on-sega" id="trading-fees-on-sega"></a>

For every swap that occurs in a pool on SEGA, a small trading fee is collected. The fee structure varies depending on the specific pool, and the collected fees are distributed to incentivize liquidity providers and the treasury.

***

#### Fee Structure for Standard AMM Pools <a href="#fee-structure-for-standard-amm-pools" id="fee-structure-for-standard-amm-pools"></a>

* **Trading Fee:** The trading fee for standard AMM(AMM V2) pools is **0.25%** per swap.
  * **Liquidity Providers:** Receive **84%** of the trading fee for every swap in the pool.
  * **Treasury:** Allocated **16%** of the collected fees to support the protocol.

***

### Pool Creation Fee <a href="#pool-creation-fee" id="pool-creation-fee"></a>

Creating a standard AMM(AMM V2)  pool incurs a **0.15 SOL** fee. This fee is designed to:

1. Prevent spam creation of pools.
2. Ensure the sustainability of the SEGA protocol.

<br>

<br>


# Key Addresses

For developers and users interacting with the SEGA protocol at a technical level, here are some important contract addresses you’ll need to know. These addresses are used for various functions, including swapping, administration, and liquidity pool management.

| Name               | Address                                      |
| ------------------ | -------------------------------------------- |
| CpSwap             | SegazTQwbYWknDZkJ6j2Kgvm5gw3MrHGKtWstZdoNKZ  |
| Admin              | Ajk8d9bERSaFdeoT1d8JUVfaDayrYLnAdgeB47TFMUaG |
| CreatePoolReceiver | 2HbjxVVKJ7Ct72Rcd8WK4VTqmwTXL5aAggkH1CHGFGmh |


# Social Media

For the latest updates, news, and announcements about the SEGA protocol, follow us on our social media channels and join our community. Staying connected will ensure you’re always in the loop with new features, opportunities, and insights.

### X (Twitter) <a href="#x-twitter" id="x-twitter"></a>

<https://x.com/Sega_so>

### Discord <a href="#discord" id="discord"></a>

<https://discord.gg/5K3GNFyqAR>


# Audit

To ensure the security and reliability of the SEGA protocol, an in-depth [audit](https://beosin.com/audits/Sega-Swap_202502261538.pdf) has been conducted.&#x20;

#### Audit Report Overview

The audit was carried out by [Beosin](https://beosin.com), a reputable blockchain security firm. The report provides an analysis of SEGA’s smart contracts, highlighting any potential risks and validating the security measures in place. You can view the full audit report here: [SEGA Protocol Audit Report](https://beosin.com/audits/Sega-Swap_202502261538.pdf).


# SEGA Token

Token Distribution

Total supply : 4.2B Sega&#x20;

40% Liquidity Mining&#x20;

50% Team & Ecosystem

10% IDO

<figure><img src="https://3555825233-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFh7yHhIZBfvcedBz9Z4f%2Fuploads%2FpBi5svMnaQnl4pDiVnjD%2Fimage.png?alt=media&amp;token=3b3d512f-e00e-4b91-b48b-9118d15465db" alt=""><figcaption></figcaption></figure>


# SEGA - Internal - 待确定

Sega Detailed Distribution and Emission Plan

Total Supply: 4.2B SEGA

<table><thead><tr><th width="229">Category</th><th width="120">Allocation %</th><th width="327">Token Amount (Millions)</th></tr></thead><tbody><tr><td>Liquidity Mining</td><td>30%</td><td>1,260,000,000</td></tr><tr><td>Team &#x26; Advisors</td><td>20%</td><td>840,000,000</td></tr><tr><td>Ecosystem Fund</td><td>30%</td><td>1,260,000,000</td></tr><tr><td>IDO (Seed Round)</td><td>10%</td><td>420,000,000</td></tr><tr><td>Liquidity Support</td><td>6%</td><td>252,000,000</td></tr><tr><td>Initial Release</td><td>4%</td><td>168,000,000</td></tr></tbody></table>

<figure><img src="https://3555825233-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFh7yHhIZBfvcedBz9Z4f%2Fuploads%2FOpzY1YpykhY4PLGTkL3f%2Fimage.png?alt=media&amp;token=03c5dfa1-7311-4bc1-9dd9-4c5037421f27" alt=""><figcaption></figcaption></figure>

<figure><img src="https://3555825233-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFh7yHhIZBfvcedBz9Z4f%2Fuploads%2FqJpMTxX2QDN0Y1BUgKpv%2Fimage.png?alt=media&amp;token=dda16b68-a564-4d8d-b3ef-fcb83f1f7946" alt=""><figcaption></figcaption></figure>

**SEGA Tokenomics Model**

**Total Supply:** 4,20,000,000 SEGA tokens

**1. Liquidity Mining (30% - 1,260,000,000 SEGA)**

* **Release Schedule:**
  * **First 2 Years:** 50% released (630,000,000 SEGA) via monthly linear unlock.
  * **Next 3 Years:** Remaining 50% released (630,000,000 SEGA) via monthly linear unlock.
* **Dynamic Incentives:**
  * Adjust rewards based on trading volume and liquidity growth.
  * Example: Additional 1% release upon reaching specific trading volume thresholds.
* **Purpose:**
  * Encourage long-term liquidity provision.
  * Stabilize the ecosystem.

**2. Team & Advisors (20% - 840,000,000 SEGA)**

* **Vesting Schedule:**
  * 6-month lockup.
  * 30-month linear release post-lockup.
* **Purpose:**
  * Align team interests with long-term project success.
  * Prevent short-term liquidation.

**3. Ecosystem Fund (30% -  1,260,000,000 SEGA)**

* **Release Schedule:**
  * Quarterly unlocks for ecosystem development.
* **Usage:**
  * Protocol-approved initiatives: developer incentives, partnerships, marketing.
  * Regular fund usage reports to maintain community trust.

**4. IDO (10% - 420,000,000 SEGA)**

* **Release Schedule:**
  * 100% immediate release.
* **Purpose:**
  * Facilitate a fair launch.
  * Attract early community participation.

**5. Liquidity Support (6% - 252,000,000 SEGA)**

* **Vesting Schedule:**
  * <mark style="color:red;">6-month lockup.</mark> <mark style="color:red;"></mark>~~*<mark style="color:red;">**(待定）**</mark>*~~
  * Release based on liquidity pool health metrics.
* **Purpose:**
  * Maintain exchange liquidity.
  * Reduce price volatility.

**6. Initial Release (4% - 168,000,000 SEGA)**

* **Usage:**
  * Fund trading competitions
* **Purpose:**
  * Boost early user engagement.
  * Enhance platform activity.

**Deflationary Mechanisms**

* **Transaction Fees:**
  * 4% of each fee go to Sega treasury, may be used to buyback or burn SEGA tokens, reducing supply.
  * 88% allocated to liquidity providers
  * Remaining 8% goes into Ecosystem Fund.

* **Ecosystem Fund Buybacks:**
  * Portion of fund profits used to repurchase and burn SEGA tokens.
  * Buyback timing determined by Sega Protocol to ensure community stability.

* Utility
  * medium of exchange between participants on Sega in a decentralized manner.


# Sega Staking (Coming Soon) - 可弃用

No Plan

#### **SEGA Staking: Earn Rewards by Staking SEGA Tokens**

#### SEGA Staking allows users to lock up their SEGA tokens to support the security and operations of the protocol while earning attractive rewards. Staking is a key feature of the SEGA ecosystem, designed to incentivize long-term participation and align the interests of users with the growth of the platform.

***

**How SEGA Staking Works**

1. **Stake SEGA Tokens**:
   * Users can stake their SEGA tokens directly through the SEGA platform.
   * Staked tokens are locked for a chosen period (e.g., 30, 90, or 180 days).
2. **Earn Rewards**:
   * Stakers earn rewards in SEGA tokens, distributed based on the amount staked and the duration of the lock-up period.
   * Longer lock-up periods typically offer higher Annual Percentage Yields (APYs).
3. **Unstake Tokens**:
   * After the lock-up period ends, users can unstake their tokens and claim their rewards.
   * <mark style="color:red;">Early unstaking may incur a penalty fee (e.g., forfeiting a portion of rewards).</mark>

***

**Benefits of SEGA Staking**

* **Passive Income**: Earn rewards simply by holding and staking SEGA tokens.
* **Support the Ecosystem**: Staked tokens help secure the network and support protocol operations.
* **Flexible Options**: Choose from multiple lock-up periods to suit your investment strategy.
* **Transparent and Secure**: All staking activities are recorded on-chain, ensuring transparency and security.

***

**Staking Rewards Distribution**

* **Rewards Pool**: A portion of the total SEGA supply (e.g., 10-20%) is allocated to the staking rewards pool.
* **Dynamic APY**: Rewards are distributed based on the total amount of tokens staked and the lock-up duration.
* **Bonus Rewards**: Stakers may receive additional rewards during special campaigns or ecosystem milestones.

***

**How to Stake SEGA Tokens**

1. **Connect Your Wallet**: Link your wallet to the SEGA platform.
2. **Navigate to Staking**: Go to the **“Staking”** section.
3. **Choose a Lock-Up Period**: Select your preferred staking duration (e.g., 30, 90, or 180 days).
4. **Stake Your Tokens**: Enter the amount of SEGA tokens you wish to stake and confirm the transaction.
5. **Earn Rewards**: Start earning rewards immediately, which will be distributed at the end of the lock-up period.

***

**Unstaking and Claiming Rewards**

1. **Wait for Lock-Up Period to End**: Tokens cannot be unstaked before the lock-up period expires.
2. **Unstake Tokens**: Go to the **“Staking”** section and click **“Unstake”**.
3. **Claim Rewards**: After unstaking, claim your rewards directly to your wallet.

***

**Tips for SEGA Staking**

* **Diversify**: Consider splitting your tokens across different lock-up periods to balance risk and reward.
* **Monitor APY**: Keep an eye on the staking APY, as it may fluctuate based on network activity.
* **Stay Informed**: Participate in special staking campaigns to maximize your rewards.

***

#### **Example of SEGA Staking Rewards**

* **Staked Amount**: 10,000 SEGA tokens
* **Lock-Up Period**: 90 days
* **APY**: 15%
* **Rewards Earned**:

  Rewards=10,000×15%/4=375 SEGA tokens

  (Note: The rewards are calculated based on the lock-up period as a fraction of the year.)

***

#### **Conclusion**

SEGA Staking is a powerful way to grow your crypto holdings while contributing to the security and growth of the SEGA ecosystem. By staking your tokens, you can earn passive income and play an active role in the decentralized future of finance.


# Protocol Fees

Trading Fees on SEGA

For every swap that occurs in a pool on SEGA, a small trading fee is collected. The fee structure varies depending on the specific pool, and the collected fees are distributed to incentivize liquidity providers and the treasury.

***

#### Fee Structure for Standard AMM Pools <a href="#fee-structure-for-standard-amm-pools" id="fee-structure-for-standard-amm-pools"></a>

* **Trading Fee:** The trading fee for standard AMM pools  is **0.25%** per swap.
  * **Liquidity Providers:** Receive **88%** of the trading fee for every swap in the pool.
  * **Sega Treasury:** Allocated **4%** of the collected fees to support the protocol.
  * **Ecosystem Fund:** Allocated &#x38;**%** of the collected fees to support the protocol.

***

#### Pool Creation Fee <a href="#pool-creation-fee" id="pool-creation-fee"></a>

{% content-ref url="/pages/x5UHRyZJvCGpzbcPEr19" %}
[Pool Creation Fees - 待确认gas费，地址](/getting-started/creating-a-pool/pool-creation-fees-dai-que-ren-gas-fei-di-zhi)
{% endcontent-ref %}

***

#### Summary <a href="#summary" id="summary"></a>

SEGA’s fee structure is carefully designed to balance rewarding liquidity providers with maintaining protocol sustainability, ensuring a healthy and efficient ecosystem.


# Sega Buybacks

**SEGA Token Buyback Mechanism**

The SEGA protocol implements a dual-faceted token buyback and burn strategy to enhance token scarcity, increase value, and maintain community stability:

**1. Treasury Fund Buyback**

* **Source of Funds:**
  * 4% of each transaction fee is allocated to the SEGA Treasury, designated for potential token buybacks and burns.
* **Operational Guidelines:**
  * **Flexible Utilization:** Treasury funds may be used for buybacks and burns or directed towards other protocol development needs (e.g., technical upgrades, marketing).
  * **Decision-Making Process:**
    * Initially, the core team determines buyback timing and proportions.
    * Transitioning to DAO governance, the community votes on fund usage (buyback, burn, or ecosystem expenditure).
  * **Buyback Execution:**
    * Buybacks are conducted via decentralized exchanges (DEX) or over-the-counter (OTC) transactions to prevent market manipulation.
    * All burned tokens are recorded with public transaction hashes to ensure transparency.
* **Example:**
  * If the Treasury accumulates 50,000 SEGA in a month, and the Core Team/DAO votes to allocate 80% (40,000 SEGA) for buyback and burn, the total supply decreases by 40,000 SEGA, directly enhancing token value through deflation.

**2. Ecosystem Fund Profit Buyback**

* **Source of Funds:**
  * 8% of each transaction fee is continuously injected into the Ecosystem Fund as foundational capital.
  * Profits from Ecosystem Fund investments (e.g., revenue shares from partner projects, profits from ecosystem initiatives) are utilized for buybacks.
* **Operational Guidelines:**
  * **Profit Allocation:** 5-20% of Ecosystem Fund profits are designated for buyback and burn, with the specific percentage determined by Core Team/DAO consensus.
  * **Buyback Triggers:**
    * If SEGA's price declines by over 30% within a short period, may trigger strategic buybacks to stable price
    * Achieving significant ecosystem milestones (e.g., surpassing 1 million users) may trigger celebratory buybacks.
  * **Execution Methods:**
    * Employ algorithmic strategies (e.g., scheduled buybacks) or manual interventions based on market conditions.
    * Prioritize buybacks during low liquidity periods to maximize capital efficiency.
* **Example:**
  * If the Ecosystem Fund earns 200,000 SEGA in profits, and the Core team/DAO decides to allocate 50% (100,000 SEGA) for buyback and burn, this action reduces circulating supply and signals long-term value commitment to the community.

**Design Objectives of the Buyback Mechanism**

* **Token Deflation:** Consistent burning reduces total supply, counteracting inflation from liquidity mining and other sources.
* **Price Stability:** Provides support during market volatility, preventing panic selling.
* **Community** **Governance:** Gradual transition to DAO control ensures decentralized decision-making.
* **Transparency and Trust:** All buyback records are on-chain, with regular burn reports to maintain community confidence.

**Data Transparency and Community Oversight**

* **Real-Time Dashboard (coming soon):** The SEGA official website offers live buyback data, including:
  * Total tokens burned.
  * Current Treasury balance.
  * Ecosystem Fund buyback history.
* **Monthly Reports:** Detailed disclosures on fund allocations, buyback costs, and market impact analyses.
* **Community Alerts:** Major buyback events are communicated via social media and DAO notifications to keep users informed.

**Conclusion**

SEGA's buyback mechanism, driven by both Treasury and Ecosystem Fund, integrates algorithmic rules with community governance to reduce token supply and enhance market confidence. This approach not only increases SEGA's value capture potential but also establishes trust through transparent operations, laying a solid foundation for the protocol's long-term success.


# Liquidity Mining/Farms(根据UI待定）

#### **What is LP Mining?**

LP (Liquidity Provider) Mining is a core feature of SEGA that allows users to earn rewards by contributing liquidity to trading pools. By depositing pairs of tokens into a liquidity pool, users enable seamless trading and swaps on the platform. In return, they earn a share of the trading fees generated by the pool, as well as additional rewards in the form of SEGA tokens or other incentives.

#### **How Does LP Mining Work on SEGA?**

1. **Provide Liquidity**:
   * Deposit an equal value of two tokens into a SEGA liquidity pool (e.g., SEGA and USDC).
   * These tokens form a trading pair that other users can swap between.
2. **Earn Trading Fees**:
   * Every time a trade occurs in your pool, you earn a portion of the trading fees.
   * Fees are distributed proportionally based on your share of the total liquidity in the pool.
3. **Receive Additional Rewards**:
   * SEGA offers extra incentives, such as SEGA, for participating in LP Mining.
   * These rewards are distributed periodically and are based on your contribution to the pool.
4. **Flexible Withdrawals**:
   * You can withdraw your liquidity and rewards at any time, giving you full control over your assets.

#### **Benefits of LP Mining on SEGA**

* **Passive Income**: Earn trading fees and token rewards by simply providing liquidity.
* **Permissionless Access**: Anyone can participate in LP Mining without restrictions.
* **Boost Ecosystem Growth**: Help SEGA grow by increasing liquidity and improving trading efficiency.
* **Transparent and Secure**: All transactions and rewards are recorded on-chain, ensuring transparency and security.

***

#### **Getting Started with LP Mining on SEGA**&#x20;

1. **Connect Your Wallet**: Link your compatible wallet (e.g., Internet Computer wallet) to SEGA Dex.
2. **Choose a Pool**: Select a liquidity pool that supports LP Mining.
3. **Deposit Tokens**: Add an equal value of both tokens to the pool.
4. **Start Earning**: Begin earning trading fees and rewards immediately.

***

#### **Tips for LP Mining**

* **Diversify**: Participate in multiple pools to spread risk and maximize rewards.
* **Monitor Impermanent Loss**: Be aware of potential price fluctuations between the paired tokens.
* **Stay Updated**: Keep an eye on SEGA  announcements for new pools and reward programs.

#### Other Incentives for Liquidity Providers <a href="#incentives-for-liquidity-providers" id="incentives-for-liquidity-providers"></a>

* **Farming Rewards:** Key liquidity pools are incentivized with farming rewards to attract more participation.
* **Customizable Rewards:** Projects can add additional reward tokens to encourage liquidity provision.


# AMM

What is an Automated Market Maker (AMM)?

&#x20;**Automated Market Maker (AMM)** is a type of decentralized exchange (DEX) protocol that allows users to trade cryptocurrencies directly with a liquidity pool, rather than relying on traditional order books. Instead of matching buyers and sellers, AMMs use smart contracts and mathematical formulas to automatically set prices and execute trades.

How Does an AMM Work?

1. **Liquidity Pools**:\
   AMMs rely on liquidity pools, which are collections of funds provided by users (called liquidity providers or LPs). These pools contain pairs of tokens (e.g., SEGA/USDC) that traders can swap between.
2. **Pricing Mechanism**:\
   AMMs use a mathematical formula to determine the price of assets in the pool. The most common formula is the **Constant Product Market Maker** model (popularized by Uniswap), which follows the equation:

   x×y=k

   Here, x and y represent the quantities of two tokens in the pool, and k is a constant. As traders swap one token for another, the ratio of the tokens changes, and so does the price.
3. **No Order Books**:\
   Unlike centralized exchanges, AMMs don’t use order books. Instead, trades are executed directly against the liquidity pool, ensuring continuous liquidity and eliminating the need for buyers and sellers to match orders.
4. **Liquidity Providers (LPs)**:\
   Users who deposit tokens into the liquidity pool earn fees from trades that occur in the pool. These fees are distributed proportionally to LPs based on their share of the pool
5. Key Benefits of AMMs:
   * **Decentralization**: AMMs operate on blockchain networks, removing the need for intermediaries.
   * **Accessibility**: Anyone can become a liquidity provider and earn fees.
   * **Continuous Liquidity**: Trades can happen 24/7 without relying on market makers or order books.
   * **Permissionless**: Users can trade and provide liquidity without needing approval from a central authority.


# Developer Docs - 待技术支持！！

[<mark style="color:red;">https://docs.raydium.io/raydium/protocol/developers</mark>](https://docs.raydium.io/raydium/protocol/developers)


# Addresses - 待技术支持！

{% embed url="<https://docs.raydium.io/raydium/protocol/developers/addresses>" %}

<mark style="color:red;">refer to ...</mark>

<figure><img src="https://3555825233-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFh7yHhIZBfvcedBz9Z4f%2Fuploads%2FsBnh7FCzeIkVHrhour7Q%2Fimage.png?alt=media&amp;token=7cee7e9e-54b6-42bf-9ee8-78a64c8336d1" alt=""><figcaption></figcaption></figure>


# APIs - 待技术支持！！

<mark style="color:red;">refer to ...</mark>

{% embed url="<https://docs.raydium.io/raydium/protocol/developers/apis>" %}

<figure><img src="https://3555825233-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFh7yHhIZBfvcedBz9Z4f%2Fuploads%2FZaXza6IvBAjGwfcAuG84%2Fimage.png?alt=media&amp;token=f625028a-cbbf-44d4-88ac-8d59c02d5ee2" alt=""><figcaption></figcaption></figure>


