# Tsunagi - Modern AnkiConnect alternative

**URL:** <https://forums.ankiweb.net/t/tsunagi-modern-ankiconnect-alternative/71411>\
**Category:** Add-ons\
**Created:** [October 12, 2026, 6:03pm UTC](https://forums.ankiweb.net/t/tsunagi-modern-ankiconnect-alternative/71411 "2026-10-12T18:03:47Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![drepic](https://sea2.discourse-cdn.com/flex002/user_avatar/forums.ankiweb.net/drepic/32/35214_2.png) [@drepic](https://forums.ankiweb.net/u/drepic)\
**Post date:** [October 12, 2026, 6:03pm UTC](https://forums.ankiweb.net/t/tsunagi-modern-ankiconnect-alternative/71411/1 "2026-10-12T18:03:47Z")

</div>

I’ve been working on **Tsunagi** for the past few months and wanted to share it here, and give it a place for discussion.

It’s an Anki desktop add-on that lets other apps and scripts connect to your collection. It includes an **AnkiConnect compatibility shim** for existing tools, alongside a new HTTP API for developers building integrations.

I’ve been mining vocabulary daily with Tsunagi for a while now, using my own project, [Yomine](https://github.com/mcgrizzz/Yomine), alongside asbplayer and Yomitan. I haven’t run into any issues. Yomine initially used the AnkiConnect shim, and I’ve since switched it to the new API.

### Using existing AnkiConnect tools

The shim handles requests through Tsunagi’s own logic, using Anki’s `QueryOp` and `CollectionOp` system for collection work. Existing tools get:

- **Less UI blocking** , with collection work running in the background.
- **Undo** for most collection changes through **Edit \> Undo**.
- **Per-app keys and permissions** , so tools can have separate access limits.
- **A request log** showing what reached Anki and why anything was refused.

After installation, click **Take over** to import your AnkiConnect port, API key, and allowed websites. Yomitan, asbplayer, and other existing tools should generally keep working without reconfiguration.

All 122 AnkiConnect actions are implemented, with [known differences documented here](https://github.com/mcgrizzz/Tsunagi/blob/main/docs/ankiconnect_parity.md).

### Live collection events

A **live event stream** lets apps follow changes to notes, cards, and reviews, including changes made inside Anki itself.

A vocabulary tool could update its known-word list after an edit, or a dashboard could update after a review, without repeatedly polling. The TypeScript client also supports **watched queries** , reporting results being added, changed, or removed.

### Building an integration

The new API lets you request only the fields you need and fetch related data together. For example, you can get note types with their field names, or each card’s latest review without downloading its entire history. This means **fewer requests, smaller responses, and less processing in your app**.

Note creation supports media and duplicate handling together, and request keys let you retry writes without performing the same change twice.

The **[TypeScript client](https://github.com/mcgrizzz/Tsunagi/blob/main/packages/typescript/README.md)** is available as `tsunagi-client` on npm, with autocomplete and type checking for queries, fields, and values.

For example, this watches a mining deck and reports changes, including edits made inside Anki:

```ts
const anki = new Tsunagi({ baseUrl: "http://127.0.0.1:7777" });

// returns a subscription
const sub = await anki.notes.search("deck:Mining").select("id", "firstField").watch({
  added: notes => console.log("Added", notes),
  updated: notes => console.log("Updated", notes),
  removed: ids => console.log("Removed", ids),
});

// later you may want to stop watching: 
// sub.stop();

```

The client handles keeping the query current, so your app doesn’t need its own polling loop.

A **Rust client** is in the works too.

### Trying it out

Install from [AnkiWeb](https://ankiweb.net/shared/info/666370974) using code **666370974**. It’s still marked experimental and currently supports **Anki 26.08 and 26.09**.

[GitHub and documentation](https://github.com/mcgrizzz/Tsunagi) · [Interactive API reference](https://mcgrizzz.github.io/Tsunagi/)

Questions, compatibility reports, and discussion about integrations are welcome here. If something behaves differently after switching, let me know which tool you’re using and what happened.

I’d also appreciate feedback from developers on the TypeScript client and upcoming Rust client, especially anything that feels awkward to use or takes more code than it should.
