Labsco
MCP SERVER

AWS Knowledge Base Retrieval

by sammcj

Retrieve context from an AWS Bedrock Knowledge Base by query and knowledge base id, with the result count under your control.

Vector Stores & RAG RetrievalVerified
Summary
Taking the knowledge base id per call is what makes this usable across several bases rather than pinned to one.

Bedrock Knowledge Bases are usually created per domain — one for product docs, one for policies, one for support history — and a client hardcoded to a single id means running several servers. Passing the id per query keeps one connection serving all of them, with the configured id list bounding what is reachable. One tool, no ambition beyond retrieval: this returns context for a model to use, and the generation half stays wherever you are already doing it.

What it is

A single-tool retrieval client over AWS Bedrock Agent Runtime: it queries a Knowledge Base and returns the matching context.

What you get
  • retrieve_from_aws_kb takes a query and a knowledge base id and returns retrieved context, with a customisable number of results.
Requirements

AWS credentials — access key, secret and optionally a session token — plus a region and the knowledge base ids it may reach.

Setup effort

One command plus a key — npx -y @modelcontextprotocol/server-aws-kb-retrieval, then supply credentials