TypeScript APIs for various Versia services.
Find a file
2024-05-13 21:52:02 -10:00
.github/workflows fix(build): 🐛 Make CI also change federation package version number 2024-05-13 21:52:02 -10:00
.vscode feat(build): 👷 Add automatic CI build and deploy to NPM 2024-05-13 21:35:05 -10:00
federation refactor(build): 👷 Make CI NPM publish only be run manually 2024-05-13 21:50:11 -10:00
.gitignore feat(build): 👷 Add automatic CI build and deploy to NPM 2024-05-13 21:35:05 -10:00
biome.json feat: Port code from Lysand Server and improve it 2024-05-13 21:00:05 -10:00
build.ts feat: Port code from Lysand Server and improve it 2024-05-13 21:00:05 -10:00
bun.lockb feat: Port code from Lysand Server and improve it 2024-05-13 21:00:05 -10:00
LICENSE Initial commit 2024-05-13 17:15:26 -10:00
package.json feat: Port code from Lysand Server and improve it 2024-05-13 21:00:05 -10:00
README.md feat(docs): 📝 Add initial README and docs 2024-05-13 17:58:03 -10:00
tsconfig.json feat: Port code from Lysand Server and improve it 2024-05-13 21:00:05 -10:00

Lysand Logo

Lysand API

Set of NPM packages written in TypeScript to interact with Lysand-compatible services.

Packages

  • @lysand-org/federation: Federation types and validators for Lysand server implementations.
  • @lysand-org/client: Client for the reference Lysand Server implementation.

Usage

Warning

These packages are not even published on NPM yet. They are still in development and are not ready for production use.

Getting Started

Prerequisites

For Usage

See the Compatibility section for the supported environments. Any package manager can be used to install the packages.

For Development

  • Bun version 1.1.8 or higher.
  • Either the Linux or macOS operating systems. (Windows will work, but is not officially supported.)

Compatibility

This library is built for JavaScript runtimes with the support for:

Runtimes

  • Node.js: 14.0+ is the minimum, but only Node.js 20.0+ (LTS) is officially supported.
  • Deno: Support is unknown. 1.0+ is expected to work.
  • Bun: Bun 1.1.8 is the minimum-supported version. As Bun is rapidly evolving, this may change. Previous versions may also work.

Browsers

Consequently, this library is compatible without any bundling in the following browser versions:

  • Chrome: 80+
  • Edge: 80+
  • Firefox: 74+
  • Safari: 13.1+
  • Opera: 67+
  • Internet Explorer: None

If you are targeting older browsers, please don't, you are doing yourself a disservice.

Transpilation to non-ES Module environments is not officially supported, but should be simple with the use of a bundler like Parcel or Rollup.

Installation

Both packages are distributed as a scoped package on the NPM registry.

npm install @lysand-org/federation @lysand-org/client # For NPM
yarn add @lysand-org/federation @lysand-org/client # For Yarn
pnpm add @lysand-org/federation @lysand-org/client # For PNPM
bun add @lysand-org/federation @lysand-org/client # For Bun

From Source

If you want to install from source, you can clone this repository and run the following commands:

bun install # Install dependencies

bun run build # Build the packages

License

This project is licensed under the MIT License - see the LICENSE file for details.

Acknowledgments

Projects

  • Bun: Thanks to the Bun team for creating an amazing JavaScript runtime.
  • TypeScript: TypeScript is the backbone of this project.
  • Node.js: Node.js created the idea of JavaScript on the server.

People

  • April John: Creator and maintainer of the Lysand Server ActivityPub bridge.