Amazon CloudWatch Logs MCP Server

by hyorimitsu

285 downloads Not rated yet MIT license

About

A Model Context Protocol (MCP) server that enables AI assistants to interact with Amazon CloudWatch Logs through a standardized interface using AWS SDK.

Details

License
MIT license

Explore

- Create, describe, and delete log groups
- Create, describe, and delete log streams
- Write log events to a log stream
- Retrieve log events from a log stream
- Search log events with a filter pattern across groups and streams

To use the MCP server, you need to configure it with your AWS credentials. You can do this by setting environment variables:

{
  "mcpServers": {
    "amazon-cloudwatch-logs": {
      "command": "node",
      "args": ["/path/to/mcp-amazon-cloud-watch-logs/build/index.js"],
      "env": {
        "AWS_REGION": "us-east-1",
        "AWS_ACCESS_KEY_ID": "<YOUR_ACCESS_KEY>",
        "AWS_SECRET_ACCESS_KEY": "<YOUR_SECRET_KEY>"
      }
    }
  }
}

> Note: In the future, this project will be published as an npm package and as a Docker image for easier installation and usage.

pnpm install

- Docker
- Visual Studio Code
- VS Code Dev Containers extension

1. Clone the repository:

   git clone https://github.com/hyorimitsu/mcp-amazon-cloud-watch-logs.git
   cd mcp-amazon-cloud-watch-logs
   

2. Open the project in VS Code:

   code .
   

3. When prompted, click "Reopen in Container" or use the command palette and select "Dev Containers: Reopen in Container".

4. VS Code will build the dev container and open the project inside it. This may take a few minutes the first time.

5. Once inside the container, the development environment is fully set up with all dependencies installed.

create_log_group

Creates a new Amazon CloudWatch Logs log group

describe_log_groups

List and describe Amazon CloudWatch Logs log groups

delete_log_group

Delete an Amazon CloudWatch Logs log group

create_log_stream

Create a new log stream in an Amazon CloudWatch Logs log group

describe_log_streams

List and describe log streams in an Amazon CloudWatch Logs log group

delete_log_stream

Delete a log stream in an Amazon CloudWatch Logs log group

put_log_events

Write log events to a specified log stream in Amazon CloudWatch Logs

get_log_events

Retrieve log events from a specified log stream in Amazon CloudWatch Logs

filter_log_events

Search log events with a pattern across log groups and streams in Amazon CloudWatch Logs

| Tool Name | Description |
| -------------------- | ---------------------------------------------------------------------------------------- |
| create_log_group | Creates a new Amazon CloudWatch Logs log group |
| describe_log_groups | List and describe Amazon CloudWatch Logs log groups |
| delete_log_group | Delete an Amazon CloudWatch Logs log group |
| create_log_stream | Create a new log stream in an Amazon CloudWatch Logs log group |
| describe_log_streams | List and describe log streams in an Amazon CloudWatch Logs log group |
| delete_log_stream | Delete a log stream in an Amazon CloudWatch Logs log group |
| put_log_events | Write log events to a specified log stream in Amazon CloudWatch Logs |
| get_log_events | Retrieve log events from a specified log stream in Amazon CloudWatch Logs |
| filter_log_events | Search log events with a pattern across log groups and streams in Amazon CloudWatch Logs |

For detailed documentation on each tool, including parameters and examples, see TOOLS.md.

> Note: This project is under development. Additional CloudWatch Logs operations are planned for future releases.

A Model Context Protocol (MCP) server that provides tools for interacting with Amazon CloudWatch Logs services. This server enables AI assistant to manage CloudWatch logs through a standardized interface using AWS SDK.

License: MIT

> Note: This project is currently under active development and not yet ready for production use. Features and APIs may change significantly before the first stable release.

Overview

This MCP server allows AI assistant to interact with Amazon CloudWatch Logs through the Model Context Protocol. It provides a standardized interface for performing various CloudWatch Logs operations, enabling comprehensive management and monitoring of log data.

Setup

Using Local Development Build

```bash

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.