mcp-s3-toolkit

Sidhartht1607/mcp-s3-toolkit

3.1

If you are the rightful owner of mcp-s3-toolkit and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.

This server provides an interface to AWS S3 through the Model Context Protocol (MCP), allowing LLM agents to interact with S3 storage.

Tools
10
Resources
0
Prompts
0

๐Ÿ—‚๏ธ Simple S3 MCP Server

This server exposes an AWS S3 interface as tools for an LLM agent via the Model Context Protocol (MCP).

โœ… Available Tools

ToolDescription
list_filesLists all object keys in a bucket
list_keys_with_metadataLists keys with storage class and region
get_file_contentReturns content of UTF-8 .txt files
upload_textUploads a text string as a file
upload_fileUploads a local file by path
upload_reportUploads multi-line report as .txt
delete_fileDeletes a file from S3
download_and_previewDownloads and prints .txt or .pdf
check_authorizationChecks if AWS credentials are valid
create_bucketCreates a new S3 bucket

โš ๏ธ Common Problems and Fixes

1. โŒ SSE connection not established or 500 Internal Server Error

  • Cause: Tool crashed due to large files or invalid UTF-8 content
  • Fix: Use get_file_content only for small .txt files

2. โŒ MCP error -32001: Request timed out

  • Cause: Tool (e.g. get_file_content) taking too long or file is large
  • Fix: Use truncated previews or limit to first few KB of content

3. โŒ Invalid bucket name or The specified key does not exist

  • Fix: Ensure no trailing spaces in input fields
  • Solution: All tools automatically apply .strip() to inputs

4. ๐Ÿง  JSON formatting issues in upload_report

  • Fix: Must enter lines as valid JSON array:
    [
      "Line 1",
      "Line 2"
    ]
    
  1. Create and activate virtual environment
  • python3 -m venv venv
  • source venv/bin/activate
  1. Install dependencies
  • pip install -r requirements.txt
  1. Create your .env file
  • AWS_ACCESS_KEY_ID=your_access_key
  • AWS_SECRET_ACCESS_KEY=your_secret_key
  • AWS_DEFAULT_REGION=us-east-1

๐Ÿงช Run the MCP Server in Dev Mode

  • mcp dev s3_mcp_server.py