If you’re willing to set up a web-server, I developed a JavaScript program that collects much more than a user’s game-passes. You can fork the API endpoints used by the program and convert the program’s code to Luau as well. Here is the repository
I won’t give you all my scripts, but this script on the server-side should get you very far.
local http = game:GetService("HttpService")
local function getGamepasses(plr, user, gamepasses, pageNumber, lastLength)
gamepasses = gamepasses or {}
pageNumber = pageNumber or 1
lastLength = lastLength or math.huge
local requestUrl = "https://games.RoProxy.com/v2/users/"..user.."/games?accessFilter=Public&sortOrder=Asc&limit=50"
local success, result = pcall(function()
return http:GetAsync(requestUrl)
end)
if success then
pcall(function()
local alldata = http:JSONDecode(result)
for _,GameInfo in pairs(alldata["data"]) do
local gameId = GameInfo.id
local url = "https://games.RoProxy.com/v1/games/"..gameId.."/game-passes?limit=100&sortOrder=Asc"
local success2,result2 = pcall(function()
return http:GetAsync(url)
end)
if success2 then
result2 = http:JSONDecode(result2)
for _,GamepassDetail in pairs(result2["data"]) do
local gamepassId = GamepassDetail.id
table.insert(gamepasses,gamepassId)
end
end
end
end)
else
warn(result)
getGamepasses(plr, user, gamepasses, pageNumber, lastLength)
end
return gamepasses
end
game.ReplicatedStorage.GetGamepasses.OnServerInvoke = getGamepasses
I use this, and when I am printing the gamepasses they have, it prints all of them 3 times.