Skip to content

Conversation

SteveL-MSFT
Copy link
Member

PR Summary

This tool allows an agent to invoke a dsc resource directly.

@SteveL-MSFT SteveL-MSFT requested a review from Copilot October 6, 2025 23:17
Copy link
Contributor

@Copilot 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

Adds a new MCP (Model Context Protocol) tool invoke_dsc_resource() that allows direct invocation of DSC resource operations (Get, Set, Test, Export).

Key changes:

  • New MCP tool for invoking DSC resources with JSON properties
  • Added operation support infrastructure in dsctest tool
  • Modified command execution to use synchronous wrapper for async operations

Reviewed Changes

Copilot reviewed 11 out of 12 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
dsc/src/mcp/invoke_dsc_resource.rs New MCP tool implementation for invoking DSC resources
tools/dsctest/src/operation.rs New Operation struct for handling operation parameters
tools/dsctest/src/main.rs Added operation subcommand handling and schema support
tools/dsctest/src/args.rs Added Operation enum variant and CLI arguments
tools/dsctest/dscoperation.dsc.resource.json DSC resource manifest for operation testing
dsc_lib/src/dscresources/command_resource.rs Changed async function to sync with tokio runtime wrapper
dsc/tests/dsc_mcp.tests.ps1 Added comprehensive tests for the new invoke_dsc_resource tool
dsc/src/mcp/mod.rs Added module declaration for invoke_dsc_resource
dsc/src/mcp/mcp_server.rs Integrated new tool router into MCP server
dsc/locales/en-us.toml Added localization strings and improved consistency
dsc/Cargo.toml Updated rmcp dependency version

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@SteveL-MSFT SteveL-MSFT requested a review from tgauth October 7, 2025 02:06
@SteveL-MSFT SteveL-MSFT added this pull request to the merge queue Oct 7, 2025
Merged via the queue into PowerShell:main with commit 288336a Oct 7, 2025
3 checks passed
@SteveL-MSFT SteveL-MSFT deleted the mcp-invoke branch October 7, 2025 18:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants