From 6b6b8b689bf4b8d5eea3ff3f10a44f3878cc29ec Mon Sep 17 00:00:00 2001 From: Scott Noyes Date: Fri, 1 May 2020 11:21:55 -0500 Subject: [PATCH] Update README for importPackage action --- README.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/README.md b/README.md index 7f1104a..cd35b14 100644 --- a/README.md +++ b/README.md @@ -323,6 +323,30 @@ guarantee that your application continues to function properly in the future. } ``` +* **importPackage** + + Imports a file in `.apkg` format into the collection. Returns `true` if successful or `false` otherwise. + Note that the file path is relative to Anki's collection.media folder, not to the client. + + *Sample request*: + ```json + { + "action": "importPackage", + "version": 6, + "params": { + "path": "/data/Deck.apkg", + } + } + ``` + + *Sample result*: + ```json + { + "result": true, + "error": null + } + ``` + #### Decks * **deckNames**