Skip to main content
Glama

AWS S3 MCP 服务器

MCP 服务器用于 AWS S3 操作,通过预签名的 URL 提供对 S3 存储桶的安全访问。

工具

  1. list_objects

    • 列出 S3 存储桶中的对象

    • 输入:

      • prefix (字符串,可选):对象键的前缀过滤器

    • 返回:包含键、大小和上次修改日期的对象数组

  2. get_object

    • 生成用于访问对象的预签名 URL

    • 输入:

      • key (字符串,必需):要检索的对象键

      • expiry (数字,可选):URL 过期时间(秒)(默认值:3600)

    • 返回:包含预签名 URL 的object_url

  3. put_object

    • 生成用于上传对象的预签名 URL

    • 输入:

      • key (字符串,必需):要上传的对象键

      • expiry (数字,可选):URL 过期时间(秒)(默认值:3600)

    • 返回:包含预签名 URL 的upload_url

  4. delete_object

    • 从存储桶中删除对象

    • 输入:

      • key (字符串,必需):要删除的对象键

    • 返回:表示删除状态的success布尔值

Related MCP server: S3 MCP Server

设置

环境变量

服务器需要以下环境变量:

  • BUCKET_NAME :您的 S3 存储桶的名称(必需)

  • REGION :AWS 区域(默认值:“ap-southeast-1”)

应使用标准 AWS 凭证配置方法(环境变量、IAM 角色或 AWS 凭证文件)配置 AWS 凭证。

与 Claude Desktop 一起使用

将以下内容添加到您的claude_desktop_config.json中:

{
  "mcpServers": {
    "aws-ow-s3-mcp": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "BUCKET_NAME",
        "-e",
        "REGION",
        "-e",
        "AWS_ACCESS_KEY_ID",
        "-e",
        "AWS_SECRET_ACCESS_KEY",
        "mcp/aws-ow-s3-mcp"
      ],
      "env": {
        "BUCKET_NAME": "<YOUR_BUCKET_NAME>",
        "REGION": "<AWS_REGION>",
        "AWS_ACCESS_KEY_ID": "<YOUR_ACCESS_KEY>",
        "AWS_SECRET_ACCESS_KEY": "<YOUR_SECRET_KEY>"
      }
    }
  }
}

NPX 命令

{
  "mcpServers": {
    "aws-ow-s3-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-aws-ow-s3-mcp"
      ],
      "env": {
        "BUCKET_NAME": "<YOUR_BUCKET_NAME>",
        "REGION": "<AWS_REGION>",
        "AWS_ACCESS_KEY_ID": "<YOUR_ACCESS_KEY>",
        "AWS_SECRET_ACCESS_KEY": "<YOUR_SECRET_KEY>"
      }
    }
  }
}

建造

Docker 构建:

docker build -t mcp/aws-ow-s3-mcp-server .

发展

该服务器使用以下方式构建:

  • Node.js

  • TypeScript

  • @modelcontextprotocol/sdk

  • @aws-sdk/客户端-s3

  • @aws-sdk/s3-request-presigner

执照

此 MCP 服务器采用 MIT 许可证。这意味着您可以自由使用、修改和分发该软件,但须遵守 MIT 许可证的条款和条件。更多详情,请参阅项目仓库中的 LICENSE 文件。

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      D
      maintenance
      Enables interaction with S3-compatible storage services like AWS S3 and Cloudflare R2, supporting bucket management, object listing, reading, uploading, and deletion operations.
      5
      ISC
    • A
      license
      Not graded
      quality
      F
      maintenance
      Enables interaction with AWS S3 through MCP, supporting bucket and object management, lifecycle configurations, tagging, policies, CORS settings, presigned URLs, and file uploads/downloads.
      3
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      Enables interaction with AWS S3 storage through bucket operations (create, delete, list), object management (upload, download, delete, list), and bucket policy configuration using AWS credentials.
      15 npm
      2
      MIT