Skip to main content
An order can carry a maker fee: a share of the maker’s USDC leg that the maker pays DFlow. The quote request carries the rate in feeBps, and DFlow opens the order with it as maker_fee_ubps, which is feeBps × 100. The rate is at most 5%. maker_fee_ubps sets it in hundredths of a basis point, so its maximum is 50,000. The fee is not part of the quote, so quoted_in, quoted_out and what the user receives are the same with or without a maker fee. The fee is base × maker_fee_ubps ÷ 1000000, rounded down. On a sell, the maker’s source account must hold the payment plus the fee. The fee goes to the order’s maker_fee_account, DFlow’s USDC account (852m4g1SCToN77W4ysZGpEeNjkoBtZw67BcigNPPm8Bf). The fill includes that account as writable. In the fill’s account list, it comes after the fee recipient’s account, or after account 17 when the order has no platform fee. Any other account, or none, reverts the fill. If the account is missing or frozen, the fee is skipped.

Maker Fee Example

An order has quoted_in of 201,000,000 USDC, quoted_out of 1,005,000,000 of an equity, and a 10 bps maker fee. A full fill:
  1. Moves 201,000,000 USDC into the maker’s receive account.
  2. Moves 201,000 of it on to DFlow.
  3. Leaves the maker with 200,799,000.
The user receives the same 1,005,000,000.