ui_builder_merge_branch
Replay a branch's edits onto its parent's current revision through the same reducer every edit goes through — all or nothing. The reply reports every command: applied with the revision it landed at and any STALE_* notice of what it overwrote, or refused with the rejection code that stopped the run (nothing is then written), plus skippedOperationIds and how many were never tried. Run dryRun: true first: it reports merged: false and wouldMerge (true when every command would land) and writes nothing. Resolve a refusal by passing that command's id in skipOperationIds (skip an undo with what it undoes), or branch again from the parent. On success the branch is merged and its open siblings — branches forked at the same revision — are archived. Needs write access to the parent.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| token | No | A grant token from poll_access, when you cannot set the X-Compose-Preview-Token header yourself — an MCP client fixes its headers at connect time, so this is how a token approved during this session is used in it. Prefer the header where you control it. | |
| dryRun | No | Replay and report without writing anything: the reply's merged is then false and wouldMerge carries the verdict. Defaults to false. | |
| branchId | Yes | ||
| agentName | No | Optional agent/client name shown to design viewers; self-reported. | |
| agentModel | No | Optional current model name shown to design viewers; self-reported. Omit when unknown. | |
| skipOperationIds | No | Logged commands to leave out of the replay. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| dryRun | Yes | ||
| merged | Yes | ||
| schema | Yes | ||
| summary | Yes | ||
| branchId | Yes | ||
| commands | Yes | ||
| remaining | Yes | ||
| wouldMerge | Yes | ||
| forkRevision | Yes | ||
| parentDesignId | Yes | ||
| archivedSiblingIds | No | ||
| parentRevisionAfter | Yes | ||
| skippedOperationIds | No | ||
| parentRevisionBefore | Yes |