AnkiIO 1.0.2

dotnet add package AnkiIO --version 1.0.2
                    
NuGet\Install-Package AnkiIO -Version 1.0.2
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="AnkiIO" Version="1.0.2" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="AnkiIO" Version="1.0.2" />
                    
Directory.Packages.props
<PackageReference Include="AnkiIO" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add AnkiIO --version 1.0.2
                    
#r "nuget: AnkiIO, 1.0.2"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package AnkiIO@1.0.2
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=AnkiIO&version=1.0.2
                    
Install as a Cake Addin
#tool nuget:?package=AnkiIO&version=1.0.2
                    
Install as a Cake Tool

AnkiIO

Created with substantial help from GPT-5.6-Sol Ultra and tested against my own use cases. Please do not treat this project as a measure of my abilities as a developer, for better or worse.

CI Documentation Security Coverage gate .NET 10 License: MIT

Get AnkiIO on NuGet · Browse the API documentation →

Sample projects · Formats and safety · MIT license

AnkiIO is a stable, open-source .NET 10 library for creating, validating, importing, editing, and exporting Anki deck data. It provides a format-independent deck model, practical helpers for common note types, deterministic JSON, a CrowdAnki-inspired interchange format, media, scheduling state, diagnostics, and guarded legacy APKG I/O.

Quick start

Install the package from NuGet:

dotnet add package AnkiIO
using AnkiIO;

var deck = new AnkiDeck("German Vocabulary");
deck.AddBasicNote("Haus", "house", tags: ["german", "vocabulary"]);

await AnkiPackageWriter.WriteAsync(deck, "GermanVocabulary.apkg");

A note stores information; a card is a study prompt generated from a note template. Scheduling belongs to cards. New cards receive a safe default schedule, while explicit scheduling is validated and rejected when its queue/type combination is inconsistent.

Highlights

  • Decks and nested Parent::Child hierarchies
  • Notes, ordered fields, custom note types, card templates, CSS, tags, GUIDs, and cards
  • Helpers for Basic, Basic-and-reversed, and Cloze notes, including safe cloze-markup construction
  • Safe new-card initialization and explicit, validated scheduling state
  • Streaming media ingestion with SHA-256 integrity metadata
  • Deterministic, versioned native JSON and CrowdAnki-inspired JSON
  • Guarded APKG import/export with configurable archive limits and path-traversal defenses
  • Structured validation diagnostics and documented unknown-data preservation
  • Read-only installed-Anki detection and opt-in, isolated local compatibility testing

See the samples for focused programs and the German–English showcase for a complete custom deck with note types, media, tags, and verification.

Compatibility and scope

AnkiIO targets net10.0, collection schema 18, and v3 scheduler semantics. APKG export writes the legacy collection.anki2 representation. Native JSON and CrowdAnki-inspired JSON support documented subsets, with unknown native-JSON properties retained where the API promises preservation.

AnkiIO does not write to a live Anki profile or generate modern collection.anki21b databases. Filtered decks, arbitrary database mutation, and complete review-log or deck-configuration preservation are outside its scope. Read formats, compatibility, and safety before processing untrusted packages or important data.

Contributions use focused pull requests and must preserve the documented compatibility contract; see CONTRIBUTING.md. Security reports follow SECURITY.md. Licensed under MIT.

AnkiIO is maintained by Julius Jacobsohn.

AnkiIO is not affiliated with, endorsed by, or sponsored by Ankitects, Anki, AnkiDroid, or CrowdAnki. “Anki” is a trademark of Ankitects Pty Ltd.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.2 109 7/23/2026
1.0.1 97 7/22/2026

See the changelog and API documentation for release details, compatibility, and safety guidance.