📌  相关文章
📜  discord.py 向具有多个 id 的通道发送消息 - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:17.430000             🧑  作者: Mango

代码示例2
@bot.command(pass_context=True)
async def ping(ctx):
    channels_to_send = ["1234567890", "234567890"]
    for channel_id in channels_to_send:
        channel = bot.get_channel(channel_id)
        await bot.send_message(channel, "Pong")