📗Configuring Credentials

This page will help you configure your credentials.toml file properly

TwitchSpawn uses a well-known data transporting library called SocketIO to communicate with various streaming platforms' Socket APIs. In the sake of authenticating inbound connection, those APIs require a long string data called a socket token. Therefore in order for TwitchSpawn to connect to those APIs, we need to let it know what our socket token is.

The tokens you put in credentials.toml are not sent to anywhere else than the platform's Socket API. Therefore, your tokens are safe as long as you do not share them or credentials.toml with any untrusted source.

However, if somehow you think your tokens are in wrong hands, you can always reset them in the platform's settings.

Where to find your Socket Token?

Finding your socket token is quite easy on Streamlabs! You can start off by logging into your Streamlabs account on https://streamlabs.com/

After logging into your account, you can see Settings section on the left menu. Navigate there.

Under Settings, you can see API Settings tag, and another tab under that called API Tokens. Nagivate there and you'll see your Socket Token unrevealed. You'll need that token in credentials.toml.

Those pages are NOT provided/designed by the developers of TwitchSpawn, therefore the way you find your Socket Tokens might change over time. If you cannot find your Socket Token by following the way explained in this page, consider reaching us on our Discord Server!

Plugging in the Socket Token(s)

The credentials config file is a TOML file. It is consisted of 3 arrays.

With all the information you retrieved from the platform of choice, it is rather easy to fill the file. However since TOML is a case sensitive language, try not to change field names (E.g socketTokenSocketToken). Exemplar credentials.toml files can be found below:

credentials.toml
moderatorsTwitch = [ "TheDiaval" ] # You can have as many names as you desire
moderatorsMinecraft = [ "Neeta", "Pomapi", "Toastnomnomnom" ]

[[streamers]]
	minecraftNick = "iGoodie"
	twitchNick = "iGoodiex"
	platform = "Streamlabs"
	token = "YOUR_SOCKET_TOKEN_HERE"

Also while filling nicknames, beware that they are case sensitive as well. Be sure you fill them considering the case sensitivity (E.g igoodieiGoodie).

Last updated