update_live_flow
Update or create a flow. Use dryRun: true to preview any change without writing. Omit flowName to create: definition and displayName are required. Give flowName to update: displayName and/or definition and/or connectionReferences. SURGICAL EDIT: pass operations — an ordered list of set/add/remove/merge ops on array-of-keys paths — to change one action or parameter without resending the whole definition. Provide EITHER operations OR definition; connectionReferences may accompany either and lands in the same save. WHOLE definition: call get_live_flow, mutate properties.definition, pass it here. RENAME: pass displayName alone. Power Automate rejects a PATCH carrying no flow content, so this re-saves the unchanged definition — the maker portal does the same. definition.description is required, and must be brief — we append " #flowstudio-mcp" to it.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| dryRun | No | Preview only, on BOTH paths: with flowName, apply the change to the live definition and return the result + what changed; without flowName, return the flow that WOULD be created. Nothing is written either way. | |
| flowName | No | Name (ID) of the flow to update. Omit or leave blank to create a new flow. | |
| definition | No | Full flow definition as a JSON object (triggers + actions + parameters + outputs + description). MUST be a JSON object — strings are rejected. Do not JSON.stringify the definition; pass the parsed object directly. Required when creating. For updates, obtain from get_live_flow (properties.definition), modify it, then pass the modified object here. definition.description is required (a short note about what changed); when updating, if you omit it we reuse the flow's existing description. | |
| operations | No | SURGICAL EDIT of an existing flow (requires flowName; do not combine with definition). An ordered list applied to the LIVE definition. Each item = { op, path, value? }. path is an ARRAY of literal keys, e.g. ["actions","Send_Email","inputs","parameters","subject"] (each element is one key; a "/" inside an element is literal, so it addresses SharePoint/Dataverse columns like ["actions","Update_Item","inputs","parameters","item/Title"]). ops: set (create/overwrite), add (new key — errors if it already exists), remove (delete key — no-op if absent), merge (deep-merge an object value, keeping sibling keys). | |
| displayName | No | Display name for the flow. Required when creating. | |
| environmentName | Yes | Name of the Power Platform environment. | |
| connectionReferences | No | Connection references map copied from get_live_flow. Direct-flow entries use { connectionName, id }. Solution-aware entries also include { connectionReferenceLogicalName, source } and must retain those fields exactly. A freshly migrated entry may instead be keyed by the physical connection name and carry no connectionName field at all — copy it back as-is. The action/trigger inputs.host.connectionName must match the map key; the physical connectionName stays inside the entry. Never invent a solution logical name. Adding a connectionReferenceLogicalName to an entry that lacks one does not always take: the save can return success without storing it, so re-read with get_live_flow to confirm. MAY BE PASSED ALONGSIDE operations: your entries are merged over the stored map and saved in the SAME request as the edit. That is how you add the first action for a connector the flow does not use yet — a reference saved on its own does not stick, because Power Automate prunes an entry no action references. Your entries win on a key collision. |