Help needed with Roblox Groups API

Hey, so recently I wanted to make a bot that uses the Roblox Groups API in order to figure out what group dosen’t have any owner, I know that open ones are rare but still available.

The issue is that I cannot find a way to figure out if a group is open, closed, or locked using the API, the only useful information I could gather from the API is if it has an owner or not which is already a good step, but not enough for what I am trying to achieve.

I have tried looking for how to know if a group is closed or not but just couldn’t.
If you are wondering, here is the groups API link : Swagger UI

Thank you for reading.
I am really sorry if the category is wrong, please notify me so I can correct it.

1 Like

you can use https://groups.roblox.com/v2/groups/idhere/wall/posts to see if a group is locked or not, if it is locked it will return error code 1

1 Like

Thank you, but it dosen’t quite work, I used the game Group Finder to find a closed group and here is the output it game me:

{
“previousPageCursor”: null,
“nextPageCursor”: null,
“data”: []
}

1 Like

I assume you only care if you’re able to join the group and claim it, not the specifics of whether it’s locked or closed.

To do this, you already know how to detect if a group doesn’t have an owner (the owner object will return null).

Then, you can use the groups V1 API to check if the group is able to be publicly joined. If it isn’t and the owner is null, it means that the group has either been locked or closed (since you are not able to join it).

The endpoint you’d use is https://groups.roblox.com/v1/groups/{GROUPID}, which will return a response like this:

{
  "id": 123,
  "name": "group name",
  "description": "group description",
  "owner": 123,
  "shout": "hi",
  "memberCount": 123,
  "isBuildersClubOnly": true/false,
  "publicEntryAllowed": true/false,
  "hasVerifiedBadge": true/false
}

With this, you can check if owner is null and if publicEntryAllowed is true. If they are, then the group is open without an owner.

For example, this group is without an owner but closed, and it returns the following (owner is null but publicEntryAllowed is false):

{
    "id": 305694,
    "name": "yeah",
    "description": "",
    "owner": null,
    "shout": null,
    "memberCount": 0,
    "isBuildersClubOnly": false,
    "publicEntryAllowed": false,
    "hasVerifiedBadge": false
}
1 Like

Thank you, but I still have one more question, I’m sorry I didn’t mention it earlier, but if I were to make a bot like that, would it check for a random number as the group ID and if it’s the case then what would be the maximum ID.

It probably doesn’t matter. I think you could do it consecutively (from a minimum to a maximum) or with random IDs. If you’re scanning a specific range of groups (e.g, groups from 2016-2017), then you’re most likely better off doing it consecutively. If you’re looking through a large range of groups, you might get better results if you do it randomly.

The one downside to doing it randomly is that after a while (depending on the range of IDs), you’ll end up checking groups that you’ve already checked. I don’t recommend logging IDs you’ve already tried and checking against the random ones, because it’ll slow down the bot by a fair amount.

You’re probably fine doing it randomly if you’re checking a large range (millions) of groups, but otherwise I’d recommend consecutive checking to avoid trying the same group multiple times.

There’s no API to get the most recently-created group, but the highest group ID is around 33000000 as of right now if you’re looking for a maximum. It is unlikely for someone to leave a group they made recently, so I suggest starting with groups that have not just been created.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.