1.0.7 • Published 5 years ago

@support-pp/sinusbot-ts v1.0.7

Weekly downloads
4
License
MIT
Repository
github
Last release
5 years ago

Publish

@support-pp/sinusbot-ts

WIP: JavaScript library wrapper to communicate with the SinusBot API (HTTP)

Installation

$ npm install @support-pp/sinusbot-ts

# Or, if you prefer yarn
$ yarn add @support-pp/sinusbot-ts

Usage

The lib is work in progress. But here is a small example.

const { SinusBot } = require('@support-pp/sinusbot-ts');

// Host as string to your sinusbot (https://example.de)
const HOST = process.env.Host;
// Port as number to your sinusbot (8087)
const PORT = process.env.PORT;

const bot = new SinusBot(HOST, PORT);

(async () => {
    const botId = await bot.getBotId();
    console.log(`BotID :: ${botId.defaultBotId}`)

    const loginStatus = await bot.login({
        username: "admin",
        password: "foobar",
    })
    if (loginStatus.success){
        console.log(`> SinusBot auth success!`)
    }

})();

Getting Help

If you get stuck, we're here to help.

  • Issue Tracker for questions, feature requests, bug reports.
  • Discord: you can ask for help on our discord server.
1.0.7

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago