#Thread help

1 messages · Page 1 of 1 (latest)

jovial quail
#

Trying to set perms for all the commands to be only usable by me

odd jetty
#

So you are setting the permissions on startup of the bot?

jovial quail
#

ye

odd jetty
#

What did you rename the perms array to?

jovial quail
#
        const fullPermissions = []
        client.application.commands.fetch().then(e => {
            e.map(comm => {
                fullPermissions.push({
                    id: comm.id,
                    permissions: [{
                        id: '628703380851916827',
                        type: 'USER',
                        permission: true,
                    }],
                })
            })
            guild.commands.permissions.set({
                fullPermissions
            })
        })
    })```
#

and it didnt error

odd jetty
#

Are you using slashcommandbuilder?

jovial quail
#

ye

odd jetty
#

Add .setDefaultPermission(false)

jovial quail
#

yep

odd jetty
#

To all your commands

jovial quail
#

yep

odd jetty
#

Can you use the commands then after you have done that?

jovial quail
#

nope they dont show in the menu

odd jetty
#

So the commands aren't registering?

jovial quail
#

yeah it seems so

odd jetty
#

Drop your permissions part and see if they register

jovial quail
#

kk

odd jetty
#

They should appear like this

jovial quail
#

nothing

odd jetty
#

Are you registering commands to guild or global?

jovial quail
#

global

odd jetty
#

Global can take an hour to apply

#

Better to use guild for testing purposes

jovial quail
#

ahh okay 😮

#

okay now they show up but disabled

odd jetty
#

Good, now apply your permissions

jovial quail
#

Perfect that worked

#

so just need to wait got knows how long for global ones

odd jetty
#

Yeah, better to use guild for dev purposes

jovial quail
#

kk

odd jetty
#

Then once you are happy, push it to global

jovial quail
#

Once pushing to global I need to wait to push after clearing global right