Quick Start Guide
This document contains an overview of the DLN API endpoints, giving readers an expedited understanding of how to get quotes, place, track and manage limit orders on the DLN.
DLN API provides developers an effortless way to interact with the DLN protocol and trade across chains in seconds with deep liquidity, limit orders, and protection against slippage and MEV. The API takes the burden off of building complex and sometimes painful interactions with blockchain RPCs and smart contracts by providing a complete set of RESTful endpoints, sufficient to quote, create, and manage trades during their whole lifecycle.
The lifecycle of an order is defined as follows:
- getting a quote
- requesting a transaction that places (creates) the limit order on-chain
- submitting a transaction to the source chain
- tracking the status of the order on the destination chain
- (optional) requesting a transaction that cancels the limit order on the destination chain
This guide gives a brief step-by-step overview of how to manage limit orders using DLN API endpoints.
This article assumes a specific use case: a user, who has 100 USDC on BNB Chain, would like to receive a reasonable amount of USDT on Avalanche. Additionally, an affiliate fee of 0.1% would be set during this order creation.
Hereinafter, we assume that the input token is USDC, and the user actually gives 100 USDC; the source chain is BNB Chain here. The output token is USDT, and the user is willing to take an amount of USDT recommended by the API. Here, the destination chain is Avalanche.