An open API service indexing awesome lists of open source software.

https://github.com/maneesha-raj/amm


https://github.com/maneesha-raj/amm

automated-market-makers blockchain ethereum liquidity-pool smart-contracts solidity

Last synced: about 1 month ago
JSON representation

Awesome Lists containing this project

README

          

# 🌟 Supply/Demand AMM (Project ongoing)

Supply/Demand AMM is a decentralized Automated Market Maker built on Ethereum. It enables seamless token swapping and liquidity provision with dynamic pricing based on supply and demand curves. This AMM allows users to swap tokens, add liquidity, and benefit from a decentralized trading mechanism.

## 📄 Project Overview
Supply/Demand AMM is designed to provide an efficient and user-friendly decentralized trading experience. The platform supports liquidity providers and token traders with an adaptive pricing model driven by supply and demand.

---

## 🔑 Features

### 👤 User Features
- **Swap Tokens:** Trade between two tokens with dynamic pricing.
- **Add Liquidity:** Provide liquidity to earn a share of transaction fees.
- **View Pool Stats:** See real-time token reserves, pool fees, and your liquidity share.

### 🛠️ Admin Features
- **Manage Liquidity Pools:** Add or update token pairs.
- **Monitor Stats:** Access insights like trading volume, total liquidity, and fees collected.

---

## ⚙️ Technologies Used

### **Frontend**
- React.js
- Tailwind CSS
- Ethers.js

### **Smart Contracts**
- Solidity
- Hardhat
- OpenZeppelin Libraries

### **Backend (Optional)**
- Node.js
- Express.js
- MongoDB (for analytics and optional off-chain data storage)

---

---

## 👥 User Roles and Permissions
| Role | Permissions |
|-----------------|-----------------------------------------------------------------------------|
| Liquidity Provider | Add liquidity, view pool stats, and withdraw liquidity. |
| Trader | Swap tokens, view dynamic prices, and access pool details. |
| Admin | Add token pairs, manage liquidity pools, and monitor platform-wide stats. |

---

---

## 🚀 Getting Started

### Prerequisites

- MetaMask or a similar Ethereum wallet.

### Setup Steps

#### 2. Install Dependencies:
```bash
npm install
```

#### 3. Compile and Deploy Smart Contracts:
- Update `.env` with your Infura or Alchemy API keys and wallet private key.
- Run the following commands:
```bash
npx hardhat compile
npx hardhat run scripts/deploy.js --network goerli
```

#### 4. Run the Application:
- Start the frontend:
```bash
npm start
```
- Start backend services (if applicable):
```bash
node server.js
```

#### 5. Run with Docker:
```bash
docker-compose up --build
```

Access the application in your browser at: `http://localhost:3000`

---

## 📂 Directory Structure
```
Supply-Demand-AMM/
├── contracts/ # Smart contracts written in Solidity
├── scripts/ # Deployment and helper scripts
├── frontend/ # React.js application for user interaction
├── backend/ # (Optional) Node.js APIs for analytics
├── docker-compose.yml # Docker configuration
└── README.md # Project documentation
```

---

## 📜 License
This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.

---

## 🤝 Contributing
Contributions are welcome! Feel free to open issues or submit pull requests to enhance the platform.

---

## ✨ Acknowledgments
- Ethereum Community for their extensive resources.
- OpenZeppelin for secure smart contract libraries.
- Chainlink for reliable oracle services.
- The Graph for seamless on-chain data querying.