Skip to content

Commit fcec8fb

Browse files
committed
feat: add flowstudio-power-automate-debug and flowstudio-power-automate-build skills
Two companion skills for the FlowStudio Power Automate MCP server: - flowstudio-power-automate-debug: Debug workflow for failed Power Automate cloud flow runs - flowstudio-power-automate-build: Build & deploy flows from natural language descriptions Both require a FlowStudio MCP subscription: https://flowstudio.app These complement the existing flowstudio-power-automate-mcp skill (merged in PR #896).
1 parent f3142d7 commit fcec8fb

10 files changed

Lines changed: 3483 additions & 0 deletions

File tree

skills/flowstudio-power-automate-build/SKILL.md

Lines changed: 460 additions & 0 deletions
Large diffs are not rendered by default.

skills/flowstudio-power-automate-build/references/action-patterns-connectors.md

Lines changed: 542 additions & 0 deletions
Large diffs are not rendered by default.

skills/flowstudio-power-automate-build/references/action-patterns-core.md

Lines changed: 542 additions & 0 deletions
Large diffs are not rendered by default.

skills/flowstudio-power-automate-build/references/action-patterns-data.md

Lines changed: 734 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 108 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,108 @@
1+
# Common Build Patterns
2+
3+
Complete flow definition templates ready to copy and customize.
4+
5+
---
6+
7+
## Pattern: Recurrence + SharePoint list read + Teams notification
8+
9+
```json
10+
{
11+
"triggers": {
12+
"Recurrence": {
13+
"type": "Recurrence",
14+
"recurrence": { "frequency": "Day", "interval": 1,
15+
"startTime": "2026-01-01T08:00:00Z",
16+
"timeZone": "AUS Eastern Standard Time" }
17+
}
18+
},
19+
"actions": {
20+
"Get_SP_Items": {
21+
"type": "OpenApiConnection",
22+
"runAfter": {},
23+
"inputs": {
24+
"host": {
25+
"apiId": "/providers/Microsoft.PowerApps/apis/shared_sharepointonline",
26+
"connectionName": "shared_sharepointonline",
27+
"operationId": "GetItems"
28+
},
29+
"parameters": {
30+
"dataset": "https://mytenant.sharepoint.com/sites/mysite",
31+
"table": "MyList",
32+
"$filter": "Status eq 'Active'",
33+
"$top": 500
34+
}
35+
}
36+
},
37+
"Apply_To_Each": {
38+
"type": "Foreach",
39+
"runAfter": { "Get_SP_Items": ["Succeeded"] },
40+
"foreach": "@outputs('Get_SP_Items')?['body/value']",
41+
"actions": {
42+
"Post_Teams_Message": {
43+
"type": "OpenApiConnection",
44+
"runAfter": {},
45+
"inputs": {
46+
"host": {
47+
"apiId": "/providers/Microsoft.PowerApps/apis/shared_teams",
48+
"connectionName": "shared_teams",
49+
"operationId": "PostMessageToConversation"
50+
},
51+
"parameters": {
52+
"poster": "Flow bot",
53+
"location": "Channel",
54+
"body/recipient": {
55+
"groupId": "<team-id>",
56+
"channelId": "<channel-id>"
57+
},
58+
"body/messageBody": "Item: @{items('Apply_To_Each')?['Title']}"
59+
}
60+
}
61+
}
62+
},
63+
"operationOptions": "Sequential"
64+
}
65+
}
66+
}
67+
```
68+
69+
---
70+
71+
## Pattern: HTTP trigger (webhook / Power App call)
72+
73+
```json
74+
{
75+
"triggers": {
76+
"manual": {
77+
"type": "Request",
78+
"kind": "Http",
79+
"inputs": {
80+
"schema": {
81+
"type": "object",
82+
"properties": {
83+
"name": { "type": "string" },
84+
"value": { "type": "number" }
85+
}
86+
}
87+
}
88+
}
89+
},
90+
"actions": {
91+
"Compose_Response": {
92+
"type": "Compose",
93+
"runAfter": {},
94+
"inputs": "Received: @{triggerBody()?['name']} = @{triggerBody()?['value']}"
95+
},
96+
"Response": {
97+
"type": "Response",
98+
"runAfter": { "Compose_Response": ["Succeeded"] },
99+
"inputs": {
100+
"statusCode": 200,
101+
"body": { "status": "ok", "message": "@{outputs('Compose_Response')}" }
102+
}
103+
}
104+
}
105+
}
106+
```
107+
108+
Access body values: `@triggerBody()?['name']`
Lines changed: 225 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,225 @@
1+
# FlowStudio MCP — Flow Definition Schema
2+
3+
The full JSON structure expected by `update_live_flow` (and returned by `get_live_flow`).
4+
5+
---
6+
7+
## Top-Level Shape
8+
9+
```json
10+
{
11+
"$schema": "https://schema.management.azure.com/providers/Microsoft.Logic/schemas/2016-06-01/workflowdefinition.json#",
12+
"contentVersion": "1.0.0.0",
13+
"parameters": {
14+
"$connections": {
15+
"defaultValue": {},
16+
"type": "Object"
17+
}
18+
},
19+
"triggers": {
20+
"<TriggerName>": { ... }
21+
},
22+
"actions": {
23+
"<ActionName>": { ... }
24+
},
25+
"outputs": {}
26+
}
27+
```
28+
29+
---
30+
31+
## `triggers`
32+
33+
Exactly one trigger per flow definition. The key name is arbitrary but
34+
conventional names are used (e.g. `Recurrence`, `manual`, `When_a_new_email_arrives`).
35+
36+
See [trigger-types.md](trigger-types.md) for all trigger templates.
37+
38+
---
39+
40+
## `actions`
41+
42+
Dictionary of action definitions keyed by unique action name.
43+
Key names may not contain spaces — use underscores.
44+
45+
Each action must include:
46+
- `type` — action type identifier
47+
- `runAfter` — map of upstream action names → status conditions array
48+
- `inputs` — action-specific input configuration
49+
50+
See [action-patterns-core.md](action-patterns-core.md), [action-patterns-data.md](action-patterns-data.md),
51+
and [action-patterns-connectors.md](action-patterns-connectors.md) for templates.
52+
53+
### Optional Action Properties
54+
55+
Beyond the required `type`, `runAfter`, and `inputs`, actions can include:
56+
57+
| Property | Purpose |
58+
|---|---|
59+
| `runtimeConfiguration` | Pagination, concurrency, secure data, chunked transfer |
60+
| `operationOptions` | `"Sequential"` for Foreach, `"DisableAsyncPattern"` for HTTP |
61+
| `limit` | Timeout override (e.g. `{"timeout": "PT2H"}`) |
62+
63+
#### `runtimeConfiguration` Variants
64+
65+
**Pagination** (SharePoint Get Items with large lists):
66+
```json
67+
"runtimeConfiguration": {
68+
"paginationPolicy": {
69+
"minimumItemCount": 5000
70+
}
71+
}
72+
```
73+
> Without this, Get Items silently caps at 256 results. Set `minimumItemCount`
74+
> to the maximum rows you expect. Required for any SharePoint list over 256 items.
75+
76+
**Concurrency** (parallel Foreach):
77+
```json
78+
"runtimeConfiguration": {
79+
"concurrency": {
80+
"repetitions": 20
81+
}
82+
}
83+
```
84+
85+
**Secure inputs/outputs** (mask values in run history):
86+
```json
87+
"runtimeConfiguration": {
88+
"secureData": {
89+
"properties": ["inputs", "outputs"]
90+
}
91+
}
92+
```
93+
> Use on actions that handle credentials, tokens, or PII. Masked values show
94+
> as `"<redacted>"` in the flow run history UI and API responses.
95+
96+
**Chunked transfer** (large HTTP payloads):
97+
```json
98+
"runtimeConfiguration": {
99+
"contentTransfer": {
100+
"transferMode": "Chunked"
101+
}
102+
}
103+
```
104+
> Enable on HTTP actions sending or receiving bodies >100 KB (e.g. parent→child
105+
> flow calls with large arrays).
106+
107+
---
108+
109+
## `runAfter` Rules
110+
111+
The first action in a branch has `"runAfter": {}` (empty — runs after trigger).
112+
113+
Subsequent actions declare their dependency:
114+
115+
```json
116+
"My_Action": {
117+
"runAfter": {
118+
"Previous_Action": ["Succeeded"]
119+
}
120+
}
121+
```
122+
123+
Multiple upstream dependencies:
124+
```json
125+
"runAfter": {
126+
"Action_A": ["Succeeded"],
127+
"Action_B": ["Succeeded", "Skipped"]
128+
}
129+
```
130+
131+
Error-handling action (runs when upstream failed):
132+
```json
133+
"Log_Error": {
134+
"runAfter": {
135+
"Risky_Action": ["Failed"]
136+
}
137+
}
138+
```
139+
140+
---
141+
142+
## `parameters` (Flow-Level Input Parameters)
143+
144+
Optional. Define reusable values at the flow level:
145+
146+
```json
147+
"parameters": {
148+
"listName": {
149+
"type": "string",
150+
"defaultValue": "MyList"
151+
},
152+
"maxItems": {
153+
"type": "integer",
154+
"defaultValue": 100
155+
}
156+
}
157+
```
158+
159+
Reference: `@parameters('listName')` in expression strings.
160+
161+
---
162+
163+
## `outputs`
164+
165+
Rarely used in cloud flows. Leave as `{}` unless the flow is called
166+
as a child flow and needs to return values.
167+
168+
For child flows that return data:
169+
170+
```json
171+
"outputs": {
172+
"resultData": {
173+
"type": "object",
174+
"value": "@outputs('Compose_Result')"
175+
}
176+
}
177+
```
178+
179+
---
180+
181+
## Scoped Actions (Inside Scope Block)
182+
183+
Actions that need to be grouped for error handling or clarity:
184+
185+
```json
186+
"Scope_Main_Process": {
187+
"type": "Scope",
188+
"runAfter": {},
189+
"actions": {
190+
"Step_One": { ... },
191+
"Step_Two": { "runAfter": { "Step_One": ["Succeeded"] }, ... }
192+
}
193+
}
194+
```
195+
196+
---
197+
198+
## Full Minimal Example
199+
200+
```json
201+
{
202+
"$schema": "https://schema.management.azure.com/providers/Microsoft.Logic/schemas/2016-06-01/workflowdefinition.json#",
203+
"contentVersion": "1.0.0.0",
204+
"triggers": {
205+
"Recurrence": {
206+
"type": "Recurrence",
207+
"recurrence": {
208+
"frequency": "Week",
209+
"interval": 1,
210+
"schedule": { "weekDays": ["Monday"] },
211+
"startTime": "2026-01-05T09:00:00Z",
212+
"timeZone": "AUS Eastern Standard Time"
213+
}
214+
}
215+
},
216+
"actions": {
217+
"Compose_Greeting": {
218+
"type": "Compose",
219+
"runAfter": {},
220+
"inputs": "Good Monday!"
221+
}
222+
},
223+
"outputs": {}
224+
}
225+
```

0 commit comments

Comments
 (0)