Skip to main content
Glama
ZeroSOC

defender-xdr

by ZeroSOC

defender_get_file_alerts

Read-only

Get all Microsoft Defender for Endpoint alerts linked to a file hash (SHA1/SHA256) to quickly investigate file-based threats.

Instructions

List the Defender for Endpoint alerts that involve a file.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
topNoMaximum number of alerts to return (default 25, max 100).
filterNoOData $filter expression. Refine the filter instead of paging deep.
file_hashYesSHA1 or SHA256 of the file.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.8/5.0
Behavior3/5

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

Annotations already establish readOnlyHint=true and destructiveHint=false, and the description does not contradict them. It adds little beyond that safety profile, such as pagination behavior or what 'involve a file' means in alert terms; no contradiction exists.

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?

One short sentence that leads with the action and scopes the resource; no filler or duplication of schema content.

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 read-only list operation with one required, well-specified hash parameter, the description is sufficient for selection and invocation. It does not describe the output shape, but no output schema exists and 'list' reasonably implies a collection of alert objects.

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?

All three parameters are already documented in the schema (file_hash as SHA1/SHA256, top default/max, filter as OData expression), so the description need not repeat them. The phrase 'involve a file' maps to file_hash without adding new semantic detail.

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

Purpose5/5

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

The description uses the specific verb 'List' plus the resource 'Defender for Endpoint alerts that involve a file,' which cleanly separates it from sibling alert-list tools scoped to domain, IP, user, or machine. It could name a sibling explicitly, but the file scope is unambiguous.

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?

The file-scoped phrasing implies the use case (alerts tied to a file), but the description does not explicitly say when to prefer this over defender_get_domain_alerts, defender_get_ip_alerts, defender_get_user_alerts, or defender_get_machine_alerts. No when-not-to-use or alternative guidance is present.

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