Hey guys! I’m currently trying to make a command for nightbot that fetches the first row of a Google sheet and displays it when the command is used. I was wondering if it is even possible to do with nightbot, judging by the lack of info when it comes to this. The current code that I have is this:
$(eval JSON.parse(decodeURIComponent(’$(querystring $(urlfetch json <https://myurl.com)
This is only a portion of the command. The link in there is a published plaintext file that outputs to JSON. I got the second portion of the command from an older forum post about this, but, nightbot doesn’t recognize the right row, and gives all sorts of errors when the command is attempted. This is the second portion of the code:
)))).feed.entry.filter(x=>x[
gs$cell][
col]==1).map(x=>x[
gs$cell][
$t]).join(
| ).slice(0,400)||
Error!`)
I’m reletively new to JavaScript, so, I’m not really sure how to troubleshoot this. If anyone has any ideas about this is would be greatly appreciated. -Maestro
Edit: Took out a link that leaked an email