qwen-mcp
This server integrates Alibaba Cloud's Qwen AI models into MCP-compatible clients, offering three tools:
🖼️ Vision Understanding (
qwen_vision): Analyze images usingqwen3-vl-plus. Supports local file paths or HTTP(S) URLs, with automatic compression, configurable detail levels (low/high), and adjustablemax_tokens(up to 8192).🔍 Real-time Web Search (
qwen_search): Perform live internet searches viaqwen-plus's nativeenable_search. Returns current information with source citations; accepts a query and optionalmax_tokens.💬 General Chat (
qwen_chat): Engage in text-based conversations withqwen-plusfor summarization, translation, rewriting, code generation, and more.
Integrates with Alibaba Cloud DashScope to provide access to Qwen models for vision understanding, live web search, and general chat.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@qwen-mcpsearch the web for the latest updates on artificial intelligence"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Reasonix Qwen MCP Server
专为 Reasonix 设计的 MCP 插件:把阿里云百炼(DashScope)的通义千问(Qwen)模型接入 Reasonix,提供视觉理解、联网搜索、通用对话三个工具。 A Qwen MCP server built for Reasonix: vision understanding, real web search and chat via Alibaba Cloud DashScope.
一个轻量 Node.js MCP server,提供三个即用工具:视觉理解(qwen3-vl-plus)、真实联网搜索(enable_search)、通用文本对话(qwen-plus)。
A lightweight Node.js MCP server exposing three ready-to-use tools: vision (qwen3-vl-plus), real web search (enable_search), chat (qwen-plus).
📖 详细中文使用手册:使用说明.md
✨ 功能特性 / Features
工具 / Tool | 说明 / Description | 模型 / Model |
| 视觉理解:传本地图片路径或 http(s) 图片 URL,让模型"看图"并回答 |
|
| 联网搜索:实时检索最新信息,返回带来源的综合回答 |
|
| 通用文本对话(总结 / 翻译 / 改写 / 写代码等) |
|
关键特性:
🖼️ 视觉提速:本地图片自动用
sharp预压缩(>300KB 或分辨率 >1568px 才压缩,小图零损耗),网络图片先下载压缩再送模型(下载限 10MB);
🔍 真联网:走百炼原生接口的
enable_search(OpenAI 兼容端点会静默忽略该参数,详见下方"工作原理");⚡ 生成长度可控:
max_tokens参数随时可调,快慢由你决定;🔐 Key 安全:支持环境变量
DASHSCOPE_API_KEY或本地config.json(已被.gitignore忽略,不会入库)。
Related MCP server: MCP Server with OpenAI Integration
📦 环境要求 / Requirements
Node.js ≥ 20.9(内置
fetch)阿里云百炼(DashScope)API Key:https://bailian.console.aliyun.com/
🚀 快速开始 / Quick Start
🤖 Reasonix 用户:无需手动配置——克隆/下载本项目后,在 Reasonix 中打开项目目录,直接让 Reasonix "安装并配置这个 MCP 插件",它会自动注册、连接并引导你填写 API Key。
1. 安装 / Install
git clone https://github.com/HUAN425/reasonix-qwen-mcp.git qwen-mcp
cd qwen-mcp
npm install2. 配置 / Configure
二选一:
方式 A:环境变量(推荐)
# Windows PowerShell
$env:DASHSCOPE_API_KEY = "sk-..."
# macOS / Linux
export DASHSCOPE_API_KEY="sk-..."方式 B:配置文件
cp config.example.json config.json # Windows: copy config.example.json config.json
# 然后编辑 config.json 填入 apiKeyconfig.json 支持的自定义项:
{
"apiKey": "sk-...", // 必填;环境变量优先
"baseUrl": "https://dashscope.aliyuncs.com/compatible-mode/v1", // 可选;仅影响对话与视觉,联网搜索固定使用国内原生端点
"visionModel": "qwen3-vl-plus", // 可选,视觉模型
"searchModel": "qwen-plus", // 可选,搜索模型
"chatModel": "qwen-plus" // 可选,对话模型
}注意:修改
config.json后需重启 MCP server 生效(配置有进程内缓存)。
3. 注册到 MCP 客户端 / Register with your client
⚠️ 兼容性说明:本项目目前仅在 Reasonix 上实际测试使用过。技术实现基于标准 MCP 协议(stdio 传输),理论上适用于其他支持 MCP 的客户端(如 Claude Desktop、Cursor 等),但尚未在它们上面实测验证。如在其他客户端遇到问题,欢迎反馈。
Claude Desktop — claude_desktop_config.json:
{
"mcpServers": {
"qwen-mcp": {
"command": "node",
"args": ["/absolute/path/to/qwen-mcp/server.js"]
}
}
}项目级 .mcp.json(Reasonix 等支持):
{
"mcpServers": {
"qwen-mcp": {
"command": "node",
"args": ["/absolute/path/to/qwen-mcp/server.js"]
}
}
}4. 使用 / Usage
三个工具会以 mcp__qwen-mcp__qwen_vision 等名称出现在你的客户端里。
工具 | 参数 | 说明 |
|
|
|
|
| 返回头标注 |
|
| 纯文本对话 |
⚙️ 工作原理 / How it works
对话与视觉:调用 DashScope OpenAI 兼容端点
POST /compatible-mode/v1/chat/completions(多模态走image_url+ base64 data URL);联网搜索:调用百炼原生端点
POST /api/v1/services/aigc/text-generation/generation并携带enable_search: true。⚠️ 实测:OpenAI 兼容端点会静默忽略
enable_search(返回模型自身知识而非实时结果),所以搜索必须走原生端点。
🧪 测试 / Test
npm test # 等价于 node test-handshake.js(MCP 握手 + 工具列表,无需 API Key)📁 项目结构 / Structure
qwen-mcp/
├── server.js # MCP server 主程序
├── config.example.json # 配置模板(复制为 config.json 使用)
├── package.json
├── .gitignore
└── test-handshake.js # 握手自测脚本🔒 安全说明 / Security
config.json、node_modules/已在.gitignore中,不会提交到仓库;请勿将任何真实 API Key 写入会进入版本库的文件;
⚠️
qwen_vision可读取本机任意路径的图片文件并发送至阿里云,请仅在可信环境使用;网络图片下载上限 10MB,超限自动回退原 URL。
📄 许可证 / License
⚠️ 免责声明 / Disclaimer
本项目与阿里云无官方关联。模型能力、价格与接口行为以百炼官方文档为准。
Available Tools
3 toolsqwen_chatA
与通义千问文本模型进行普通对话(不联网),用于总结、改写、翻译、代码生成等通用任务
| Name | Required | Description | Default |
|---|---|---|---|
| message | Yes | 要发送给模型的消息内容 |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden. It discloses the key behavioral trait of not being connected to the internet, which is a critical limitation for a chat model. It does not discuss other behaviors like statelessness or rate limits, but for a simple single-message chat tool, this is adequate.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The entire description is a single well-structured sentence that front-loads the core purpose ('ordinary conversation'), then adds the key constraint ('not connected to internet'), and ends with concrete examples. Every word contributes value, and there is no redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the simplicity of the tool (one required parameter, no output schema, no annotations), the description is fully sufficient. It explains what the tool does, provides examples, and clarifies the offline nature, which is all an agent needs to decide when and how to invoke it.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema already fully describes the 'message' parameter (the message content to send), so the schema coverage is 100%. The tool description adds context about the kinds of tasks the message can be used for, but it does not enrich the parameter semantics beyond what the schema provides.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states that this tool performs ordinary conversations with the Tongyi Qianwen text model, specifically without internet access. It lists common use cases (summarizing, rewriting, translating, code generation) and distinguishes itself from sibling tools like qwen_search (internet-connected) and qwen_vision (vision-based) by specifying 'text model' and 'not connected to internet'.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for general text tasks that do not require internet access, which sets expectations. However, it does not explicitly mention when to use qwen_chat over alternatives (e.g., 'use qwen_search when internet is needed'), so the guidance is implied rather than explicit.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
qwen_searchA
用通义千问模型开启联网搜索(enable_search),检索最新信息并返回带来源引用的综合回答;适合时效性问题、新闻、事件、产品信息等
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | 要检索的问题或关键词 | |
| max_tokens | No | 回答最大 token 数(默认 2000) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden. It discloses that the tool performs web search, returns answers with source citations, and is appropriate for current information. This is transparent for a read-only search tool, though it omits details about error handling, rate limits, or citation format specifics.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, well-structured sentence that front-loads the core function ('use Qwen to enable web search') followed by the return behavior and suitable use cases. There is no wasted wording, and the semicolon effectively separates the what from the when.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple search tool with two parameters and no output schema, the description is complete: it explains the purpose, mentions the return format (comprehensive answer with citations), and outlines use cases. It does not mention sibling alternatives explicitly, but all other essential context is present.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100% with both 'query' and 'max_tokens' documented in the schema. The description does not add additional parameter semantics beyond what the schema already provides, so the baseline score of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool uses the Tongyi Qianwen model to enable web search, retrieves the latest information, and returns a comprehensive answer with source citations. This distinguishes it from sibling tools qwen_chat and qwen_vision by emphasizing its search capability and suitability for time-sensitive topics.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explicitly lists suitable use cases: 'suitable for time-sensitive questions, news, events, product information, etc.' This gives clear context for when to use the tool. However, it does not provide explicit when-not-to-use guidance or mention alternative tools, falling short of a full 5.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
qwen_visionA
用通义千问视觉模型 qwen3-vl-plus 理解一张图片(支持本地文件路径或 http(s) 图片 URL),并回答关于图片的问题
| Name | Required | Description | Default |
|---|---|---|---|
| image | Yes | 本地图片路径(绝对路径,或相对当前工作目录)或 http(s) 图片 URL | |
| detail | No | 视觉采样分辨率:low 更快更省,high 细节更清晰(默认 low) | |
| prompt | No | 关于图片的问题或指令;省略时默认要求模型简要描述(150 字内) | |
| max_tokens | No | 回答最大 token 数(默认 800;调低更快,调高更详细) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the burden. It adds useful context by naming the specific model and explaining the default prompt behavior (150-word description). However, it does not disclose potential error conditions, rate limits, or detailed return format, which leaves gaps given the absence of annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, well-structured sentence that front-loads the core purpose, model name, and input types. No redundant words, and it efficiently covers the essential information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the moderate complexity and the presence of a detailed schema, the description sufficiently covers the tool's purpose and default behavior. It does not have an output schema, but the phrase 'answer questions about the image' adequately implies the return value. Minor gaps remain on error handling/edge cases, so it isn't a perfect 5.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, with all four parameters already explained in the schema. The description adds the model name and overall purpose but does not enrich the understanding of individual parameters beyond what the schema provides. Hence a baseline score of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's function: using the qwen3-vl-plus vision model to understand an image and answer questions about it. It specifies both the verb (understand/answer) and resource (image), and by emphasizing image input it distinctly separates itself from sibling tools qwen_search and qwen_chat.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for image-related tasks by stating it handles local file paths or URLs and answers image questions. It gives a clear context but does not explicitly mention alternatives or exclusions; thus it stops short of a perfect score.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
3 tool updates
v1.0.0- First observed
qwen_chat - First observed
qwen_search - First observed
qwen_vision
TDQS
Scored across 3 tools
Each tool has a clearly distinct purpose: qwen_vision for image understanding, qwen_search for internet-connected queries, and qwen_chat for general text conversations. There is no overlap in functionality, so an agent can easily select the right tool.
All tools follow a consistent qwen_<capability> naming pattern, using lower_snake_case. The suffix clearly indicates the tool's function, making the naming predictable and uniform.
With 3 tools, the server is tightly scoped for its purpose of providing Qwen model access across vision, search, and chat. Each tool serves a distinct core need without unnecessary bloat.
The set covers the primary use cases for a language model server: image understanding, live information retrieval, and general text tasks. However, missing capabilities like audio processing or multi-turn conversation management are minor gaps that can be worked around.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
MCP server for Qwen Image 3 AI image generation
MCP server for AI dialogue using various LLM models via AceDataCloud
MCP server for GLM chat completions using Zhipu AI models via AceDataCloud
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
Related MCP Servers
- FlicenseBqualityDmaintenanceA lightweight MCP server that provides a unified interface to various LLM providers including OpenAI, Anthropic, Google Gemini, Groq, DeepSeek, and Ollama.6738-
- FlicenseBqualityDmaintenanceProduction-ready MCP server that integrates OpenAI API with extensible tool support, enabling dynamic plugin loading and knowledge search capabilities through multiple interfaces including CLI and browser UI.2-
- AlicenseAqualityDmaintenance这是一个面向中文圈的MCP服务器,将中国互联网常用能力(如地图、快递、RSS、B站等)封装为标准MCP工具,方便AI Agent安全调用。132MIT
- FlicenseNot gradedqualityBmaintenanceA lightweight Node.js MCP server with zero dependencies offering 9 built-in tools for system info, web fetching, GitHub search, file operations, shell execution, and key-value memory, enabling AI agents to perform these tasks via the Model Context Protocol.-