Superset MCP Server

Superset MCP Server

Enables AI to create and manage Apache Superset dashboards, including adding charts and native filters from datasets.

Category
访问服务器

README

Superset MCP Server

MCP server that exposes Apache Superset as tools so the AI can build dashboards from Cursor: create dashboards, add charts from datasets (e.g. Snowflake views), and set filters from your instructions.

Sharing with the team

Best approach: Each colleague does a one-time setup on their machine with their own Superset credentials. No credentials are stored in the repo.

  • Each person: Follows TEAM_SETUP.md once: clone → pip install -e . → get their own auth (see GET_TOKEN.md) → add Superset MCP in Cursor with their path and credentials → reload MCP.

Prerequisites

  • Python 3.10+
  • A running Superset instance with API enabled
  • In Superset: at least one database (e.g. Snowflake) and datasets (tables/views) that you want to use in dashboards

Setup

1. Install dependencies

From the directory that contains mcp_superset (the folder can live anywhere):

cd <path-to-mcp_superset>
pip install -e .
# or with uv:
uv pip install -e .

2. Environment variables

Use one of: (A) session cookie, (B) access token, or (C) username/password. Set in Cursor MCP config or your shell:

Variable Required Description
SUPERSET_URL Yes Base URL of Superset (e.g. https://superset.yourcompany.com)
Option A – Session cookie (browser / Google login, no JWT)
SUPERSET_SESSION_COOKIE Yes* Cookie string, e.g. session=<value>. Get from DevTools -> Application -> Cookies -> your Superset URL -> copy session value. See GET_TOKEN.md.
Option B – Access token
SUPERSET_ACCESS_TOKEN Yes* JWT from browser. Optional: SUPERSET_REFRESH_TOKEN.
Option C – Username/password
SUPERSET_USERNAME Yes API user (e.g. admin)
SUPERSET_PASSWORD Yes Password for that user
SUPERSET_AUTH_PROVIDER No Auth provider; default db

Session cookie (when you only have cookie, no Authorization header):
See GET_TOKEN.md: log in to Superset, F12 -> Application -> Cookies -> your Superset URL -> copy the session cookie value, then set SUPERSET_SESSION_COOKIE=session=<paste value>. Session expires when you close the browser or after some time; get a fresh cookie when you get 401s.

Do not commit credentials. Use Cursor’s MCP env or a local .env that is gitignored.

3. Add the server in Cursor

  1. Open Cursor Settings → Features → MCP.
  2. Click Add new MCP server.
  3. Choose Run a script / command (stdio).
  4. Configure:

Option A – Use your Python (recommended)

  • Command:
    python (or the full path to your Python / venv, e.g. <path-to-mcp_superset>\.venv\Scripts\python.exe)
  • Arguments:
    -m mcp_superset.server
  • Working directory:
    Full path to the mcp_superset folder (e.g. c:\Bio\cursor_projects\mcp_superset)
  • Env (add here or in Cursor MCP env):
    SUPERSET_URL, SUPERSET_USERNAME, SUPERSET_PASSWORD

Option B – Global install

If you installed the package globally:

  • Command:
    mcp-server-superset
  • Env: same as above.

Option C – JSON config (Cursor MCP)

If your Cursor MCP is configured via JSON, add something like:

{
  "mcpServers": {
    "superset": {
      "command": "python",
      "args": ["-m", "mcp_superset.server"],
      "cwd": "C:\\path\\to\\mcp_superset",
      "env": {
        "SUPERSET_URL": "https://superset.yourcompany.com",
        "SUPERSET_USERNAME": "your_user",
        "SUPERSET_PASSWORD": "your_password"
      }
    }
  }
}

Replace C:\\path\\to\\mcp_superset with the actual path where you placed the folder.

Restart Cursor or reload MCP after adding the server.

Tools exposed to the AI

Tool Purpose
superset_list_databases List Superset databases (e.g. Snowflake connection)
superset_list_datasets List datasets; optional database_id, search
superset_get_dataset Get dataset by id (columns, metrics) for building charts
superset_list_dashboards List dashboards; optional search
superset_get_dashboard Get dashboard by id or slug (layout, metadata, filters)
superset_create_dashboard Create empty dashboard; then add charts and filters
superset_update_dashboard Update dashboard (title, slug, published)
superset_delete_dashboard Delete a dashboard by id
superset_update_dashboard_filters Set native filters (JSON array of filter config)
superset_add_chart_to_dashboard Add chart to dashboard with position (x, y, width, height)
superset_list_charts List charts; optional search
superset_get_chart Get chart by id
superset_create_chart Create chart (dataset_id, viz_type, slice_name, params JSON)
superset_update_chart Update chart (slice_name, params, description)
superset_delete_chart Delete a chart by id
superset_get_dashboard_charts List charts on a dashboard

Workflow: Snowflake views → Superset dashboard

  1. You tell the AI what you want: e.g. “Dashboard for view X, filter by date and region, bar chart and table.”
  2. AI uses Snowflake MCP to inspect views/tables (e.g. list_objects, run_snowflake_query).
  3. AI uses Superset MCP to:
    • superset_list_datasets to find the dataset that points at that view
    • superset_get_dataset to see columns
    • superset_create_dashboard and then superset_create_chart for each chart
    • superset_add_chart_to_dashboard to place them
    • superset_update_dashboard_filters to add the filters you asked for
  4. You open the dashboard in Superset and refine if needed.

Native filters (dashboard filters)

superset_update_dashboard_filters takes a JSON string that is an array of filter objects. Each object typically has:

  • id: unique string id for the filter
  • name: label shown in the UI
  • filterType: e.g. filter_select, filter_time, filter_timegrain
  • targets: which charts/columns the filter applies to
  • defaultDataMask: default value
  • scope: scope of the filter

The AI can build this from your instructions (e.g. “add a date range and a region dropdown”) by following Superset’s native filter schema.

Chart params

For superset_create_chart, params is a JSON string object. Contents depend on viz_type, for example:

  • table: metrics, groupby, order_desc, row_limit, etc.
  • big_number: metric, compare_lag, etc.
  • line / bar: metrics, groupby, time_range, order_desc, etc.

The AI should use superset_get_dataset to see available columns/metrics and build valid params.

Run the server locally (optional)

cd mcp_superset
set SUPERSET_URL=https://...
set SUPERSET_USERNAME=admin
set SUPERSET_PASSWORD=...
python -m mcp_superset.server

The server uses stdio; Cursor will start it automatically when the tools are used.

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选