Tr.rbxcdn.com images not displaying in-game

I wanted to load user avatars in-game but my image is not loading
Screen Shot 2564-11-21 at 3.02.13 PM
Screen Shot 2564-11-21 at 3.02.17 PM

This is the url https://tr.rbxcdn.com/c4265017c98559993061733b1125a23c/48/48/AvatarHeadshot/Png

I cannot use GetUserThumbnailAsync or https://www.roblox.com/bust-thumbnail/image?userId=1&width=420&height=420&format=png because I don’t know what is the user user-id

any way to display the image?

use GetUserThumbnailAsync() function
https://developer.roblox.com/en-us/api-reference/function/Players/GetUserThumbnailAsync

I can’t use it because in my case i won’t know the user userId

Why can you not just use Player.UserId to retrieve the ID?

you can do
game.Players.LocalPlayer.UserId

I got the image using Roblox API and roblox doesn’t show user ID for privacy reasons, so i tried to display the user profile using their tr.rbxcdn image

Okay. Can you explain to me what tr.rbxcdn.com is and why you need to use it?
As @Winbloo mentioned, you can obtain the ID and thumbnail icon of any given player. What do you need this site for?

I’m making a ui for showing list of servers, I’m using roblox API to get list of sevrer and players that is in the server.

The response only showed player profile, not UserID or Name. So I wanted to display only their user profile but it doesn’t work because the image is tr.rbxcdn. so i wanted to know is there any way around it and if you know please help me

1 Like

Use game.Players:GetUserIdFromNameAsync("NameHere")) for getting userid from a username

but I don’t have both username and user-id.

What do you mean by it only shows player profile, what info does it show?

It doesn’t show any info except the player avatar image (player profile)

You probably can’t do this because roblox only loads www.roblox.com images in-game (afaik). That endpoint is used for loading player thumbnails in your browser

1 Like

oh okay thank you! I guess i will just use messaging service to get user profile across server