Getting a badge's image ID

So I know I could definitely go about uploading a repeat image of each badge manually as a decal (or even going out of my way to manually find each Image ID for the badge - bleh), but I was wondering if it was possible scriptwise to get and use a badge’s Image ID.

For instance I want to use this badge to put it’s picture on an ImageLabel:

Is this possible via scripting? If not, is there an easy method to get the Image ID of each badge by scripting (or worst-case manually)?

2 Likes

I would assume it would have to do with the MarketplaceService:GetProductInfo() method, but I have had no luck from testing. Your manual worst case scenario is to simply upload the image as a decal and use that.

1 Like

When you create a badge, an awarder is created in your models. The awarders have a decal on them which will use the same image as the badge, you can get the image ID from there.

Your models can be found here:

2 Likes

I have changed some of the badge’s images since initially uploading, meaning that they’re incorrect on the awarder. Is there still a way to recreate the awarder (or find the new image ID)? I know there used to be.

Does this also mean there really isn’t a script method to go about this?

I think I figured it out! Not sure if it’s technically cheesing it, but I think it’ll work!

https://www.roblox.com/asset-thumbnail/image?assetId=919383558&width=420&height=420&format=png

edit: eureka!

5 Likes

Three cheers for legacy endpoints!

1 Like

Though I probably shouldn’t bump such an old thread I bookmarked it when I knew this was coming:

I don’t know if it’s been announced or fully released yet, but it’s documented in the wiki and one of the items it returns is the IconImageId that can be used with rbxassetid:// to get the badge icon texture.

7 Likes