MCP server for querying Azure resources using Azure Resource Graph and Kusto Query Language (KQL)
The server defines one tool, 'query-resources', with moderate quality. The tool name starts with a verb (good naming practice) but is generic ('query' rather than more specific 'search' or 'list'). The description is comprehensive (183 chars, within the 10-1024 baseline) and explains WHAT, WHEN, and use cases well. However, the input schema has critical gaps: the 'subscriptionId' parameter uses a default value from environment variables but accepts an empty string by default, which creates ambiguity. The 'query' parameter is optional but its description doesn't explain the default behavior clearly. Output schema is completely undocumented, the tool returns raw JSON via the Azure SDK with no specification of expected fields, structure, or pagination. Error handling returns error messages as text but does not categorize errors as retryable or provide recovery guidance. No pagination support documented despite operating on potentially large result sets. The tool lacks parameter constraints (enums, ranges, patterns) for query validation. No security considerations documented despite accepting Kusto queries that could access sensitive resources.
Retrieves resources and their details from Azure Resource Graph. Use this tool to search, filter, and analyze Azure resources across subscriptions. It supports Kusto Query Language (KQL) for complex queries to find resources by type, location, tags, or properties. Useful for infrastructure auditing, resource inventory, compliance checking, and understanding your Azure environment's current state.
No output schema documentation. Tool returns raw Azure SDK response JSON with no specified fields, structure, or format guidance. LLM cannot plan downstream tool calls or extract relevant data reliably.
Parameter 'subscriptionId' has confusing default behavior: z.string().default(process.env.SUBSCRIPTION_ID || '') allows empty string as valid input, creating silent failures if env var is unset. Default must either be a valid subscription ID or the parameter must be required.
Input parameters lack constraints. 'query' parameter accepts any string with no validation, pattern, length limits, or KQL syntax guidance. LLM will pass arbitrary strings without understanding KQL grammar or potential for unauthorized resource access.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-22 | D | 50 | 2026-07-28+ | v2 |
| 2026-03-09 | D | 53 | - | v1 |
No pagination support. Azure Resource Graph can return thousands of resources. Tool provides no limit parameter, offset/cursor, or total_count field. Large result sets will exhaust context windows.
Error handling is minimal. Errors return raw exception messages as text with no recovery guidance, retryability classification, or actionable next steps. LLM cannot determine if error is transient (retry), auth (re-login), or permanent.
Security considerations missing. Tool accepts and executes arbitrary Kusto queries without documented scoping. No audit trail, rate limiting, or permission checks documented. Query parameter should explain security implications (resource access, cost implications).
Tool description mentions 'complex queries' and 'Kusto Query Language (KQL)' but parameter description for 'query' field does not explain KQL syntax, valid operators, or examples. LLMs unfamiliar with KQL will generate invalid queries.
Optional 'query' parameter description states 'defaults to listing all resources' but does not document the exact default query or what fields are returned by that default.