write-flow

Scaffold and author Windmill flows using the wmill CLI and OpenFlow schema.

1|Updated Aug 3, 2026
One-click install
npx skills add https://github.com/vpzed-dev/smithy --skill write-flow-vpzed-dev
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: write-flow
Source: https://github.com/vpzed-dev/smithy/tree/main/windmill/local-dev/.agents/skills/write-flow
Command: npx skills add https://github.com/vpzed-dev/smithy --skill write-flow-vpzed-dev

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Creating Windmill flows by hand leads to wrong folder suffixes, malformed flow.yaml structures, and invalid module wiring. This Skill guides an AI agent to scaffold flows correctly with the wmill CLI and write structurally valid OpenFlow definitions. ## Core Features & Use Cases - CLI-driven scaffolding: Runs wmill flow new <path> --summary to create the flow folder with the correct suffix and a valid flow.yaml shell, after asking the user for path and summary. - OpenFlow structure rules: Enforces reserved module IDs, correct placement of preprocessor_module and failure_module, module-level suspend for approvals, and correct stop_after_if placement in whileloopflow loops. - Preview and deploy discipline: Distinguishes wmill flow preview (safe local testing, including single-step runs with --step) from wmill flow run and wmill sync push (deploys requiring explicit user approval), plus wmill generate-metadata for lock file maintenance. - Use Case: A user asks to build an approval workflow. The agent scaffolds the flow, writes a rawscript step calling wmill.getResumeUrls with a module-level suspend block, previews it locally with sample args, and only deploys when the user explicitly approves. ## Quick Start Ask the agent to create a new Windmill flow at a given path with a short summary, and it will scaffold, populate, and preview the flow for you.

Frequently Asked Questions about write-flow

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a new Windmill flow from the CLI?▼

Run `wmill flow new <path> --summary "description"` to scaffold the flow. The command creates the folder with the correct suffix based on the workspace's nonDottedPaths setting, writes a minimal flow.yaml, and prints next-step hints. Do not hand-create the folder and flow.yaml.

How do I test a Windmill flow locally without deploying?▼

Use `wmill flow preview <flow_path> -d '<args>'` to run the local flow.yaml against local inline scripts without deploying. Add `--step <step_id>` to run a single module in isolation, or `--remote` to use deployed workspace scripts for PathScript steps.

What is the difference between wmill flow preview and wmill flow run?▼

flow preview executes your local flow.yaml edits without deploying, making it the default for iterating. flow run executes the version already deployed in the workspace, so use it only when you explicitly want to test the deployed version.

How do I add an approval step to a Windmill flow?▼

Add a module-level `suspend` block (sibling of id and value, never inside value) to a rawscript or script step that calls wmill.getResumeUrls(approver). Do not use type: identity, since it suspends without producing resume URLs for approvers.

Why does my whileloopflow never terminate in Windmill?▼

Common causes: stop_after_if placed inside the loop's value instead of as a module-level sibling, or relying on flow_input.iter.value which is only the iteration index in while loops. To carry state, read results.<step_id> with a fallback and put stop_after_if on that inner step.

When should I run wmill generate-metadata?▼

Run it after editing inline scripts whose imports or arguments changed, so local .lock files and content hashes in wmill-lock.yaml stay current. Use --dry-run first to see what is stale and why before applying changes.