Skip to main content
Glama
nataliemona

Mode Analytics MCP Server

by nataliemona

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
MODE_API_TOKENYesAPI token (from a Member API key, ideally)
MODE_READ_ONLYNoSet to true to disable every tool that writes to Mode (overrides MODE_ENABLE_DELETES)false
MODE_WORKSPACEYesYour Workspace's username, as in app.mode.com/<workspace>/...
MODE_API_SECRETYesAPI secret
MODE_DISABLED_TOOLSNoComma-separated tool names to disable, e.g. create_report,update_query
MODE_ENABLE_DELETESNoSet to true to enable delete_report and delete_query. Off by defaultfalse

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": false
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}

Tools

Functions exposed to the LLM to take actions

NameDescription
list_data_sourcesA

List database connections in the Mode workspace.

Args: limit: Max number of results to return (default 50).

list_spacesB

List spaces (collections) in the Mode workspace.

Args: limit: Max number of results to return (default 50).

list_reportsA

List reports in a space. Archived reports are hidden unless include_archived.

Args: space_token: Space token (use list_spaces to find it). limit: Max number of results to return (default 50). include_archived: Also return archived reports (each has an archived flag).

search_reportsA

Search for reports by name or description across all spaces.

Mode's REST API has no native report-search endpoint, so this fans out across every space and filters client-side (case-insensitive substring match on name and description). May be slow on large workspaces. Archived reports are skipped unless include_archived.

Args: query: Search term to match against report names and descriptions. limit: Max number of results to return (default 50). include_archived: Also return archived reports (each has an archived flag).

get_reportC

Get a report's details and its queries (SQL).

Args: report_token: The report token.

list_report_runsC

List recent runs for a report.

Args: report_token: The report token. limit: Max number of runs to return (default 10).

create_reportA

Create a new report in a space, optionally with initial SQL queries.

This is a write operation — it creates a report visible to the workspace. If any queries fail to add, the report is still created; inspect queries_added and queries_failed in the result.

Args: space_token: Space to create the report in (use list_spaces to find it). name: Report name. description: Optional report description. queries: Optional list of queries to add. Each dict should have: - raw_query (str): The SQL text. - data_source_id (int): Data source ID (use list_data_sources). - name (str, optional): Query name.

update_reportB

Update a report's name, description, or move it to a different space.

This is a write operation — it modifies an existing report.

Args: report_token: The report to update. name: New report name. Omit to leave unchanged. description: New description. Omit to leave unchanged. space_token: Move report to this space. Omit to leave in current space.

archive_reportA

Archive a report, hiding it from view. Reversible with unarchive_report.

This is the safe alternative to delete_report.

Args: report_token: The report to archive.

unarchive_reportC

Restore an archived report.

Args: report_token: The report to unarchive.

add_queryB

Add a SQL query to an existing report.

This is a write operation — it adds a new query to the report.

Args: report_token: The report to add the query to. raw_query: SQL query text. data_source_id: Data source ID (use list_data_sources to find it). name: Optional query name.

update_queryA

Update a SQL query in a report.

This is a write operation — it modifies an existing query.

Args: report_token: The report containing the query. query_token: The query to update (use get_report to find query tokens). raw_query: New SQL text. Omit to leave unchanged. name: New query name. Omit to leave unchanged. data_source_id: New data source ID. Omit to leave unchanged.

get_run_resultsA

Get results from a report run. Defaults to the latest run.

Each query's rows are truncated to max_rows_per_query by default so a single call can't blow past the agent's context window. When a query was truncated, the result includes truncated: true and row_count: <total> so you know to re-call with a higher limit (or null) if you need all rows.

Args: report_token: The report token. run_token: Specific run token. If omitted, uses the latest succeeded run. max_rows_per_query: Max rows to return per query. Default 500. Pass null to fetch every row — can be very large (hundreds of MB) for dashboards with long time-series or wide cross-tabs.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

TDQS

A3.5/5.0

Scored across 13 tools

Disambiguation5/5

Each tool targets a distinct resource and action: reports (create/get/update/archive/unarchive/list/search), queries (add/update), and read-only listings (spaces, data sources, runs, run results). The archive/unarchive pair and list_reports vs search_reports are clearly distinguished by scope and description, leaving no real overlap.

Naming Consistency5/5

All 13 tools follow a strict snake_case verb_noun convention (create_report, update_query, list_spaces, get_run_results, etc.), including consistent use of the archive/unarchive antonym pair. No mixing of styles or verb conventions.

Tool Count5/5

At 13 tools, the set is well-scoped for a report/query management domain, with each tool earning its place and no redundant operations. It stays comfortably within the ideal 3-15 range.

Completeness4/5

Report lifecycle is well covered (create, get, update, list, search, archive, unarchive), plus query add/update and run inspection. Minor gaps remain: there is no delete_query to remove a query from a report, and no tool to trigger a report run even though run-result and run-list tools exist.

Maintenance

ActivityMaintained
ResponsivenessNo issues