Aliyun Cloud MCP server

Integrates with Alibaba Cloud services to query and filter SLS logs, with future support for ECS instance management and serverless function deployment.
Back to servers
Provider
nailuoGG
Release date
Mar 26, 2025
Language
TypeScript
Package
Stats
178 downloads
2 stars

The Aliyun MCP Server allows Claude to interact with Alibaba Cloud services, providing a seamless way to query logs and manage cloud resources through conversational AI. This server implements the Model Context Protocol (MCP) to enable Claude to execute commands on your Aliyun services.

Installation

To set up the Aliyun MCP Server, follow these steps:

  1. Install the required dependencies and build the server:
npm install
npm run build

Configuration

For Claude Desktop

To integrate the Aliyun MCP Server with Claude Desktop, add the server configuration to your claude_desktop_config.json file:

{
  "mcpServers": {
    "aliyun": {
      "command": "node",
      "args": ["/path/to/aliyun-mcp-server/build/index.js"],
      "env": {
        "ALIYUN_ACCESS_KEY_ID": "your-access-key-id",
        "ALIYUN_ACCESS_KEY_SECRET": "your-access-key-secret",
        "SLS_ENDPOINT": "cn-hangzhou.log.aliyuncs.com"
      },
      "disabled": false,
      "autoApprove": []
    }
  }
}

For Cline in VSCode

To use the Aliyun MCP Server with Cline in VSCode, update your cline_mcp_settings.json file:

{
  "mcpServers": {
    "aliyun": {
      "command": "node",
      "args": ["/path/to/aliyun-mcp-server/build/index.js"],
      "env": {
        "ALIYUN_ACCESS_KEY_ID": "your-access-key-id",
        "ALIYUN_ACCESS_KEY_SECRET": "your-access-key-secret",
        "SLS_ENDPOINT": "cn-hangzhou.log.aliyuncs.com"
      },
      "disabled": false,
      "autoApprove": []
    }
  }
}

Make sure to replace /path/to/aliyun-mcp-server with the actual path to the repository on your system and provide your Aliyun credentials.

Using the MCP Server

Once configured, you can interact with Claude to query Aliyun services. For example, ask Claude to query SLS logs from a specific project and logstore with a query pattern for a specified time range.

Claude will use the MCP server to execute your request and return the results directly in the conversation.

Available Tools

querySLSLogs

This tool allows you to query Aliyun Simple Log Service (SLS) logs.

Parameters:

  • project (required): SLS project name
  • logstore (required): SLS logstore name
  • query (required): SLS query statement
  • from (optional): Start time in milliseconds (defaults to 1 hour ago)
  • to (optional): End time in milliseconds (defaults to now)
  • limit (optional): Maximum number of logs to return (default: 100, max: 1000)
  • offset (optional): Offset for pagination (default: 0)
  • reverse (optional): Whether to return results in reverse order (default: false)

Example request:

{
  "project": "my-project",
  "logstore": "my-logstore",
  "query": "error",
  "limit": 10
}

To use this tool, simply ask Claude to query SLS logs with specific parameters. For example: "Query SLS logs from project 'my-project' and logstore 'my-logstore' with the query 'error' for the last hour."

How to add this MCP server to Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > MCP and click "Add new global MCP server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "cursor-rules-mcp": {
            "command": "npx",
            "args": [
                "-y",
                "cursor-rules-mcp"
            ]
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explictly ask the agent to use the tool by mentioning the tool name and describing what the function does.

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later