rigwild / discord-self-bot-console

A simple Discord Self-bot using devtools console
MIT License
82 stars 15 forks source link

Embed sending not working #12

Closed ghost closed 2 years ago

ghost commented 2 years ago

Sending embeds doesn't work. Returns error 50006: "Cannot send an empty message". The sendEmbed function doesn't work too. If I try to send an embed with a message, only the message will be sent, and the embed will not be sent. Here is the code I am using:

await api.apiCall(`/channels/863292952545198090/messages`, {
    "embeds": [{
        "title": "Hello, Embed!",
        "description": "This is an embedded message."
    }]
}, 'POST')
rigwild commented 2 years ago

Just tried on my side. You are right the API changed to { embeds: Embed[] } in the last API update.

Adding a content stops the error but the embed is not sent anyway

await api.apiCall(`/channels/${cid}/messages`, {
  "content": "Hello, World!",
  "tts": false,
  "embeds": [{
    "title": "Hello, Embed!",
    "description": "This is an embedded message."
  }]
}, 'POST')

Maybe they removed the ability for non bot accounts to send embeds?

ghost commented 2 years ago

I don't quite understand if this will help, but it says that bots have full access to the API, which means that selfbots have partial access. Chances are you're right and they've removed the ability for non-bot accounts to send embeds.

rigwild commented 2 years ago

Yeah, I noticed previously that new features like components were not being sent too (https://github.com/rigwild/discord-self-bot-console/discussions/8#discussioncomment-1783198)

Ok, rip, this is not possible anymore... https://www.reddit.com/r/Discord_selfbots/comments/sa0hc2/discord_embeds_patched/

I added a message in the README, I will close this issue as I can't no anything to fix it :/ Should still work with bot accounts though.