NightDev Community Forums

[CustomAPI] Quote system



I have setted up this quote system quite a while ago and it was working.
When I try now, I get an 500 Server Error.

Were there any changes in usage, is the service just not working at the moment, or is the service retired/deprecated?

Nightbot says: “Remote Server Returned Code 500”

When opening the link in the browser directly: “500 Internal Server Error
The server has either erred or is incapable of performing the requested operation.”

Thanks for any hint


I’m also getting the 500 server error. Please let me know if it gets fixed.


!quote list does not work,


can you re arange the quotes


I am using this quote system to moderator the songlist for a friend of mine playing guitarhero.


I wonder if there is anyway to remove more than one id with only one command?

At the moment we have a !clear for clearing the whole list and !clearid to clear a specific one.

Sorry for my rusty english.


Also i have another question. It is probably not possible, but is there in any way you can make the text size going to the weblink bigger in size?


It’s not possible to delete more than 1 quote at a time without wiping them all, sadly.
As for your second post about the size of the font, you could adjust the “zoom” in your browser, I think at this point every browser has that somewhere.


I have been reading up in here but seeing how helpful everyone is I kind of wanted to post to make sure I understand some things correctly.

What I want to do is make a !fact command. I want to personally add all the facts, I’m assuming it would have to be one by one, let me know if there is an easier way to add them.

I only want one command that people can type in chat and they will get a random fact.

Do remove the numbering system would I only have to add &no_id=1 in the end of the link? and only for the command that people will use to generate the fact in chat?

I think I would also like to remove the part where they can see all the facts in a list.
Is that possible?

Also I think I would be ok having the !fact “cookie” thing for example.

I would also like to know how the timer thing would work, if I’d want a random fact to come up in chat every so minutes for later use.

How would this be set up in the timers tab in nightbot? Would I just add the interval I want and the alias: !fact ??


I try to establish a management of links with this quote-system. Everything works fine, except of editing a specific entry.

There is a problem in $(querystring) in combination with another API, which is generating the links automatically.

#addmulti = $(urlfetch$(urlfetch$(querystring)))

-> When I type #addmulti stream1 stream2 a new entry is added (

#editmulti = $(urlfetch$(urlfetch$(querystring)))

-> When I type #editmulti 1 stream1 stream2, I get following message: “You must specify entry index and new value.”

So I tried to split the $(querystring) with $(eval) command by studying stackexchange, but I haven’t got that working! scripting knowledge too bad :frowning:

-> $(urlfetch"$eval( var str1 = “$(eval var q = “$(querystring)”;q.slice(0,q.indexOf(”%20")))"; var str2 = “$(urlfetch”$(eval var q = “$(querystring)”;q.slice(q.indexOf("%20") + 1))")"; var res = str.1.concat(str2);)")

Could someone help me out to get that working?
Thanks in advance


Nightbot doesn’t support more than 2 levels of variable nesting, so you need to form the link yourself, rather than using Here is code for #editmulti that does this:

$(urlfetch$(eval e=encodeURIComponent;m=decodeURIComponent("$(querystring)").match(/^(\d+) (.+)$/);if(m&&((s=m[2].replace(/@/g,"").split(" ").filter(c=>c.length).map(c=>e(c))),s.length)){"="+e(m[1]+""+s.join("/"))}else{"="}))


I’m a moderator in a server that uses this quote API, and I’ve run into a sticky situation.

The server moderators have noticed that Nightbot occasionally deletes some of our commands. Today, the !addquote command got deleted.

Since the quote API was installed automatically, the server moderators don’t know what the private key is to fix this command. We still have the !delquote and !quote commands, along with the public key.

Is there any way that this issue could be fixed?


Nightbot does not automatically delete commands. The broadcaster, a manager for the channel, or a mod is deleting the commands.

Have the broadcaster or a manager go to and select the edit button for the !delquote command. They will see something like this in the Message field: $(urlfetch$(querystring)) (but with a different token).

They should copy this text, close the edit window, then add a new command. Name this new command !addquote, paste the copied text in the Message field, and change del to add. Click Submit.


The issue has been fixed now. Thanks so much for the help!


Nightbot doesn’t support more than 2 levels of variable nesting, so you need to form the link yourself, rather than using Here is code for #editmulti that does this

Works quite well. Thanks a lot :+1:


Hey all. I don’t know if this is already somewhere in this thread, but I can’t seem to find it. I’m using the quote coding to create a queue in my stream, and would like to be able to move a name (or “quote”) from one position to another, and can’t quite figure out the code to do so. So it would be like !move 1 to 5 ideally moving the quote or user in position 1 to position 5. Any help would be greatly appreciated!


I’m actually using this API to create minigames to entertain viewers when the streamer has moments they can’t engage chat. I have been using the editquote function to change values in a list and use it as condition “checks” on whether the game should proceed. Is there a way to remove/not show the resulting statements “Successfully modified entry #X” when Nightbot responds? It ruins the immersion and feels very sloppy. I tried experimenting with slice() but couldn’t get it to work properly, so I was wondering if you could give me an example.


I don’t think you can stop Nightbot from giving a response whenever you use the customapi, but you can certainly modify its response using $(eval). You can follow this example:

!addcom !examplecommand $(eval blah="$(urlfetch$(query))";"​")

Setting variable “blah” equal to a string containing $(urlfetch) will call that urlfetch and edit the list. After that, the $(eval) will output the next line. Inside the “​” is a zero-width space. Basically this will make Nightbot appear to output a blank message instead of “Successfully modified entry #X


Ah that works, awesome thanks


I’m having a hard time removing the numbers when i bring it !quote. In nightbot, I add, &no_id=1 and when i use the command, I literally see, “&no_id=1”

Please advise! Thanks again for such a great command


You are probably putting &no_id=1 after the final parenthesis. It needs to go before the final parenthesis. Example: