I have been trying to use discord webhooks on roblox scripts for a bit and I am stumped.
I have tried so many methods but they are all outdated
I am trying to put a roblox character’s pfp or headshot or whatever into a discord webhook thumbnail and nothing has worked.
I’ve tried GetUserThumbnailAsync
but it doesnt return a website
I’ve also tried stuff like https://www.roblox.com/headshot-thumbnail/ or https://tr.rbxcdn.com/ but they all say forbidden
Can someone just give me an answer for this? Something that actually works and isnt outdated??
2 Likes
Discord webhooks are rejecting Roblox receusts instead you need to convert it with webhook.newstargeted.com
1 Like
oh thanks for that i was really trying to find out how to do the thing
how exactly do i convert it though?
this is what i have so far
i changed the webhook url but it isnt working, even with this thing commented.
i get HTTP 500 error
hs:PostAsync(webhook,
hs:JSONEncode({
["embeds"] = {{
["author"] = {
["name"] = display.." (@"..user..")",
},
["color"] = colors[severity],
["title"] = "Chat Message",
["description"] = "\""..msg.."\"",
["fields"] = {
{name = 'User ID:', value = "**"..id.."**"},
{name = 'Severity:', value = "**"..names[severity].."**"},
},
--["thumbnail"] = {
-- ["url"] = "https://www.roblox.com/headshot-thumbnail/image?userId=" .. id .. "&width=150&height=150&format=png"
--}
}},
})
)
on top of that, whenever i try to use the example that is listed straight from the website:
httpService:PostAsync("https://webhook.newstargeted.com/api/webhooks/{WEBHOOK_ID}/{WEBHOOK_TOKEN}",
httpService:JSONEncode({
content = "Hello, world!"
})
)
when i try that it doesnt work
ok i joined the discord server and i found it out
you dont need to change the discord webhook url, you need to change the image url
this is one i found that is currently working for me:
["thumbnail"] = {
["url"] = "https://api.newstargeted.com/roblox/users/v1/avatar-headshot?userid=" .. id .. "&size=150x150&format=Png&isCircular=false"
}