Skip to main content
Glama
anki-connect-mcp
by SolarianGG

noteTypes.deleteUnused

noteTypes_deleteUnused
Destructive

Deletes explicitly selected note types only when their use count is zero, helping prevent accidental removal of note types still in use.

Instructions

Delete only explicitly selected note types whose use count is zero.

Anki-Connect method noteTypes.deleteUnused. Scope: collection. Effect: write. Completion: completed. Undo: perItem.

Possible errors: collectionUnavailable, conflict, editorConflict, internalError, invalidParams, notFound, staleSession.

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": {
      "noteTypes": "<noteTypes>"
    },
    "name": "noteTypes_deleteUnused"
  }
}

Input Schema

NameRequiredDescriptionDefault
sessionNoOptional. Collection session ID: the `session` field returned by `collection_get`. Usually omit it — the server then uses the session current at the time of the call. Pass it to make the call fail with `staleSession` instead of acting on a different profile/collection than the one your IDs, cursors and tokens came from.
noteTypesYesNote types to delete if unused, each exactly one of {"id": "<noteTypeId>"} or {"name": "<note type name, e.g. Basic>"}.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true and readOnlyHint=false, yet the description adds genuinely new context: collection scope, 'Undo: perItem' (deletion is undoable per item), completion semantics, and a concrete error taxonomy including staleSession and editorConflict. The main remaining gap is whether a nonzero-use selection is rejected or silently skipped. No contradiction with the destructive annotation.

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

Conciseness5/5

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

Front-loaded single sentence carries the core constraint, followed by a compact metadata block (method, scope, effect, completion, undo, errors). Telegraphic but every clause is information-bearing; nothing is redundant with the schema.

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 small two-parameter destructive tool with no output schema and full annotation coverage, the description supplies undo behavior, scope, and error modes. Only the nonzero-usage outcome and any cascade considerations are unstated, which is a modest gap rather than a blocking one.

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%, with the noteTypes union (id XOR name) fully described in the schema itself, so the baseline applies. The description reinforces the 'explicitly selected' semantics but adds no format or edge-case detail (e.g. duplicate id/name entries or mixed forms) beyond the schema.

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?

States a precise verb and resource ('Delete... note types') plus a guard condition ('only explicitly selected... use count is zero') that separates it from a bulk sweep. It does not explicitly name a sibling (e.g. noteTypes_getTemplateUsage for checking counts, or tags_deleteUnused as the analogous tool), so the differentiation is implied rather than spelled out.

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

Usage Guidelines3/5

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

'Only explicitly selected' implies the caller must enumerate candidates rather than rely on automatic detection, and error list hints at preconditions. But it never says when to prefer this over checking usage first with noteTypes_getTemplateUsage, nor what happens when a selected note type has a nonzero count.

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

Deploy Server

Other Tools