Skip to content

Discord

Send messages to Discord users and channels through Sendivent.

Setup

Connect a Discord bot to enable Discord notifications.

  1. Go to the Discord Developer Portal
  2. Click New Application, give it a name
  3. Go to Bot in the sidebar, click Reset Token to generate a bot token
  4. Copy the token
  5. Under Privileged Gateway Intents, enable Message Content Intent if you plan to receive messages
  6. Go to OAuth2 → URL Generator, select bot scope with Send Messages permission
  7. Use the generated URL to add the bot to your server
  8. Go to Channels → Discord in your Sendivent dashboard
  9. Paste the bot token and save

Sendivent verifies the token by calling the Discord API. If verification fails, regenerate the token in the Developer Portal.

Identifiers

Send to individual users (DMs) or channels:

TypeFormatExample
User (DM)Snowflake user ID80351110224678912
ChannelSnowflake channel ID1045629063945326592

Both user IDs and channel IDs are 17-20 digit numeric strings.

Finding a user's Discord ID

  1. Open Discord Settings → Advanced → Developer Mode (enable it)
  2. Right-click a user → Copy User ID

Sending to channels

  1. Ensure the bot has been added to the server and has Send Messages permission in the target channel
  2. Right-click the channel → Copy Channel ID
  3. Use the channel ID as a broadcast target in your event configuration

Message format

Discord messages use Markdown formatting:

SyntaxResult
**bold**bold
*italic*italic
`code`code
[text](url)clickable link
> quoteblock quote

Maximum message length is 2,000 characters.

Troubleshooting

Cannot send messages to this user (50007)

The user has DMs disabled or has blocked the bot. They need to enable DMs in their server privacy settings, or the bot needs to share a server with the user.

No mutual guilds (50278)

The bot and user don't share any servers. Add the bot to a server where the user is a member.

Missing permissions (50001 / 50013)

The bot doesn't have permission to send messages in the target channel. Check the bot's role permissions in the server settings.

Unknown user or channel (10013 / 10003)

The user or channel ID is invalid. Verify you're using the correct Snowflake ID.

Invalid bot token

Regenerate the token in the Discord Developer Portal under your application's Bot settings.

See also

Released under the MIT License.