How to get a game/experience's data (Visits, Playing, Favorites)

This is when you want to get the data of a game such as Visits, Playing, Favorites, Description, Creator Information, and more.

Step 1: Get the UniverseId of your experience.

Open your experience page on create.roblox.com and tap on Copy Universe ID
image

Step 2: Check if the API is displaying correct data

URL: https://game-api.glitch.me/data?id=0000

Replace the 000 with your universe id.
Example: If your experience universeid is 12345, then replace 0000 with 12345

Then paste that URL to the browser after changing the id.
You will be seeing your experience’s information now.

Step 3: Firing from experience.

Now you call that API/URL from game to get the data.

Example:

local https = game:GetService("HttpService")
local URL = "https://game-api.glitch.me/data?id=0000"
local data = https:GetAsync(URL)
local decoded = https:JSONDecode(data)

print(decoded) -- prints the data
-- do not forget to change the id in the URL variable above

Tutorial is done.

9 Likes

Cool but why not use the already made roblox API with a proxy?
This to be exact:

https://games.roblox.com/v1/games?universeIds=id
2 Likes

This is a proxy I’m offering.

Creating a proxy can be challenging for many people, especially those who lack a server or hosting capabilities. To address these common issues and improve efficiency, I’ve developed this API. It simplifies the process, making it easier to achieve the same results without the usual complications.

You can always replicate that or create different methods but this is only a step taken to reduce duplications of processes and increase efficiency while working.

2 Likes

Is there a way to get the likes of a game? And to check if a player[specific] liked the game?

2 Likes

For now you can get the favorites count of an experience.

Speaking about likes, you have to use noblox.js to achieve that functionality along with checking if a user has liked a game.

Additionally, there might be other APIs available for public for achieving this. Moreover, I’ll be adding this a bit later. Thank you for the suggestion.

I hope this answered your question.

2 Likes

glitch shuts their servers down when its inactive meaning this could result in some issues arising. Cool but don’t use glitch.

3 Likes

I kept an uptime pinger, which pings the API every 5 minutes this way, the API will remain online most of the time.

1 Like

That could help but I recommend you change it to 2.5 minutes just incase. Ive had it work better usually that way.

2 Likes

Any cooldown below 5 minutes is paid.

1 Like

In regards to this, I believe Glitch block requests from many pinging services due to the load it puts on their servers. Consider switching to an alternative that doesn’t “kill” apps after inactivity, like Vercel or something similar. Though this would mean slightly refactoring your application to use a framework they support.

3 Likes

why would people pay you to ping a free server that’s stupid. All you’re doing is sending a request to the server which anyone could do with a python script. Don’t charge people for the stupidest things.

2 Likes

I mean I have to pay the uptimebot for it to ping the API every 2.5 minutes or 5 minutes or lower.

There is a limit of 4K requests per minute for glitch APIs, I’ll host it in a different place if the number of experiences or developers using it are high.

2 Likes