tycrek / discord-hookr

A lightweight and easy way to send webhooks to Discord, without the added baggage of a full API client.
ISC License
2 stars 0 forks source link

HTTP 400 bad reqeust from Discord API #1

Open stratbasher opened 1 year ago

stratbasher commented 1 year ago

Hello,

I'm getting an error when trying to use this library. The original library worked.


const hook = new Webhook("webhookurlhere");

hook.setUsername("Captain Hook");

const builder = new EmbedBuilder().setTitle("test").setURL("https://www.google.com").setImage("https://picsum.photos/200/300");

const embed = builder.getEmbed();

hook.addEmbed(embed);

hook.send();

Uncaught Error: Error: Received HTTP 400 Bad Request from Discord API.
saitho commented 8 months ago

I'm also having issues with dynamic image URLs being not shown in the Discord embed, but with both libraries. Can you try without the image? picsum.photos seems to redirect, maybe that's an issue for the Discord API server.