Unable to register Slash commands

i am getting 401 error while trying to register slash commands
the error:
> discord-getting-started@1.0.0 register
> node commands.js

401
Error: {"message":"401: Unauthorized","code":0}
    at DiscordRequest (file:///C:/Users/Dharamveer/Desktop/Discord%20app/discord-example-app/utils.js:21:11)
    at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
    at async InstallGlobalCommands (file:///C:/Users/Dharamveer/Desktop/Discord%20app/discord-example-app/utils.js:33:5)
Was this page helpful?