Skip to main content
Glama
Dynamics 365 MCP Server

Dynamics 365 MCP Server

by Kenny-666

query_plugin_trace_logs

Read-only

Query bounded Dataverse plugin trace logs by time, correlation ID, step, or exact plugin type to diagnose execution issues; message text is opt-in.

Instructions

Read bounded native plugin trace rows by time, correlation ID, step and exact plugin type. Default excludes message/exception text; configuration and secureconfiguration are always excluded. Empty results do not prove no execution, disabled logging or log deletion.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "query_plugin_trace_logs"
  }
}

Input Schema

NameRequiredDescriptionDefault
topNoMaximum visible rows, default 50. Reaching this bound is not a complete inventory.
stepIdNoCompatibility alias for step_id; conflicting values are rejected.
toTimeNoCompatibility alias for to_time; conflicting values are rejected.
step_idNo
to_timeNoISO timestamp with explicit timezone, inclusive. Default current UTC time.
fromTimeNoCompatibility alias for from_time; conflicting values are rejected.
maxPagesNoCompatibility alias for max_pages; conflicting values are rejected.
from_timeNoISO timestamp with explicit timezone, inclusive. Default 24 hours before to_time.
max_pagesNoMaximum native pages, default 5. Bounded reads report incompleteness.
includeTextNoCompatibility alias for include_text; conflicting values are rejected.
include_textNoDefault false. Opt in to trace/exception/job message text, which can contain business data. Secure/unsecure configuration columns are never selected.
maxTextCharsNoCompatibility alias for max_text_chars; conflicting values are rejected.
correlationIdNoCompatibility alias for correlation_id; conflicting values are rejected.
correlation_idNo
exceptionsOnlyNoCompatibility alias for exceptions_only; conflicting values are rejected.
max_text_charsNoPer-text preview limit, default 2000; truncation is explicit.
pluginTypeNameNoCompatibility alias for plugin_type_name; conflicting values are rejected.
exceptions_onlyNoOnly rows with nonempty native exceptiondetails; default false.
plugin_type_nameNo
environment_profileNoOptional named environment profile for this call; omit to use the configured default.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.1.2
    • addedInput schema / properties / environment_profile
      Added value: +{
      +  "description": "Optional named environment profile for this call; omit to use the configured default.",
      +  "pattern": "^[A-Za-z][A-Za-z0-9_]{0,31}$",
      +  "type": "string"
      +}
  2. First observedv1.0.0

TDQS

A4/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Reads safe (readOnlyHint=true, destructiveHint=false), so the bar is lower, yet the description still adds substantial behavioral context: message/exception text excluded by default, configuration and secureconfiguration never selected, bounded reads that report incompleteness rather than silently truncating, and the crucial warning that empty results do not prove the plugin did not run, logging was disabled, or logs were deleted.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three sentences, front-loaded with capability then privacy defaults then the false-negative caveat. No filler, and each sentence carries information an agent would otherwise have to guess.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 20-parameter read tool with no output schema, the description covers capability, privacy posture, bounding behavior, and the false-negative trap, while the schema carries pagination and alias details. It stops short of describing the row shape returned or the interaction between max_pages and top, which is a modest remaining gap.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 85%, so the schema already documents defaults, ranges, aliases, and ISO timestamp format; the baseline is 3. The description adds only the notion that plugin type matching is exact and that text columns are opt-in, which is useful but partial against 20 parameters.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource (read native plugin trace rows) plus the four filter axes (time, correlation ID, step, exact plugin type). That is far more specific than a sibling like get_diagnostic_settings, though it never explicitly contrasts itself with adjacent diagnostic tools such as diagnose_plugin_failure or query_failed_system_jobs.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is implied by naming the available filters and by the caveat about empty results, which tells the agent this is a forensic lookup rather than a health check. There is no explicit when-to-use statement and no routing to the obvious alternatives (diagnose_plugin_failure, query_failed_system_jobs, d365_plugin_steps_query) that an agent would need to choose correctly.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools