Reputation:
There is any way of transfering a discord server ownership with a bot? I have beed told that there is a way to do this with a python bot but I didn't figure out how.
Upvotes: 1
Views: 11050
Reputation: 26
There is a way to make a bot own a server (create a new one). Basically you will need a Discord Bot Client and your bot's token. So you have to get your bot's token and copy it, then paste it into the Token textbox in the Discord Bot Client app. Make sure you download the app because web version doesn't work. So you paste in the token and click Login, you will be logged in as the bot. You can control the bot: send messages, attachments, add reactions and a lot more. So you basically click the + icon and you will create a new server, which the owner will be set to the bot. Note that the bot can send animated emojis without nitro in the server because for some reason you can't send animated emojis from your server without nitro lol - You can also prank people but I don't think that is a good idea. Also the bot client is useful for answering questions so you don't have to script everything.
Upvotes: 0
Reputation: 1
you can actually change server ownership with a bot. but the bot must be the owner of the server before hand.
for a bot to create a guild it must use POST /guilds to change owners you must use PATCH /guilds/{guild.id} and send over the json parameter owner_id with the id you want to transfer ownership too.
Offical Discord Documentation Links:
https://discordapp.com/developers/docs/resources/guild#create-guild https://discordapp.com/developers/docs/resources/guild#modify-guild
Upvotes: 0
Reputation: 1589
It seems that a method exists on the discord.js wrapper. .setOwner()
I couldn't find a way to see if it really works. ^^
// Edit the guild owner
guild.setOwner(guild.members.cache.first())
.then(updated => console.log(`Updated the guild owner to ${updated.owner.displayName}`))
.catch(console.error);
Upvotes: 1