All skills
github avatar

/flowstudio-power-automate-mcp

@0ccadfd official
by githubgithub/awesome-copilot40k stars
5,040

Foundation skill for Power Automate via FlowStudio MCP — auth setup, the reusable MCP helper (Python + Node.js), tool discovery via `list_skills` / `tool_search`, and oversized-response handling. Load this skill first when connecting an agent to Power Automate. For specialized workflows, load `flowstudio-power-automate-build`, `flowstudio-power-automate-debug`, `flowstudio-power-automate-monitoring` (Pro+), or `flowstudio-power-automate-governance` (Pro+) — each contains the workflow narrative, this skill provides the plumbing they all rely on. Requires a FlowStudio MCP subscription or compatible server — see https://mcp.flowstudio.app

Use this Skill: https://skilld.dev/gh/github/awesome-copilot/flowstudio-power-automate-mcp

This session only. Nothing lands on disk.

referencesconnection-references.md

≈1.3k tokens on demand. Your agent reads this file only when SKILL.md points to it.

FlowStudio MCP — Connection References

Connection references wire a flow's connector actions to real authenticated connections in the Power Platform. They are required whenever you call update_live_flow with a definition that uses connector actions.


Structure in a Flow Definition

{
  "properties": {
    "definition": { ... },
    "connectionReferences": {
      "shared_sharepointonline": {
        "connectionName": "shared-sharepointonl-eeeeeeeeee-eeee-eeee-eeee-eeeeeeeeeeee",
        "id": "/providers/Microsoft.PowerApps/apis/shared_sharepointonline",
        "displayName": "SharePoint"
      },
      "shared_office365": {
        "connectionName": "shared-office365-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
        "id": "/providers/Microsoft.PowerApps/apis/shared_office365",
        "displayName": "Office 365 Outlook"
      }
    }
  }
}

Keys are logical reference names (e.g. shared_sharepointonline). These match the connectionName field inside each action's host block.


Finding Connection References

Preferred method: call list_live_connections in the target environment. Use search to narrow results to the connector you need; newer MCP server versions return paste-ready templates.

matches = mcp("list_live_connections",
    environmentName=ENV,
    search="shared_sharepointonline")

conn = next(c for c in matches["connections"]
            if c.get("overallStatus") == "Connected"
            or c.get("statuses", [{}])[0].get("status") == "Connected")

conn_refs = {
    "shared_sharepointonline": conn.get("connectionReferenceTemplate") or {
        "connectionName": conn["id"],
        "id": "/providers/Microsoft.PowerApps/apis/shared_sharepointonline",
        "source": "Invoker"
    }
}
host = conn.get("hostTemplate") or {"connectionName": "shared_sharepointonline"}

Use host as the action-side inputs.host. Use conn_refs as update_live_flow(connectionReferences=conn_refs).

Fallback method: copy from an existing flow.

Call get_live_flow on any existing flow that uses the same connection and copy the connectionReferences block. The GUID after the connector prefix is the connection instance owned by the authenticating user.

flow = mcp("get_live_flow", environmentName=ENV, flowName=EXISTING_FLOW_ID)
conn_refs = flow["properties"]["connectionReferences"]
# conn_refs["shared_sharepointonline"]["connectionName"]
# → "shared-sharepointonl-eeeeeeeeee-eeee-eeee-eeee-eeeeeeeeeeee"

⚠️ Connection references are user-scoped. If a connection is owned by another account, update_live_flow will return 403 ConnectionAuthorizationFailed. You must use a connection belonging to the account whose token is in the x-api-key header.


Passing connectionReferences to update_live_flow

result = mcp("update_live_flow",
    environmentName=ENV,
    flowName=FLOW_ID,
    definition=modified_definition,
    connectionReferences={
        "shared_sharepointonline": {
            "connectionName": "shared-sharepointonl-eeeeeeeeee-eeee-eeee-eeee-eeeeeeeeeeee",
            "id": "/providers/Microsoft.PowerApps/apis/shared_sharepointonline"
        }
    }
)

Only include connections that the definition actually uses.


Common Connector API IDs

Service API ID
SharePoint Online /providers/Microsoft.PowerApps/apis/shared_sharepointonline
Office 365 Outlook /providers/Microsoft.PowerApps/apis/shared_office365
Microsoft Teams /providers/Microsoft.PowerApps/apis/shared_teams
OneDrive for Business /providers/Microsoft.PowerApps/apis/shared_onedriveforbusiness
Azure AD /providers/Microsoft.PowerApps/apis/shared_azuread
HTTP with Azure AD /providers/Microsoft.PowerApps/apis/shared_webcontents
SQL Server /providers/Microsoft.PowerApps/apis/shared_sql
Dataverse /providers/Microsoft.PowerApps/apis/shared_commondataserviceforapps
Azure Blob Storage /providers/Microsoft.PowerApps/apis/shared_azureblob
Approvals /providers/Microsoft.PowerApps/apis/shared_approvals
Office 365 Users /providers/Microsoft.PowerApps/apis/shared_office365users
Flow Management /providers/Microsoft.PowerApps/apis/shared_flowmanagement

Teams Adaptive Card Dual-Connection Requirement

Flows that send adaptive cards and post follow-up messages require two separate Teams connections:

"connectionReferences": {
  "shared_teams": {
    "connectionName": "shared-teams-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
    "id": "/providers/Microsoft.PowerApps/apis/shared_teams"
  },
  "shared_teams_1": {
    "connectionName": "shared-teams-yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy",
    "id": "/providers/Microsoft.PowerApps/apis/shared_teams"
  }
}

Both can point to the same underlying Teams account but must be registered as two distinct connection references. The webhook (OpenApiConnectionWebhook) uses shared_teams and subsequent message actions use shared_teams_1.

Source: SKILL.md on GitHub

2 warnings16d5 checks · Risk SAFE
  • Gen Agent Trust Hub16d

    This skill provides a foundation for connecting an AI agent to the FlowStudio MCP server for Power Automate management. It includes reusable helper functions and instructions for handling large data payloads. The low-risk rating is due to the inherent nature of third-party data ingestion and communication with a service outside the core trusted infrastructure.

  • Socket16d

    No alerts

  • Snyk16d

    Risk: MEDIUM · 1 issue

  • Runlayer6mo

    4/5 files flagged

  • ZeroLeaks5mo

    Score: 93/100 · 2 sections analyzed

Signed by skilld at 0ccadfd. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 19 hours ago.

Activeupdated 4 weeks ago

README badge

README badge for github/awesome-copilot/flowstudio-power-automate-mcp

Provides authentication setup, JSON-RPC request/response handling, and tool discovery for Power Automate via FlowStudio MCP server. Load this skill first when connecting an agent to Power Automate; specialized workflow skills (build, debug, monitoring, governance) depend on it.

Generated from the current SKILL.md.

Do I need a FlowStudio subscription to use this skill?
Yes. This skill requires a FlowStudio MCP subscription or compatible Power Automate MCP server, along with an MCP endpoint, API key, and Power Platform environment name.
What should I load first when connecting an agent to Power Automate?
Load this foundation skill first. It provides auth setup, the MCP helper, and tool discovery. Then load one of the specialized skills (build, debug, monitoring, or governance) based on what the user is trying to accomplish.
Does this skill work with Python and Node.js?
Yes. The skill includes recommended helpers for both Python (using urllib.request) and Node.js 18+ (using built-in fetch). PowerShell is not recommended for flow operations due to JSON truncation issues.
How do I discover which tools are available?
Call `list_skills` for available bundles, then use `tool_search` with `query: "skill:<name>"` to load the full schema set for a specific bundle, or use free-text search for ambiguous requests.
What do I do if a tool response is too large for the context window?
The harness saves oversized responses to a file and returns the path. Parse the file by reading it as JSON, then parsing the escaped payload inside it; always extract only the fields you need and pass `actionName` to `get_live_flow_run_action_outputs` to limit results.

Generated from the current SKILL.md. These answers refresh after source changes.