Skip to main content
Glama

Fork a briq or a whole stack

briq_fork

Branch before you try something you might want to undo: a migration, a destructive test, a second approach next to the first. Pass briq to fork one briq, or stack to fork every briq of a stack into a new stack (names kept, so the forked app talks to the forked database). Each fork starts from a copy of its source's disk as it is now, keeps the same credentials, and gets its own address; the source keeps running and never sees what the fork does. Processes in a fork start fresh on the copied disk, like after a power cut (a database replays its log); memory is not copied. A briq without a volume gets its config and boot files; what it wrote to its own disk stays with the source. Returns outputs pointing at the fork. Keep the fork, or briq_destroy it to throw the attempt away.

Input Schema

NameRequiredDescriptionDefault
briqNobriq id (bq_…) to fork
intoNoStack fork only: name of the new stack (default "<stack>-fork")
nameNoSingle fork only: name of the fork (default "<name>-fork")
waitNoWait until the forks are ready (default true)
sleepNoWhen it goes to sleep: after this long without use, as a string: "30m", "3h", "7d", or "never" (always on, Pro plan and above). Never a number. Use means your calls on it (exec, files, logs, expose), on any briq of its stack, and visits to its stack's URLs. A sleeping briq keeps its disk, costs nothing, and the next call or visit wakes it. A command started with briq_exec async is use while it runs. Other work briq cannot see (a worker, a bot that only makes outgoing connections) needs a window longer than that work, or "never". Default: the source's. A window longer than your key allows is refused: send a shorter one.
stackNoWith `briq`: the stack to create the fork in (default: the same). Without: the stack to fork whole.
exposeNoStack fork only: reach the fork from outside briq (a laptop, a sandbox). Database ports get TLS endpoints, front doors a URL in this mode; outputs use them. Leave it out when only briqs of the stack use the fork.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations only declare the write/idempotency profile; the description adds substantial context beyond them: the fork starts from a live disk copy of the source, keeps the same credentials, gets its own address, and the source keeps running without seeing the fork. It also discloses the non-obvious caveats (memory is not copied, processes start fresh as after a power loss, a briq without a volume loses what it wrote) — exactly the surprises that would otherwise break an agent's mental model.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the decision rule then the mode switch, then behavior, then cleanup — a sensible order. It is dense rather than padded, though the power-cut and disk-replay sentences are long and the volume caveat could be tighter.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 7-parameter tool with no output schema, the description covers what an agent needs: two operating modes, snapshot semantics, credential and addressing inheritance, process/memory state, disk edge case, and that the return value contains outputs pointing at the fork. Nothing material about the call's consequences is left implicit.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3, but the description adds real meaning: the `briq`/`stack` pair is framed as mutually selecting single-vs-whole-stack forking, naming is explained (names kept so the forked app talks to the forked database), and `expose` is conditioned on external access. It does repeat some schema content rather than extend it, keeping it short of a 5.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (fork) and resource (a briq or a whole stack), and immediately disambiguates the two modes by naming the parameter that selects each: `briq` for one, `stack` for every briq of a stack. An agent can distinguish this from siblings like briq_up or briq_start without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicit when-to-use framing: branch before a migration, a destructive test, or a parallel approach. It also names the exit path and the sibling that implements it ("Keep the fork, or briq_destroy it to throw the attempt away"), which closes the loop on the workflow.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.