Skip to main content
Glama
rstierli

FortiManager MCP Server

by rstierli

get_device_client_location

Locate where a client is connected on a managed device by IP, MAC, or hostname, returning the FortiAP or FortiSwitch, port, and VLAN for troubleshooting.

Instructions

Locate a client on a device (Asset Identity Center): which FortiAP / FortiSwitch + VLAN it is connected through.

Proxies the device's detected-device inventory (/api/v2/monitor/user/device/query) -- the data behind the FortiManager "Asset Identity Center" view -- and answers "where is this client connected". Each match resolves to the access point / switch + port and VLAN the client is on, plus hostname, vendor/OS, online state, DHCP lease and vuln count.

Filter to one client by ip, mac or hostname (each provided filter narrows; a hostname match is case-insensitive substring). With no filter, the full detected-client inventory is returned (summarized).

Args: adom: ADOM name (defaults to DEFAULT_ADOM / "root" when omitted) device: Managed device name (e.g. "FGT-HQ"). Defaults to DEFAULT_DEVICE when omitted; required if that is not configured. ip: Client IPv4 address to locate (exact match) mac: Client MAC address to locate (case-insensitive) hostname: Client hostname to locate (case-insensitive substring)

Returns: dict with keys: - adom, device - query: the filter used (or None for full inventory) - match_count - clients: summarized detected-client records (ap/switch/port/vlan/...) - error / error_code: on failure

Input Schema

NameRequiredDescriptionDefault
ipNo
macNo
adomNo
deviceNo
hostnameNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.12.0

TDQS

A4.5/5.0
Behavior4/5

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

With no annotations provided, the description carries the behavioral burden and does well: it identifies the proxied API endpoint, says each match resolves to AP/switch plus port and VLAN, and lists hostname, OS, online state, DHCP lease, and vuln count. It does not mention auth/permission requirements or rate limits, but it is far more transparent than a bare read operation.

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?

The description is front-loaded with the core purpose and then organized into Args and Returns sections, which is easy to scan. It is somewhat verbose and the Returns section overlaps with the existing output schema, but the endpoint and filtering details justify most of the length.

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?

For a five-parameter read-only lookup with 0% schema description coverage, the definition supplies defaults, filter semantics, return shape, and error keys. An agent has enough information to call it correctly without inspecting the schema or guessing at behavior.

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

Parameters5/5

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

Schema description coverage is 0%, so the description must compensate, and it does: adom and device defaults are explained, ip is exact-match, mac is case-insensitive, and hostname is a case-insensitive substring match. Every parameter is given meaning beyond its name and type.

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 states a specific verb and resource: locating a client on a device and reporting the FortiAP/FortiSwitch, port, and VLAN it uses. It also distinguishes the tool from general device/status siblings by tying it to the Asset Identity Center and the detected-device inventory endpoint.

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

Usage Guidelines4/5

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

It clearly explains how to narrow the query with ip, mac, or hostname and notes that omitting filters returns the full detected-client inventory. It does not explicitly compare against sibling tools, but the use case is well framed and unambiguous.

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