import { AnkiConnect } from '@/ankiconnect';
|
|
|
|
async function main() {
|
|
const anki = new AnkiConnect();
|
|
console.log(
|
|
await anki.multi<['findNotes', 'getTags']>({
|
|
actions: [
|
|
{
|
|
action: 'findNotes',
|
|
params: {
|
|
query: 'added:1',
|
|
},
|
|
},
|
|
{ action: 'getTags' },
|
|
],
|
|
}),
|
|
);
|
|
console.log(
|
|
await anki.api('findNotes', {
|
|
query: 'deck:Takoboto',
|
|
}),
|
|
);
|
|
}
|
|
|
|
if (require.main === module) {
|
|
main();
|
|
}
|