Best answer

Failed to create a message in Slack: Error from Slack: channel_not_found

  • 30 March 2023
  • 7 replies
  • 392 views

Userlevel 2
Badge +1

I keep getting an error message when trying to send a private DM using the Slackbot. 

I use the “custom username” field to define which user will receive the private DM. This was working fine yesterday, and all of a sudden today I keep getting the following error message :

Failed to create a message in Slack, 

Error from Slack: channel_not_found

 

I am indeed an admin on Slack.

icon

Best answer by SamB 30 March 2023, 15:07

View original

7 replies

Userlevel 7
Badge +11

Hi @xavierB, thanks for joining the Community! 🙂

Ah, I’ve seen that error before when a username was typed into the To Username field instead of their member ID number. Was that the case here?

If so, you’d need to specify the ID number when using the custom value option instead of their username. That should help Slack to identify which user it should send the DM to. 
You may need to add a Find User by Username (Slack) action to obtain the ID for the user, if you only have the username value available. Then you can select the ID for the user that’s found by Find User by Username action.

Can you give that a try and let me know if that does the trick?

Userlevel 2
Badge +1

That indeed does work, but it adds a layer of complexity of having to find the slack user ID of the member.

Just so you know, after extensive testing, I have noticed that Zapier can tag slack users from before roughly 2021, and cannot tag slack users that signed up on Slack after. Very very weird bug.

 

 

Userlevel 7
Badge +11

Thanks for confirming that, @xavierB! 🙂

I’m so pleased it worked. Sorry it’s not an ideal solution as it involves adding an extra action to the Zap.   

I’ve not come across that behaviour before, where only users who joined before 2021 are tagged correctly when @mentioned. If you use their member ID to @mention them does it correctly tag them in the message? E.g. <@MemberID> instead of <@username>

Also, if the username is @firstname lastname, you might need to add in a “.” in between the first and last names. For example: @firstname.lastname

Hope that helps. Please do keep us in the loop on how that goes!

Hi there,

 

I’ve selected Slack ID from custom fields under the channel field and still getting the same error “Failed to create a message in Slack, Error from Slack: channel_not_found”

 

Current flow includes: 

 

When column changes in Monday.com

Search for slack user by email (as a column in Monday.com board)

Send direct message in slack 

 

Any idea what may be causing this error?

Userlevel 7
Badge +9

Hey there, @accounts help euc - sorry to hear you’re running into this. 

Can you share a screenshot of your “Send DM” Slack action with any personal details removed? That may help us get a better idea what’s going on here. To be clear, the “ID” Sam is referring to would be the user ID, pulled from the search step, and mapped into the username field. 

I hope some of this helps! 🧡

Userlevel 2
Badge +1

@accounts help euc Have you tried with earlier Slack users? For me, only the ones registered after ~2021 return a channel_not_found error, while all our early users have zero issues.

I’ve reported the bug to Zapier but it has been dismissed as me not tagging the Slack users correctly, even though I did extensive back-end and front-end testing.

Userlevel 3
Badge +4

Hi @xavierB 

I’m sorry that you’re having issues with your Zap.

Could you share how you’ve set up the steps of the Zap so far?

Also, based on the error message you mentioned, “Failed to create a message in Slack, Error from Slack: channel_not_found,” I’m thinking the issue might be related to the Slack Channel not the user.

Looking forward to your response!

Reply