Amazon Bedrock Knowledge Base MCP Server
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| PORT | No | HTTP server port. | 8000 |
| MCP_HOST | No | HTTP server bind address. | 127.0.0.1 |
| AWS_REGION | Yes | AWS region (e.g., us-west-2). | |
| AWS_PROFILE | No | AWS profile name (recommended). Either AWS_PROFILE or IAM role credentials are required. | |
| AUTH0_DOMAIN | No | Auth0 tenant domain (e.g., tenant.us.auth0.com). Required when MCP_AUTH_MODE=oauth. | |
| MCP_AUTH_MODE | No | Set to `oauth` to enable Auth0 authentication. | |
| MCP_STATELESS | No | Stateless mode (recommended for production). | true |
| MCP_TRANSPORT | No | Transport mode: stdio, sse, or streamable-http. | stdio |
| AUTH0_AUDIENCE | No | Auth0 API identifier / audience. Required when MCP_AUTH_MODE=oauth. | |
| MCP_RESOURCE_URL | No | Public URL clients connect to. Required when MCP_AUTH_MODE=oauth. | |
| FASTMCP_LOG_LEVEL | No | Log level (DEBUG, INFO, WARNING, ERROR). | INFO |
| MCP_ALLOWED_HOSTS | No | Comma-separated allowed Host headers. | |
| MCP_ALLOWED_ORIGINS | No | Comma-separated allowed CORS origins (`*` for any). | |
| KB_INCLUSION_TAG_KEY | No | Only include knowledge bases tagged with <key>=true. | mcp-multirag-kb |
| BEDROCK_KB_FILTER_MODE | No | How to combine explicit and implicit filters. | explicit_then_implicit |
| BEDROCK_KB_SEARCH_TYPE | No | Search type: DEFAULT, HYBRID, or SEMANTIC. | DEFAULT |
| BEDROCK_KB_SCHEMA_MAP_JSON | No | Path to KB ID to schema-path mapping (JSON). | |
| BEDROCK_KB_ALLOW_RAW_FILTER | No | Allow raw Bedrock RetrievalFilter passthrough. | false |
| BEDROCK_KB_RERANKING_ENABLED | No | Enable reranking by default. | false |
| BEDROCK_KB_SCHEMA_DEFAULT_PATH | No | Default schema file path (JSON). | |
| BEDROCK_KB_IMPLICIT_FILTER_MODEL_ARN | No | Model ARN for implicit filtering. |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
Retrieve information from Amazon Bedrock Knowledge Bases.
Recommended workflow:
Call ListKnowledgeBases to find an eligible knowledge base and its data sources.
Use QueryKnowledgeBases for content-focused retrieval.
Use QueryKnowledgeBasesWithMetadata for discovery and metadata-aware exploration.
If you want filtering, call DescribeMetadataSchema first, then use
where(friendly) orfilter(raw) constraints.
Prefer small number_of_results for focused answers, and enable reranking when you need better ordering.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
| prompts | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| DescribeMetadataSchemaA | Describe the metadata schema used for filtering. |
| ListKnowledgeBasesA | List available knowledge bases and their data sources. |
| QueryKnowledgeBasesB | Query a knowledge base and return relevant passages. Returns a newline-separated set of JSON objects (one per retrieval result). |
| QueryKnowledgeBasesWithMetadataA | Query a knowledge base and include metadata in results. Use this for metadata-driven exploration (discover what keys/values exist) before applying precise filters. Returns newline-separated JSON objects. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 4 tools
ListKnowledgeBases and DescribeMetadataSchema are clearly distinct, but QueryKnowledgeBases and QueryKnowledgeBasesWithMetadata overlap heavily. The descriptions do explain the difference—metadata inclusion versus standard retrieval—so an agent can disambiguate with care, though misselection remains plausible.
All tools use consistent PascalCase verb-noun naming: Describe..., List..., Query..., Query...WithMetadata. The suffix variant on the last tool is descriptive rather than a convention break.
Four tools is well-scoped for a read-only knowledge base retrieval server. Each tool maps to a distinct retrieval concern: listing, schema discovery, standard query, and metadata-aware query.
The surface covers the core read-only workflow: discover knowledge bases, inspect metadata schema, and query with or without metadata. Minor gaps exist around data source detail or pagination, but agents can work around them using list and query tools.