A TypeScript Matrix SDK that runs anywhere. Built on mautrix-go + goolm compiled to WebAssembly. E2EE works out of the box. No matrix-js-sdk, no Rust sidecar, no Node FFI.
| Package | What it does |
|---|---|
@beeper/pickle |
Matrix SDK: login, sync, rooms, messages, reactions, threads, media, E2EE. |
@beeper/pickle-chat-adapter |
Build Matrix bots using the Chat SDK. |
@beeper/pickle-ai-sdk |
Pipe AI SDK streams into Matrix messages. |
@beeper/pickle-state-file · -sqlite · -indexeddb · -memory · -simple |
State adapters for Node, browsers, and custom backends. |
npm install @beeper/pickle @beeper/pickle-state-sqliteimport { createMatrixClient, onMessage } from "@beeper/pickle/node";
import { createSQLiteMatrixStore } from "@beeper/pickle-state-sqlite";
const client = createMatrixClient({
homeserver: "https://matrix.example.org",
token: process.env.MATRIX_ACCESS_TOKEN!,
store: await createSQLiteMatrixStore(".matrix-state/bot.db"),
recoveryKey: process.env.MATRIX_RECOVERY_KEY, // optional, for E2EE history
});
await onMessage(client, undefined, async (event) => {
if (event.sender.isMe) return;
await client.messages.send({
roomId: event.roomId,
text: `echo: ${event.text}`,
replyTo: event.eventId,
});
});That's a working E2EE-capable Matrix bot. The first awaited method boots WASM, store, and crypto lazily — call await client.boot() if you want startup failures up front.
Same bot, written as a Chat SDK adapter — gets you Slack/Discord/Teams parity and shared bot logic across platforms:
npm install chat @beeper/pickle @beeper/pickle-chat-adapterimport { Chat } from "chat";
import { createMatrixAdapter } from "@beeper/pickle-chat-adapter";
const matrix = createMatrixAdapter({
homeserver: "https://matrix.example.org",
token: process.env.MATRIX_ACCESS_TOKEN!,
});
const bot = new Chat({ adapters: { matrix }, state });
bot.onNewMention(async (thread, message) => {
await thread.subscribe();
await thread.post(`echo: ${message.text}`);
});
await bot.initialize();- Node bots and browser apps
- Login (password, token, JWT) and Beeper registration
/synclong polling with shared subscriptions and catch-up- Send / edit / redact, replies, mentions, reactions, threads, typing, receipts
- Encrypted media upload and download
- Full E2EE (Olm, Megolm, cross-signing, key backup, recovery key)
- Beeper native streaming + ephemeral events
- Streaming AI responses (debounced edits everywhere; native on Beeper)
- URL previews (send rendered content explicitly)
examples/dummybridge-bot— full-featured Node bot using Pickle directly.examples/beeper-streaming-smoke— Chat SDK adapter streaming rich markdown.
pnpm install
pnpm build # TS + Go WASM
pnpm test
pnpm typecheckLive Matrix smoke tests live in e2e and are opt-in because they need
real accounts.
See CONTRIBUTING.md for the release flow.
See LICENSE.