notes.create
notes_createCreates an Anki note using a specified note type, deck, and field values, then returns the actual cards generated from it.
Instructions
Create a note and return its actual generated cards.
Anki-Connect method notes.create. Scope: collection. Effect: write. Completion: completed. Undo: single.
Possible errors: collectionUnavailable, editorConflict, internalError, invalidParams, notFound, staleSession, validationFailed.
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": {
"noteType": "<noteType>",
"deck": "<deck>",
"fields": "<fields>"
},
"name": "notes_create"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| deck | Yes | Deck: exactly one of {"id": "<deckId>"} or {"name": "<full deck name, e.g. Japanese::Verbs>"}. | |
| tags | No | Tags for the new note (no spaces inside a tag). | |
| fields | Yes | Field values keyed by exact field name of the note type; values are HTML. Example: {"Front": "猫", "Back": "cat"}. For media, first call `media_store` and use the returned filename. | |
| 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. | |
| noteType | Yes | Note type: exactly one of {"id": "<noteTypeId>"} or {"name": "<note type name, e.g. Basic>"}. | |
| duplicates | No | Duplicate policy {allow, scope: collection|deck, deck?}. Default: duplicates of the first field are rejected collection-wide. | |
| rejectEmptyQuestions | No | Fail if no card of the note would have a non-empty question. Default true. |