Skip to main content
Glama

Import Anki deck package

import-deck-package
Destructive

Preview a trusted local .apkg file and import its reviewed contents into the active Anki collection, including note updates, deck presets, and scheduling when present.

Instructions

Previews a trusted local .apkg file and imports its reviewed bytes into the active Anki collection. Anki can update existing Notes and merge Note Types; it imports scheduling and deck presets when present. Preview does not calculate a collection diff. Requires local AnkiConnect v1.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "localPath": "<localPath>"
    },
    "name": "import-deck-package"
  }
}

Input Schema

NameRequiredDescriptionDefault
dryRunNoPreview without exporting a file or importing into Anki.
localPathYesAbsolute path to a trusted .apkg inside ANKI_PACKAGE_IMPORT_DIR.
confirmImportNoAccept the import, including possible updates and learning progress.
expectedImpactHashNoHash from the reviewed preview.

Output Schema

NameRequiredDescriptionDefault
dryRunYes
packageYes
profileYes
blockersYes
importedYes
warningsYes
impactHashYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A3.9/5.0
Behavior4/5

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

Beyond destructiveHint=true, the description discloses concrete mutation effects: existing Notes may be updated, Note Types merged, and scheduling/deck presets imported. It also flags a real preview limitation (no collection diff), which matters for interpreting the preview. It does not discuss reversibility or partial-failure behavior, keeping it below a 5.

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?

Four tight sentences, front-loaded with the core action and ending with the environment prerequisite. Each sentence carries distinct information with no filler, though the 'reviewed bytes' phrasing is slightly indirect.

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 destructive import tool the description covers purpose, mutation scope, preview limitation, and connectivity requirements, and the output schema handles return values. Only unusual edge behavior such as failure/rollback semantics is left unaddressed.

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

Parameters3/5

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

Schema coverage is 100%, so dryRun, confirmImport, expectedImpactHash, and localPath are already well documented in the schema. The description reinforces the preview concept but adds no meaning beyond it for the hash or confirmation parameters, so baseline 3 applies.

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

Purpose4/5

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

The description names a specific verb pair (previews and imports) and resource (.apkg into the active Anki collection), which is unambiguous. It does not explicitly contrast with export-deck-package or other siblings, but the import/export distinction is clear from the wording and name.

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?

It states a prerequisite (requires local AnkiConnect v1) and describes the two-phase preview-then-import flow implied by the reviewed bytes, giving an agent clear context for when each mode applies. It stops short of explicitly saying when not to use it or naming any alternative tool.

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