AWS Amplify Documentation MCP Server

by ykethan

1 stars
183 downloads
Not rated
GitHub

About

Model Context Protocol (MCP) server for AWS Amplify documentation

Details

Author
ykethan
GitHub stars
1
Downloads
183
Categories
Knowledge Base

- Powerful natural‑language search of AWS Amplify documentation
- Advanced search syntax (boolean operators, wildcards, field‑specific search)
- Smart relevance ranking of results
- Pagination support for large result sets
- Performance caching and automatic documentation updates
- Generation selection (Gen 1, Gen 2, or both) to reduce disk usage
- Built with TypeScript for type safety

Install dependencies with npm install, build with npm run build, then start with npm start or the provided ./start-server.sh script. Configure the server via docs-mcp.config.json, setting options like the Git repository URL, auto-update interval, and which Amplify generation (Gen 1, Gen 2, or both) to index. The server exposes a tool named search_amplify_docs that accepts parameters such as query, page, includeContent, maxResults, and more.

AWS Amplify Documentation MCP Server

A Model Context Protocol (MCP) server that provides powerful search functionality for AWS Amplify documentation. This server clones the official AWS Amplify documentation repository and makes it searchable through a simple MCP tool interface.

Features

- Powerful Search: Search AWS Amplify documentation using natural language queries
- Advanced Search Syntax: Support for boolean operators, wildcards, field-specific search, and more
- Smart Results Ranking: Intelligent ranking of search results based on relevance to query
- Pagination: Navigate through large result sets with pagination support
- Performance Caching: Caching of search results for improved performance
- Auto-Updates: Automatic updates of documentation from the official AWS Amplify repository
- Generation Selection: Choose between Gen 1, Gen 2, or both documentation sets to optimize disk usage and search radius.
- TypeScript Implementation: Built with TypeScript for better type safety and developer experience

> Disclaimer: This is a personal project and is not affiliated with, endorsed by, or officially connected to AWS Amplify or Amazon Web Services. This tool is provided as-is without any guarantees or warranty.

Installation

1. Clone this repository:

git clone https://github.com/ykethan/amplify-doc-mcp.git
cd amplify-doc-mcp

1. Install dependencies:

npm install

1. Build the TypeScript code:

npm run build

Configuration

The server is configured using the docs-mcp.config.json file:

{
  "gitUrl": "https://github.com/aws-amplify/docs.git",
  "gitRef": "main",
  "autoUpdateInterval": 60,
  "toolName": "search_amplify_docs",
  "toolDescription": "Search AWS Amplify documentation using the probe search engine.",
  "ignorePatterns": [
    "node_modules",
    ".git",
    "dist",
    "build",
    "coverage",
    ".vitepress/cache",
    ".jpg",
    ".jpeg",
    ".png",
    ".gif",
    ".svg",
    ".mp4",
    "*.webm"
  ],
  "amplifyGeneration": "gen2"
}

Configuration Options

| Option | Description | Default |
|--------|-------------|---------|
| gitUrl | URL of the Git repository to clone for documentation | "https://github.com/aws-amplify/docs.git" |
| gitRef | Git branch or tag to checkout | "main" |
| autoUpdateInterval | Interval in minutes to check for updates (0 to disable) | 60 |
| dataDir | Directory to store documentation data | "./data" |
| toolName | Name of the search tool | "search_amplify_docs" |
| toolDescription | Description of the search tool | "Search AWS Amplify documentation using the probe search engine." |
| ignorePatterns | Array of patterns to ignore when searching | ["node_modules", ".git", ...] |
| amplifyGeneration | Which Amplify documentation generation to include | "gen2" |

Auto-Update Mechanism

The server includes an automatic update mechanism that keeps the documentation up-to-date:

1. When the server starts, it clones the documentation repository specified in gitUrl.
2. If autoUpdateInterval is set to a value greater than 0, the server will periodically check for updates.
3. Every autoUpdateInterval minutes, the server:
- Fetches the latest changes from the remote repository
- Checks if the local branch is behind the remote branch
- If updates are available, pulls the changes automatically
- If no updates are needed, continues with the current documentation

This ensures that your documentation search results always include the latest information without requiring a server restart.

Usage

Starting the Server

npm start

Or use the provided start script with options:

./start-server.sh [--gen <1|2|both>] [--rebuild]

Options

- --gen 1: Include only Gen 1 documentation (reduces disk space usage)
- --gen 2: Include only Gen 2 documentation (default, reduces disk space usage)
- --gen both: Include both Gen 1 and Gen 2 documentation
- --rebuild: Force rebuild of data directory

Examples

```bash

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.