Getting a players profile picture URL


I am trying to get the URL for the player’s profile picture for a discord webhook.

I saw another thread on this involving API’s but no mention on how to do it.

Can someone please help me out here?


1 Like

Avatar Thumbnmails API:

I understand I need that API, but how do I use it?

local Players = game:GetService("Players")

local player = Players.LocalPlayer

-- Fetch the thumbnail
local userId = player.UserId
local thumbType = Enum.ThumbnailType.HeadShot
local thumbSize = Enum.ThumbnailSize.Size420x420
local content, isReady = Players:GetUserThumbnailAsync(userId, thumbType, thumbSize)

-- Set the ImageLabel's content to the user thumbnail
local imageLabel = script.Parent
imageLabel.Image = content
imageLabel.Size =, 420, 0, 420)

OK, so down the page, there is the Users section, click GET to see the Parameters required. Click “Try It Out” to enter some test parameters such as the payer Ids, then click Execute and it will show you the curl request, an example GET and then the response.

My example:

curl -X 'GET' \
  '' \
  -H 'accept: application/json'

Test URL:
JSON Response:

  "data": [
      "targetId": 576373112,
      "state": "Completed",
      "imageUrl": "",
      "version": "TN3"

It is this JSON response that you will need to parse and extract the imageUrl from in Disco.