1.0.3 • Published 5 years ago

utililogs-client v1.0.3

Weekly downloads
-
License
Unlicense
Repository
gitlab
Last release
5 years ago

UtiliLogs Client

A client library for interfacing with UtiliLogs - an external and real-time logging system

Usage

const createUtiliLogsClient = require("utililogs-client")

// host starts with `ws://` or `wss://` (ie.: ws://localhost:4000)
// token is given by UtiliLogs and is a string
const client = createUtiliLogsClient(host, token)

// emoji and id are optional
// message is required
// one of `timestamp_s` or `timestamp_ms` is required
client.log({
    emoji: "🎉",
    id: "123456789",
    message: "We logged in!",
    timestamp_ms: Date.now(),
})

// optional, but can be used for cleaner shutdowns
client.close()
1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago