Skip to content

Commit

Permalink
update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
jlin27 committed Dec 18, 2024
1 parent e6603da commit 4157841
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 32 deletions.
55 changes: 26 additions & 29 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,65 +2,62 @@

A collection of 0x API code examples

## Swap API
## v2 (Latest)

### v2
### Swap API

- [Swap API v2 Demo App (Permit2) using Next.js App Router](https://github.com/0xProject/0x-examples/tree/main/swap-v2-next-app)
- [Swap API v2 (Permit2) Headless Example](https://github.com/0xProject/0x-examples/tree/main/swap-v2-headless-example)
- [Swap API v2 (AllowanceHolder) Headless Example](https://github.com/0xProject/0x-examples/tree/main/swap-v2-allowance-holder-headless-example)
- [Use Swap API v2 in Your Smart Contract with Foundry](https://github.com/0xProject/0x-examples/tree/main/swap-v2-with-foundry)

### v1
### Gasless API

- [Swap API Demo App using Next.js App Router](https://github.com/0xProject/0x-examples/tree/main/swap-next-app)
- [Swap API Demo App using Next.js Pages Router](https://github.com/0xProject/0x-nextjs-demo-app/tree/main)
- [Swap API Demo App using HTML/CSS/JavaScript](https://github.com/0xProject/swap-demo-tutorial)
- [Swap API Headless Example](https://github.com/0xProject/0x-examples/tree/main/swap-headless-example)
- [Gasless API v2 Headless Example](https://github.com/0xProject/0x-examples/blob/main/gasless-v2-headless-example/README.md)

## Gasless API

### v2
## v1 (Deprecated)

- [Gasless API v2 Headless Example](https://github.com/0xProject/0x-examples/blob/main/gasless-v2-headless-example/README.md)
> [!WARNING]
> We will sunset 0x API v1 on April 11, 2025. Please migrate to v2 before this date to avoid service distruptions. For details, see the [migration guide](https://0x.org/docs/upgrading).
### Swap API

- [Swap API v1 Demo App using Next.js App Router](https://github.com/0xProject/0x-examples/tree/main/swap-next-app)
- [Swap API v1 Demo App using Next.js Pages Router](https://github.com/0xProject/0x-nextjs-demo-app/tree/main)
- [Swap API v1 Demo App using HTML/CSS/JavaScript](https://github.com/0xProject/swap-demo-tutorial)
- [Swap API v1 Headless Example](https://github.com/0xProject/0x-examples/tree/main/swap-headless-example)

### Gasless API

### v1
- [Gasless API v1 Demo App using Next.js App Router](https://github.com/0xProject/0x-examples/tree/main/gasless-next-app)

- [Gasless API Demo App using Next.js App Router](https://github.com/0xProject/0x-examples/tree/main/gasless-next-app)


## Contribution Guidelines

#### 1. 🍴 Fork the Repository
Start by forking the repository and creating a new branch for your contributions.
1. **Fork the Repository:** Start by forking the repository and creating a new branch for your contributions.

#### 2. πŸ”§ Set Up Environment
Follow the setup guide in the README to ensure your environment matches the development requirements.
2. **Set Up Environment:** Follow the setup guide in the README to ensure your environment matches the development requirements.

#### 3. πŸ’» Code Standards
Adhere to the ESLint rules provided in the project
3. **Code Standards:** Adhere to the ESLint rules provided in the project

#### 4. πŸ“„ Documentation
Include or update relevant documentation for new features or changes.
4. **Documentation:** Include or update relevant documentation for new features or changes.

#### 5. πŸ” Pull Request
5. **Pull Request:**
- Provide a clear description of the changes and the issue(s) addressed
- Tag at least one maintainer for review
- Include screenshots or logs for UI changes or CLI commands

## Code of Conduct

#### 1. Be Respectful
Treat others with respect and kindness in all interactions.
1. **Be Respectful:** Treat others with respect and kindness in all interactions.

#### 2. Constructive Feedback
Provide feedback that is thoughtful, helpful, and actionable.
2. **Constructive Feedback:** Provide feedback that is thoughtful, helpful, and actionable.

#### 3. No Harassment
Harassment, abusive language, or any form of discrimination will not be tolerated.
3. **No Harassment:** Harassment, abusive language, or any form of discrimination will not be tolerated.

#### 4. Collaborative Environment
Support an open and welcoming space for contributors from all backgrounds.
4. **Collaborative Environment:** Support an open and welcoming space for contributors from all backgrounds.

## Licenses

Expand Down
6 changes: 3 additions & 3 deletions gasless-trading-bot/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,9 @@ Once the inputs are entered, the bot will run the following:
1. Buys the specified ERC20 token using WETH.
- If not the wallet does not have enough WETH, it will try to wrap ETH for WETH.
2. Watches for conditions:
- Price increases by Take Profit Percentage (e.g. 10%) β†’ Trigger "Take Profit" β†’ Sell.
- Price drops by Stop Loss Percentage (e.g. 5%) β†’ Trigger "Stop Loss" β†’ Sell.
- Timeout after Timeout Duration (e.g. 300s) β†’ Trigger "Timeout" β†’ Sell.
- Price increases by X% β†’ Trigger "Take Profit" β†’ Sell.
- Price drops by Y% β†’ Trigger "Stop Loss" β†’ Sell.
- Timeout after Z sec β†’ Trigger "Timeout" β†’ Sell.
3. Updates MongoDB with trade results and PnL.


Expand Down

0 comments on commit 4157841

Please sign in to comment.