glpi-mcp
Summary: glpi-mcp is an MCP server for querying and, when enabled, managing GLPI service-desk data and workflows.
Inspect the active GLPI API/version, URL, safety modes, and current GLPI identity/profile/entity.
Search, list, and read tickets, changes, problems, assets, users, groups, locations, categories, suppliers, contracts, KB articles, and other GLPI itemtypes.
Get full ticket details including timeline, team, linked assets, and raw read-only API GETs for advanced queries.
Use the README’s full feature set for similar-ticket/KB lookup, SLA risk, approvals, attachments, asset context, and ticket statistics.
When writes are enabled (
GLPI_READ_ONLY=false), create/update tickets, add followups/tasks/solutions, assign people/groups, upload attachments, request/answer approvals, and create/update items.Delete only with writes and (
GLPI_ALLOW_DELETE=true).Resolve names to IDs for users, groups, categories, locations, and assets, returning candidates when ambiguous.
Run over stdio or Streamable HTTP, with static-token or OAuth/per-user GLPI identity, and automatic legacy API fallback for unsupported High-Level API features.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@glpi-mcp show me open tickets assigned to me"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
glpi-mcp
MCP (Model Context Protocol) server that lets Claude and other AI assistants work with GLPI the way a service desk actually works: "what's in my queue?", "what's about to breach SLA?", "has this happened before?", "assign it to Mario", "what's in this screenshot?", "approve the laptop request".
Works with GLPI 9.5, 10, 11 and 12. It speaks both GLPI APIs and picks one automatically.
Plain language in, plain text out. People, groups, categories, locations and assets can be given by name; ticket text comes back as readable text, not HTML.
Each person can act as themselves. Run it for one service account, or let every user sign in with their own GLPI token (including as a claude.ai custom connector over OAuth).
Safe by default. Read-only unless you enable writes; deleting needs a second switch.
Runs over stdio (Claude Desktop, Claude Code) or Streamable HTTP (a remote server for claude.ai, Claude Code, the Claude API MCP connector or your own agents).
What you can ask
You say | The assistant uses |
"What should I work on?" |
|
"Anything about to breach SLA for Service Desk?" |
|
"Users say Outlook keeps asking for the password" |
|
"Open a ticket for that and assign it to Mario" |
|
"What's in the screenshot of ticket 4512?" |
|
"Approve the laptop request" |
|
"Tell me about LAPTOP-07" |
|
"How did we do last month?" |
|
Prompts (slash commands)
Clients that support MCP prompts show these as commands (in Claude: type / and look for glpi):
Prompt | What it does |
| Reviews new tickets and proposes category, priority, assignee, duplicates and known fixes |
| My queue, SLA risks and yesterday's numbers in a short briefing |
| Hands over a person's or group's open work, SLA risks first |
| Turns a problem description into a ticket, offering KB fixes and duplicates first |
| Walks through the approvals waiting for me with the context to decide |
Related MCP server: ServiceNow MCP Server
Tools
Read (always available)
Tool | What it does |
| Active API and version, identity mode, safety modes |
| GLPI user, profile, entity and groups the tools act as |
| Open items assigned to me and my groups, highest priority first |
| Items past or near their time-to-own / time-to-resolve target (and OLA) |
| Search tickets / changes / problems by status, priority, type, category, text, assignee, requester |
| One item as text: description, timeline (followups, tasks, solutions), team, linked assets |
| KB articles, open duplicates and solved tickets (with their solution) matching a description |
| Find any itemtype by name (users by login, first or last name) |
| List or read items of any itemtype |
| An asset with its owner, location, status and ticket history |
| Search KB articles by title |
| Documents of an item; download one (images as images, text as text) |
| Approvals waiting for me; approvals of one item |
| Metrics for a date range: volume, resolution time, time to own, SLA compliance |
| Read-only GET on any endpoint of the active API |
Write (only with GLPI_READ_ONLY=false)
glpi_create_ticket, glpi_update_ticket, glpi_add_followup, glpi_add_task, glpi_add_solution,
glpi_assign (requester / assigned / observer, user or group), glpi_upload_attachment,
glpi_request_approval, glpi_answer_approval, glpi_create_item, glpi_update_item.
Delete (only with GLPI_READ_ONLY=false and GLPI_ALLOW_DELETE=true): glpi_delete_item.
Tools carry MCP annotations (readOnlyHint, destructiveHint) so clients ask before writing.
Names instead of IDs
Wherever a tool expects a user, group, category, location or asset you can pass a name:
assigned_group: "Service Desk", category: "Laptops", member: "Mario", requester: "me".
A unique match is used. If a name is ambiguous, the tool returns the candidates with their IDs and the
assistant asks which one you mean.
Which API, which features
GLPI | API used | Auth |
9.5 / 10.x | Legacy REST API ( | App-Token (optional) + user token, or login/password |
11.x / 12.x | High-Level API ( | OAuth2 password grant, or user token |
Everything works on the legacy API. On the High-Level API, my queue, SLA dates, attachments, approvals, asset history and statistics are not available yet. GLPI 11 and 12 still ship the legacy API, so when legacy credentials are configured as well (a user token, or the same username/password), those tools automatically fall back to the legacy API.
1. Prepare GLPI
Enable the API (any version): Setup > General > API: enable the REST API and "Enable login with external token". Optionally add an API client with an App-Token and restrict it by IP.
Then choose how the tools act in GLPI:
One service account (simplest): create a user such as
svc-mcpwith a least-privilege profile on the entities it should see. Log in as it > My settings > Remote access keys > regenerate the API token.Each person as themselves (HTTP mode, see below): every user uses their own API token from My settings > Remote access keys. GLPI applies each person's own profile and entities.
High-Level API (GLPI 11+, optional): Setup > OAuth clients > Add: grant Password, scope api.
2. Install
Requires Node.js 22+.
git clone https://github.com/zylarion-solutions/glpi-mcp.git
cd glpi-mcp
npm ci # also builds dist/
cp .env.example .env # reference for the variables3. Connect it
Claude Code (stdio)
claude mcp add glpi \
-e GLPI_URL=https://glpi.example.com \
-e GLPI_USER_TOKEN=xxxx \
-e GLPI_APP_TOKEN=yyyy \
-- node /absolute/path/to/glpi-mcp/dist/index.jsClaude Desktop (stdio)
claude_desktop_config.json:
{
"mcpServers": {
"glpi": {
"command": "node",
"args": ["/absolute/path/to/glpi-mcp/dist/index.js"],
"env": {
"GLPI_URL": "https://glpi.example.com",
"GLPI_APP_TOKEN": "...",
"GLPI_USER_TOKEN": "...",
"GLPI_READ_ONLY": "true"
}
}
}
}Remote server (Streamable HTTP)
docker build -t glpi-mcp .
docker run -d --name glpi-mcp -p 8000:8000 --env-file .env glpi-mcpPut it behind HTTPS (reverse proxy, tunnel, PaaS). GET /healthz is an unauthenticated health check.
Behind a reverse proxy set MCP_TRUST_PROXY=1 so rate limiting sees the real client address.
Option A — static token (Claude Code, Claude API, agents)
# .env: MCP_TRANSPORT=http, MCP_AUTH_TOKEN=$(openssl rand -hex 32)
claude mcp add --transport http glpi https://mcp.example.com/mcp \
--header "Authorization: Bearer <MCP_AUTH_TOKEN>"Tools act as the service account. To let each client act as its own GLPI user, set
MCP_ALLOW_USER_TOKENS=true; clients then add X-GLPI-User-Token: <their GLPI API token>.
Option B — OAuth (claude.ai custom connectors, everyone as themselves)
MCP_TRANSPORT=http
MCP_AUTH_MODE=oauth
MCP_PUBLIC_URL=https://mcp.example.com # the URL users will add
MCP_OAUTH_SECRET=$(openssl rand -hex 32) # keep it secret and stable
MCP_OAUTH_STATE_FILE=/data/oauth-state.bin # optional: keep sign-ins across restarts
GLPI_APP_TOKEN=... # if your GLPI API client requires oneIn claude.ai: Settings > Connectors > Add custom connector and enter https://mcp.example.com/mcp.
Each person is sent to a sign-in page where they paste their own GLPI API token; from then on Claude
acts in GLPI with that person's rights. No service account is needed in this mode.
How it is protected:
OAuth 2.1 with dynamic client registration, PKCE (S256) and single-attempt authorization codes.
Only allowed apps receive codes: redirect URIs must be on
MCP_OAUTH_REDIRECT_HOSTS(defaultclaude.ai,claude.com) or loopback for local apps. The sign-in page shows which host will get access.Access tokens expire (default 1 hour); refresh tokens rotate on every use (default 30 days) and a reused refresh token signs the whole connection out; a sign-in ends after
MCP_OAUTH_MAX_GRANT_DAYS(default 90) however often it is refreshed; revoking either token signs the connection out.At most 10 active connections per GLPI user; registered apps that never sign anyone in are forgotten after 7 days.
Tokens are stored as SHA-256 hashes. The optional state file is encrypted with AES-256-GCM using a key derived from
MCP_OAUTH_SECRET; GLPI tokens are never written to disk in clear text.The sign-in form is sealed (encrypted and authenticated), rate limited (10 failed attempts per 15 minutes per address) and served with a strict Content-Security-Policy.
Users revoke access at any time by regenerating their API token in GLPI.
Configuration
Variable | Default | Description |
| — | GLPI root URL (required) |
|
|
|
| — | Legacy API client App-Token, if defined |
| — | Service account API token (legacy API) |
| — | OAuth password grant user; also legacy Basic auth |
| — | High-Level API OAuth client |
| — | Password grant user, when different from the above |
|
| OAuth scope(s) |
|
|
|
|
| Register write tools only when |
|
| Register the delete tool |
|
| Timeout per GLPI request |
|
| Max rows per list/search call |
|
| Max attachment size downloaded or uploaded |
|
|
|
|
| HTTP listen address ( |
|
|
|
| — | Bearer token required on |
|
| Token mode: accept |
| — | Public https URL of the server (required for OAuth) |
| — | 32+ random characters (required for OAuth) |
| — | Encrypted file to keep sign-ins across restarts |
|
| Token lifetimes, seconds |
|
| A sign-in ends after this many days, even if refreshed |
|
| Hosts (and their subdomains) allowed to receive codes; |
| — | Allowed browser |
|
|
|
Security notes
Read-only by default; deleting needs two explicit switches.
GLPI enforces the acting user's profile and entities on every call; prefer per-user identity over a powerful shared account.
Secrets come from the environment only and are never logged.
HTTP mode refuses to start without authentication (unless
MCP_ALLOW_NO_AUTH=truefor local tests), compares tokens in constant time, and binds to127.0.0.1unless told otherwise.Itemtypes, file names and raw paths are validated (no path traversal); attachments have a size cap.
Rich text from GLPI is converted to plain text; links are kept only for http, https, mailto and relative URLs.
Development
npm run dev # run from source (tsx)
npm test # vitest, HTTP mocked
npm run ci # typecheck + tests + build (same as CI)
npx @modelcontextprotocol/inspector node dist/index.js # try the tools interactivelysrc/
index.ts entry point (stdio | http)
http.ts Streamable HTTP transport: token and OAuth modes
server.ts MCP server
tools.ts tool definitions (API-agnostic)
prompts.ts slash-command workflows
resolve.ts names -> IDs
text.ts GLPI HTML -> readable text
config.ts environment
oauth/ authorization server, encrypted store, sign-in page
glpi/
types.ts backend contract
legacy.ts /apirest.php client (session, search engine, documents, approvals...)
hlapi.ts /api.php client (OAuth2, version pinning, RSQL)
factory.ts auto-detection, legacy fallback, per-user session pool
similar.ts keyword extraction and ranking
stats.ts service desk metricsContributing
Branches, pull requests and commit conventions: CONTRIBUTING.md (Spanish). Report vulnerabilities privately to security@zylarion.io — see SECURITY.md.
Roadmap
High-Level API coverage for attachments, approvals, SLA and statistics (no legacy fallback needed)
Ticket templates and mandatory fields per category
MCP resources (tickets and KB articles as attachable context)
License
MIT — made by Zylarion for the GLPI community.
Available Tools
9 toolsglpi_get_itemGet a GLPI itemCRead-onlyIdempotent
Full record of one item of any itemtype (asset, user, group, KB article, ...).
Inputs: id (required), itemtype (required).
glpi_get_ticketGet a ticket, change or problemARead-onlyIdempotent
Full details of one ticket (or change/problem). Optionally include its timeline (followups, tasks, solutions) and its team (requesters, assigned technicians and groups, observers).
Inputs: id (required), itil_type, include_team, include_timeline.
glpi_list_itemsList GLPI itemsBRead-onlyIdempotent
List items of one itemtype (e.g. all Computers), paginated.
Inputs: itemtype (required), limit, start.
glpi_raw_getRaw GET on the GLPI APIARead-onlyIdempotent
Read-only escape hatch: GET any endpoint of the API in use, relative to its root. Legacy examples: 'Ticket/12/Document_Item', 'search/Computer' with query {criteria: [...]}, 'listSearchOptions/Ticket'. High-Level examples: 'Assets/Computer/5', 'Administration/User/Me'. Call glpi_server_info to know which API is active.
Inputs: path (required), query.
glpi_search_itemsSearch GLPI items by nameARead-onlyIdempotent
Find assets, users, groups, locations, categories, suppliers, KB articles or any other itemtype by name (partial match). Returns IDs to use with glpi_get_item or the ticket tools.
Inputs: query (required), itemtype (required), limit, start.
glpi_search_knowledgebaseSearch the knowledge baseARead-onlyIdempotent
Find knowledge base articles whose title matches the text. Read one with glpi_get_item (itemtype KnowbaseItem).
Inputs: query (required), limit, start.
glpi_search_ticketsSearch tickets, changes or problemsARead-onlyIdempotent
List tickets (or changes/problems), newest change first, with a compact summary of each. Status IDs: 1 new, 2 processing (assigned), 3 processing (planned), 4 pending, 5 solved, 6 closed. Priority IDs: 1 very low ... 5 very high, 6 major. Ticket type: 1 incident, 2 request. Use glpi_get_ticket for the description, timeline and team of one item. Filtering by assignee/requester works on the legacy API only.
Inputs: text, limit, start, statuses, +8 more.
glpi_server_infoGLPI server infoARead-onlyIdempotent
Show which GLPI API this server uses (legacy REST or High-Level API and its pinned version), the GLPI URL and the safety modes (read-only, delete allowed). Call it first when a connection problem is suspected.
Inputs: no named parameters.
glpi_whoamiCurrent GLPI userARead-onlyIdempotent
The GLPI user the tools act as, with the active profile and entity. Every call runs with that user's rights.
Inputs: no named parameters.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 9 tools
Most tools have clearly distinct roles: server diagnostics, identity, ticket search/get, generic item search/list/get, KB search, and a raw escape hatch. The main overlap is glpi_search_items and glpi_search_knowledgebase, since the former explicitly claims it can find KB articles by name; glpi_raw_get also overlaps conceptually with everything but is positioned as an explicit last resort.
All tools share a glpi_ prefix and mostly follow a verb_noun pattern (search_tickets, get_ticket, list_items, get_item, search_items). Deviations are minor: glpi_server_info and glpi_whoami are noun phrases, and glpi_raw_get puts the verb last.
Nine tools is well within the sweet spot and each one maps to a distinct need: diagnostics, identity, two ticket readers, three generic item readers, a KB search, and an escape hatch. Nothing looks padded or redundant.
The surface is entirely read-only: there is no way to create or update a ticket, add a followup or task, or modify any item, even though glpi_server_info advertises a 'delete allowed' safety mode implying write capability is expected. An agent can inspect everything but cannot act on the domain, which is a significant lifecycle gap.
Maintenance
Related MCP Connectors
Read tickets, contacts, companies, agents and groups; create, update and reply to tickets.
Connect Claude, ChatGPT or any AI assistant to Zendesk tickets, CSAT, macros and Help Center.
Read and write Sage Intacct from Claude or ChatGPT. Write tools are flagged for approval.
Read tickets, users, orgs, macros and satisfaction ratings; create, update and comment on tickets.
Related MCP Servers
- AlicenseBqualityNot gradedmaintenanceEnables Claude to interact with ServiceNow instances through the ServiceNow API. Supports comprehensive ServiceNow operations including incident management, service catalog management, change requests, user management, and workflow automation through natural language.82MIT
- AlicenseCqualityDmaintenanceEnables Claude to interact with ServiceNow instances through comprehensive API integration. Supports incident management, service catalog operations, change requests, knowledge base management, user administration, and agile project management with multiple authentication methods.82MIT
- AlicenseNot gradedqualityDmaintenanceEnables Claude to interact with ServiceNow instances through the ServiceNow API, supporting record management, service catalog operations, change management, and more via natural language.MIT
- FlicenseCqualityDmaintenanceConnects Claude to your Freshservice ITSM instance, enabling management of tickets, changes, assets, knowledge base, and more through natural language.701-