Skip to main content
DFlow has a single, unified trading API that builders can use to trade different asset types through the same interface. Today, users can trade spot crypto and prediction market outcomes. From an app’s perspective, trading follows the same high-level flow: request a quote, present it to a user, and submit a signed transaction for execution. What changes across asset types is the underlying trade mechanics, not the integration surface. DFlow supports two trade types: declarative trades and imperative trades. Choose declarative trades when adaptability and execution quality matter more than enforcing a specific route. Choose imperative trades when deterministic routing, explicit venue control, or strategy-driven execution matter more than adaptation. When trading spot crypto, builders can use either declarative or imperative trades, and execution is synchronous. Prediction market trades use imperative async trades backed by Concurrent Liquidity Programs.

TLDR; Declarative vs Imperative Trades

Need Help?

https://mintcdn.com/dflow/a8Yx7HBusmKl4Z7w/images/meteor-icons_discord.svg?fit=max&auto=format&n=a8Yx7HBusmKl4Z7w&q=85&s=0ea834bc8a9fa3fe161ba181329effda

Join Our Discord

Connect with other developers, get help, and stay updated on the latest DFlow developments.
https://mintcdn.com/dflow/a8Yx7HBusmKl4Z7w/images/meteor-icons_telegram.svg?fit=max&auto=format&n=a8Yx7HBusmKl4Z7w&q=85&s=e928c5dd68311ff0d419936a35c86eed

Dev Notifications

Join the DFlow Dev Notifications Telegram group to stay in the loop on new features and other announcements.