Skip to main content
Glama
FortiManager MCP Server

FortiManager MCP Server

by rstierli

get_device_bgp

Retrieve a managed device's configured BGP settings from FortiManager, including resolved neighbors, AS, and networks, to verify routing configuration rather than live session state.

Instructions

Get a managed device's BGP configuration from FortiManager's device DB.

Reads the router bgp config FortiManager holds for the device -- the result of any BGP template plus local settings, with variables resolved. This is configuration, not runtime state: it says which neighbors are configured, not whether they are established.

Args: device: Managed device name (e.g. "FGT-HQ") vdom: VDOM name (default: "root") summary_only: Leave out the raw bgp object, which lists some 150 fields per neighbor (default: False)

Returns: dict with keys: - device, vdom - bgp: raw router/bgp config object (neighbor password stripped -- see _BGP_SECRET_FIELDS), unless summary_only - summary: condensed AS/router-id/neighbors/networks - error / error_code: on failure

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": {
      "device": "<device>"
    },
    "name": "get_device_bgp"
  }
}

Input Schema

NameRequiredDescriptionDefault
vdomNoroot
deviceYes
summary_onlyNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.13.1

TDQS

A4.6/5.0
Behavior5/5

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

With no annotations, the description carries the full burden and does so well: it discloses that variables are resolved from templates, that the neighbor password field is stripped, that summary_only omits a ~150-field-per-neighbor object, and that failures come back as error/error_code rather than raising. These are exactly the behavioral facts an agent cannot get from the schema.

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 purpose is front-loaded in the first sentence and the rest is well-sectioned into behavior, args and returns. The Returns block is partly redundant given an output schema exists, but the secret-stripping note in it is not, so the length is largely earned.

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 three-parameter read tool with an output schema, everything needed to call it correctly is present: what is read, what is stripped, what the flag does, and what failure looks like. Nothing material is missing.

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

Parameters4/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: device is named as a managed device name with an example, vdom is documented with its 'root' default, and summary_only is explained in terms of what it omits and why. Minor ding for not stating a vdom format or device naming constraint.

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 first line names a specific verb and resource ('Get a managed device's BGP configuration from FortiManager's device DB'), and the following paragraph draws a hard line between configuration and runtime state. That distinction lets an agent separate it from siblings like get_device_bgp_status without opening either schema.

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 gives clear context for use: read the resolved BGP config, not the established-state view. The gap is that it never names get_device_bgp_status as the alternative; the agent must infer the routing from the config-vs-runtime phrasing.

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