Custom Commands

Hey All!

I’m new to Nightbot and loving it so far! Thank you devs! I’ve got a bunch of different questions and instead of making one huuuuuuge post I thought it would be easier to separate it into three different posts to address each question, so please know I’m not trying to spam. ;o)

My first question relates to the custom command feature. I’m trying to make it so that the folks who chat in only have to type the following to request a song …

! url

So the chat would look something like this …

! www.test.URL_Of_Song_They_Want

As opposed to having to type out the default command of…

!songs request www.test.URL_Of_Song_They_Want

I’ve provided a screenshot below of what I tried to do to make that happen, but for some reason it didn’t work. Apparently I’m misapprehending the instructions or something. Any ideas? Thank you so so much for your time! Seriously appreciated.

You’ll need to pass along the rest of the data with $(query) for user input (mentioned at the bottom of the alias section). Something like this will work:

!commands add ! -a=!songs request $(query)

Hey Aaron!

Thanks so much for all of your responses! So helpful dude!

I’m still a little confused on this one. I tried pasting your suggested command in a couple of different ways b/c I wasn’t sure where to put it. First, I tried it in the “Alias” section of the custom command dialogue box as seen below. When I used it in the chat, it didn’t work so then I tried putting your suggested command in the “Command” section of the custom command dialogue box, and it still didn’t work. Any ideas?

Hey @kmarler18!

That’s not what Aaron meant, the code he gave you is to add the command from the chat, which would give this command in the dashboard:

1 Like

Awesome! Worked like a charm! Thank you so much!

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.