When you specify a testServer and try to register a slash command, the code fails at startup.
F:\WORKSPACE\UselessBot3\node_modules\discord.js\src\rest\RequestHandler.js:154
throw new DiscordAPIError(request.path, data, request.method, res.status);
^
DiscordAPIError: Invalid Form Body
options[0].name: Command name is invalid
options[1].name: Command name is invalid
at RequestHandler.execute (F:\WORKSPACE\UselessBot3\node_modules\discord.js\src\rest\RequestHandler.js:154:13)
at processTicksAndRejections (node:internal/process/task_queues:94:5)
at async RequestHandler.push (F:\WORKSPACE\UselessBot3\node_modules\discord.js\src\rest\RequestHandler.js:39:14) {
method: 'post',
path: '/applications/633203527115735060/guilds/610160488097251359/commands',
code: 50035,
httpStatus: 400
}
When you specify a testServer and try to register a slash command, the code fails at startup.