Skip to main content
Glama
glpi-mcp

glpi-mcp

by maimik

GLPI MCP Server

A Model Context Protocol (MCP) server for interacting with GLPI (Gestionnaire Libre de Parc Informatique) via its REST API.

This server empowers AI assistants (like Claude) to manage your GLPI inventory, tickets, and specifically CIA (Confidentiality, Integrity, Availability) security fields directly.

Features

  • Core GLPI Operations:

    • List, Get, Create, Update, Delete items (Computers, Tickets, Users, etc.).

    • Native GLPI Search API support.

  • Advanced CIA Management:

    • Dedicated tools to view and update Security/CIA fields (data_sensitivity, critical_asset, max_downtime).

    • Batch Updates: Update thousands of assets in a single request.

    • Future-Proof: Supports custom/future plugin fields via dynamic parameters without code changes.

  • Robust Authentication:

    • Supports modern header-based auth and legacy body-based auth (/apirest.php).

    • Built-in handling for OAuth plugin quirks.

Related MCP server: Hermes GLPI Wave Hub

Installation

npx -y glpi-mcp

Configuration

You need to provide the following environment variables to authenticate with your GLPI instance:

Variable

Description

Required

Example

GLPI_API_URL

The full URL to your GLPI API endpoint.

Yes

http://your-glpi/apirest.php

GLPI_APP_TOKEN

The unique App Token generated in GLPI (Setup > General > API).

Yes

j0RHdOk...

GLPI_USER_TOKEN

The User Token from your personal settings.

Yes*

FOOKqs...

GLPI_OAUTH_TOKEN

OAuth Access Token (if using OAuth).

No**

* Either GLPI_USER_TOKEN or GLPI_OAUTH_TOKEN is required. ** GLPI_OAUTH_TOKEN takes precedence if both are provided.

Claude Desktop Configuration

Add this to your claude_desktop_config.json:

{
  "mcpServers": {
    "glpi": {
      "command": "npx",
      "args": ["-y", "glpi-mcp"],
      "env": {
        "GLPI_API_URL": "https://glpi.example.com/apirest.php",
        "GLPI_APP_TOKEN": "your_app_token_here",
        "GLPI_USER_TOKEN": "your_user_token_here"
      }
    }
  }
}

Available Tools

1. Standard Item Management

  • glpi_list_items: List generic items (Computer, Ticket, User, etc.).

  • glpi_get_item: Get details of a specific item.

  • glpi_create_item: Create a new item (e.g., Ticket).

  • glpi_update_item: Update standard fields of an item.

  • glpi_delete_item: Delete or purge an item.

  • glpi_search: Advanced search queries.

2. CIA / Security Fields Management 🛡️

Designed for working with the Generic Object or Fields plugins that add CIA ratings to assets.

glpi_get_cia_fields

View the current security ratings of an asset.

  • Args: itemType (e.g., "Computer"), id.

glpi_update_cia_fields

Update security ratings for a single asset.

  • Args:

    • itemType, id

    • data_sensitivity (e.g., "Confidential")

    • critical_asset (1 or 0)

    • max_downtime (integer)

    • other_fields (JSON string): Important! Use this to update any new fields you add to GLPI later without updating this server.

      • Example: '{"new_custom_field": "some_value"}'

glpi_update_cia_fields_batch

Update security ratings for multiple assets at once. Ideally used by scripts or for bulk policy application.

  • Args:

    • itemType

    • ids (Comma-separated string: "42, 43, 44")

    • data_sensitivity, critical_asset, max_downtime

    • other_fields

Examples

Batch Update Computers

Assign "Confidential" sensitivity to Computers with IDs 100, 101, and 102.

{
  "name": "glpi_update_cia_fields_batch",
  "arguments": {
    "itemType": "Computer",
    "ids": "100, 101, 102",
    "data_sensitivity": "Confidential",
    "critical_asset": 1
  }
}

Future-Proofing with other_fields

If you add a new field called compliance_level to GLPI tomorrow, you can update it immediately:

{
  "name": "glpi_update_cia_fields",
  "arguments": {
    "itemType": "Computer",
    "id": 50,
    "other_fields": "{\"compliance_level\": \"high\"}"
  }
}

Troubleshooting

  • 2FA/OTP Error on Publish: If you are trying to publish this package yourself and see OTP errors, use the provided helper script: ./publish_with_otp.sh.

  • 403 Forbidden: Verify your GLPI_APP_TOKEN and GLPI_USER_TOKEN. Ensure the user has write access to the specific assets.

  • Authorization Header Missing: Typical with the GLPI OAuth plugin. Ensure you are using the /apirest.php endpoint in your URL, or configure the plugin to accept user_token.

License

ISC

Available Tools

9 tools
glpi_create_itemD

Inputs: input (required), itemType (required).

glpi_delete_itemD

Inputs: id (required), itemType (required), force.

glpi_get_cia_fieldsD

Inputs: id (required), itemType (required), endpoint_override.

glpi_get_itemD

Inputs: id (required), itemType (required), with_disks, get_hateoas, +4 more.

glpi_list_itemsD

Inputs: itemType (required), sort, order, range, +2 more.

glpi_update_cia_fieldsD

Inputs: id (required), itemType (required), max_downtime, other_fields, +6 more.

glpi_update_cia_fields_batchD

Inputs: ids (required), itemType (required), other_fields, integrityfield, +3 more.

glpi_update_itemD

Inputs: id (required), input (required), itemType (required).

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    C2/5.0

    Scored across 9 tools

    Disambiguation4/5

    The CRUD operations (list, create, get, update, delete) are clearly distinct, and the CIA fields tools are separate from item tools. However, glpi_search may overlap with glpi_list_items in function, and the generic 'item' term could cause confusion without descriptions.

    Naming Consistency4/5

    Most tools follow a consistent verb_noun pattern (e.g., glpi_list_items, glpi_create_item), but glpi_search breaks the pattern by omitting the object. Overall, naming is clear and predictable.

    Tool Count5/5

    With 9 tools, the server is well-scoped for basic GLPI item management and CIA field handling. The count is appropriate, neither too sparse nor overwhelming.

    Completeness4/5

    The tool set covers full CRUD for items, search, and specialized CIA field operations. Minor gaps exist, such as batch create/delete or listing item types, but the core functionality is complete.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      Connects AI assistants to GLPI IT Service Management, enabling ticket management, asset search, and ITIL processes via natural language.
      11 npm
      3
      MIT
    • A
      license
      B
      quality
      C
      maintenance
      Enables AI assistants to interact with a GLPI instance through its REST API, allowing natural-language consultation, creation, and updating of tickets, followups, tasks, solutions, knowledge base articles, suppliers, contacts, contracts, and statistics.
      52
      -
    • A
      license
      Not graded
      quality
      B
      maintenance
      Connects AI assistants to GLPI through the Model Context Protocol, enabling management of tickets, ITIL objects, assets, projects, tasks, documents, sessions, entities and massive actions via the legacy REST API. It supports GLPI 10 and 11 with safe defaults such as read-only mode, disabled destructive operations and masked secrets.
      MIT