Skip to main content
Glama

Manage note types

manage_models
Destructive

List, create, and modify Anki note types, including fields, card templates, and CSS, so you can keep flashcard structures aligned before adding note content.

Instructions

List and modify Anki note types (models): fields, card templates and CSS. Use list before creating notes to find a note type's exact field names (e.g. "Front"/"Back"); use manage_flashcards for note content.

Operations:

  • list: read-only; every note type with its ID and ordered field names.

  • create: needs modelName, fields (ordered names) and templates ([{ Front, Back }]); optional css, isCloze.

  • add_field: needs modelName, fieldName, fieldIndex.

  • remove_field: needs modelName, fieldName. Deletes that field's content from every note of this type (destructive).

  • rename_field: needs modelName, fieldName, newFieldName.

  • add_template: needs modelName, template ({ Front, Back }). Generates new cards for existing notes.

  • remove_template: needs modelName, templateName. Deletes the cards generated by that template (destructive).

  • update_styling: needs modelName, css. Replaces the note type's CSS.

All operations except list change the collection immediately and affect every note of that type.

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": {
      "operation": "<operation>"
    },
    "name": "manage_models"
  }
}

Input Schema

NameRequiredDescriptionDefault
cssNocreate/update_styling: CSS for the card templates
fieldsNocreate: field names in order
isClozeNocreate: make a cloze deletion note type
templateNoadd_template: template to add, { Front, Back } HTML
fieldNameNoadd_field/remove_field/rename_field: field name (current name for rename)
modelNameNoNote type name (all operations except list), e.g. "Basic"
operationYesWhich operation to run; see the tool description for required parameters
templatesNocreate: card templates, e.g. [{ Front: "{{Front}}", Back: "{{FrontSide}}<hr id=answer>{{Back}}" }]
fieldIndexNoadd_field: 0-based position for the new field
newFieldNameNorename_field: new field name
templateNameNoremove_template: template name, e.g. "Card 1"

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed15 schema fields changedv0.7.0
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • removedInput schema / additionalProperties
      Removed value: -false
    • changedInput schema / properties / css / description
      Previous value: -"CSS styling"New value: +"create/update_styling: CSS for the card templates"
    • changedInput schema / properties / fieldIndex / description
      Previous value: -"Field index position"New value: +"add_field: 0-based position for the new field"
    • changedInput schema / properties / fieldName / description
      Previous value: -"Field name"New value: +"add_field/remove_field/rename_field: field name (current name for rename)"
    • changedInput schema / properties / fields / description
      Previous value: -"Field names in order (for create)"New value: +"create: field names in order"
    • changedInput schema / properties / isCloze / description
      Previous value: -"Is cloze deletion type"New value: +"create: make a cloze deletion note type"
    • changedInput schema / properties / modelName / description
      Previous value: -"Model/note type name"New value: +"Note type name (all operations except list), e.g. \"Basic\""
    • changedInput schema / properties / newFieldName / description
      Previous value: -"New field name (for rename)"New value: +"rename_field: new field name"
    • changedInput schema / properties / operation / description
      Previous value: -"Model management operation"New value: +"Which operation to run; see the tool description for required parameters"
    • removedInput schema / properties / template / additionalProperties
      Removed value: -false
    • changedInput schema / properties / template / description
      Previous value: -"Template content"New value: +"add_template: template to add, { Front, Back } HTML"
    • changedInput schema / properties / templateName / description
      Previous value: -"Template name"New value: +"remove_template: template name, e.g. \"Card 1\""
    • changedInput schema / properties / templates / description
      Previous value: -"Card templates (for create)"New value: +"create: card templates, e.g. [{ Front: \"{{Front}}\", Back: \"{{FrontSide}}<hr id=answer>{{Back}}\" }]"
    • removedInput schema / properties / templates / items / additionalProperties
      Removed value: -false
  2. Addedv1.0.0

TDQS

A4.7/5.0
Behavior5/5

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

Annotations only say destructiveHint=true and idempotentHint=false generically; the description localizes the risk per operation — remove_field deletes that field's content from every note, remove_template deletes generated cards, update_styling replaces CSS, add_template generates new cards for existing notes. It also discloses the global timing trait ("All operations except list change the collection immediately and affect every note of that type"), which is the single most important behavioral fact for this tool.

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?

Front-loaded summary sentence followed by a scannable operation list, with the global side-effect warning placed last where it lands hardest. Every bullet earns its place, though the repeated parameter names per bullet partially duplicate the schema descriptions.

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 an 11-parameter, nested-object, destructive tool with no output schema, the description covers what list returns (IDs and ordered field names) and what each mutation does to the collection. Remaining gaps are edge behavior — duplicate model names, failure/rollback semantics — which are not covered anywhere.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description adds the per-operation grouping and required-parameter sets (which params combine for create vs. add_field vs. rename_field) that the flat schema cannot express. It also clarifies ordering semantics ("fields (ordered names)") and the Front/Back template shape. Minor duplication of individual parameter meanings keeps it from a 5.

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?

States a specific verb set and resource ("List and modify Anki note types (models): fields, card templates and CSS") and immediately delimits scope against the sibling manage_flashcards. An agent can tell this is schema management, not note content management, without opening either schema.

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

Usage Guidelines5/5

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

Gives an explicit prerequisite workflow ("Use list before creating notes to find a note type's exact field names") and an explicit alternative ("use manage_flashcards for note content"). Each of the eight operations carries its own required-parameter contract, so selection between operations is unambiguous.

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