mcp-server-chart is a server based on the Model Context Protocol (MCP), developed by the AntV team and built with TypeScript. It is used to generate various charts through MCP tools and is suitable for chart generation and data analysis scenarios. It also supports use in Dify.
Main capabilities: It currently supports 26+ chart types, including area chart, bar chart, box plot, column chart, district map, dual-axis chart, fishbone diagram, flowchart, funnel chart, histogram, line chart, liquid chart, mind map, network graph, organization chart, path map, pie chart, pin map, radar chart, sankey diagram, scatter chart, treemap, Venn diagram, violin plot, word cloud, spreadsheet (including pivot table), etc. Among them, geographic visualization charts (district map, path map, pin map) use Amap services and currently only support map generation within China.
Usage: The server can be run via SSE or Streamable transport. It can be used in desktop applications (such as Claude, VSCode, Cline, Cherry Studio, Cursor, etc.) by adding an MCP server configuration; it can also be used on platforms such as aliyun, modelscope, glama.ai, smithery.ai via HTTP and SSE protocols. If using an AI IDE that supports skills (such as Claude Code), you can use the chart-visualization skill to automatically select the best chart type and generate visualizations. The skill can be obtained from https://github.com/antvis/chart-visualization-skills Add it. Installation methods include installing the package globally and then running the server, or deploying with Docker (enter the docker directory and deploy with docker-compose). At runtime, CLI options can be used; view command options with -H.
Environment variables and configuration: Supports VIS_REQUEST_SERVER (custom privately deployed chart generation service), SERVICE_ID (generate a service identifier to view chart generation records), DISABLED_TOOLS (disable specific chart generation tools, suitable when there are compatibility issues between tools and the MCP client or when available features need to be restricted).
Private deployment: A free chart generation service is provided by default; users with private deployment needs can customize the chart generation service through VIS_REQUEST_SERVER. You can use AntV's GPT-Vis-SSR project to deploy an HTTP service in a private environment, then pass in the URL address through an environment variable. The request parameters will be passed to GPT-Vis-SSR for rendering, and the returned object contains success (whether the chart was generated successfully), resultObj (chart image URL), and errorMessage (error message on failure). The private deployment solution currently does not support geographic visualization chart generation, including the three tools geographic-district-map, geographic-path-map, and geographic-pin-map.
Generation records: By default, users need to save the results themselves. A service for viewing chart generation records is also provided, which requires the user to generate a service identifier and configure the SERVICE_ID environment variable. You can scan the mini program with Alipay to generate a personal service identifier. After configuration, restart the AI client application. After successful generation, you can view the generation records on the "My Maps" page of the mini program.
Development and running: Steps such as installing dependencies, building the server, and starting the MCP server (supporting SSE and Streamable transport) are described in the repository.