用于Discord API,它提供了一个界面,允许您为Discord消息传递服务编程机器人。
[2025-03-17 17:35:34] [INFO ] discord.client: logging in using static token Traceback (most recent call last): File "C:\Users\yahowa\Desktop\SkinPort İnstaBuy Bot\bot.py", line 83, in <module> bot.run('MY BOT TOKEN I DELETED I KNOW THERES NO TOKEN') File "C:\Users\yahowa\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\client.py", line 906, in run asyncio.run(runner()) File "C:\Users\yahowa\AppData\Local\Programs\Python\Python310\lib\asyncio\runners.py", line 44, in run return loop.run_until_complete(main) File "C:\Users\yahowa\AppData\Local\Programs\Python\Python310\lib\asyncio\base_events.py", line 649, in run_until_complete return future.result() File "C:\Users\yahowa\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\client.py", line 895, in runner await self.start(token, reconnect=reconnect) File "C:\Users\yahowa\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\client.py", line 824, in start await self.connect(reconnect=reconnect) File "C:\Users\yahowa\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\client.py", line 748, in connect raise PrivilegedIntentsRequired(exc.shard_id) from None discord.errors.PrivilegedIntentsRequired: Shard ID None is requesting privileged intents that have not been explicitly enabled in the developer portal. It is recommended to go to https://discord.com/developers/applications/ and explicitly enable the privileged intents within your application's page. If this is not possible, then consider disabling the privileged intents instead.
discordApp(使用discord.js,node.js构建)slash命令在服务器内部工作,但在dm
我的应用程序在服务器中起作用
真的不确定为什么,但似乎我的斜杠命令正在注册两次。我尝试了各种方法,是的,使用chatgpt,但是到目前为止,所有结果都具有重复。 有什么建议吗? (此外...
def addLogger(fn): from functools import wraps @wraps(fn) async def add_logger(*args, **kwargs): print(f"addLogger: About to run {fn.__name__}") log = logger startTime = time.time() log.info('About to run %s' % fn.__name__) result = await fn(*args, **kwargs) log.info('Done running %s Execution time: %s' % (fn.__name__, time.time() - startTime)) print(f"addLogger: Done running {fn.__name__}") return result return add_logger
如何更正此命令?我需要为删除所有消息,用户和bots创建一个命令
这是代码 @bot.command() @commands.has_permissions(manage_messages = true) 异步def delmessages(ctx,id = none,quasity = none): 公会= ctx.guild id = discord.textchannel.id(id) 噢...
我想让我的Discord Bot加入语音聊天,但是每次运行命令时,我都会在日志(CMD)中收到一个错误消息,说:
当我运行时,没有控制台输出 节点src/register-commands.js 。已经正确设置了.env文件,这就是我的代码的样子: require('dotenv')。config(); console.log('tok ...
在我的Discord bot上,我创建了A /清除所有命令,该命令通过使用channel.clone()discordjs v14的函数来克隆当前频道(这会创建一个具有相同名称a ... a ...
目标是没有的,并且有机会看到哪个用户是通过此管理员移动的?
我对事件的问题有一个问题,即on_message_pin和on_message_unpin,当消息被固定或取消封锁时,都应调用两个事件,但是在我的scritp中,应无效。我有任何我的意见...
因此,即使我快速打开它,也可以将游戏添加到用户中,但不会被删除 if(oldpresence.activities.count(e => convert.tostring(e.type)==“ play”)> ...
这是代码 const body =等待提取(`https://shot.screenshotapi.net/screenshot?&url = $
我想在不和谐中编写一个小机器人,我遇到了一个问题,即命令没有显示,并且不起作用。如何修复它? 范围: 在此处输入图像描述 代码: @bot.tree.