Skip to main content
Glama

Scan Agent

scan_agent
Idempotent

Scan the agent's source: generate its context, then discover its behaviors.

Asynchronous: returns an `operation_id` at once, and the scan continues on
the server even if this session ends. Follow it with
get_operation_status. A context already generated for the current source
is not generated again, and if a previous scan failed in behavior
discovery, calling this again resumes from there. Asking while a scan
runs returns that scan; asking once behaviors exist for the current
source returns `already_complete`. Needs collected source and an approved
organization. Does not generate probes.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "agent_id": "<agent_id>"
    },
    "name": "scan_agent"
  }
}

Input Schema

NameRequiredDescriptionDefault
agent_idYesThe agent's stable ID, such as agt_1a2b3c4d, from list_agents.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.2/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=false, idempotentHint=true, and destructiveHint=false, so the safety profile is partly covered. The description adds substantial context beyond that: asynchronous execution with an operation_id, server-side continuation after session end, context caching, and resume-from-failure behavior. However, it does not clarify why a non-read-only, idempotent operation mutates state or what side effects the scan produces, leaving a gap against the annotation profile.

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

Conciseness4/5

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

Front-loads the core action in the first sentence, then layers async and idempotency details. Dense but each sentence carries operational information; the parenthetical phase breakdown is slightly redundant with the first clause but not wasteful.

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

Completeness5/5

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

No output schema exists, yet the description explains the return values (operation_id, already_complete) and the follow-up path. Combined with prerequisites and resume semantics, an agent has everything needed to invoke and interpret the call.

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 coverage is 100% and the single agent_id parameter is fully documented in the schema, including its format and where to obtain it. The description adds no meaning beyond that, so the baseline 3 applies.

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?

States a specific verb and resource ('Scan the agent's source') and decomposes it into the two phases it performs (generate context, discover behaviors). It also explicitly excludes a sibling capability ('Does not generate probes'), letting an agent distinguish it from generate_probes and classify_behaviors.

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

Usage Guidelines5/5

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

Gives explicit preconditions ('Needs collected source and an approved organization'), names the follow-up tool (get_operation_status), and describes the resume/already_complete conditions that determine whether calling it is useful. It also states the negative case (does not generate probes), so when-not-to-use is covered.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.