This is a NodeCG bundle.
Listens for tips to a given account on StreamTip and emits API events for other bundles to use. Also displays stats on the dashboard and easily allows the user to reset said stats.
This bundle integrates with lfg-nucleus.
- Install to
nodecg/bundles/lfg-streamtip - Create
nodecg/cfg/lfg-streamtip.jsonwith theclientIdandaccessTokenof the StreamTip account that you wish to listen to:
{
"clientId": "xxxxx",
"accessToken": "yyyyy"
}If you simply want to see top tips for the daily and monthly periods on your dashboard, you are done.
If you would like to use this data in another bundle, add the following code to your view/panel:
nodecg.listenFor('tip', 'lfg-streamtip', callback);... where 'callback' is the name of a function with the signature function callback(data)
If you want to use tip events in another bundle's extension,
add lfg-streamtip as a bundleDependency in your bundle's nodecg.json
Then add the following code:
var streamTip = nodecg.extensions['lfg-streamtip'];
streamTip.on('tip', function(tip) {
// Do your thing.
});lfg-streamtip is provided under the MIT license, which is available to read in the [LICENSE][] file. [license]: LICENSE