We do have a law, but last I checked then in Estonia there was no way for a private person to do API based payments without later needing to log in to the website and signing the transactions manually with an ID card (i.e a smart card). Sad.
Essentially, you just mark the code blocks with `:script name`, and then can list or execute the block from a terminal. This also keeps the script in context within whatever other notes you had on the topic, when you were figuring it out etc. And if something turns out to be a useful snippet, you move it out to an actually separate script. :)
Write all your notes to org-mode files in a git repo, sync these (selectively) to Anki. No need to depend on proprietary services.
Ironically though, the easiest way to get your cards to AnkiDroid/AnkiMobile is through ankiweb.net (a free service) then you could manually export/import cards and stats should that disappear. org-anki saves note ID within org-mode, so you can keep updating cards after an export/import.
org-drill works entirely in emacs (as does org-fc and pamparam) so you'd need to be near a computer when using it (unless you run emacs on your phone).
[1] https://github.com/eyeinsky/org-anki