# DFlow (/docs/nodes/defi/dflow)

Prediction market events, orderbooks, and trades via DFlow.



DFlow is a prediction market protocol on Solana. The DFlow node provides event discovery, market data, orderbooks, candlesticks, and trade history.

Prerequisites [#prerequisites]

No credential required. All operations use DFlow's public API.

Operations [#operations]

| Operation       | Description                       | Key inputs         |
| --------------- | --------------------------------- | ------------------ |
| getEvents       | List prediction events            | status, limit      |
| getEvent        | Get details for a specific event  | ticker             |
| searchEvents    | Search events by keyword          | searchQuery, limit |
| getMarkets      | List markets for an event         | ticker, limit      |
| getMarket       | Get details for a specific market | ticker             |
| getMarketByMint | Look up a market by token mint    | mintAddress        |
| getOrderbook    | Get orderbook depth for a market  | ticker             |
| getCandlesticks | Get OHLCV data for a market       | ticker             |
| getTrades       | Get recent trades for a market    | ticker, limit      |
| getCategories   | List event categories             | (none)             |

Configuration [#configuration]

| Field       | Type   | Required            | Description                          |
| ----------- | ------ | ------------------- | ------------------------------------ |
| ticker      | string | For most ops        | Event or market ticker               |
| mintAddress | string | For getMarketByMint | Token mint address                   |
| searchQuery | string | For searchEvents    | Search keyword (max 200 chars)       |
| status      | string | No                  | Event status filter                  |
| limit       | number | No                  | Results limit (default: 20, max: 50) |

Output [#output]

All operations return the standard envelope:

```json
{
  "success": true,
  "operation": "getEvents",
  "data": { /* raw DFlow response */ }
}
```

Reference fields downstream with the response name (default `dflowResponse`), for example `{dflowResponse.data[0].ticker}` for a list of events or `{dflowResponse.data.outcomes[0].price}` for `getMarket`.

Common use cases [#common-use-cases]

* Monitor prediction market odds for crypto events
* Track orderbook depth and trade volume
* Combine with AI to analyze event sentiment

Next steps [#next-steps]

* [Polymarket](/docs/nodes/data/polymarket) - alternative prediction market data
* [Drift](/docs/nodes/defi/drift) - perpetuals trading data
