https://github.com/aeharding/threadiverse
Unified typescript client for threadiverse instances (Lemmy, Piefed, Mbin etc)
https://github.com/aeharding/threadiverse
Last synced: 4 months ago
JSON representation
Unified typescript client for threadiverse instances (Lemmy, Piefed, Mbin etc)
- Host: GitHub
- URL: https://github.com/aeharding/threadiverse
- Owner: aeharding
- License: agpl-3.0
- Created: 2025-06-18T23:57:45.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-12-28T03:44:19.000Z (7 months ago)
- Last Synced: 2026-03-28T00:58:06.632Z (4 months ago)
- Language: TypeScript
- Size: 621 KB
- Stars: 5
- Watchers: 0
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
threadiverse
Unified typescript client for threadiverse APIs (Lemmy, Piefed, Mbin etc)
> [!WARNING]
> **Early Development Stage**: This project is under active development and may undergo significant API changes between versions. While v0, this project's design decisions will be guided by [Voyager](https://github.com/aeharding/voyager)'s usage.
## Features
- 🧙♂️ Automagic software detection via `.well-known`
- 📦 API support:
- ✅ Lemmy v0
- ⚠️ Lemmy v1 - in development
- ⚠️ Piefed - partial, experimental
- ❌ Mbin - no support yet (PRs welcome!)
- 🛑 Guaranteed response types via runtime Zod schema validation
- 🛡️ Strongly typed internally: Uses official software types (Swagger from Piefed, `lemmy-js-client` from Lemmy) to enforce compat layer type correctness
## Example
This project provides a `ThreadiverseClient` class which you can use similarly to [`lemmy-js-client`](https://github.com/LemmyNet/lemmy-js-client)'s `LemmyHttp` class. For the most part, it should be a drop-in replacement.
```sh
pnpm i threadiverse
```
```ts
import { ThreadiverseClient } from "threadiverse";
const client = new ThreadiverseClient("https://lemmy.world");
const posts = await client.getPosts();
```