BUILD: write, compile, and save
BUILD turns a ready THINK plan into a saved Studio flow. Your coding agent writes one TypeScript file per flow, and the Mindflow MCP server compiles it. The agent then saves the flow’s latest version in the environment your plan names and shares a link that opens it in Studio. Saving does not start a run.
When to use
Section titled “When to use”- THINK finished: the plan is ready and your design answers (environment, credentials, create or update) are filled.
- Prefer THINK: discover and design when the brief or plan is missing or you need to change operations.
- Prefer RUN: try, fix, and roll back when the flow is saved and you want to try it.
- Prefer AI··Build when you want to add steps on a canvas that already exists in Studio.
Before you begin, connect your coding agent and finish THINK in a prior chat. Open a new chat for BUILD so the interview is not replayed.
Start BUILD from the ready plan
Section titled “Start BUILD from the ready plan”BUILD reads src/think/plan.json and src/think/selections.json in your application folder. It copies operation ids
from the catalog; it does not invent connectors.
- Open a new chat. Do not continue BUILD in the THINK chat.
- Ask to continue the build. Ask the agent to continue the Mindflow build. When the plan is ready, the agent starts BUILD; otherwise it goes back to THINK.
- Check create or update. The agent follows your design answers: it creates new flows, or updates only the flows you named.
- Let it load operation details. The agent reads what each selected operation needs from the catalog, plus transforms and models when the plan uses them.
Compile through the Mindflow MCP server
Section titled “Compile through the Mindflow MCP server”Compiling is a Mindflow service call, not a tool on your computer. If compile reports findings, the agent fixes the TypeScript and compiles again. You never paste flow JSON by hand.
- Wait for compile. The agent sends each TypeScript file to the Mindflow MCP server.
- Review findings. If compile fails, the agent names the step and field to fix, fixes the TypeScript, and compiles again. If the plan needs something the flow format cannot express, the agent stops and tells you.
- Check the local files. The TypeScript files stay under
src/. Compile returns findings only; it does not write files.
Save and open in Studio
Section titled “Save and open in Studio”Once compile succeeds, the agent saves each flow with the access you approved at sign-in. Each flow it builds has one deployment in your plan’s environment that follows the flow’s latest version, so each save shows up there.
- Let the agent save a new flow. For a new flow, the agent creates the flow and its deployment, saves the compiled flow, and binds the credentials your design answers named. It leaves other credentials for you to bind in Studio.
- Let the agent update an existing flow. For an update, the agent first reads the latest version. If someone changed the flow in Studio since the last save, the agent refreshes its local file and tells you. Before its first overwrite in a session, it saves a checkpoint version named Before AI Build: … so you can roll back.
- Open the Studio link. The agent shares a link to the flow. Open it to review the canvas and bind any remaining credentials.
- Try it. When your design answers said every product can be called, the agent offers to try the flow in the same chat. See RUN: try, fix, and roll back.
Example
Section titled “Example”The SOC analyst’s plan for Triage malicious webhook IPs is ready (VirusTotal lookup, Slack post on a malicious reputation, environment Docs). They start BUILD in a new Claude Code chat.
- Ask to continue. They ask the agent to continue the Mindflow build.
- Compile. The first compile succeeds. The TypeScript file is under
triage-malicious-webhook-ips/src/. - Open the Studio link. The agent creates the flow, saves it to Docs, binds the VirusTotal and Slack credentials from the plan, and shares the link. Nothing has run yet. The agent offers to try it.
Keep in mind
Section titled “Keep in mind”- Never put secrets in chat, TypeScript, or the agent’s tool calls. Credentials bind the way your design answers said.
- Do not ask the agent to compile on your computer. Compile happens on the Mindflow MCP server only.
- If someone saves the flow in Studio while the agent works, the agent reads it again and re-applies its change. It never overwrites a newer save.
- Renaming a step in the TypeScript replaces that step in Studio. Its canvas position, run history, and credential binding are lost, and the agent warns you.
- BUILD never runs or deletes flows. Promoting to Live, pinning a version, and deleting stay in Studio. See Manage version and deployments.
Related
Section titled “Related”THINK: discover and design · RUN: try, fix, and roll back · Manage version and deployments