Mcp Glpi
MCP Server for GLPI - IT Service Management integratio
A Model Context Protocol server for GLPI, the open-source IT service management suite. It gives an AI assistant (Claude Desktop, Claude Code, Cursor, Open WebUI, any MCP client) 46 tools over the GLPI REST API: tickets and their timeline, problems, changes, validations, assets and every other common itemtype, users and groups, the knowledge base, multi-criteria search and reporting. Outputs are compact JSON built for a model's context window, write tools are annotated and can be switched off with one variable, and the 50 tool names of v3 keep working as hidden aliases.
Version 4.0.0. See CHANGELOG.md for the release notes and Upgrading from 3.x below.
Install and configure
Requirements: Node.js 20 or later, a GLPI 10 or 11 instance with the REST API enabled (Setup > General > API), an API client (app token, optional) and a user API token (My settings > Remote access keys) or a login and password.
stdio: Claude Desktop, Claude Code, Cursor
stdio is the default transport: the client starts the server and talks to it
over stdin/stdout. Claude Desktop (claude_desktop_config.json) and Cursor
(~/.cursor/mcp.json or .cursor/mcp.json in a project) use the same shape:
{
"mcpServers": {
"glpi": {
"command": "npx",
"args": ["-y", "mcp-glpi"],
"env": {
"GLPI_URL": "https://glpi.example.com",
"GLPI_APP_TOKEN": "your-app-token",
"GLPI_USER_TOKEN": "your-user-token",
"GLPI_READ_ONLY": "1"
}
}
}
}
Drop GLPI_READ_ONLY to allow writes. Claude Code:
claude mcp add glpi \
-e GLPI_URL=https://glpi.example.com \
-e GLPI_APP_TOKEN=your-app-token \
-e GLPI_USER_TOKEN=your-user-token \
-- npx -y mcp-glpi
The server opens a GLPI session at startup (or on the first call if GLPI is unreachable then) and closes it when the client disconnects.
Streamable HTTP: Open WebUI and other web clients
MCP_TRANSPORT=http GLPI_URL=https://glpi.example.com GLPI_USER_TOKEN=... npx -y mcp-glpi
# same with flags
npx -y mcp-glpi --http --host 127.0.0.1 --port 3000 --path /mcp
MCP GLPI Server v4.0.0 listening on http://127.0.0.1:3000/mcp
transport: streamable HTTP (stateless, JSON responses)
auth: none — bind to loopback or set MCP_HTTP_AUTH_TOKEN before exposing this port
| Flag | Description |
|---|---|
--http |
Shorthand for --transport http |
--transport <mode> |
stdio (default) or http |
--host <host> |
Bind address (default 127.0.0.1) |
--port <port> |
Port; 0 picks a free port (default 3000) |
--path <path> |
Endpoint path (default /mcp) |
-h, --help |
Print usage |
CLI flags win over the MCP_* variables. Endpoints: POST /mcp (JSON-RPC,
one JSON response per request) and GET /health (liveness, no auth, no GLPI
call). GET and DELETE /mcp answer 405: the server is stateless and never
pushes messages. A POST must accept both application/json and
text/event-stream (or */*), as MCP clients do:
curl -s http://127.0.0.1:3000/mcp \
-H 'Content-Type: application/json' \
-H 'Accept: application/json, text/event-stream' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'
Open WebUI (v0.6.31 or later): Admin Settings > External Tools > +,
type MCP (Streamable HTTP) (not OpenAPI), URL http://<host>:3000/mcp
(http://host.docker.internal:3000/mcp when Open WebUI runs in Docker and
mcp-glpi on the host with Docker Desktop; on Linux, bind mcp-glpi to an
address the container can reach). Auth: None, or Bearer with the value of
MCP_HTTP_AUTH_TOKEN (Open WebUI rejects Bearer with an empty key). Then
enable the tool per chat under + > Integrations > Tools.
Docker. No image is published; the npm package runs in any Node image.
Inside a container the server must bind to 0.0.0.0, so set a token:
From the project's README.