noteTypes.deleteUnused
noteTypes_deleteUnusedDeletes 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
| Name | Required | Description | Default |
|---|---|---|---|
| session | No | Optional. 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. | |
| noteTypes | Yes | Note types to delete if unused, each exactly one of {"id": "<noteTypeId>"} or {"name": "<note type name, e.g. Basic>"}. |