AWS Knowledge Base
About
Integrates with AWS Knowledge Bases to retrieve information using Bedrock Agent Runtime, enabling RAG operations with structured metadata for organizational knowledge access.
Details
- Author
- sammcj
- Repository
- sammcj/mcp-aws-kb
- Categories
- Cloud Service, Infrastructure, Productivity, Design, Developer Tools, AI, Frontend, Knowledge Base
Jump to
- RAG (Retrieval-Augmented Generation): Retrieve context from the AWS Knowledge Base based on a query and a Knowledge Base ID.
- Supports multiple results retrieval: Option to retrieve a customizable number of results.
Setting up with Highlight
This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:
- Download and install Highlight from highlightai.com/download
- Navigate to the plugins tab and select "Add Custom Plugin"
-
Configure the plugin with the settings below
Plugin Name
AWS Knowledge BaseCommand (node, npx, python, etc.)npxArguments-
Argument 1
-y -
Argument 2
@modelcontextprotocol/server-aws-kb-retrieval
Environment-
AWS_KB_IDS
["kb-12345", "kb-67890"] -
AWS_REGION
YOUR_AWS_REGION_HERE -
AWS_ACCESS_KEY_ID
YOUR_ACCESS_KEY_HERE -
AWS_SESSION_TOKEN
YOUR_OPTIONAL_SESSION_ID_FOR_SSO_TEMPORARY_CREDENTIALS_HERE -
AWS_SECRET_ACCESS_KEY
YOUR_SECRET_ACCESS_KEY_HERE
Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.
-
Argument 1
- Enable "Start Automatically" if you want the plugin to start when Highlight launches
From the repository
You can optionally specify one or more knowledge base IDs to use by default:
1. Create an array of knowledge base IDs in JSON format.
2. Set this as the AWS_KB_IDS environment variable in your configuration.
3. When this is configured, the knowledgeBaseId parameter becomes optional in the tool.
Add this to your claude_desktop_config.json:
retrieve_from_aws_kb
Perform retrieval operations using the AWS Knowledge Base. Inputs: query (string): The search query for retrieval. knowledgeBaseId (string): The ID of the AWS Knowledge Base. n (number, optional): Number of results to retrieve (default: 3).
- retrieve_from_aws_kb
- Perform retrieval operations using the AWS Knowledge Base.
- Inputs:
- query (string): The search query for retrieval.
- knowledgeBaseId (string): The ID of the AWS Knowledge Base.
- n (number, optional): Number of results to retrieve (default: 3).
- Response format:
- The response now returns two separate content items:
- A text item containing the raw context from the knowledge base.
- A JSON item containing the structured RAG sources with metadata (id, fileName, snippet, and score).
- This separation allows for more flexible processing of the results.
Claude Desktop / Cursor
Paste into your MCP client config file to install this server.
{
"mcpServers": {
"aws knowledge base": {
"env": {
"AWS_KB_IDS": "[\"kb-12345\", \"kb-67890\"]",
"AWS_REGION": "YOUR_AWS_REGION_HERE",
"AWS_ACCESS_KEY_ID": "YOUR_ACCESS_KEY_HERE",
"AWS_SESSION_TOKEN": "YOUR_OPTIONAL_SESSION_ID_FOR_SSO_TEMPORARY_CREDENTIALS_HERE",
"AWS_SECRET_ACCESS_KEY": "YOUR_SECRET_ACCESS_KEY_HERE"
},
"args": [
"-y",
"@modelcontextprotocol/server-aws-kb-retrieval"
],
"command": "npx"
}
}
}
Linux
{
"env": {
"AWS_KB_IDS": "[\"kb-12345\", \"kb-67890\"]",
"AWS_REGION": "YOUR_AWS_REGION_HERE",
"AWS_ACCESS_KEY_ID": "YOUR_ACCESS_KEY_HERE",
"AWS_SESSION_TOKEN": "YOUR_OPTIONAL_SESSION_ID_FOR_SSO_TEMPORARY_CREDENTIALS_HERE",
"AWS_SECRET_ACCESS_KEY": "YOUR_SECRET_ACCESS_KEY_HERE"
},
"args": [
"-y",
"@modelcontextprotocol/server-aws-kb-retrieval"
],
"command": "npx"
}
Macos
{
"env": {
"AWS_KB_IDS": "[\"kb-12345\", \"kb-67890\"]",
"AWS_REGION": "YOUR_AWS_REGION_HERE",
"AWS_ACCESS_KEY_ID": "YOUR_ACCESS_KEY_HERE",
"AWS_SESSION_TOKEN": "YOUR_OPTIONAL_SESSION_ID_FOR_SSO_TEMPORARY_CREDENTIALS_HERE",
"AWS_SECRET_ACCESS_KEY": "YOUR_SECRET_ACCESS_KEY_HERE"
},
"args": [
"-y",
"@modelcontextprotocol/server-aws-kb-retrieval"
],
"command": "npx"
}
Windows
{
"env": {
"AWS_KB_IDS": "[\"kb-12345\", \"kb-67890\"]",
"AWS_REGION": "YOUR_AWS_REGION_HERE",
"AWS_ACCESS_KEY_ID": "YOUR_ACCESS_KEY_HERE",
"AWS_SESSION_TOKEN": "YOUR_OPTIONAL_SESSION_ID_FOR_SSO_TEMPORARY_CREDENTIALS_HERE",
"AWS_SECRET_ACCESS_KEY": "YOUR_SECRET_ACCESS_KEY_HERE"
},
"args": [
"/c",
"npx",
"-y",
"@modelcontextprotocol/server-aws-kb-retrieval"
],
"command": "cmd"
}
Retrieve information from an AWS Knowledge Base using the Bedrock Agent Runtime.
An MCP server implementation for retrieving information from the AWS Knowledge Base using the Bedrock Agent Runtime.
- RAG (Retrieval-Augmented Generation): Retrieve context from the AWS Knowledge Base based on a query and a Knowledge Base ID.
- Supports multiple results retrieval: Option to retrieve a customizable number of results.
- retrieve_from_aws_kb
- Perform retrieval operations using the AWS Knowledge Base.
- Inputs:
- query(string): The search query for retrieval.
- knowledgeBaseId(string): The ID of the AWS Knowledge Base.
- n(number, optional): Number of results to retrieve (default: 3).
- The response now returns two separate content items:
- A text item containing the raw context from the knowledge base.
- A JSON item containing the structured RAG sources with metadata (id, fileName, snippet, and score).
You have two options for configuring AWS credentials:
- Obtain AWS access key ID, secret access key, and region from the AWS Management Console.
- Ensure these credentials have appropriate permissions for Bedrock Agent Runtime operations.
- Set the environment variables as shown in the configuration examples below.
- For temporary credentials, you can also provide a session token using theAWS_SESSION_TOKENenvironment variable.
The server now supports AWS SSO credentials:
- Configure AWS CLI with your SSO profile:aws configure sso
- Set only the AWS_REGION environment variable in the MCP server configuration.
- The server will use the default credential provider chain, which includes SSO credentials.
Optional: Configure Default Knowledge Base IDs
You can optionally specify one or more knowledge base IDs to use by default:
- Create an array of knowledge base IDs in JSON format.
- Set this as the AWS_KB_IDS environment variable in your configuration.
- When this is configured, theknowledgeBaseIdparameter becomes optional in the tool.
Add this to yourclaude_desktop_config.json:
{ "mcpServers": { "aws-kb-retrieval": { "command": "docker", "args": [ "run", "-i", "--rm", "-e", "AWS_ACCESS_KEY_ID", "-e", "AWS_SECRET_ACCESS_KEY", "-e", "AWS_REGION", "-e", "AWS_KB_IDS", "mcp/aws-kb-retrieval-server" ], "env": { "AWS_ACCESS_KEY_ID": "YOUR_ACCESS_KEY_HERE", "AWS_SECRET_ACCESS_KEY": "YOUR_SECRET_ACCESS_KEY_HERE", "AWS_SESSION_TOKEN": "YOUR_OPTIONAL_SESSION_ID_FOR_SSO_TEMPORARY_CREDENTIALS_HERE", "AWS_REGION": "YOUR_AWS_REGION_HERE", "AWS_KB_IDS": "[\"kb-12345\", \"kb-67890\"]" } } } }
{ "mcpServers": { "aws-kb-retrieval": { "command": "docker", "args": [ "run", "-i", "--rm", "-e", "AWS_REGION", "-e", "AWS_KB_IDS", "-v", "${HOME}/.aws:/root/.aws", "mcp/aws-kb-retrieval-server" ], "env": { "AWS_ACCESS_KEY_ID": "YOUR_ACCESS_KEY_HERE", "AWS_SECRET_ACCESS_KEY": "YOUR_SECRET_ACCESS_KEY_HERE", "AWS_SESSION_TOKEN": "YOUR_OPTIONAL_SESSION_ID_FOR_SSO_TEMPORARY_CREDENTIALS_HERE", "AWS_REGION": "YOUR_AWS_REGION_HERE", "AWS_KB_IDS": "[\"kb-12345\", \"kb-67890\"]" } } } }
{ "mcpServers": { "aws-kb-retrieval": { "command": "npx", "args": [ "-y", "@modelcontextprotocol/server-aws-kb-retrieval" ], "env": { "AWS_ACCESS_KEY_ID": "YOUR_ACCESS_KEY_HERE", "AWS_SECRET_ACCESS_KEY": "YOUR_SECRET_ACCESS_KEY_HERE", "AWS_SESSION_TOKEN": "YOUR_OPTIONAL_SESSION_ID_FOR_SSO_TEMPORARY_CREDENTIALS_HERE", "AWS_REGION": "YOUR_AWS_REGION_HERE", "AWS_KB_IDS": "[\"kb-12345\", \"kb-67890\"]" } } } }
{ "mcpServers": { "aws-kb-retrieval": { "command": "npx", "args": [ "-y", "@modelcontextprotocol/server-aws-kb-retrieval" ], "env": { "AWS_ACCESS_KEY_ID": "YOUR_ACCESS_KEY_HERE", "AWS_SECRET_ACCESS_KEY": "YOUR_SECRET_ACCESS_KEY_HERE", "AWS_SESSION_TOKEN": "YOUR_OPTIONAL_SESSION_ID_FOR_SSO_TEMPORARY_CREDENTIALS_HERE", "AWS_REGION": "YOUR_AWS_REGION_HERE", "AWS_KB_IDS": "[\"kb-12345\", \"kb-67890\"]" } } } }
Local Repository (from cloned/built repo)
{ "mcpServers": { "aws-kb": { "command": "node", "args": [ "/path/to/mcp-aws-kb/dist/index.js" ], "env": { "AWS_ACCESS_KEY_ID": "YOUR_ACCESS_KEY_HERE", "AWS_SECRET_ACCESS_KEY": "YOUR_SECRET_ACCESS_KEY_HERE", "AWS_SESSION_TOKEN": "YOUR_OPTIONAL_SESSION_ID_FOR_SSO_TEMPORARY_CREDENTIALS_HERE", "AWS_REGION": "YOUR_AWS_REGION_HERE", "AWS_KB_IDS": "[\"kb-12345\", \"kb-67890\"]" }, "disabled": false, "autoApprove": [ "retrieve_from_aws_kb" ], "timeout": 120 } } }
docker build -t mcp/aws-kb-retrieval -f src/aws-kb-retrieval-server/Dockerfile .
This MCP server is licensed under the MIT License. This means you are free to use, modify, and distribute the software, subject to the terms and conditions of the MIT License. For more details, please see the LICENSE file in the project repository.
This README assumes that your server package is named@modelcontextprotocol/server-aws-kb-retrieval. Adjust the package name and installation details if they differ in your setup. Also, ensure that your server script is correctly built and that all dependencies are properly managed in yourpackage.json.
Navigate your Aiven projects and interact with the PostgreSQL®, Apache Kafka®, ClickHouse® and OpenSearch® services
Yunxiao MCP Server provides AI assistants with the ability to interact with the Yunxiao platform.
Get prescriptive CDK advice, explain CDK Nag rules, check suppressions, generate Bedrock Agent schemas, and discover AWS Solutions Constructs patterns.
This AWS Labs Model Context Protocol (MCP) server for CloudTrail enables your AI agents to query AWS account activity for security investigations, compliance auditing, and operational troubleshooting.
Core AWS MCP server providing prompt understanding and server management capabilities.
Analyze CDK projects to identify AWS services used and get pricing information from AWS pricing webpages and API.
Query and analyze your Axiom logs, traces, and all other event data in natural language
Manage and interact with Microsoft Azure services.
Bastion: External Attack Surface Monitoring
Ask your AI assistant about your attack surface: run scans, catch expiring certificates and domains, triage findings, and generate reports.
Agent-ready global image CDN that AI agents can install and operate through MCP.
Sign in to leave a review
Use Google, GitHub, or an email account so ratings stay tied to real people.
No reviews posted yet.



