Skip to content

An API wrapper for https://blacket.org/ written in TypeScript, attempting providing 1:1 implementation of the API by v1.0.0

License

Notifications You must be signed in to change notification settings

zastlx/blacket-sdk

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

blacket-sdk

An API wrapper for https://blacket.org/ written in TypeScript, attempting providing 1:1 implementation of the API by v1.0.0

Installation

npm install blacket-sdk

Usage

import { Client, getToken } from 'blacket-sdk';

const client = new Client({
    token: await getToken("zastix", "password"),
    // Whether to reconnect to the WebSocket when disconnected
    reconnect: true
});

client.on(SocketEvents.OPEN, (c) => {
    console.log(`Logged in as ${c.user.username} (${c.user.id})`);

    const room = c.roomManager.getOrCreateRoom(0, "global");

    await room.send("Hello, world!");
});

Documentation

The documentation can be found here, we are actively working to improve our documentation!

made with ❤️ by zastix

About

An API wrapper for https://blacket.org/ written in TypeScript, attempting providing 1:1 implementation of the API by v1.0.0

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published