Skip to main content

An open-source Model Context Protocol (MCP) server for Amazon S3.

Project description

AWS S3 Explorer - MCP Server

An open-source Model Context Protocol (MCP) server built in Python that securely connects AI assistants to Amazon S3.

This server provides Large Language Models (LLMs) with the ability to list buckets, inspect dataset structures, and read file schemas directly without requiring massive data downloads. It is engineered for ML infrastructure pipelines, featuring fully asynchronous I/O and defensive error handling.

Features

  • Asynchronous I/O: Utilizes aiobotocore for non-blocking concurrent requests, ensuring the server doesn't fall over under heavy LLM workloads.
  • Defensive Error Handling: Catch-and-return patterns for AWS exceptions (including missing credentials) that allow AI agents to cleanly self-correct.
  • Strict Typing: Heavily typed Python interfaces using the FastMCP wrapper to automatically generate robust JSON schemas for the client.
  • Mocked CI/CD: Fully automated test suites using pytest and pytest-asyncio, integrated into a GitHub Action pipeline.

Tools Exposed to the LLM

This server exposes three specific primitives:

  1. list_s3_buckets(): Lists all S3 buckets accessible by the current AWS credentials.
  2. list_s3_objects(bucket_name, prefix, max_keys): Lists objects inside a specific bucket. Limits results by default to prevent LLM context window overflow.
  3. read_s3_file_head(bucket_name, object_key, byte_limit): Reads the first few kilobytes of an S3 object to inspect its contents (e.g., CSV headers, JSON structures) without downloading the entire file.

Installation and Setup

Prerequisites

  • Python 3.11+
  • AWS credentials configured locally (e.g., aws configure or ~/.aws/credentials)

Option 1: User Setup

Install the package with pip directly from GitHub:

pip install git+https://github.com/kbates97/AWS_S3_Explorer_MCP.git

You can start the MCP server by running:

aws-s3-mcp

Option 2: Developer Setup

Clone the repository and install the required dependencies:

git clone https://github.com/kbates97/AWS_S3_Explorer_MCP.git
cd AWS_S3_Explorer_MCP
python -m venv venv

# Windows: .\venv\Scripts\activate
# Mac/Linux: source venv/bin/activate

pip install -r requirements.txt

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

aws_s3_explorer_mcp-0.1.0.tar.gz (5.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

aws_s3_explorer_mcp-0.1.0-py3-none-any.whl (4.2 kB view details)

Uploaded Python 3

File details

Details for the file aws_s3_explorer_mcp-0.1.0.tar.gz.

File metadata

  • Download URL: aws_s3_explorer_mcp-0.1.0.tar.gz
  • Upload date:
  • Size: 5.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.13

File hashes

Hashes for aws_s3_explorer_mcp-0.1.0.tar.gz
Algorithm Hash digest
SHA256 833d0132ed480e778f6e8739fedb000f1b8fb5f80e7514f306ae5a6a81581af1
MD5 33503cca3908a5788f667cbf87c5f5aa
BLAKE2b-256 cb8eb26d70d481b4c0d9543671fdb1aabfc683837eade60e7c06a2b3de018ff3

See more details on using hashes here.

File details

Details for the file aws_s3_explorer_mcp-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for aws_s3_explorer_mcp-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0dcee5cdcc2538143dd7faf4f3e302e520176814da1d0e2232ec89eeae5b80aa
MD5 f56adb6e0681304388e7c135633b5cfc
BLAKE2b-256 049e9e99c2b9d3ecda8c8b893478f4c879e5667d6c722d75da37857a43a2eb24

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page