> ## Documentation Index
> Fetch the complete documentation index at: https://docs.delphina.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# On-Demand Steps

> Run Data App pipeline steps live when a viewer interacts, with the values they pick

By default, every [Data App](https://docs.delphina.ai/analytics-agent/data-apps.md) pipeline step runs at **refresh** time and the app serves that snapshot. Any [step kind](https://docs.delphina.ai/analytics-agent/data-apps.md#data-sources-and-pipeline-steps) except built-in tools can instead be marked **on-demand**: it runs at the moment a *viewer* interacts with the app, with values the viewer chose bound in as typed parameters.

## When to use on-demand steps

Use on-demand steps for two shapes of question:

* **Needle in a haystack.** A lookup across a space too big to precompute — one customer's orders among 10M rows, one ticket's detail among thousands. The dashboard's rollups stay precomputed; the viewer's pick queries live.
* **Fresher than the refresh.** A pane whose numbers should be minutes old, not as old as the last scheduled refresh — a live status or queue depth, with or without parameters.

The rest of the app is unchanged: on-demand results can join against the app's precomputed datasets (for example, "this customer's orders" laid over the daily rollup), and an agent step can run on demand too — generating an AI summary for exactly the record a viewer selected.

## Adding an on-demand step

Describe the interaction to Delphina — for example, *"add a dropdown of customers, and when I pick one, look up their orders live"*. Delphina marks the right steps on-demand and wires the app.

## What viewers experience

* Selecting a value shows a **Live lookup** progress strip while the query runs; results typically land in a few seconds (agent steps take longer). Panes show a **live · as of…** badge telling viewers exactly when their numbers were produced.
* Results are **cached per parameter value** for a duration the app author chooses, so repeating a selection (by you or a colleague, where applicable) is instant.
* On-demand queries run under **the viewer's own data connections**, not the owner's — the opposite of [refreshes](https://docs.delphina.ai/analytics-agent/data-apps.md#refreshing). A viewer's live lookups return exactly what *their* warehouse access allows, and results from credentialed lookups are private to the viewer who ran them. In workspaces where warehouse access is connected per user, a viewer who hasn't connected theirs sees a prompt to do so instead of data.
* **PDF exports** capture on-demand panes as the viewer currently sees them: panes the viewer has loaded appear with their results, and panes they haven't loaded appear empty.

> [!NOTE]
>
> Because on-demand queries use the viewer's own access, build on-demand panes
> for audiences who hold data access themselves. For dashboards aimed at viewers
> without warehouse access, keep steps on the default refresh schedule — those
> always run under the owner's connections.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.