Skip to main content
Glama

Import from Notion

vault_import_notion
Idempotent

Import Notion pages and databases into a LoreDocs vault. Avoids re-imports via deduplication and supports resuming interrupted imports with a continuation token.

Instructions

Import Notion pages and databases into a LoreDocs vault.

Uses the import-once-and-own model: pages are fetched once and stored as LoreDocs documents. No live sync dependency.

Token is read from the NOTION_TOKEN environment variable or OS keychain -- it is NEVER passed as a parameter, so it never appears in MCP tool-call logs.

vault accepts a vault ID (stable across renames, preferred for automation) or a vault name (case-insensitive, for interactive use).

page_ids and database_ids accept Notion UUIDs (32 hex chars without dashes or 36 chars with dashes). Both null/omitted = rejected (at least one required).

continuation_token: opaque token from a prior call's return value. When provided, omit page_ids/database_ids/vault/checkpoint_file to resume. The token encodes the vault's primary-key UUID -- recreation under the same name invalidates the token.

Block depth is capped at LOREDOCS_NOTION_MAX_BLOCK_DEPTH (default 10). Pages hitting the cap are listed in truncated_pages in the return value.

MCP host cancellation may leave a partial checkpoint. Use the continuation_token from the last successful response to resume, or run a fresh import (deduplication prevents re-import of already-committed pages).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tagsNo
vaultYes
resumeNo
categoryNoreference
page_idsNo
max_pagesNo
database_idsNo
checkpoint_fileNo
continuation_tokenNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior5/5

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

Annotations already indicate a non-read-only, idempotent, non-destructive operation. The description adds substantial behavioral context: token is read from environment/keychain and never passed as a parameter, vault ID is stable vs name case-insensitive, UUID formats are specified, continuation token semantics and invalidation are explained, block depth cap produces truncated_pages, and MCP host cancellation may leave partial checkpoints with a resumption path. There is no contradiction with annotations; in fact, the deduplication note reinforces idempotency.

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 multi-paragraph and fairly long, but it is well structured. It opens with the core purpose and then dedicates paragraphs to token handling, vault identification, ID formats, continuation tokens, block depth cap, and cancellation behavior. Every sentence adds value, though a few details (e.g., 'Both null/omitted = rejected') could be phrased more succinctly. Overall, the length is appropriate for the tool's complexity.

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?

Given the tool's complexity—9 parameters, external token retrieval, resumption, cancellation handling, and block depth limits—the description covers a remarkable amount of context: security (token logging), input validation (UUID format), error handling (truncated_pages, partial checkpoints), and deduplication. It does omit explanations for several parameters and assumes familiarity with Notion IDs, but since an output schema exists, return values are likely documented elsewhere. This is nearly complete but has minor gaps.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must fully compensate. It explains vault, page_ids, database_ids, and continuation_token in detail, and checkpoint_file is referred to indirectly. However, four key parameters—tags, category, max_pages, and resume—are completely unexplained. For a 9-parameter tool, leaving 4+ parameters undocumented in both schema and description is a significant gap that forces the agent to guess.

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 tool's function: 'Import Notion pages and databases into a LoreDocs vault.' The verb 'import' is specific, and both the source (Notion pages/databases) and destination (LoreDocs vault) are named. This distinguishes it from sibling tools like vault_import_dir (local directory import) and vault_import_notion_setup (setup, not import).

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 provides clear context: it explains the import-once-and-own model and explicitly states 'No live sync dependency,' which serves as a when-not-to-use signal for users needing live sync. It also gives practical guidance on vault identification (ID vs name) and required page_ids/database_ids. However, it never names alternative tools (e.g., vault_import_dir or a hypothetical sync tool), so it stops short of fully explicit exclusions/alternatives.

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

Install Server

Other Tools

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/labyrinth-analytics/loredocs'

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