Workflow builder
A React block (a whole screen) in Beamline's Blocks category.
Automation rules for a SaaS without code: a trigger, conditions built with the query builder that branch into Yes and No, actions and waits, drawn as a flow you edit step by step; test it on sample records and watch each step decide, read past runs with what every step did, pause it with a reason everyone sees, and publish the draft only after reading what changed against the live version.
Part of Beamline UI: React UI components and complete screens for apps built with coding agents. The code is copied into your repo; your app never depends on our servers. Build your own style from any look; tokens, fonts, radii, motion; not only colours. 200+ components and 50+ complete screens. $49 launch price; one payment; your whole team, no seats. Lifetime updates: every new version of the complete system, for as long as we publish it, and every version you received stays yours. React 19, TypeScript, Tailwind v4, Radix. Free MIT sample, commercial use included. Made by Danylo Pravda in Kyiv, Ukraine.
Use it for
- Automation rules people set up themselves: route tickets, alert sales, nudge trials, escalate what waits too long.
- Any rule that runs on an event, decides on the record's fields and acts, where people need to test it, see what it did and change it safely.
Not for
- Showing a fixed flow an agent will run, read-only (flowchart on its own).
- Segments and saved filters with no actions (query-builder).
- Watching agent runs and their traces (agent-runs).
Anatomy
- app shell: your navigation with the workspace's automations as a group, each with its state in words (Live, Paused, Draft)
- header: the workflow's name (rename in place), its version and state (v3 live · 2 changes in draft), the on/off switch, Test run and Publish (the page's primary action)
- paused notice: who paused it, when and why, and Turn on
- tabs: Build · Runs (count) · Changes (count)
- flow: the flowchart of the draft (Build), of the live version painted with a run's or a test's step results (Runs, Test run); the chosen step carries the ring
- step editor (Build): the trigger's event; a condition's rules (query builder with the matching count) and its Yes and No paths; an action's kind and settings; a wait's length; add a step after this one; remove the step
- test run: a sample record (and its fields), Run test, then each step's outcome in words; nothing is sent
- runs: the last runs as a strip of status blocks, the runs as a table, and the chosen run's steps with what each did and how long it took; a failed run says why with Run again
- changes: the live version against the draft as one tree (added, removed, changed old → new), Publish and Discard draft
States
- a new rule: only the trigger, never published (Publish makes v1 live; the switch waits for it)
- draft matches the live version; draft with changes (counted on the tab and in the header)
- a step unfinished (a rule with no value, an action with no queue): said on the step, Publish disabled and the reason beside it with Show
- publishing, published, refused (the current draft stays as built; a later pause survives the refusal; Try again publishes the current valid draft)
- on; asking why (the switch stays on until a reason is given); paused with its reason; turning on; a refused switch goes back and says why
- test run: choosing a sample, running (steps decide one at a time), done (each step's outcome), a condition that does not hold (its path skipped)
- runs: loading, none yet, completed, waiting at a wait step (resumes at), failed at a step (the reason, Run again)
Keyboard
- Tab: name, switch, Test run, Publish, the tabs, the flow, then the step editor
- The flow is one tab stop walked with the arrows (the flowchart's own); Enter opens a step in the editor
- Every control in the editor is the system's own field
- Escape closes the pause question with the workflow still on
Motion
The ring travels from step to step (the flowchart's own). In a test run each step turns Running and then decides, one after another, and the path not taken turns Skipped; the run settles and nothing moves after. The matching count in a condition rolls as rules change. The tab counts roll. Reduced motion: the test still goes step by step (it carries information), with no travel.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
workflow / defaultWorkflow / onWorkflowChange | Workflow | — | { id, name, draft, published, version, enabled, paused? }: what is edited (draft) and what runs (published, null before the first publish). |
events (required) | WorkflowEvent[] | — | What can start a workflow, each with the fields its conditions can test: { id, label, description?, fields: QueryField[], noun? }. |
actions (required) | WorkflowActionType[] | — | What a step can do: { id, label, icon?, params: { id, label, options?, placeholder? }[], describe(params) }. |
samples | WorkflowSample[] | — | Records for a test run; without them there is no Test run. |
runs | WorkflowRun[] | null | — | Past runs, newest first; null while loading. |
countMatches | (eventId, query) => number | null | — | How many recent records a condition matches; null while counting. |
countNoun | [string, string] | — | What countMatches counts. Default the event's noun. |
onPublish | (workflow: Workflow) => Promise<void> | void | — | Shows Publish; a rejection keeps the draft and says why. |
onEnabledChange | (enabled: boolean, reason: string | null) => Promise<void> | void | — | Turning off asks for a reason first; a rejection puts the switch back and says why. |
onRetryRun | (runId: string) => void | Promise<void> | — | |
pauseReasons | string[] | — | Reasons offered when turning it off; Other (with a note) always follows. |
user | string | "You" | Who is signed in, for the pause record. |
tab / defaultTab / onTabChange | "build" | "runs" | "changes" | — | |
selected / defaultSelected / onSelectedChange | string | null | — | The step in the editor. |
workflows / onOpenWorkflow | { id, name, state: "live" | "paused" | "draft" }[] / (id) => void | — | The automations listed in the navigation. |
workspace / nav / defaultSidebarOpen | string / AppShellNavGroup[] / boolean | — | |
className / style / ref | string / CSSProperties / Ref<HTMLDivElement> | — | className: Classes on the documented visual root; no override by default. style: Inline styles on the documented visual root; no overrides by default. ref: Receives the documented native target or imperative handle; omitted by default. |
workflow | Workflow | — | |
defaultWorkflow | Workflow | — | |
onWorkflowChange | ((workflow: Workflow) => void) | — | |
tab | WorkflowTab | — | |
defaultTab | WorkflowTab | — | |
onTabChange | ((tab: WorkflowTab) => void) | — | |
selected | string | null | — | The step in the editor. |
defaultSelected | string | null | — | |
onSelectedChange | ((id: string | null) => void) | — | |
workflows | { id: string; name: string; state: "live" | "draft" | "paused"; }[] | — | |
onOpenWorkflow | ((id: string) => void) | — | |
workspace | string | — | |
nav | SidebarNavGroup[] | — | |
defaultSidebarOpen | boolean | — | |
className | string | — | |
style | CSSProperties | — | |
ref | Ref<HTMLDivElement> | — |
Built from
- app-shell
- flowchart
- query-builder
- inline-edit
- switch
- popover
- radio-group
- textarea
- tabs
- select
- number-field
- input
- dropdown-menu
- confirm-morph
- button
- badge
- alert
- tracker
- data-grid
- json-viewer
- json-diff-viewer
- empty-state
- spinner
Dependencies
lucide-react
Import
import { WorkflowBuilder } from "@beamline/workflow-builder";
Get it
Workflow builder is part of Beamline: 200+ components and 50+ complete screens for React, installed as local code in your repo. Your app never depends on Beamline servers at runtime. Build your own style from any look with public tokens, your fonts, radii, density and motion; custom style files stay in your app. Use local kit tools or let your coding agent find and install parts through the optional hosted MCP server. $49 launch price, one payment, no subscription, lifetime updates, one licence for your whole team. Get Beamline · Connect your agent
More in Blocks
- Trading terminal: A perpetuals terminal on your feed and your account: ticker tape, market header with funding, candles, book / trades / depth, order ticket, account…
- Market screener: The whole market at a glance and a way to narrow it down: a sector heatmap, today's top movers with the market's breadth, ready-made screens (gainers…
- AI agent workspace: Threads, a conversation with streamed reasoning, cited answers and a plan that waits for approval then runs step by step, and an artifacts panel with…
- Portfolio overview: What an account holds and how it is doing: the total that rolls as prices tick with today's change, value over time against a benchmark, allocation by…
- AI image studio: Write a prompt, pick a shape, a style and how many, and watch the variations generate side by side; each one opens full screen and can be upscaled or…
- Model playground: Try one prompt on up to three models side by side: pick each model with its price and speed in view, set the system prompt, temperature and length once…
- Artifact workbench: Where the things an assistant makes are checked before they leave: every document, piece of code, small app and data result from a conversation, each…
- Analytics dashboard: A SaaS overview in the app shell, fed by your metrics hook: range and segment filters drive KPIs, new and expansion revenue, channels, plan mix, uptime…
- Sales dashboard: A sales leader's week in one screen: closed won against quota and pace, pipeline coverage and win rate, the quarter's run toward target with the forecast…
- Document review: A PDF going through review: the document in the viewer with every comment pinned to its place, the reviewers' threads beside it (open or resolved, one…
- Product analytics: How people use the product: a funnel whose steps are the selector, where the people lost at a step went (saved as a cohort in one action), retention by…
- Status dashboard: An operations view of service health: the overall state in one line, every service with its status, uptime, latency now and 90 days of history, latency…
- CRM pipeline: A pipeline screen: KPIs and stage mix derived from a virtualised deals grid with inline edit, bulk moves and delete with undo; a row opens the deal in a…
- Helpdesk inbox: A support team's inbox: views with counts, a virtualised ticket queue with search, priority filters and live SLA clocks, and the open ticket with its…
- Project board: A team's sprint as a board: the sprint's goal, points done and days left, filters by person and label, the work as cards in columns with work-in-progress…
- Team calendar: A team's schedule: the people and shared calendars to show (each its colour), a month to jump by, who is out this week, and the week, day or month of…
- Invoices: Accounts receivable in one screen: what is outstanding, overdue and paid, the invoices by status in a virtualised grid with bulk reminders, and each…
- Orders admin: A shop's order desk: today's orders and revenue, quick filters for what needs doing (to fulfil, unpaid, returns), a virtualised orders grid, and the…
- Contact profile: One customer on one page: who they are and how to reach them (fields edit in place), their lifecycle stage and owner, the deals they are in with what is…
- File manager: Files and folders in one screen: the views (My files, Shared, Recent, Starred, Trash) with storage at the foot, a folder tree beside the files…
- Projects: A team's projects: the portfolio by health (on track, at risk, off track) with progress, lead, team and due date, filtered and searched; a project opens…
- Report builder: Build a chart from your metrics without code: choose metrics, how to group them over time, an optional breakdown, filters, the range and the chart, see…
- Voice agent: A voice agent in three layouts on one session: a support panel that mixes typing and talking, a call screen with the agent's orb and one call button, and…
- Admin users: Your staff's view of every account: headline counts that follow the filters, a virtualised users table with search, status and plan filters and sorting…
- Billing & invoices: The billing page of a subscription: the plan with its seats and renewal, cancel and resume in place, the card on file with a checked update form, metered…
- Onboarding checklist: The first screen after sign-up: a welcome with how far set-up has come, a checklist of the few steps that make the product useful (each with why, how…
- Roles & permissions: What each role may do, as one matrix: permissions grouped by area down the side, roles across the top with their head counts, a check per cell; a group's…
- Security: A person's account security on one page: how protected they are at a glance with the next step to take, password change with strength and rules, two-step…
- AI support chat: The customer's side of AI support: an assistant that answers from your help centre with numbered citations, a thumbs up or down on every answer (a down…
- AI support console: The support team's side of AI support: a queue sorted by what is due first (who the assistant is still handling, who asked for a person, who waits), the…
- Conversation history: Past conversations with an assistant, ready to pick up again: the list by day with bookmarks and unsent drafts, a search through every message that…
- Agent runs monitor: Every run of your agents in one place: success rate, run time, tokens and spend; the last runs as a strip of status blocks; a live table where running…
- Social media scheduler: Plan posts across your social accounts: a week calendar where every post sits at its time in its account's colour and moves by drag, a queue of what goes…
- Team chat: A team's messages in one screen: channels and direct messages with unread counts and mentions, who is online, the conversation with reactions, receipts…
- Knowledge base manager: What your assistant knows and whether it is fresh: sources with live sync status (syncing with progress, out of date, failed with the reason and Retry)…
- Meeting and call review: Everything a recorded call left behind on one screen: the recording with its transcript by speaker, an AI summary that streams in, action items with…
- Order history and fills: Every order the account placed and every fill it got, for a period: totals for volume, fees, fill rate and maker share; orders with their status and how…
- Integrations: A directory of the apps a product connects to: search and categories with counts, connected apps first with their state (Connected, Needs attention), a…
- Plan comparison: Plans side by side against every feature: prices that roll between monthly and yearly, the current and recommended plan marked, a header that stays in…
- System pages: The four pages a product shows when the normal one cannot: page not found (search and the likely places), something broke (try again, an error id to…
- API keys & webhooks: The developer page of a SaaS: API keys with environment, scopes, last use and expiry, created through a form whose secret is shown once (copy it before…
- Audit log: Who did what, to what, when and from where, for a whole workspace: newest first and grouped by day, people with avatars and keys or systems with toned…
- Team & members: The people page of a workspace: seats used against the plan, members and pending invitations in one list with search and a role filter, role changes that…
- Notification preferences: What reaches a person and where: events grouped by area down the side, channels (email, push, Slack, in-app) across the top, a switch per pair that saves…
- Workspace switcher: Moving between workspaces and making a new one: a switcher for the top of your sidebar (the current workspace's mark, name and plan; a searchable list…
- Step form: The finished frame for any multi-step form you compose — onboarding, intake brief, questionnaire, booking, application: a wide card with progress, the…
- Changelog feed: An in-app What's new page: release notes grouped by month with tags, versions, pictures and details, a tag filter with counts, entries since your last…
- Page header: The top of a record or project page: breadcrumb, title with status, description and meta, a primary action with secondary actions that fold into a More…
- Empty states: The five empty moments every product has, written and wired: first use with a first step, no results with the filters to clear, an error with retry and a…
- Settings: Profile and workspace settings with one draft and a real save handler, on grouped panels: photo upload, time zone with the local time, appearance cards…
- Auth page: The whole sign-in / sign-up route: product mark, a quiet dotted field with a light that follows the mouse, an optional notice, the SignIn and SignupForm…
- Sign in: The sign-in card: email and password, a one-time code or a magic link, passkeys and single sign-on, with validation, progress, errors and a signed-in…
- Sign up form: The account creation card: single sign-on, name, work email and a password with strength and Caps Lock hints, terms consent, inline validation, your…