Skip to main content
Glama
patternfly

PatternFly MCP Server

Official
by patternfly
README.md
# PatternFly MCP Server

A Model Context Protocol (MCP) server that provides access to PatternFly rules and documentation, built with Node.js.

The PatternFly MCP server is a comprehensive library resource for PatternFly.
It is intended to be extensible to meet the needs of different teams and projects, from simple to complex, from design to development.
[Read more about our roadmap and how we've structured the server in our architecture docs](./docs/architecture.md).

## Requirements
- [Node.js 22+](https://nodejs.org/)
- NPM (or equivalent package manager)

## Quick start

The PatternFly MCP Server supports multiple configurations; see the [usage documentation](./docs/usage.md#mcp-client-configuration) for details.

### For integrated use with an IDE

#### Set a basic MCP configuration

> Unable to update to the required Node.js version? [See pinned MCP configuration examples for earlier Node.js versions.](./docs/usage.md#pinned-mcp-package-version)

Minimal configuration
```json
{
  "mcpServers": {
    "patternfly-mcp": {
      "command": "npx",
      "args": ["-y", "@patternfly/patternfly-mcp@latest"],
      "description": "PatternFly rules and documentation"
    }
  }
}
```

HTTP transport mode
```json
{
  "mcpServers": {
    "patternfly-mcp": {
      "command": "npx",
      "args": ["-y", "@patternfly/patternfly-mcp@latest", "--http", "--port", "8080"],
      "description": "PatternFly rules and documentation (HTTP transport)"
    }
  }
}
```

[See the MCP Server Configuration documentation for more examples.](./docs/usage.md#mcp-client-configuration)

### For development, advanced usage

#### Run the latest released server
Run the latest published package immediately via `npx`:

```bash
npx -y @patternfly/patternfly-mcp@latest
```

Or with options

```bash
npx -y @patternfly/patternfly-mcp@latest --log-stderr --verbose
```

#### Run a locally built server
```bash
# clone the repo, change the directory, npm install, npm run build, then in the repo context run...
npm start
```

#### Inspect the server
Visualize and test the packaged MCP interface:

```bash
npx -y @modelcontextprotocol/inspector npx -y @patternfly/patternfly-mcp@latest
```

Build from source and test a local built MCP interface:

```bash
# clone the repo, change the directory, npm install, npm run build, then in the repo context run...
npx -y @modelcontextprotocol/inspector node dist/cli.js
```

#### Embed the server in your application

```typescript
import { start } from '@patternfly/patternfly-mcp';

// Remember to avoid using console.log and info, they pollute STDOUT
async function main() {
  const server = await start();

  // Graceful shutdown
  process.on('SIGINT', async () => {
    await server.stop();
    process.exit(0);
  });
}

main();
```

[See the development documentation for additional examples, CLI and embedded server options.](./docs/development.md)

## Documentation

For comprehensive usage, development, and project state [read the docs](./docs/README.md).

- **Architecture**: Learn about our [architecture, collections, and data sources](./docs/architecture.md#collections-and-data-sources).
- **Usage**: Detailed guide on [built-in tools, resources, and troubleshooting for general use](./docs/usage.md).
- **Development**: Reference for [CLI options and tool plugins](./docs/development.md).

## Security & Governance

See [SECURITY.md](./SECURITY.md) for vulnerability reporting and [GOVERNANCE.md](./GOVERNANCE.md) for how contributions are reviewed.

## Contributing

Contributing? Guidelines can be found here [CONTRIBUTING.md](./CONTRIBUTING.md).

### AI agent

If you're using an AI assistant to help with development in this repository, please prompt it to `review the repo guidelines` to ensure adherence to project conventions.

Guidelines for developer-agent interaction can be found in [CONTRIBUTING.md](./CONTRIBUTING.md#ai-agent).

TDQS

A3.9/5.0

Scored across 2 tools

Disambiguation4/5

The pair follows a clean search-then-fetch split: searchPatternFlyDocs returns names/URIs/URLs, usePatternFlyDocs consumes them. The only slight fuzziness is that 'usePatternFlyDocs' alone doesn't signal 'fetch content' without reading the description, but the two tools are not confusable in practice.

Naming Consistency5/5

Both names use camelCase with a verb+PatternFly+Docs structure (searchPatternFlyDocs, usePatternFlyDocs), giving a predictable, parallel pattern. No mixed conventions or vague one-word verbs.

Tool Count4/5

Two tools is deliberately minimal but justified: this is the canonical search/fetch pattern for a documentation server, and each tool has a distinct, non-redundant role. It sits at the thin end of the range but is well scoped.

Completeness4/5

Discovery (search, including wildcard and version-specific queries) plus retrieval of markdown docs and JSON schemas covers the core documentation use case with no dead ends. Minor gaps exist, such as no explicit enumeration of available versions or collections, but '*' search largely compensates.

Maintenance

ActivityActive
ResponsivenessWithin a week