Gettting a player thumbnail for a Discord webhook

  1. What do you want to achieve?
    Put a headshot (image) of a player in a Discord webhook
  2. What is the issue?
    To put it simply, I have no idea what I’m doing, I just need to get an image URL of the player
  3. What solutions have you tried so far?
    I’ve been looking at various posts for the past hour or two, I’ve tried using HttpService:GetAsync() and things along that line.
--change these to whatever needed
local thumbnailType = Enum.ThumbnailType.HeadShot
local thumbnailSize = Enum.ThumbnailSize.Size420x420

local image, ready = game.Players:GetUserThumbnailAsync(USER_ID, thumbnailType, thumbnailSize)

--you can then send the image through a discord webhook.

That doesn’t return an image URL does it?

You should be able to use these urls found in this post: New image endpoints that can be used in-game!

You can replace the userId section with what you want and use that url as the image url and should work.

1 Like

It does return the URL. That’s the “image” return parameter.

1 Like