question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

"DiscordInteraction" doesn't work in Direct Messages

See original GitHub issue

On a direct message, the member and guild_id are null.

Guild:

{"channel_id":"513405772911345664","data":{"id":"812846584084955136","name":"online"},"guild_id":"268353819409252352","id":"814909719054647316","member":{"deaf":false,"is_pending":false,"joined_at":"2017-01-10T12:22:16.323000+00:00","mute":false,"nick":null,"pending":false,"permissions":"4294967295","premium_since":null,"roles":["297051132793061378","334711955736625185","401353261266763778","650869752524439563","693210200496144424"],"user":{"avatar":"8bd2b747f135c65fd2da873c34ba485c","discriminator":"4185","id":"123170274651668480","public_flags":131712,"username":"MrPowerGamerBR"}},"token":"-","type":2,"version":1}

Direct Message:

{"channel_id":"637662290170216458","data":{"id":"812857383717699626","name":"online"},"id":"814909846746431539","token":"-","type":2,"user":{"avatar":"8bd2b747f135c65fd2da873c34ba485c","discriminator":"4185","id":"123170274651668480","public_flags":131712,"username":"MrPowerGamerBR"},"version":1}

This causes errors when trying to parse a command received via direct message.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
DRSchlaubicommented, Feb 26, 2021

Look at that Discord updates their API so quickly I didn’t even notice

0reactions
HopeBaroncommented, Mar 14, 2021

fixed as of #201

Read more comments on GitHub >

github_iconTop Results From Across the Web

discord.js sending DM in response to user's slash commands
I assume I'm doing something wrong (per the error), but I can't figure out the cookbook to DM the user from the slash...
Read more >
Interactions - Discord
An Interaction is the message that your application receives when a user uses an application command or a message component. For Slash Commands,...
Read more >
Interactions API Reference - discord.py - Read the Docs
This function is a coroutine. Edits the original interaction response message. This is a lower level interface to InteractionMessage.edit() in case you do...
Read more >
Command response methods | discord.js Guide
The most common way of sending a response is by using the ChatInputCommandInteraction#reply() method, as you have done in earlier examples. This ...
Read more >
Discord Bot Troubleshooting - Scryfall
The bot does not reply at all. Check the Discord status to see if anything is currently affecting messages. Make sure the bot...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found