Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add limit order api demo #1

Merged
merged 1 commit into from
May 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions limit-order-api-demo/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Pendle Limit Order API Demo

This repository is designed for developers seeking to interact with Pendle Limit Order using TypeScript. For simplicity, the examples are implemented purely in Node.js so that users can focus on the backend logic required to achieve the following Limit Order operations:

* Maker APIs:
- Generate limit order data (generateLimitOrderData())
- Sign limit order (signLimitOrderData())
- Post limit order to backend system (postLimitOrder())

* Taker APIs:
- Fetch limit orders to fill
- Fill a limit order

## Getting Started
To run examples:
- Change directory to the demo project folder: `cd limit-order-api-demo`
- Install required dependencies with `npm install`
- Configure the ethers.js signer in `/src/libs/signer.ts`
- Execute the index.ts file using `npm run start`

## Api specifications
* [Maker](https://api-v2.pendle.finance/limit-order/docs)
* [Taker](https://api-v2.pendle.finance/limit-order/docs)

## Additional Notes

Please be aware that the code examples provided in this repository are for educational purposes and are not intended for production use. They serve as a starting point for integrating Pendle Limit Order functionality into your decentralized application (dApp).
Loading
Loading