Join a random server from the client side

local HttpService = game:GetService("HttpService")
local placeId = "PLACE_ID"
local url = "https://games.roblox.com/v1/games/" .. placeId .. "/servers/Public?limit=100"

local success, response = pcall(function()
    return HttpService:GetAsync(url)
end)

if success then
    local serverData = HttpService:JSONDecode(response)
    local servers = serverData.data
    if #servers > 0 then
        local randomServer = servers[math.random(1, #servers)]
        print("Random Server ID:", randomServer.id)
    else
        print("No available servers found.")
    end
else
    warn("Failed to retrieve server data:", response)
end

ERROR: Failed to retrieve server data: Attempt to call blacklisted method

change the url from games.roblox.com to games.roproxy.com
You can request roblox links

Attempt to call blacklisted method, same.


need ‘Allow HTTP Requests’ ?

I said this is from the client side, not server side.

I believe you cannot use HttpService on the client, you should also stick to using the newest url which is:

https://games.roblox.com/v1/games/{PlaceID}/servers/0?sortOrder=2&excludeFullGames=false&limit=10

Sort order → 2 for ascending, 1 for descending
ExcludeFullGames → boolean
Limit → Amount of servers to return

Oh sorry, I missed the part where it said client side. You can’t run HTTP request on the client due to security reasons, you can use a remote function or remote event for it