-
Notifications
You must be signed in to change notification settings - Fork 4
feat: add destructive hints, titles, and readonly hints to mcp tools #471
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
JamieSinn
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot caught one missing
There was a problem hiding this 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 enhances MCP tool definitions by adding structured annotations to improve AI assistant behavior and user experience. The changes focus on adding safety guardrails and better UI display for tools that interact with DevCycle's feature flag management system.
- Added destructive hints to operations that can affect production environments
- Added human-readable titles to all tools for better UI display
- Added read-only hints to distinguish non-destructive operations
Reviewed Changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| src/mcp/tools/variableTools.ts | Added annotations for variable management operations with appropriate destructive/read-only hints |
| src/mcp/tools/selfTargetingTools.ts | Enhanced self-targeting tools with titles and destructive hints for override clearing |
| src/mcp/tools/resultsTools.ts | Added read-only annotations to evaluation reporting tools |
| src/mcp/tools/projectTools.ts | Enhanced project management tools with appropriate annotations |
| src/mcp/tools/featureTools.ts | Comprehensive annotation updates for feature flag operations including targeting and variations |
| src/mcp/tools/environmentTools.ts | Added annotations to environment management tools |
| src/mcp/tools/customPropertiesTools.ts | Enhanced custom property tools with destructive hints for modify operations |
| name: 'update_feature_variation', | ||
| description: | ||
| 'Update an existing variation by key. Include dashboard link in the response.', | ||
| 'Update an existing variation by key. ⚠️ WARNING: Updating a feature variation may affect production environments. Include dashboard link in the response.', |
Copilot
AI
Jul 25, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The warning message format is inconsistent with other tools. Other destructive operations use '
| 'Update an existing variation by key. ⚠️ WARNING: Updating a feature variation may affect production environments. Include dashboard link in the response.', | |
| 'Update an existing variation by key. ⚠️ IMPORTANT: Updating a feature variation may affect production environments. Include dashboard link in the response.', |
…471) * feat: add destructive hints, titles, and readonly hints to mcp tools * fix: update tool descriptions
…471) * feat: add destructive hints, titles, and readonly hints to mcp tools * fix: update tool descriptions
This PR enhances all MCP tool definitions with proper annotations to improve AI assistant behavior and user experience.
Changes Made
destructiveHint: trueto operations that can affect production environments (delete, update, enable/disable targeting)titleannotations to all tools for better UI display (e.g., "List Feature Flags", "Create Variable")readOnlyHint: trueto all non-destructive operations (list, get, fetch)Impact