Anki Forums

Imported Deck Destination

A few months ago I wrote an add-on which makes use of the TextImporter. Previously generated cards would end up in the current deck, but now they always end up in the default deck. I would like to be able to ensure that new cards end up in the appropriate deck, but I was unable to find the relevant code change that would have affected this behavior. Does somebody know the solution?

There’s an example of how to do this in the add-on writing docs: https://addon-docs.ankiweb.net/#/getting-started?id=the-collection

Thank you.