1

enter image description here enter image description here My Code:

import disnake
from disnake.ext import commands

intents = disnake.Intents.default()
intents.members = True
intents.message_content = True

bot = commands.Bot(command_prefix=commands.when_mentioned_or("!"), intents=intents)

@bot.slash_command()
async def generate_password(inter):
    await inter.response.send_message("password")
    
@bot.event
async def on_ready():
    print(f"Logged in as {bot.user} (ID: {bot.user.id})\n------")

bot.run("token")

How to I make it so the user who executed can see it, the image describes it better

I have no idea how to do this.

  • Does this answer your question? [How do you send a private message in discord.py to command user?](https://stackoverflow.com/questions/71748448/how-do-you-send-a-private-message-in-discord-py-to-command-user) – mx0 Nov 04 '22 at 16:59

1 Answers1

1

Oh, i Get what you Mean,Those are Called Ephemeral Messages, And You can easy make them By:

@bot.slash_command()
async def generate_password(interaction):
    await interaction.response.send_message("password", ephemeral=True)