Create a new Anki deck
Creates a new Anki deck via AnkiConnect API. Use this when you need to set up a new deck for flashcards before adding cards to it.
/plugin marketplace add jtmuller5/anki-claude-plugin/plugin install jtmuller5-anki-claude-plugin@jtmuller5/anki-claude-pluginCreate a new Anki deck using the AnkiConnect API.
Process:
API Request Format:
curl -X POST http://localhost:8765 \
-H "Content-Type: application/json" \
-d '{
"action": "createDeck",
"version": 6,
"params": {
"deck": "{{name}}"
}
}'
Validation: Before creating, check if deck exists:
curl -X POST http://localhost:8765 \
-H "Content-Type: application/json" \
-d '{
"action": "deckNames",
"version": 6
}'
Error Handling:
Success Response: Confirm that the deck was created and provide the deck ID if available.
Example Usage:
/create-deck --name "Spanish Vocabulary"
/create-deck --name "Computer Science::Algorithms"
Note: You can create nested decks using "::" separator (e.g., "Parent::Child").