Firm-Quote
Based on the order book you provide, our router will determine the optimal liquidity source to offer the best price. If your pricing is selected, Native will request a firm quote from you.
The firm quote endpoint must adhere to the following format:
Endpoint
Params
sellerTokenAmount
The token input amount of the order, in wei
chainId
Chain ID of the network (e.g., 1 for Ethereum, 56 for BSC)
sellerToken
The ERC20 token address that will be sent to the market maker
buyerToken
The ERC20 token address that will be received from the market maker
pool
Native pool contract address that will execute this order. Additional data for validation or pricing.
seller
The address that will send the seller token to the market maker (typically NativeRouter)
beneficiary
Address of the end user who initiated the swap request
quoteId
Unique ID for this order request
deadlineTimestamp
Deadline UNIX timestamp specified by the user; you can accept, reject, or modify this request
feeBps
Fee that Native will charge market makers, factored into their quote. Native collaborates with market makers to track and pay fees off-chain. Contracts with market makers will specify how fees are set and paid, and data sources will be provided for monitoring fee obligations.
availableBorrowBalance
The amount Market Makers can borrow from Native Inventory, in wei
Example
In this example, a user sells 10,000 USDC to the market maker in exchange for USDT on Binance Smart Chain (BSC).
Response
You must provide a response in the following format:
success
Indicates whether you can provide a firm quote for this order flow (true/false)
buyerTokenAmount
The amount of tokens you are exchanging with the seller
deadlineTimestamp
The timestamp when this order will expire, typically 20-30 seconds for execution
isBorrowing
Indicates whether you want to use Native's Credit Pool (true/false)
auth
Optional field used for verification with the signer, relayed by Native for signing
Example
In the response above, the market maker returns 10,100 USDT for the order sent in the example.
Last updated