slackapi / bolt-js

A framework to build Slack apps using JavaScript
https://tools.slack.dev/bolt-js/
MIT License
2.75k stars 394 forks source link

Socket mode not response #2216

Closed ropiDK closed 2 months ago

ropiDK commented 2 months ago

im trying to use socket mode, yesterday all already successful, but now when im trying to hit the command slash, i got this error

/command-slah failed with the error "dispatch_failed"

thanks

seratch commented 2 months ago

Hi @ropiDK, thanks for asking the question!

There are a few possible causes of your situation:

I hope this helps. If you need more information, enabling debug-level logging for your app may display further helpful information for you: https://slack.dev/bolt-js/concepts/logging.

ropiDK commented 2 months ago

thanks, for the slash command already work, but for message, mention, and other event not work

ropiDK commented 2 months ago

do you have any best practice, how to develop with 2 environment like development and production

seratch commented 2 months ago

Regarding enabling message events, please double-check if you've properly configured the Event Subscriptions page on https://api.slack.com/apps and invited your app's bot user to the channel where you want to receive message events. As for dev/prod management, the common approach is to create two apps (dev and prod). You can install both into the same testing workspace.

ropiDK commented 2 months ago

actually i already created 2 apps, but i face this issue

seratch commented 2 months ago

If you're mentioning the issue about event subscription, having two apps is not a solution for it. Please double-check if you've enabled bot events - message, app_metion and re-install the app with sufficient permissions. Also, inviting your app's bot user to the channels you want to use is necessary to enable it. If you have two apps with the same name, I'd suggest adding suffix like "(dev)" to the dev version of the app to avoid confusion.

ropiDK commented 2 months ago

ok thank's, i'll try again...

one more question, why when i created new app, the new app now show on my slack app client? im using manifest to create new app, and already install to workspace, but cannot see on app, when im trying to add to channel

seratch commented 2 months ago

Do you mean you don't see a newly installed app on your Slack client right after the installation? If yes, please try restarting the Slack app (or reloading the app by ctrl + r). If this does not work out, you might have installed the app into a different workspace (or the installation failed for some reason).

ropiDK commented 2 months ago

i already installed to correct workspace, but cannot see, already reload the browser, i created SREBot (DEV), but not found Screenshot 2024-08-23 at 11 55 41

seratch commented 2 months ago

You can either use /invite @bot-user-name-here or click the channel name, go to "Integrations" tab, click "add apps"

ropiDK commented 2 months ago

thank's, now it's visible