Skip to content

Comments

MCP Support for Consumption #8788

Open
Bhavd13 wants to merge 2 commits intoAzure:mainfrom
Bhavd13:mcp
Open

MCP Support for Consumption #8788
Bhavd13 wants to merge 2 commits intoAzure:mainfrom
Bhavd13:mcp

Conversation

@Bhavd13
Copy link
Contributor

@Bhavd13 Bhavd13 commented Feb 4, 2026

Commit Type

  • feature - New functionality
  • fix - Bug fix
  • refactor - Code restructuring without behavior change
  • perf - Performance improvement
  • docs - Documentation update
  • test - Test-related changes
  • chore - Maintenance/tooling

Risk Level

  • Low - Minor changes, limited scope
  • Medium - Moderate changes, some user impact
  • High - Major changes, significant user/system impact

What & Why

This PR implements MCP (Model Context Protocol) connection support for Consumption Logic Apps. Most of the MCP implementation code was already common for managed connectors, shared between Standard and Consumption. For built-in MCP connections in Consumption, I removed the connection panel settings dependency and created a dedicated createBuiltInMcpConnection() method in ConsumptionConnectionService that generates local connection objects stored in workflow.json instead of API Hub. I also created a Consumption-specific MCP connector mcpclientconnector.ts with the builtin capability to differentiate it from managed connectors.

Impact of Change

  • Users: Consumption Logic Apps users can now add MCP servers (both built-in "Add your own" and Microsoft-managed) to their workflows.
  • Developers: New method and helper functions available in ConsumptionConnectionService for handling built-in MCP connections.
  • System: None

Test Plan

  • Unit tests added/updated
  • E2E tests added/updated
  • Manual testing completed
  • Tested in:

Contributors

Screenshots/Videos

Copilot AI review requested due to automatic review settings February 4, 2026 12:01
@github-actions
Copy link

github-actions bot commented Feb 4, 2026

🤖 AI PR Validation Report

PR Review Results

Thank you for your submission! Here's detailed feedback on your PR title and body compliance:

⚠️ PR Title

  • Current: MCP Support for Consumption
  • Issue: Trailing space and a bit vague — doesn't mention "Logic Apps" or clarify that this is adding MCP support for Consumption SKU and both built-in and managed MCP connection handling. Prefer explicit scope and capitalization.
  • Recommendation: Make the title concise and specific. Example: Add MCP support for Consumption Logic Apps (built-in and managed connectors) or MCP support for Consumption Logic Apps

Commit Type

  • Properly selected (feature) — the PR adds new functionality.
  • Note: Only one commit type is selected which is correct.

Risk Level

  • Assessment: The PR body marks this as Low, but given the size and nature of the changes (new connection handling for MCP, new manifest, new connection creation logic that affects how connections are stored/created, and ~838 additions across 5 files), the realistic risk is Medium.
  • Recommendation: Update the PR Risk Level to Medium in the PR body if you agree, and add a matching repository label (see below). If you believe it truly is Low, please add justification in the body explaining why the changes are low-risk (e.g., fully isolated to non-production code paths, feature-flagged, trivial changes, etc.).
  • Important: The PR is currently missing a risk label on the PR (expected labels: risk:low, risk:medium, or risk:high). Please add the appropriate risk:* label and ensure it matches the PR body.

What & Why

  • Current: This PR implements MCP connection support for Consumption Logic Apps and explains changes to createBuiltInMcpConnection and a consumption-specific connector manifest.
  • Issue: (None — good short explanation present.)
  • Recommendation: Keep as-is but consider concisely calling out the main code paths/files changed (e.g., ConsumptionConnectionService.createBuiltInMcpConnection, mcpclientconnector manifest, and UI change in createConnection). That helps reviewers quickly focus on areas of impact.

⚠️ Impact of Change

  • The section is present and lists Users / Developers / System.
  • Issue: The System entry is None — please double-check if there are any operational implications (storage of connections in workflow.json vs API Hub for built-in connections, telemetry, createdTime usage, etc.). If there are potential impacts to deploy or migrate, call them out explicitly.
  • Recommendation:
    • Users: Consumption Logic Apps users can add MCP servers — keep this wording.
    • Developers: Mention the specific files/APIs changed, e.g., libs/logic-apps-shared/.../consumption/connection.ts, new manifest mcpclientconnector.ts, and UI tweak in createConnection.tsx.
    • System: If none, explicitly state why (e.g., no infra change, no DB/schema change). If there are possible migration concerns (existing workflows, connection ids), document them.

Test Plan

  • Assessment: Unit tests were claimed and I verified a new unit test file was added in the diff (libs/logic-apps-shared/src/designer-client-services/lib/consumption/__tests__/connection.spec.ts). Good.
  • Recommendation: Because this change affects runtime behavior (connection creation/storage and connection manifests), consider adding either E2E tests or describe the manual test steps performed and the environments used. If E2E isn't feasible, add a short justification.

⚠️ Contributors

  • Assessment: Section left blank.
  • Recommendation: If others (PMs, designers, reviewers) contributed, list them. If no one else contributed, it's fine to leave blank, but include a short note or confirm none.

⚠️ Screenshots/Videos

  • Assessment: Not applicable — no UI screenshots required for this backend/manifest change. If there are UI changes visible (create connection panel behavior changed to hide name input for Consumption MCP), consider adding a small screenshot or gif showing the new UX, as reviewers often appreciate visual confirmation.

Summary Table

Section Status Recommendation
Title ⚠️ Update to explicitly mention "Consumption Logic Apps" and remove trailing space
Commit Type No change needed
Risk Level Change PR body to Medium or add justification for Low; add matching risk:* label
What & Why Optionally add file references for faster review
Impact of Change ⚠️ Clarify system impact or confirm none (explain why)
Test Plan Good — unit tests present. Consider E2E or documented manual verification steps
Contributors ⚠️ Add contributors or state none
Screenshots/Videos ⚠️ Optional: add screenshot proving UI behavior change (hide name field for Consumption MCP)

Final message
Please update the PR with the following before re-requesting review:

  1. Update the PR title to be clearer and remove trailing whitespace. Example: Add MCP support for Consumption Logic Apps (built-in and managed connectors).
  2. Re-evaluate the Risk Level in the PR body — change to Medium if you agree with the assessment above, and add the corresponding repo label risk:medium to the PR. If you want to keep Low, add a short justification in the body explaining why this is low-risk.
  3. Ensure the Impact of Change section explicitly calls out any system/operational implications or confirms there are none with reasoning (important because built-in connections are now stored in workflow.json vs API Hub).
  4. Add a short note under Test Plan describing how the unit tests exercise the behavior and whether manual/E2E testing was done; if not, either add E2E coverage or document manual verification steps.
  5. (Optional) Add contributors and a screenshot showing the create connection UI change (the code hides the name input for Consumption MCP connections); this helps reviewers validate UX changes quickly.

Once you update the title/body and add the appropriate risk label, I can re-run the title/body compliance check. Thank you for the clear PR body and the unit tests — good work.


Last updated: Thu, 19 Feb 2026 13:03:50 GMT

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds MCP (Model Context Protocol) connection support for Consumption Logic Apps by implementing built-in and managed MCP connection capabilities. The implementation reuses most existing MCP code for managed connectors, with Consumption-specific additions for built-in connections that store connection objects locally in workflow.json instead of API Hub.

Changes:

  • Added Consumption-specific MCP connector manifest (mcpclientconnector.ts) with builtin capability
  • Created createBuiltInMcpConnection() method in ConsumptionConnectionService for local connection storage
  • Added comprehensive unit tests for MCP connection creation and parameter extraction
  • Modified connection panel to hide name input for Consumption MCP connections

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
servers Subproject commit reference update
libs/logic-apps-shared/src/designer-client-services/lib/consumption/manifests/mcpclientconnector.ts Defines the MCP Client connector manifest with authentication types and parameter sets
libs/logic-apps-shared/src/designer-client-services/lib/consumption/connection.ts Implements built-in and managed MCP connection creation logic with parameter extraction
libs/logic-apps-shared/src/designer-client-services/lib/consumption/tests/connection.spec.ts Adds comprehensive unit tests for MCP connection functionality
libs/designer-v2/src/lib/ui/panel/connectionsPanel/createConnection/createConnection.tsx Hides name input for Consumption MCP connections in the UI

},
},
uiDefinition: {
displayName: 'Basic',
Copy link

Copilot AI Feb 4, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The authentication type name 'Basic' should match the parameter set name defined on line 41. Currently the parameter set uses 'Basic' as the name, but this should be 'BasicAuth' for consistency with the extractAuthParameters method which checks for 'BasicAuth' in connection.ts line 239.

Copilot uses AI. Check for mistakes.

if (connectionParametersSet?.values) {
const values = connectionParametersSet.values;
const authKeys = ['username', 'password', 'key', 'keyHeaderName', 'clientId', 'secret', 'tenant', 'authority', 'audience', 'pfx'];
Copy link

Copilot AI Feb 4, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The hardcoded list of authentication keys should be defined as a constant at the class or module level to improve maintainability and allow reuse. Consider extracting this to a private static readonly property or a module-level constant.

Copilot uses AI. Check for mistakes.
});

try {
const connectionName = connectionInfo.displayName || connectionId.split('/').at(-1) || `mcp-${Date.now()}`;
Copy link

Copilot AI Feb 4, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The fallback connection name generation using Date.now() could produce non-unique names if multiple connections are created in rapid succession. Consider using a more robust unique identifier generation approach, such as a UUID or a combination of timestamp with a random component.

Suggested change
const connectionName = connectionInfo.displayName || connectionId.split('/').at(-1) || `mcp-${Date.now()}`;
const fallbackSuffix = `${Date.now()}-${Math.random().toString(16).slice(2)}`;
const connectionName = connectionInfo.displayName || connectionId.split('/').at(-1) || `mcp-${fallbackSuffix}`;

Copilot uses AI. Check for mistakes.
expect(result.name).toBe('test-mcp-connection');
expect(result.id).toContain('connectionProviders/mcpclient/connections/');
expect((result.properties as any).parameterValues.mcpServerUrl).toBe('https://mcp-server.example.com');
expect((result.properties as any).parameterValues.authenticationType).toBe('ApiKey');
Copy link

Copilot AI Feb 4, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The test expects authenticationType to be 'ApiKey' but the connection info specifies 'ApiKey' on line 78. However, the connector manifest defines 'Key' as the authentication type name (line 275). This inconsistency should be resolved to match the actual authentication type names defined in the manifest.

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant