I'm looking to make a personal discord bot that will be used by moderators to create channels for specific users. It will be called in the form of "$create firstName lastName category user" which category is the category the channel is being created in and user is the user's username with the tag. I have managed to get it to create the channel but I am clueless as to how to give specific permissions to a user for that newly created channel. Here is my current def for creating the channel from the command
@bot.command()
async def create(ctx, firstName, lastName, category, user):
print(ctx)
role = discord.utils.get(ctx.guild.roles, name="Moderator")
if role in ctx.author.roles:
cat = discord.utils.get(ctx.guild.categories, name=category)
await ctx.guild.create_text_channel(firstName + ' ' + lastName, category=cat)
#insert permission changes for user id: user id is the actual username and tag
else:
await ctx.send("You do not have permissions to create a channel. Only Moderators do")```