Skip to content
Skill

Document

Author, edit and copy Metabase documents with embedded cards via the mb CLI

Document is an open-source agent skill for files and documents. It is available on Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose.

Scripts
None
Platforms
Claude Code, Codex, Cursor
GitHub stars
20
Last commit
License
AGPL-3.0
Listing updated

Similar skills

About Document

This skill teaches an agent to build and maintain Metabase documents, the rich-text pages that mix prose with saved questions and links to other Metabase entities. It explains the TipTap/ProseMirror JSON body format and the inventory of standard and Metabase-specific nodes, including card embeds, smart links, flex containers and resizable wrappers.

The skill covers the mb command verbs for listing, fetching, creating, updating, copying and archiving documents. It sets out the rule that every id-bearing node needs a UUID, which the agent mints with mb uuid, and it gives a read-edit-write loop so existing bodies are changed safely without losing node ids. It also shows how to create new cards inline with a document using negative ids and a cards map.

It expects the mb CLI to be installed and configured with a profile, and it points to other skills for querying, visualization and shared core conventions.

When your agent uses it

Author and edit Metabase documents via `mb` — the TipTap (ProseMirror) JSON body shape, the node-type inventory (paragraphs, headings, lists, plus the Metabase-custom `cardEmbed` / `smartLink` / `flexContainer` / `resizeNode`), the per-node-type `_id` requirement, embedding existing or brand-new cards, and the list/get/create/update/copy/archive verbs. Load when the user touches documents — "create a document", "add a card to a document", "edit a document", "copy a document", "list documents", or anything `mb document …`.

From the skill's SKILL.md. Your agent reads this description to decide when to load the skill.

What it can access

From a static check of its 1 file (10 KB) on GitHub on 4 December 2026. Nothing was run. Read the files before you install a skill: it can tell your agent to run anything its tools allow.

Check another skill before you install it.

Install

Copy the skill folder to ~/.claude/skills/document to use it in all your projects:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/metabase/metabase-cli.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/document &&
cp -R "$tmp/packages/cli/skill-data/document" ~/.claude/skills/document &&
rm -rf "$tmp"

For one project only, put the folder in .claude/skills/document inside it instead.

Claude Code docs on skills

Copy the skill folder to ~/.agents/skills/document to use it in every repository:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/metabase/metabase-cli.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/document &&
cp -R "$tmp/packages/cli/skill-data/document" ~/.agents/skills/document &&
rm -rf "$tmp"

For one repository only, put the folder in .agents/skills/document inside it instead.

Codex docs on skills

Copy the skill folder to ~/.cursor/skills/document to use it in every project:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/metabase/metabase-cli.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/document &&
cp -R "$tmp/packages/cli/skill-data/document" ~/.cursor/skills/document &&
rm -rf "$tmp"

For one project only, put the folder in .cursor/skills/document inside it instead.

Cursor docs on skills

Run in a terminal (add --scope workspace to install it for the current workspace only):

gemini skills install https://github.com/metabase/metabase-cli.git --path packages/cli/skill-data/document

Or copy the folder to ~/.gemini/skills/document yourself.

Gemini CLI docs on skills

For GitHub Copilot in VS Code, copy the skill folder to ~/.copilot/skills/document:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/metabase/metabase-cli.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/document &&
cp -R "$tmp/packages/cli/skill-data/document" ~/.copilot/skills/document &&
rm -rf "$tmp"

For one project only, put the folder in .github/skills/document inside it instead.

VS Code docs on skills

Get the folder:

git clone --depth 1 https://github.com/metabase/metabase-cli.git

Then copy metabase-cli/packages/cli/skill-data/document into your agent's skills folder as document. Agents that support SKILL.md read one folder per skill.

The SKILL.md format

What it does

Document body format
Explains the TipTap JSON tree and the standard text nodes, marks and lists a document can contain.
Metabase custom nodes
Covers card embeds, resizable wrappers, flex containers, supporting text and smart links.
Node id handling
Describes which node types need UUID _id attributes and how to mint them with mb uuid.
Card embedding
Shows how to reference existing saved questions inside a document body.
Inline card creation
Describes creating new cards atomically alongside a document using negative ids.
Document lifecycle commands
Covers list, get, create, update, copy and archive verbs, including unarchiving.

Good for

  • Create a weekly report document with headings and an embedded saved question
  • Add an existing card to a document under a section heading
  • Edit the text of a document without losing its embedded cards
  • Copy a document into another collection with its saved cards
  • Build a new document and its questions in one step
  • Archive or unarchive an old document

Document FAQ

What does the skill need to run?

It uses the mb CLI with a configured profile, and the body is authored as TipTap JSON, with mb uuid used to create node ids.

Does updating a document replace its whole body?

Yes. Document update replaces the entire body, so the skill recommends reading the current body, editing it and writing the whole thing back.

Which nodes need an _id?

Paragraphs, headings, code blocks, ordered and bullet lists, blockquotes, card embeds and supporting text need a non-empty UUID _id.

Can a document create new cards?

Yes, new cards can be defined in a cards map and referenced by negative ids, and the server creates them along with the document.

How do I install Document in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/document to use it in all your projects, or to .claude/skills/document in one project.

Does Document run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

Which AI agents can use Document?

Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose. Each reads skills in the SKILL.md format from its own folder; the install steps on this page list them.

What are the best alternatives to Document?

The closest alternatives to Document are Core, Metabase CLI, Metadata, Mbql and Dashboard.

Where this comes from

  • Description: from the skill's own SKILL.md.

More from metabase/metabase-cli

  1. Guides an agent to write end-to-end tests that run the built CLI against real Metabase

    • Open source
    • 20 GitHub stars
    • Developer tools
  2. Writes unit and Playwright tests for a Metabase data app with mocked queries and actions

    • Open source
    • 20 GitHub stars
    • Developer tools
  3. Plans fixtures, expectations and coverage for testing a transform's logic on known rows

    • Open source
    • 20 GitHub stars
    • Analytics and data
  4. Guides an agent to add a Metabase API resource across client, CLI and e2e tests

    • Open source
    • 20 GitHub stars
    • Analytics and data
  5. Sweeps a whole repository for architectural drift using parallel read-only review passes

    • Open source
    • 20 GitHub stars
    • Developer tools
  6. Runs a strict end-of-task review that flags architectural drift before work is marked done

    • Open source
    • 20 GitHub stars
    • Developer tools