pi-kb-mcp
Click on "Install 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., "@pi-kb-mcpsearch KB for 'PI Web API 401 Unauthorized' error"
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.
PI KB MCP
Ground your AI answers in AVEVA's Customer Support knowledge base.
An MCP server that searches and reads knowledge base articles from the AVEVA Customer Support Portal — tech notes, known issues, error-message diagnostics and workarounds that do not appear in the public product documentation.
Companion to pi-doc-mcp, which covers the public product manuals. Use both: manuals for how things work, KB for when they don't.
Requires an AVEVA support entitlement
KB articles are licensed to your support contract. You sign in with your own AVEVA account and see exactly what that account is entitled to.
Related MCP server: Broadcom Support MCP Server
Install
Requires uv and Python 3.11+.
git clone https://github.com/nurnaufal321/pi-kb-mcp.git
cd pi-kb-mcp
uv sync --extra loginRegister it, replacing the path with wherever you cloned it:
claude mcp add pi-kb --scope user -- uv run --directory /path/to/pi-kb-mcp pi-kb-mcpThen sign in:
uv run pi-kb-mcp loginpi-kb-mcp login opens a window on AVEVA's own sign-in page. Your password is
never seen, handled or stored by this tool — it is typed into AVEVA's page. Only the
resulting session token is cached, at ~/.config/pi-kb-mcp/session.json (mode 0600).
Sessions last about 8 hours; re-run pi-kb-mcp login when a tool tells you to.
Tools
Tool | What it does |
| Search KB articles by error message or symptom |
| Read one article in full by number or URL |
| List product names for narrowing a search |
Configuration
Variable | Purpose |
| Use this bearer token instead of the cached session. Fallback for headless machines and Linux without GTK/WebKit. |
| Override the session file location. |
| Mode B only. Shared secret gating the HTTP server; 24 characters minimum. |
| Mode B only. Where pushed portal cookies are stored. |
| Mode B only. Comma-separated hostnames to accept, e.g. |
| Mode B only. Host bind, if you uncomment the |
Phone access (optional, private)
The steps above are all you need on a laptop. If you also want to reach the KB
from your phone, pi-kb-mcp serve runs a private, single-user HTTP server
you host yourself.
It holds exactly one AVEVA session — yours. It never asks a caller to sign in to AVEVA and has no code path that accepts anyone else's AVEVA credentials.
python -c 'import secrets; print(secrets.token_urlsafe(32))' # your secret
PI_KB_MCP_SECRET=<secret> docker compose up -d # see docker-compose.ymlThen seed it from your laptop, which is the only machine that can sign in:
PI_KB_MCP_SECRET=<secret> uv run pi-kb-mcp login --push https://kb.example.comAdd it in your client as a remote MCP server at https://kb.example.com/mcp
with header Authorization: Bearer <secret>.
How long it lasts. The bearer token AVEVA issues lives 8 hours, so the server
re-mints one itself: it stores your portal cookies and boots the portal in headless
Chromium to obtain a fresh token — the token issuer cannot be called directly (see
NOTES.md). You only sign in again when the cookies expire, which is
typically days rather than hours, but AVEVA controls that and it is not guaranteed.
When they do expire, tools return a message telling you to run login --push again.
Read this before hosting it
Never share the URL or the secret, and never advertise it publicly. Anyone who has both queries the KB as you — your entitlement, your identity, in AVEVA's logs. Sharing it looks exactly like you scraping the KB, which is how support accounts get suspended. Point other people at this repo instead; they run their own.
Always put TLS in front of it.
docker-compose.ymlbinds to loopback for that reason.This box now holds a long-lived credential of yours. If it is compromised, your AVEVA session goes with it. That is the cost of phone access, and it is the reason Mode B is opt-in rather than the default.
The server refuses to start without a 24+ character secret, rejects every unauthenticated request, and never logs cookie values.
Privacy
The server process reads a token file and talks to AVEVA. That's all. It never
touches your browser's cookie store or keychain, has no telemetry, and sends
nothing anywhere except softwaresupportsp.aveva.com and
services.softwaresupport.aveva.com.
Don't share your session token. The default stdio server is not networked at all; if you enable the optional phone access above, keep its URL and secret private — anyone who reaches it spends your support entitlement under your identity.
Development
uv sync --extra login
uv run pytestAPI shapes are documented in NOTES.md.
License
MIT
Available Tools
3 toolsget_kb_articleARead-only
Fetch the full text of one AVEVA knowledge base article, including its symptoms, cause and resolution sections.
Use after search_pi_kb to read an article whose excerpt looks relevant, or directly whenever the user supplies an article number or a softwaresupportsp.aveva.com link. Search excerpts are truncated and routinely omit the actual fix, so read the article before answering from a search result alone.
Read-only; no side effects. Returns a header line with title, products, article type and last-updated date, then the article body converted from HTML to plain text and truncated at max_chars, with a marker when cut.
| Name | Required | Description | Default |
|---|---|---|---|
| article | Yes | Article number such as '000100024', or a full portal URL such as 'https://softwaresupportsp.aveva.com/en-US/knowledge/details/000100024'. Both forms are accepted. | |
| max_chars | No | Maximum characters of article body to return, 500-20000. Raise it if the response ends in a truncation marker. |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Even though readOnlyHint is already set, the description adds concrete behavioral details: no side effects, a header line with metadata fields, HTML-to-plain-text conversion, and truncation with a marker when cut. This gives the agent an accurate mental model of the response without contradicting annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well organized into purpose, usage guidance, and behavior, with no wasted sentences. It front-loads the core function and places important usage and truncation details where they are easy to find.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a two-parameter read-only tool, the description is complete: it names the input forms, explains when to use it, describes the output format, and warns about truncation. The presence of an output schema further reduces the need for the description to detail return values.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the schema already fully documents both the article parameter (number or URL) and max_chars (range, default, truncation-marker hint). The description reinforces these details in context but adds little beyond what the schema provides.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description states a specific verb ('Fetch') and resource ('full text of one AVEVA knowledge base article') and lists the article sections it covers. It clearly differentiates from the sibling tools by focusing on full-text retrieval rather than search or product listing.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly instructs when to use the tool: after search_pi_kb when an excerpt looks relevant, or directly when a user supplies an article number or support link. It also explains why reading the full article is necessary, because search excerpts are truncated and routinely omit the fix.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_kb_productsARead-only
List AVEVA product names accepted by the products argument of search_pi_kb, optionally filtered by a substring.
Use when a search returns results spanning unrelated products and you need the exact spelling to narrow it, or when the user names a product informally ('PI AF', 'Data Archive') and you need AVEVA's canonical form. Not needed for a first, unscoped search.
Read-only; no side effects. AVEVA publishes over a thousand product names, so with no argument this returns only PI System products; pass contains to find products outside that set. Results are cached for the life of the process. Returns one name per line, alphabetically, or a note if nothing matched.
| Name | Required | Description | Default |
|---|---|---|---|
| contains | No | Case-insensitive substring to filter product names, e.g. 'vision', 'historian' or 'adapter'. Omit to list PI System products only. |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations provide readOnlyHint=true and openWorldHint=true, and the description reinforces these with 'Read-only; no side effects'. Beyond the annotations, the description discloses critical behavioral traits: the non-obvious default (no argument returns only PI System products, not everything), the caching behavior for process lifetime, the return format (one name per line, alphabetical), and the 'note if nothing matched' outcome. The scale context ('over a thousand product names') explains why this default exists. All of this is additive value that annotations cannot express.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Four sentences in a purposeful order: purpose, usage guidance with concrete examples, behavioral caveats, return format. Every sentence carries distinct information with zero filler. The slight redundancy of 'Read-only; no side effects' against the annotation is acceptable reinforcement rather than waste. Front-loaded with the core purpose, which is exactly what an agent scanning tool lists needs.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with one optional parameter, an output schema, and strong annotations, the description is complete. The most dangerous gotcha — that omitting the argument does not mean 'all products' but rather 'PI System products only' — is explicitly highlighted. The description covers when to use, when not to use, default behavior, caching, output format, and empty-result behavior. Nothing an agent would need to call this correctly is missing.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% and the schema description is already strong with worked examples ('vision', 'historian', 'adapter'). The description adds one useful clarification beyond the schema: passing `contains` expands beyond the default PI System set ('find products outside that set'), which resolves an ambiguity in the schema's phrasing 'Omit to list PI System products only' — one might otherwise infer contains merely filters within that set. That semantic disambiguation is real value, though the schema does most of the heavy lifting.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The first sentence states a specific verb ('List'), a specific resource ('AVEVA product names'), and ties it precisely to the products argument of the sibling tool search_pi_kb. It is immediately distinguishable from both siblings: search_pi_kb (which searches articles) and get_kb_article (which retrieves a single article). This is textbook purpose clarity.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives two explicit trigger scenarios (narrowing cross-product search results by exact spelling, and resolving informal user names like 'PI AF' to AVEVA canonical form) and an explicit exclusion ('Not needed for a first, unscoped search'). It also names the sibling tool whose results this tool supports, giving the agent a clear decision rule for when to call it.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
search_pi_kbARead-only
Search AVEVA's Customer Support knowledge base and return matching article numbers, titles, products and excerpts.
Use this for support-desk material: specific error messages, known issues, version incompatibilities, workarounds and how-to notes. Prefer product documentation tools for conceptual or reference questions (what a feature is, configuration reference, API syntax); reach here when the user reports something broken or quotes an error.
Read-only; no side effects. Scoped to English-language Knowledge Base articles, excluding product documentation, community posts and product news. Requires a signed-in AVEVA support session — with none, it returns an instruction to run pi-kb-mcp login rather than failing silently. Returns a match count followed by up to n_results entries, each carrying the article number that get_kb_article needs.
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | Free-text search terms. Quoting a verbatim error message works well, e.g. 'Index was out of range' or 'PI Vision authentication Kerberos'. | |
| products | No | Optional product names to narrow the search, matched exactly against AVEVA's product list, e.g. ['PI Vision'] or ['PI Data Archive', 'PI Asset Framework']. Call list_kb_products for valid values. Omit to search all products. | |
| n_results | No | Number of articles to return, 1-50. |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond readOnlyHint, the description discloses no side effects, English/KB scope, exclusions (product docs, community posts, product news), and that missing auth returns a login instruction instead of failing. It also pre-announces the result shape: match count then entries with article number.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is dense but every sentence earns its place: purpose, use cases, exclusions, auth behavior, and return shape. Key facts are front-loaded and nothing extraneous is included.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a search tool with three params and two siblings, the description covers all decision-relevant context: when to use it, scope restrictions, auth prerequisite, output format, and how it relates to get_kb_article and list_kb_products. An output schema exists, so return details are also backed by structured info.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the baseline applies. The input schema already gives detailed meanings, examples, defaults, and ranges for query, products, and n_results. The description adds a small bit of context by saying n_results limits returned entries, but doesn't need to compensate for any schema gap.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states a specific verb ('Search') and resource (AVEVA Customer Support knowledge base) and lists the exact return fields: article numbers, titles, products and excerpts. It also differentiates from siblings by noting the article number is what get_kb_article needs and referencing list_kb_products.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
It explicitly says when to use this tool (support-desk material, error messages, known issues, workarounds, how-to notes) and when not to use it (conceptual or reference questions should go to product documentation). It also covers the signed-in session requirement and the fallback behavior.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
3 tool updates
v0.1.0- First observed
get_kb_article - First observed
list_kb_products - First observed
search_pi_kb
TDQS
Each tool has a clearly distinct purpose: search returns article matches, get_kb_article retrieves full article text, and list_kb_products supplies valid product names for search filtering. There is no overlap in what the tools do, and the descriptions reinforce when each should be used.
All tool names follow a consistent verb_noun pattern using underscores: search_, get_, list_. The shared 'kb' component in each name further ties them together as a cohesive set with no mixed naming conventions.
Three tools is perfectly scoped for this server's purpose: search the knowledge base, read a specific article, and list valid product filters. Every tool fulfills a necessary step in the workflow, and none feel superfluous or missing.
The read-only knowledge base workflow is fully covered: search with optional product filtering, retrieve full article text, and resolve product names. The descriptions also handle edge cases like unsigned sessions and truncated excerpts, leaving no obvious dead ends for the stated domain.
Maintenance
Related MCP Connectors
Search and query nTop's knowledge base and engineering guides from AI applications.
Shared knowledge base for AI agents. Search and contribute solutions to technical problems.
Knowledge base MCP for AI agents on iknow.dev. Search, read, and maintain via OAuth.
Structured knowledge base for AI agent solutions. Search, explore, and retrieve build logs.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables AI assistants to search and fetch documentation content from Adobe Experience League, allowing natural language queries to retrieve Adobe product documentation and articles.-
- FlicenseBqualityDmaintenanceEnables searching and retrieving Knowledge Base articles from the Broadcom Support Portal for products like VMware, Tanzu, and Cybersecurity. Users can perform documentation searches and fetch specific articles in Markdown format via the SearchUnify API.2-
- AlicenseAqualityAmaintenanceProvides AI assistants with direct access to Jamf official documentation, enabling them to answer Jamf-related questions by searching, retrieving articles, and browsing product documentation.63452MIT
- FlicenseAqualityDmaintenanceEnables searching and retrieving Zendesk Help Center articles through natural language, supporting article search and detailed article lookup by ID.26-
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/nurnaufal321/pi-kb-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server