Skip to main content
Glama
FortiManager MCP Server

FortiManager MCP Server

by rstierli

install_package

Deploy a firewall policy package to specified managed devices; use a verified preview to confirm the target before applying changes and monitor the task.

Instructions

Install a policy package to managed devices.

Deploys firewall policies and configurations from a policy package to the specified devices. This is an asynchronous operation - use wait_for_task() to monitor completion.

By default (FMG_INSTALL_SAFETY=strict) a real install requires a verified preview first: run preview_install for the same ADOM, package, and devices and review its result (on FortiManager builds older than 7.6.7 / 8.0.2, preview_install returns a task: wait_for_task on it and read get_preview_result). Each preview authorizes one install, and only while the package is unchanged — if the package was edited after the preview, the install is refused (preview_stale) and a fresh preview is required. A preview that found nothing to install authorizes nothing.

Args: adom: ADOM name package: Policy package name devices: Target devices [{"name": "FGT1", "vdom": "root"}, ...] preview: If True, run preview_install instead: nothing is installed (default: False). Changed in 1.13.0: this used to stage the install and return at once, leaving the devices held by an install-wizard session; it now runs the same full preview as preview_install, returns its result, and like it authorizes one install of the same target.

Returns: dict: Installation result with keys: - status: "success" or "error" - task_id: Task ID for monitoring (if successful) - message: Status or error message With preview=True: the preview_install response plus preview: True.

Example: >>> # Install to single device >>> result = await install_package( ... adom="root", ... package="default", ... devices=[{"name": "FGT-HQ", "vdom": "root"}] ... ) >>> if result["status"] == "success": ... await wait_for_task(result["task_id"])

>>> # Preview installation first
>>> result = await install_package(
...     adom="root",
...     package="default",
...     devices=[{"name": "FGT-HQ", "vdom": "root"}],
...     preview=True
... )

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": {
      "adom": "<adom>",
      "package": "<package>",
      "devices": "<devices>"
    },
    "name": "install_package"
  }
}

Input Schema

NameRequiredDescriptionDefault
adomYes
devicesYes
packageYes
previewNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.9/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 behavioral burden and does so: it declares the operation asynchronous and points to wait_for_task, describes the security gate, the single-use authorization model, the preview_stale refusal after package edits, the null-authorization case of an empty preview, and even the behavior change in 1.13.0. That is materially more than the schema or any annotation conveys.

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 prose is dense and front-loaded, with the safety gate prioritized before argument details. It runs long and the doctest-style example block largely restates the Args and Returns sections, which is the main redundancy, though the examples do illustrate the wait_for_task follow-up.

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 destructive, gated, asynchronous install tool this covers everything an agent needs: prerequisites, failure modes, async follow-up, return keys, and the preview variant. An output schema exists, so the description need not explain return values further, and it does not overreach.

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, package and devices are each described, devices includes a concrete shape example ({'name': 'FGT1', 'vdom': 'root'}), and preview's default plus its redirect-to-preview behavior and 1.13.0 semantic change are documented. Nothing about the four parameters is left undefined.

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 sentence names a concrete verb and resource ('Install a policy package to managed devices') and the body immediately distinguishes it from the sibling preview_install and the monitoring sibling wait_for_task. An agent can classify this tool without inspecting the schema.

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?

It states an explicit prerequisite (run preview_install for the same ADOM, package and devices, and review the result before a real install under FMG_INSTALL_SAFETY=strict) and names the alternative path (preview=True). The conditions that select each path, plus the 'one preview authorizes one install' rule, are spelled out rather than implied.

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