Skip to content

Instantly share code, notes, and snippets.

@chuckreynolds
Last active December 12, 2022 08:33
  • Star 17 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Embed
What would you like to do?
Nightbot commands reference for Twitch and sometimes youtube gaming. Most are accessible via google and reading many docs but I like to keep things in one location for reference. If you want to see something here lmk on Twitter: https://twitter.com/chuckreynolds or comment below.

General stuff

Add, Edit, Delete Commands

  • !addcom !keyword New text here
  • !editcom !keyword Edited version of the text here
  • !delcom !keyword

Reference the user whom entered command

  • $(user)

Reference user-entered text

  • $(query)

Add an alias for another command

!addcom !newkeyword -a=!currentkeyword $(query)

Time Related

Time commands example to show your current time

!addcom !time Clintus lives near Phoenix Arizona USA. Current time there is $(time US/Arizona "LTS").

Time countdown example

!addcom !24 24 Hour Stream Status: $(countdown Mar 13 2018 03:30:00 PM America/Los_Angeles) remaining!

Follow Age / Following Since (via 2g.be)

!addcom !followage $(urlfetch https://2g.be/twitch/following.php?user=$(touser)&channel=$(channel)&format=mwdhms)

Weather

  • For Nightbot specifically: !addcom !weather $(weather 85001) (just change zipcode to what you want)
  • For StreamElements or can use w/ Nightbot too: Current $(customapi.https://api.scorpstuff.com/weather.php?units=imperial&city=Phoenix)

Social

Tweet the stream command

!addcom !tweet Click here to tweet & promote the stream! $(tweet Come watch @YOURTWITTERHANDLE play $(twitch $(channel) "{{game}} on Twitch! {{url}}"))

  • ONLY change the "YOURTWITTERHANDLE" and that message before the $(twitch part... dont touch the {{game}} or {{channel}} as those are variables that Twitch will fill in automagically.

Setup a command for LMGTFY (let me google that for you)

!addcom !lmgtfy Let Me Google That For You $(touser) http://lmgtfy.com/?q=$(querystring)

  • Usage is like this: !lmgtfy @username text to google

Add a !shoutout (or !so) command for mods to reference other streamers

!addcom -ul=moderator !shoutout Check out $(touser) at twitch.tv/$(touser)

  • Usage: !shoutout username
  • Some ppl like to use !so but I have both and alias so->shoutout. nbd.

Setup a !multiset command to auto-update !multi for multiple twitch stream viewer

  • This will overwrite anything you currently have in !multi so heads up
  • First add !multi: !addcom !multi Multi-stream link:
  • Next add !multiset command for mods+ only !addcom !multiset -ul=moderator -a=!commands edit !multi Multi-stream link: http://multitwitch.tv/$(channel)/$(query) (or use http://kadgar.net/live/ instead)
  • Usage: Never touch !multi, just do !multiset otherchannel and it'll append it to the url/yourchannel. For multiple streamers just do this: !multiset channel2/channel3/channel4 etc.

Setup a random Dad Joke in chat

!addcom !dadjoke Dad joke? Here's one: $(urlfetch http://api.scorpstuff.com/dadjokes.php)

Game specific stuff

Fortnite wins (via 2g.be)

!addcom !fortnite YOURNAME's Fortnite BR Stats: $(urlfetch https://2g.be/twitch/Fortnite/command/query=solowins%20YOURNAME&default_platform=pc&notext) $(urlfetch https://2g.be/twitch/Fortnite/command/query=duowins%20YOURNAME&default_platform=pc&notext) $(urlfetch https://2g.be/twitch/Fortnite/command/query=squadwins%20YOURNAME&default_platform=pc&notext) See all stats here: https://fortnitetracker.com/profile/pc/YOURNAME

  • Initially xgerhard set this up for query commands, I changed it to only respond w/ a certain users info but the bot didn't like this. Xgerhard setup the &notext var to turn off the username response. I'd like more customizability but it's a good start
  • Obviously change "YOURNAME" to your Fortnite username. reference
  • Also PC is default_platform=pc... change pc to ps for PS4, or xbox for Xbox.

General Code Reference

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment