npm package: @kaho0924/manus
Description: A Model Context Protocol (MCP) server that provides integration with the Manus API, enabling AI assistants to interact with Manus&#39;s powerful AI agent capabilities.
Latest version: 0.1.0

# Manus MCP Server

A Model Context Protocol (MCP) server that provides integration with the Manus API, enabling AI assistants to interact with Manus's powerful AI agent capabilities.

This TypeScript-based MCP server provides seamless integration with the Manus Integrations API, allowing AI assistants to:
- Create and manage AI tasks with the Manus agent
- Upload and manage files for task attachments
- Configure webhooks for real-time task notifications

## Features

### Task Management Tools
- `create_task` - Create a new Manus AI task
  - Required: `prompt` (task instruction)
  - Optional:
    - `taskMode` (chat/adaptive/agent)
    - `agentProfile` (speed/quality)
    - `attachments` (array of file attachments)
    - `connectors` (array of connector UUIDs - see [Available Connectors](https://open.manus.ai/docs/connectors#all-available-connectors) for IDs. Popular connectors: Gmail, Google Calendar, Notion)
    - `hideInTaskList` (boolean)
    - `createShareableLink` (boolean)
    - `taskId` (for multi-turn tasks)
    - `locale` (e.g., 'en-US', 'zh-CN')
- `list_tasks` - List tasks with filtering, pagination, and sorting
  - Optional:
    - `after` (string) - Cursor for pagination (ID of last task from previous page)
    - `limit` (number) - Max number of tasks to return (1-1000, default: 100)
    - `order` (asc/desc) - Sort direction (default: desc)
    - `orderBy` (created_at/updated_at) - Sort field (default: created_at)
    - `query` (string) - Search term to filter by title and body content
    - `status` (array) - Filter by status: pending, running, completed, failed
    - `createdAfter` (number) - Filter tasks created after Unix timestamp
    - `createdBefore` (number) - Filter tasks created before Unix timestamp
- `get_task` - Get detailed information about a specific task
  - Required: `task_id`
- `update_task` - Update task metadata (title, sharing settings, visibility)
  - Required: `task_id`
  - Optional: `title`, `enableShared`, `enableVisibleInTaskList`
- `delete_task` - Permanently delete a task
  - Required: `task_id`

### File Management Tools
- `create_file` - Create file record and get presigned S3 upload URL
  - Required: `filename`
  - Returns: `file_id` and `upload_url` for uploading file content
- `upload_file` - Upload file content to presigned URL
  - Required: `filepath` (absolute path to local file), `upload_url` (from create_file response)
  - Uploads the file to S3 storage
- `list_files` - List the 10 most recently uploaded files
  - No parameters required
- `get_file` - Get file details including status and metadata
  - Required: `file_id`
- `delete_file` - Delete file from storage (removes both record and S3 file)
  - Required: `file_id`

### Webhook Management Tools
- `create_webhook` - Register webhook for real-time task event notifications
  - Required: `url` (webhook endpoint URL)
  - Returns: `webhook_id`
- `delete_webhook` - Remove a previously registered webhook
  - Required: `webhook_id`

## Prerequisites

Before using this server, you need:
1. A Manus account with API access
2. A Manus API key (generate one from your account settings at https://open.manus.ai/)

## Development

Install dependencies:
```bash
pnpm install
```

Build the server:
```bash
pnpm run build
```

For development with auto-rebuild:
```bash
pnpm run watch
```

## Installation

### Environment Setup

Set your Manus API key as an environment variable:
```bash
export MANUS_API_KEY="your-api-key-here"
```

Optionally, set a custom API base URL (defaults to `https://api.manus.ai`):
```bash
export MANUS_API_BASE_URL="https://api.manus.ai"
```

### Claude Desktop Integration

To use with Claude Desktop, add the server config:

On MacOS: `~/Library/Application Support/Claude/claude_desktop_config.json`
On Windows: `%APPDATA%/Claude/claude_desktop_config.json`

```json
{
  "mcpServers": {
    "manus": {
      "command": "node",
      "args": ["/absolute/path/to/manus-mcp/build/index.js"],
      "env": {
        "MANUS_API_KEY": "your-api-key-here"
      }
    }
  }
}
```

**Important:** Replace `/absolute/path/to/manus-mcp` with the actual path to your installation, and `your-api-key-here` with your actual Manus API key.

### Debugging

Since MCP servers communicate over stdio, debugging can be challenging. We recommend using the [MCP Inspector](https://github.com/modelcontextprotocol/inspector), which is available as a package script:

```bash
pnpm run inspector
```

The Inspector will provide a URL to access debugging tools in your browser.

## Usage Examples

Once the server is running in Claude Desktop, you can interact with Manus through natural language:

### Creating a Simple Task
```
"Create a Manus task to analyze the quarterly sales data and generate insights"
```

### Creating a Task with Attachments
```
"Create a Manus task with prompt 'Analyze this document' and attach the file with ID file_123"
```

### Creating a Task with Connectors
```
"Create a Manus task to check my recent emails and summarize them, using the Gmail connector with UUID [connector-uuid]"
```

Note: Find connector UUIDs at https://open.manus.ai/docs/connectors#all-available-connectors. Popular connectors include Gmail, Google Calendar, and Notion.

### Listing and Getting Tasks
```
"Show me all my Manus tasks"
"List my completed tasks"
"Show me tasks created in the last 24 hours"
"Search for tasks containing 'sales report'"
"List my 50 most recent tasks sorted by update time"
"Get details for task task_abc123"
```

### File Upload Workflow
```
1. "Create a file record for report.pdf"
   (Returns file_id and upload_url)

2. "Upload the file at /path/to/report.pdf to the upload URL"
   (Uploads file to S3)

3. "List my uploaded files"
   (Shows all recent files including the new one)
```

### Managing Files
```
"Show me my uploaded files"
"Get details for file file_xyz789"
"Delete file file_xyz789"
```

### Working with Webhooks
```
"Create a webhook at https://my-app.com/webhook to receive task notifications"
"Delete webhook webhook_123"
```

## API Reference

For detailed information about the Manus API, visit the official documentation:
- API Documentation: https://open.manus.ai/docs
- API Reference: https://open.manus.ai/docs/api-reference
- Quickstart Guide: https://open.manus.ai/docs/quickstart

## License

This project is part of the Manus ecosystem. Please refer to Manus's terms of service for API usage guidelines.