Create flashcards
Add flashcards to a document as bullets with RemNote's card triggers.
POST https://cotlet.dev/api/v1/remnote/documents/{document_id}/flashcards
Adds flashcards as new bullets at the end of a document, using the same trigger characters RemNote documents for text import. Types: basic (front >> back), reverse, two_way, cloze ({{hidden}}) and multi_line (front with items nested under it). New cards wait in their own queue before you start learning them. It writes into your own knowledge base and reaches no one, so it does not ask first.
Parameters
| Name | Type | Description |
|---|---|---|
| document_id string required | string | Document or note ID from search_notes or list_documents. |
| cards array required | array | Cards to add: each has type (basic, reverse, two_way, cloze, multi_line) plus front and back, or text for cloze, or items for multi_line. |
Request
curl -X POST https://cotlet.dev/api/v1/remnote/documents/rem_8f21a0/flashcards \
-H "Authorization: Bearer $COTLET_API_KEY" \
-H "Content-Type: application/json" \
-d '{"cards":[{"type":"basic","front":"Citrate","back":"First product of the Krebs cycle"},{"type":"cloze","text":"The cycle runs in the {{mitochondrial matrix}}"}]}' result = client.call("remnote", "create_flashcards", {"document_id":"rem_8f21a0","cards":[{"type":"basic","front":"Citrate","back":"First product of the Krebs cycle"},{"type":"cloze","text":"The cycle runs in the {{mitochondrial matrix}}"}]}) const result = await cotlet.call('remnote', 'create_flashcards', {"document_id":"rem_8f21a0","cards":[{"type":"basic","front":"Citrate","back":"First product of the Krebs cycle"},{"type":"cloze","text":"The cycle runs in the {{mitochondrial matrix}}"}]}); cotlet call remnote create_flashcards --data '{"document_id":"rem_8f21a0","cards":[{"type":"basic","front":"Citrate","back":"First product of the Krebs cycle"},{"type":"cloze","text":"The cycle runs in the {{mitochondrial matrix}}"}]}' Example response
{
"document_id": "rem_8f21a0",
"cards_added": 2,
"by_type": {
"basic": 1,
"cloze": 1
}
}