←back to thread

655 points domenicd | 5 comments | | HN request time: 0.841s | source
Show context
entropie ◴[] No.44020830[source]
Pretty OT: A few month ago I tried to marry my simple note system with anki. My goal was to be able to send simple front/backside cards to an api and it would get integrated and I can use it immediately. Ofc, when I edit cards via my notes-backend, the cards in anki should update too.

Long story short: not possible with anki. It took like an entire day for me to realize its just not possible without diving deep into ankis sqlitedb and having the client installed on my server to interact in a horrible way with decks. I wrote my own space repetition [1] backend in a week and never looked back to anki. Ill intergrate FSRS in my software.

1: https://github.com/entropie/ha2itat/tree/main/plugins/entrom...

replies(7): >>44020907 #>>44020976 #>>44021072 #>>44021095 #>>44021100 #>>44021107 #>>44021598 #
johanyc ◴[] No.44020976[source]
Every anki card is just a webview. Its very possible to call an api
replies(1): >>44021022 #
1. entropie ◴[] No.44021022[source]
Then you should be able to link me to some docs.
replies(2): >>44021283 #>>44021522 #
2. david_allison ◴[] No.44021283[source]
> In Anki, templates are written in HTML, which is the language that web pages are written in. The styling section is CSS, which is the language used for styling web pages.

https://docs.ankiweb.net/templates/intro.html

----

But you'd want AnkiConnect, or a Python-based addon for your workflow

3. criddell ◴[] No.44021522[source]
Have you looked into any of the open source clients to see how they are communicating with the server?
replies(1): >>44021816 #
4. entropie ◴[] No.44021816[source]
I did that. The consens is like, just an example, yanki-connect:

> Anki desktop app auto-launch > Perhaps the most precarious aspect of the Anki-Connect add-on is that the Anki desktop application must be running for any of the API calls to work. Yanki Connect tries to sand down this rough edge by (optionally) automatically launching the Anki desktop app if it's not running already.

replies(1): >>44023972 #
5. ◴[] No.44023972{3}[source]