Combine StreamLabs Total Donations with Total Superchats
While stream labs seems to be focused on twitch support, they also have decent integration with youtube.
Recently I started a Streamlabs donation goal for a new editing machine for my youtube channel and wanted to have any and all “donations” received during my weekly YouTube live streams count toward that goal.
Basically I wanted StreamLabs to combine donations through StreamLabs AND SuperChats through YouTube into a single number so I could display the total given seamlessly. It seems that Streamlabs is unable to do this due to legal reasons (as it’s a relatively easy task for them). So I took it upon myself to come up with a solution.
HEADS UP! This solution ONLY works for Apple Mac OS, though the idea could easily be transferred to some Microsoft Windows solution if you have the know how... but if you have the know-how, you don’t need to be reading this. Moving on...
First you need to download StreamLabels the standalone software from StreamLabs that generate txt files of all kinds of stats for you.
Once that is setup, open up the Automator app that comes standard on every Mac. You’ve probably never used this before but rest assured you don’t need to know much.
Create a new Workflow and add an Applescript module. Paste this code into that Applescript module (replacing the dummy files paths I have written here to where those files generated by StreamLabels are stored on YOUR harddrive): --Subroutine on replace_chars(this_text, search_string, replacement_string) set AppleScript's text item delimiters to the search_string set the item_list to every text item of this_text set AppleScript's text item delimiters to the replacement_string set this_text to the item_list as string set AppleScript's text item delimiters to "" return this_text end replace_chars --Read files and set vars set totalDonofile to POSIX file ("/Users/xxxx/xxx/total_donation_amount.txt") set totalDono to (read totalDonofile) set the totalDono to replace_chars(totalDono, "$", "") set totalSuperfile to POSIX file ("/Users/xxxx/xxx/total_youtube_superchat_amount.txt") set totalSuper to (read totalSuperfile) set the totalSuper to replace_chars(totalSuper, "$", "") --Variable Operations set totalGiven to "$" & (totalDono + totalSuper) as textset filepath to "/Users/xxxx/xxx/Total_dono_and_superchat.txt" try set openfile to open for access filepath with write permission write totalGiven to openfile close access openfile on error try close access openfile end try end try
Now add a pause and a loop module so this thing will pause for a little bit after running, then run again effectively checking the files every so often and updating the new file you’ve created in the process
There you have it! Tune the Pause and Loop modules to whatever you’d like and hit the Run button on the top right while you’re streaming. It’ll read your Total Donations and Total SuperChats from StreamLabs StreamLabels and generate a new file called Total_dono_and_superchat.txt with the total. You can then use that txt file in OBS to display the number on screen.











