Skip to main content
Glama
questdb

mcp-server-questdb

Official

add_cell

Add a SQL or markdown cell to a QuestDB notebook, optionally running read-only queries to return per-statement success status while skipping writes.

Instructions

Append a cell to the notebook. Returns the new cell id and, if run=true, a per-query status array with the same semantics as run_cell (reads run in parallel; an invalid statement is skipped with its error). Writes are never auto-run: a cell containing DDL/DML comes back { ran: false, skipped: true }. You never see query rows or column data. Set type:"markdown" to add a prose cell instead of a SQL cell — its sql field then carries the markdown source, it is rendered (never executed), and run is ignored.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
runYesIf true, run the cell immediately after inserting. Response then includes `ran` (true iff every statement succeeded), `queryCount`, and `results: string[]` — one entry per `;`-separated statement, each `"success"`, `"cancelled"`, or `"ERROR: <message>"`. The order matches the cell's SQL. Still no row data. Pass null to skip. Running is DQL-only: a cell containing DDL/DML (INSERT/UPDATE/CREATE/DROP/...) is added but NEVER executed — the response gets `{ ran: false, skipped: true, note: <reason> }`. Markdown cells (type:"markdown") are likewise never executed. Take consent from the user, then call run_cell explicitly.
sqlYesSQL for the cell. May contain multiple statements separated by `;`. In draw mode, multi-statement cells overlay series on a single chart: the first query's timestamp column is the x-axis anchor, subsequent queries contribute additional numeric series merged on the time axis. For a markdown cell (type:"markdown"), this is the markdown source text instead of SQL.
typeYesCell kind. "markdown" creates a rendered prose cell that is never executed (`run` is ignored). null/omitted = "sql".
buffer_idYes
after_cell_idYesInsert after this cell id; pass null to append to the end.

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv0.3.0

TDQS

A4.5/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries full disclosure burden and does so thoroughly. It reveals return behavior (new cell id, per-query status array), execution semantics (invalid statements skipped, reads run in parallel), and safety caveats (DDL/DML never auto-run, no row/column data returned). This goes well beyond a simple 'adds a cell' statement.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is dense and front-loaded, starting with the action and return value before covering important caveats. It is fairly long, but the length is justified given the complexity of run semantics and markdown behavior. Every sentence adds meaningful information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 5-parameter mutation tool with no output schema, the description covers return values, execution behavior, and non-execution cases well. The main gap is buffer_id, which is left entirely to context, and error conditions or permission requirements are not mentioned. Overall, it is near-complete with minor omissions.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 80%, but buffer_id is undocumented in both schema and description. The description enriches sql (multi-statement chart overlay, markdown source), run (parallel reads, invalid statement handling), and type (markdown render-only). It does not add meaning for buffer_id or after_cell_id, though those are partly covered by the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the core operation: 'Append a cell to the notebook.' It differentiates from sibling tools like update_cell, run_cell, and delete_cell by explicitly covering SQL vs markdown cell creation. The 'append' wording is slightly narrow given after_cell_id insertion, but the action remains unambiguous.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives concrete conditional guidance: use type:'markdown' for prose cells, and explicitly warns that DDL/DML and markdown cells are never auto-run, advising 'Take consent from the user, then call run_cell explicitly.' It references run_cell semantics but does not explicitly contrast add_cell with update_cell or delete_cell, so alternative selection is not fully exhaustive.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/questdb/mcp-server-questdb'

If you have feedback or need assistance with the MCP directory API, please join our Discord server