Discord - Can't send message to user

When I try to use the official Discord node to DM a user, I get an error.
Everything else works (channel message, assign role etc.)

The error displayed is “Could not fing server for channel with the id 12XXXXX96XXXX854”

I’m not sharing the workflow because it’s only one action in one node. The picture is probably enough.

Information on your n8n setup

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

Hi @gmsalomao2! Thanks for reaching out. You can see from the error stack that the error message is not originating from n8n and that instead we’re parsing the error sent by Discord. Is the server running?

I would recommend checking your connection to the Discord server, as you’ll likely find your culprit there.

It ended up being a problem with the auth method.
When I switched to Bot Token method, it worked.

@Ludwig and @Jon may I ask you if this is a bug?

Other commands work with OAuth2 method, in this node.

1 Like

Same issue here. Sending a message to a user using OAuth2 throws an error, using the Bot Token works.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.