Description

Used to listen to a new topic.

Example

// ... Initializing

pubsub.addTopic('41677043')
    .then(console.log)
    .catch(console.error);

Parameters

topic - {String} - The ID of a twitch channel as a string.

Returns

{
    topic: '41677043',
    err: 'success',
    shard: Shard
}

topic - {String} - The topic given as parameter.

err - {String} - The error message, 'success' if the request succeed.

shard - {Shard} - The Shard object to which the topic has been added.

results matching ""

    No results matching ""