Your Title Here

MM SPOTiFY v1000 Instructions



Description


This extension adds the flexibility and the controllability of manipulating your Spotify player through commands and/or with the push of a button!


Listeners can submit song requests in chat via artist/song, or they can drop a Spotify link and accomplish the same thing. With this extension, each action is completely independent, meaning you can have your volume automatically adjust when you change scenes, pause the music when you switch to just chatting, or tie a channel point redeem to playing a specific song...the possibilities really are endless!


This extension requires a paid Spotify Premium account. Without it, you will only be allowed to fetch your queue and get the current/previously played songs.


Video Tutorial


VIDEO COMING SOON


Import Code


You can download the Import code from the following link: Ko-Fi Download.


Obtaining your Spotify Credentials


Go over to the Spotify Developer website and sign in, or create an account. Once you've signed in, follow the steps below.


Step 1:


Click your profile in the top right and then on the 'Dashboard' drop-down.


Spotify Dashboard

Step 2:


Click on the 'Create App' button.


Spotify-Create App

Step 3:


The required fields are highlighted in red below. The 'App Name' can be whatever you want it to be, and 'App description' can be left blank.
The 'Redirect URI' MUST match this: http://127.0.0.1:1400/spotifyAuth/.
Lastly, don't worry about checking any of the boxes, except for agreeing with the terms. Press 'Save' and move to the next step.


Spotify-App Fields

Step 4:


Press the 'Settings' button to be taken to the settings of your newly created app.


Spotify-Click Settings

Step 5:


Press the 'Show client secret' button to expand the field and copy both the 'Client ID' and the 'Client Secret' to paste into Streamer.bot. Once both are copied, you may close out of your browser.

(Don't use the Client ID / secret from this screenshot (I've already deleted them))


Spotify-ClientId_Secret

Setting it up


Import into Streamer.bot


Press the Import button on Streamer.bot and drag the previously downloaded file into the 'Import String' box. If you are using Streamer.bot 0.2.3+, you will be importing 14 Actions, 1 Queue, 12 Commands, and 1 Timed Action. If you're using a version of Streamer.bot that is 0.2.2 (or earlier) you will NOT have the Timed Action.


Press the Import button on the bottom of the 'Import Actions' pop out window, and then press the 'Ok' button acknowledging the commands are set to 'Disabled' by default.


SB Import Screen


Create a Timed Action


These next 3 steps only apply if you are using Streamer.bot 0.2.2 (or earlier). If you have version 0.2.3-beta.1 or newer, skip down to 'Initializing'.

  1. Click on the 'Settings' Tab
  2. Click on the 'Timed Actions' sub tab
  3. Right-click in the box and select 'Add'
  4. Name MUST be Spotify Auto Runner
  5. Set the interval to 1
  6. Press 'Ok' and click on the 'Actions' Tab

SB-Timed Action


Assign the Timer to the Trigger


(Streamer.bot 0.2.2 or earlier only)


By First clicking on the 'Spotify Auto Runner' Action to highlight it and then double-clicking on the existing Trigger, you can now select 'Spotify Auto Runner' and press 'Ok'


SB-Setting Trigger


Manually add the references


(Streamer.bot 0.2.2 or earlier only)


On the 'Spotify Auto Runner', 'Spotify Controls', and 'Spotify Initialization' Actions, you need to double-click on the 'Execute Code' Sub-Actions. When they pop open, select the 'References' tab and then Right-Click and select 'Add Reference from file...'.


SB-References


On the pop-out window, select your Streamer.bot folder and then add each of the following, one at a time:


  • System.Threading.Task.Extensions.dll
  • Newtonsoft.Json.dll
  • Microsoft.Bcl.AsyncInterfaces.dll

SB-your folder


After you add the new files, delete the original 3 that were in your folder, press Compile to ensure you get 'Compiled Successfully'! Once you get that message, you can press 'Save and Compile' and then head to the next step!


Initializing


Click on the 'Spotify Initialization' Action and past your 'Client ID' and 'Client Secret' that you copied earlier from your Spotify app to it's respective argument.


SB-ClientID_Secret


Navigate to your 'Commands' Tab, right-click on the group name, and 'Enable All'.


SB-Enable Commands


Open up your chat window and run the initialization command: !spotifyInit.


You MUST have the Spotify App open and running on your computer PRIOR to initialization. If not, you'll have to run the command again!

Upon successful initialization, you will be greeted by this really AWESOME screen and a friendly chat message that has your current PC name listed for Spotify control.


Commands


All of the commands listed below are NOT case-sensitive and can be changed to your likings for your stream/community. For example, somebody that plays a lot of Marbles on Stream may not want to keep !play.

Command Controllable Feature Description
!play Play/Resume Playback Standard 'Play' button for the Spotify App.
!pause Pause Playback Standard 'Pause' button for the Spotify App.
!skip Skip the current song Skips the currently playing song.
!previous Skip back to previous song Moves playback to previously played song.
!volume Set the volume of the player Accepts command with numerical values, or argument input (i.e. !volume 70).
!sr Song Requests Accepts either Artist and Song, or Spotify track links (no playlist, album, or artist).
!song Display the current song Displays the current 'Song' by Artist in the chat (even with song names turned off).
!queue Show the current queue If used without a number, it shows the next song. Also accepts values to show next 'X' songs (i.e. !queue 5).
!last Show the last played song If used without a number, shows the last song. Also accepts values to show previous 'X' songs (i.e. !last 3).
!requesterName Toggle requester names Show requester name with song information. Toggles on/off or can be explicit. (i.e. !requestername on/off, yes/no, true/false)
!songName Toggle song names Shows 'Song' by Artist in chat on song change. Toggles on/off or can be explicit. (i.e. !songname on/off, yes/no, true/false)

!play

Command Aliases: None
Modifiers: None
Notes: It has ONE job...
play


!pause

Command Aliases: None
Modifiers: None
Notes: Sometimes you just need to pause the music...
pause


!skip

Command Aliases: !next
Modifiers: None
Notes: Who requested that song? Let's get rid of it...
skip


!previous

Command Aliases: !prev
Modifiers: None
Notes: Maybe that last song was a banger?!
previous


!volume

Command Aliases: !vol
Modifiers: 0-100
Notes: This command accepts an argument %volPercent% (disabled by default and name cannot be changed) for use in other Actions. IF the argument is enabled and you use !volume with no numbers, it'll set the volume at that value.
volume


!sr

Command Aliases: !request, !songRequest
Modifiers: None
Notes: This accepts either song titles, artist and song titles, or Spotify track links (will send a message in chat telling the requester it can't accept album, artist, or playlist links).
song requests


!song

Command Aliases: None
Modifiers: None
Notes: Even if song names are disabled via the !songNames command, you can manually view the currently playing 'Song' by Artist. It will include the requester name if that is enabled!
song


!queue

Command Aliases: None
Modifiers: 1-50
Notes: If left blank, it will return the next one. When used with a number, it'll return that many songs (i.e. !queue 5 would return the next 5 songs). If the number of songs requested would exceed the 500 character limit for a Twitch message, it'll say that in chat instead.
queue


!last

Command Aliases: !lastSong, !lastSongs
Modifiers: 1-50
Notes: Just like the !queue command, if left blank, it will return the last played song. When used with a number, it'll return that many songs (i.e. !last 3 would return the previously played 3 songs). If the number of songs requested would exceed the 500 character limit for a Twitch message, it'll say that in chat instead.
last


!requesterName

Command Aliases: !requesterNames
Modifiers: On/Off, Yes/No, Y/N, True/False
Notes: This can be used as a toggle (i.e. if you type !requesterName and they're currently on, it will turn them off). Conversely, you can explicitly use one of the modifiers !requesterNames on.
requestername


!songName

Command Aliases: !songNames
Modifiers: On/Off, Yes/No, Y/N, True/False
Notes: This only affects the ability to show the 'Song' by Artist every time a NEW song plays and operates independently of the !song command. This can be used as a toggle (i.e. if you type !songName and they're currently on, it will turn them off). Conversely, you can explicitly use one of the modifiers !songNames on.
songname


Global Variables Available


The following global variables are available to be used for things like overlays, GDI text, and Now Playing widgets. Access them like this: ~currentSongName~ throughout Streamer.bot.

Variable Name Description
currentAlbumImage URL of current Album Cover
currentAlbumName Name of Album from currently playing track
currentAlbumTracks Number of tracks on Album associated with currently playing Track
currentArtistName Name of Artist for currently playing Track
currentDurationMs Length of currently playing Track (in milliseconds)
currentProgressMs Progress of currently playing Track (in milliseconds)
currentReleaseYear Release year of Album (or Single) associated with currently playing Track
currentSongLink Spotify link for currently playing Track
currentSongName Name of currently playing Track
currentSpotifyUri Spotify URI for currently playing Track
currentTrackNumber Track number for Album associated with currently playing Track

FREE StreamDeck Buttons


Inspired by Bar Raiders, but created by my good friend, @fgr_freakon. Feel free to download them from the .zip file below the picture!


SD Toggle-On
SD Toggle-Off

Download the StreamDeck icons from the Ko-Fi link above, or Google Drive here: StreamDeck Buttons