API Reference¶
Use this page when you already understand the overall framework shape and want the current public surface in one place.
Pair this page with:
Core¶
db.App(...)¶
Main application object.
Important parameters:
titlethemetheme_colorlogofaviconauth_modeauth_providercors_originstrusted_hostswebsocket_origins
Methods:
@app.page(path, title=..., icon=..., access=..., roles=...)@app.route(path, methods=[...], access=..., roles=...)app.mount(component)app.run(host=None, port=None, reload=False)
State Hooks¶
db.use_state(initial)db.use_effect(fn, deps=None)db.use_memo(fn, deps=[...])db.use_context(key, default=None)db.set_context(key, value)
Auth Helpers¶
db.current_principal()db.current_user()db.current_app_identity()db.is_authenticated()db.require_auth()db.require_role(role)db.Principal(...)db.HeaderAuthProvider()db.StaticAuthProvider(principal)
Layout Components¶
db.Columndb.Rowdb.Griddb.Carddb.Dividerdb.Spacer
Useful additive props:
Card(..., elevated=True, animated=True, animation="fade-up", animation_delay=0.1)Button(..., animated=True, animation="pulse")
Content Components¶
db.Textdb.Codedb.Badgedb.Alertdb.Statdb.Progressdb.Spinnerdb.EmptyStatedb.Toastdb.Timelinedb.Imagedb.SparklineStatdb.Herodb.SectionHeaderdb.StatusStripdb.Stepperdb.KanbanBoarddb.ChatMessagedb.ChatInput
Useful additive props:
Stat(..., animated=True)Toast(..., visible=True)
Input Components¶
db.Buttondb.Inputdb.Selectdb.Checkboxdb.Toggledb.Sliderdb.DateRangePickerdb.MultiSelectdb.Form
Notes:
Input(..., loading=True)andSelect(..., loading=True)show inline loading affordancesDateRangePickeremits{"start": "...", "end": "..."}to itson_changeMultiSelectemitslist[str]to itson_changeFormpreserves repeated field names as arrays when posting JSON
Navigation And Surface Components¶
db.Sidebardb.NavItemdb.Breadcrumbsdb.Tabsdb.TabItemdb.Modaldb.Drawerdb.Popupdb.Accordiondb.AccordionItem
Data Components¶
db.Table
Useful additive props:
Table(..., loading=True)Table(..., empty_message="No rows yet")Table(..., exportable=True)Table(..., on_row_click=handler)
Chart Components¶
db.Plotdb.AreaChartdb.BarChartdb.LineChartdb.DonutChartdb.ScatterChartdb.ComposedChartdb.GaugeChartdb.RadarChartdb.Heatmapdb.FunnelChartdb.TreeMapdb.PipelineGraph
Useful additive props:
loadingempty_messageon_clickcolors
Example:
db.BarChart(
data=rows,
x_key="week",
y_keys=["runs", "failures"],
title="Pipeline trend",
loading=is_loading,
empty_message="No pipeline data available",
on_click=handle_bar_click,
)
Pipeline And App Composition Components¶
These components were added for richer 0.1.6 dashboards and internal apps:
db.PipelineGraph(nodes, edges, on_node_click=...)renders a simple pipeline/DAG-style flow from plain dictionaries.db.StatusStrip(items=[...])renders compact signal cards for freshness, SLA, cost, latency, and incident counts.db.KanbanBoard(columns=[...], on_card_click=...)renders operational triage boards.db.Stepper(steps=[...], active=...)renders release, setup, or pipeline-stage progress.db.ChatMessage(...)anddb.ChatInput(...)render chatbot/copilot-style experiences.db.Hero(...)anddb.SectionHeader(...)provide polished landing-page and dashboard section patterns.db.Popup(...)provides a lightweight overlay for helper flows and quick confirmations.db.Image(...)renders screenshots, diagrams, and branded media inside apps.
Example pipeline graph:
db.PipelineGraph(
nodes=[
{"id": "bronze", "label": "Bronze Orders", "layer": "bronze", "status": "running"},
{"id": "silver", "label": "Silver Quality", "layer": "silver", "status": "watch"},
{"id": "gold", "label": "Gold Mart", "layer": "gold", "status": "healthy"},
],
edges=[
{"from": "bronze", "to": "silver"},
{"from": "silver", "to": "gold"},
],
on_node_click=lambda node: set_selected(node["id"]),
)
Example chat input:
message, set_message = db.use_state("")
db.ChatInput(
value=message,
placeholder="Ask about failed pipelines",
on_change=set_message,
on_submit=lambda prompt: set_answer(f"Investigating: {prompt}"),
)
Theme Surface¶
Supported theme sections:
brandingcolorssurfacestypographyspacingbordersshadowsmotion
Useful aliases:
background -> bgprimary_hover -> primary-hovertext_muted -> text-mutedfont_family -> sansbase_size -> base-sizesurfaces.background -> canvassurfaces.surface -> mutedshadows.medium -> mdmotion.duration_normal -> duration-normal
Databricks Helpers¶
brickflowui.databricks.sql¶
query(sql, params=None)query_to_records(sql, params=None)execute(sql, params=None)transaction()
brickflowui.databricks.uc¶
list_catalogs()list_schemas(catalog)list_tables(catalog, schema)table_schema(catalog, schema, table)get_table(catalog, schema, table, limit=100)