How do I add temprole to any user in an automated way using djs14??

I know I can use dyno bot or carl bot for it but I want to automate it. Writing my own temprole feature feels like peeling off skin from the side of my fingernails. I tried to do this but it wont work for obvious reasons because carl bot ignores my bot.I know I can use dyno bot or carl bot for it but I want to automate it. Writing my own temprole feature feels like peeling off skin from the side of my fingernails. I tried to do this but it wont work for obvious reasons because carl bot ignores my bot.
46 Replies
d.js toolkit
d.js toolkit3mo ago
- What's your exact discord.js npm list discord.js and node node -v version? - Not a discord.js issue? Check out #other-js-ts. - Consider reading #how-to-get-help to improve your question! - Explain what exactly your issue is. - Post the full error stack trace, not just the top part! - Show your code! - Issue solved? Press the button! - Marked as resolved by staff
BigBrainAFK
BigBrainAFK3mo ago
so do you have any code of your attempts to write this yourself?
Devvvvvv
Devvvvvv3mo ago
the image above? yes that message is written using code that checks for a certain action, just that carl bot ignores my message
BigBrainAFK
BigBrainAFK3mo ago
so your bot already knows who to give the roles to. at that point just add the roles via your bot and have some automated cron like jobs to remove them after the time, of 30mins in the screenshot, instead of using a secondary bot
Devvvvvv
Devvvvvv3mo ago
I thought it is the same as me doing it manually, how would it be innefficient?? @Qjuh cron job is like a thread?
chewie
chewie3mo ago
Because any decent bot ignores other bots
Devvvvvv
Devvvvvv3mo ago
they could atleast add a feature to make exceptions 😭
BigBrainAFK
BigBrainAFK3mo ago
well first off you automated the command generation already and then try to pass of the small work left to another bot idk how this is an effective solution (passing it to another bot that is)
Devvvvvv
Devvvvvv3mo ago
no im not storing anthing 😭
BigBrainAFK
BigBrainAFK3mo ago
yeah idk where your bot gets the role names from then
Devvvvvv
Devvvvvv3mo ago
so i need to enter a key in a modal and if the key works then the bot assigns a temp role to user problem with cronjob (like a thread or timer i think) i see is that if my bot goes down then it forgets to take off role hwne it comes back up hence database and if i want to implement robustly this solution, i need to write another database system that tracks all this the role names are hardcoded since they are specific to this "key" feature i have no database solution implemented yes they are actual roles that i want to remove from users after a while, like a temp access kind of thing
BigBrainAFK
BigBrainAFK3mo ago
implementing sqlite is simple
Devvvvvv
Devvvvvv3mo ago
is there no other way other than databases 😭 this is why im passing of this job to super efficient largescale god carl bot or dyno bot yes but then if my bot gies down for maintainance or some other issue, people with the roles keep it
BigBrainAFK
BigBrainAFK3mo ago
no if it comes back up you remove all the timed roles (of people who have it)
Devvvvvv
Devvvvvv3mo ago
yes but untill it comes back up also how would i mass remove roles? (its interesting)
Want results from more Discord servers?
Add your server