Grid82
grid82.comJoin the waitlist
DevelopersTools and Code Mode

Tools and Code Mode

How Grid82 generates MCP tools from its route registry, tool annotations, pagination, intentional exclusions, and Code Mode sandboxes.

Every Grid82 MCP tool mirrors an operation in the REST API, generated from the exact same route registry. Adding an endpoint ships the matching MCP tool and CLI command on the same day.

Tool naming and annotations

Operation IDs convert dots to _: records.list becomes records_list, schema.get becomes schema_get, and rules.simulate becomes rules_simulate. Every App API and Builder API reference page displays its exact MCP tool name.

Each tool carries standard MCP annotations so clients know when to prompt before acting:

AnnotationMeaning
readOnlyHintOperation only reads data or metadata
destructiveHintDeletes records or resources, or mutates many records at once (such as records_delete_many or sql_execute)
idempotentHintCalling twice with the same inputs produces the same state

Pagination and errors

  • Cursors. Paged list tools return { data, meta }. Keep passing meta.nextCursor as cursor while meta.hasMore is true, and narrow queries with filter or where first to conserve context window tokens.
  • Tool errors. Permission refusals and validation errors return as MCP tool results (isError: true) carrying the structured code and message, rather than transport failures.

Operations intentionally excluded from MCP

OperationWhy it is not an MCP toolUse instead
files.uploadMCP tools pass JSON; uploads stream raw file bytesUpload bytes via REST or grid82 files upload, then attach the returned file descriptor with records_update
Creating or revoking keysAn agent credential must not be able to mint persistent successor tokensCreate and revoke API keys in a browser session
Password setup linksGrants account sign-in authorityBuilders generate links from the Studio UI or authenticated session
Add-on and top-up checkoutPurchasing plans or credit packs requires an interactive human browser sessionUse the Studio Billing page in a browser

Code Mode (/mcp/code)

When a task requires filtering, joining, or batching dozens of calls, connect an agent to /mcp/code (https://{suite}.grid82.app/mcp/code or https://studio.grid82.app/mcp/code). Code Mode replaces individual operation tools with two tools:

  1. search: Filters the caller’s masked OpenAPI document using JavaScript expressions (detail: "compact" returns a lightweight index first; filtered queries return full parameter schemas).
  2. execute: Runs one TypeScript/JavaScript snippet inside an isolated JavaScript sandbox that authenticates calls as you with zero outbound internet access.
Code Mode sandbox limitValue
Execution timeout30 seconds
API requests per run100
Script source size64 KB
Return payload size256 KB

Large page writes

Writing a large Interface page via MCP sends every character of TSX source through model tokens. For substantial page refactors, update code via PUT .../pages/{pageId}/code (grid82 pages code-set --code @Page.tsx).

Use these docs with your AI tools

An AI agent can read this documentation directly. You do not need an account or an API key. Everything here is public and read-only.

Query these docs via MCP

Recommended

Add this server to Claude, Claude Code, Cursor, Mistral, or any tool that supports MCP. Your agent can then search Grid82 documentation and read it in full, instead of answering from memory.

https://grid82.com/docs/mcp
  • searchFind the passages that answer a question.
  • fetchRead one page in full, as Markdown.
  • list_pagesSee every page in this documentation.

Query these docs over HTTP

The same tools also work as plain web requests. Use this for scripts, or for any tool that does not support MCP. There is one endpoint per tool. Arguments go in the query string, and the answer comes back as JSON.

https://grid82.com/docs/api/docs/search?query=custom+domain

Read the OpenAPI description. It is built from the same definitions as the tools, so it always matches what the endpoints do.

Read these docs as Markdown

Add .md to any page URL to get its Markdown source. You can also send the headerAccept: text/markdown to the page URL itself.

To read the whole documentation in one file, open llms-full.txt. For a short index of every page, open llms.txt.