valorant !rank command

I’ve seen someone do !rank with this command so I copied it so I can update it for the channels i mod for but it doesn’t wanna work for some reason.
When i try it I get this response back: Unexpected token ‘%’ but when i tried it the other day i got Unexpected token o in JSON at position 1. I don’t know am i typing it wrong I just copied it.

This is the coding for the command:

@$(user), $(eval r = $(urlfetch json;g=%22%22;json = JSON.parse(r);;;m =; g+=“Hypers current rank is " +rank1+” - "+rank+"RR. ";if (m > 0){g += “Gained +” + m + “RR last game.”;}else{g += "Lost " + m + “RR last game.”;}g;)

Hey @abcd!

Please either link the original post you got this code from, or format it properly as code so it’s easy to read and the website formatting doesn’t mess with it.

I’ll redirect you to a similar topic where I provided an answer: