列出卡组里的复习卡
const r = await mn.api('/decks/' + deckId + '/cards');
if (r.error) { mn.log(r.error.code); return; }
const alive = r.cards.filter(c => c.sourceAlive).length;
mn.log(alive + '/' + r.cards.length);{
"cards": [
{
"cardNoteId": "1D797495-9138-40E5-9938-8143878F76E0",
"sourceNoteId": "B9F3696A-AF8A-43B2-A8A2-2791717F1695",
"sourceAlive": true,
"title": "光合作用"
}
]
}学习集与卡组
列出卡组复习卡
列出卡组里的复习卡。每项返回复习卡本身、该卡对应的背面卡片,以及背面卡片是否存在(见 sourceAlive 字段)。
传学习集的标识进来会返回 422 NOT_A_DECK,反过来则返回 IS_A_DECK。
GET
/
decks
/
{deckid}
/
cards
列出卡组里的复习卡
const r = await mn.api('/decks/' + deckId + '/cards');
if (r.error) { mn.log(r.error.code); return; }
const alive = r.cards.filter(c => c.sourceAlive).length;
mn.log(alive + '/' + r.cards.length);{
"cards": [
{
"cardNoteId": "1D797495-9138-40E5-9938-8143878F76E0",
"sourceNoteId": "B9F3696A-AF8A-43B2-A8A2-2791717F1695",
"sourceAlive": true,
"title": "光合作用"
}
]
}