Hi,
I have 2 questions
- How can I give badge based on remote from discord bot?
- Are ToS alowing this?
I want it for giving badge for reading rules for discord server, so badge collectors will have bigger motivation to read it.
Hi,
I have 2 questions
I want it for giving badge for reading rules for discord server, so badge collectors will have bigger motivation to read it.
The Badges API does not have a method for awarding badges, but the general API does under the assets category. I would imagine that you cannot remotely award a badge because then a request from a Discord server doesn’t carry sufficient authentication details to guard against being able to award badges from other games. You may be able to do it with certain fields in the POST request but it’s not explained what they are nor are any examples given.
The Terms of Service are not going to explicitly state whether this is allowed or not but the logical guess is that it’s permitted. The real question is whether it’s possible in the first place or not and from my understanding, no it isn’t.
Nice new username, colbert.
It could be though.
What you’d do is in the discord bot, if they react then you add their list to a db. (Hosted off a site)
Then, when a player joins, it checks if their name is on the db. If it is, then it’ll give the badge.
I believe that it is possible.
Fair. It’s not a direct solution but I suppose it’s still one at all. How agreeable it is I can’t tell you for sure but I’m not the one to decide that here.
You could use a third party service to act as a cache of names of players who should be awarded a certain badge when they next join. So in essence, your Discord bot would upload a name to that database/cache/whatever and then notify the player that they’ll be able to claim a badge when they next join a server.
Smart. I like that.
Thanks. I wanted Post_Approval but someone sniped that.
True, or you could just intergrate it into the bot itself.
I’ve done it myself w/ bans.
That you set it via the bots, it puts that db onto a website, and roblox pools from it.
Looking at you:
How would you mean integrate it into the bot? Are you able to store information in a Discord application raw or was there a difference in what I mentioned?
There’s also the point of determining the argument for awarding the badge. You could just pass a Roblox name so that it’s -award [plr] [badge]
or something. I know RoVer has a public-facing API with Roblox-Discord name fetching and vice versa but last I heard the features were restricted for privacy reasons, so awarding by Discord account is probably right out.
I know how to make bot (and i prefer heroku)
So like, the database is w/ the bot.
As in this example, the bot might run in node.js
Therefore, you can use express to create a webserver, and that pulls from the basic.db package every 1 minute.
Then, you could use discord.js to run a bot, ofc.
And set it.
You’d use the Roblox username or id, not a tag.
How? As when you join the server, the user’s username would be set to their roblox username; so you’d just take their username.
PS: When storing it you’d store their userid.
Yes.
I just used Glitch as an example beacuse you can create a website from it.
Or in this case, put the json on a webpage
As Colbert said (not mentioning your new name lmao), you can award badges with the general api. You’re going to have to use a wrapper for the Roblox web api though.
This includes using your .ROBLOSECURITY cookie token, and updating a csrf header value called “x-csrf-token”. This way, you’ll be able to award badges to any user (who has joined your game, I believe).
I have tested the badge api myself, so yeah, it does work as expected.
You can stop it from sleeping.
Just use UptimeRobot.
Not needed for this.
As you are just trying to get their id from their username.
I tried, but it was crashing xC
It’s all been fixed now.
It doesn’t crash anymore.