1.0.2 • Published 4 years ago

bolt-api v1.0.2

Weekly downloads
4
License
ISC
Repository
github
Last release
4 years ago

Bolt API

A simple API wrapper for http://bolt.watch written in Node JS

Usage

Installation

npm i bolt-api --save

Examples

Create a Client Instance

const Bolt = require('bolt-api');
const client = new Bolt({ key: 'YOUR KEY HERE' });

Get all Users

client.getUsers().then((users) => {...})

Get a User's Data

client.getUser(username).then((user) => {...})

Get a channel by ID or Channel Name

client.getChannel(id).then((channel) => {...})

Get all channels

client.getChannels().then((channels) => {...})

Get channel by User ID

client.getChannelByUserId(userId).then((channel) => {...})

Check if a user is following a channel

client.isUserFollowingChannel(followerId, channelId).then((data) => {...})

Get all channels by Game ID

client.getChannelsByGame(gameId).then((channel) => {...})

Search for a game by name

client.searchGame(game).then((game) => {...})

Get data from Game ID

client.getGame(gameId).then((game) => {...})

Get all games that channels have set across Bolt

client.getGames().then((games) => {...})

Get stream by a Channel ID

client.getStream(channelId).then((stream) => {...})

Get Stream Spotlight

client.getSpotlight().then((spotlight) => {...})

Get all active streams

client.getStreams().then((streams) => {...})