Slack trigger and and resposnse

Describe the problem/error/question

Im using Slack as a trigger, I am planning this so different users can use it in slacks VIA dm, i want the bot receive request via DM but also get replies from the bot via them for multiple users, if user A dm the bot that user will receive the reply to its own Dm, but also the same with user B and C etc…if i cant do that how about ill make a channel for each user and use that channel to talk to the bot.

I cant contain all the messages/conversation inside a DM. I need to go out of the dm just to message the bot and receive the messages when it was process via rag and read that on my DM.

here are my slacks permissions

What is the error message (if any)?

Please share your workflow


Share the output returned by the last node

Information on your n8n setup

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

Hi @Betty Welcome!
You can try using the BOT mention thing so that each user can mention the bot and interact with it personally, and so if the DMs dont combine you can just use the channel ID for the last check before responding, just make sure to use all the right permissions for your slack app/bot and that is it, i built this and by always checking the channel ID to route the replies back to the correct DM i mean user.

Hi, thanks for replying, app mention is on, my workflow is like this gets a trigger from an app mentionn, direct dm to bot or channel, proccess things in RAG, goes thru an if node if there is items missing or clarification, send it via user. but whenever i reply to the DM of the bot, it wont “hear” the message even if the apps mention is on

i cant converse on it on a DM, i need to go out the of the DM and see the response in a channel

@Betty have you added message.im bot event subscriptions? Although this can cause troubles in a huge workspace but you can try switching your n8n slack trigger to “Watch Whole Workspace”. And again make sure your slack bot has all the required scopes enabled, as mostly slack problems are really related to slack credentials:

yeah that is turned on too, thats why im kinda stuck why its not receiving app mentions in user

DMS

@Betty Have you set the webhook URL for trigger on slack correctly? And does it work with all other operations of trigger? (If Yes consider revoking that token and then let me know as if you have everything turned on that issue should be resolved)

revoked the app_mention in event subscription and also change the trigger to all events, when i dm the bot app it triggers, replies to user under users chat name, not the bot name/chat, when i try to reply under that converstation still cant listen back when i chat :frowning:

im not hitting reply when i message back, just regular chat, .

when i look at the tokens there is only one. bot user oath token

tried even creating a new app bot but still nothing :frowning:

found a post that almost the same issue as mine, looks like they solved with an filter node but dont know how tho How to get slack trigger to work by sending a direct message to the bot in slack - Questions - n8n Community

@Betty i should not mention, but have you checked the webhook URL your flows are using? As slack only allows 1 URL per slack app, so make sure you handle this correctly as which trigger is getting fired by which client, this can be a bad cause. (verify that in your event subscriptions), also in your DM sending flow make sure the channel ID is coming properly and working, also that starts with D, let me know if this brings some help.

welcome to the n8n community @Betty !

Adding to what has already been said, I think this may be a combination of factors rather than a single root cause.

I’d check those pieces together: make sure DM events are actually being handled, not just app_mention; keep the bot_id filter in place to prevent the workflow from triggering itself; and always reply using the original event.channel, especially in DMs.

Each point already mentioned above is valid on its own, and Anshul and Benjamin both raised good points, but putting them together is probably what will make the flow behave consistently across both channels and direct messages.
Hope this helps clarify things a bit.