Detect if a person is following someone on Roblox (like roblox followers)

I need help! Basically I want to detect if a person is following someone on roblox! I’ve had trouble with this as Im a builder and my scripter is confused to what Im asking him.

So basically I want this script

local Player = game.Players.LocalPlayer

if Player:IsInGroup(35622107) then
	if workspace:FindFirstChild("GroupOnly") then
		workspace.GroupOnly.Parent = game.ReplicatedStorage
	end
end

to only work if a player is following someone,.

Any help would be appreciated, Ive searched in the dev forums and could not find an answer!

In Roblox, you can’t directly detect if a player is following another player through the engine’s APIs. You’ll need to use an external API call, typically through a proxy, to check their followings.

  1. Using a Proxy:
  • Roblox doesn’t provide a built-in way to check if a player is following another. You’ll need to use a proxy service like RoProxy to access the Roblox API.
  1. Making the API Request:
  • You’ll use the HttpService in Roblox to make a GET request to the proxy’s API endpoint for checking followings.
  • The API endpoint typically looks like this: https://friends.roproxy.com/v1/users/<User ID>/followings.
  • Replace <User ID> with the User ID of the player you want to check if they are following someone.
  1. Decoding the Response:
  • The API response will be in JSON format. You’ll need to use HttpService:JSONDecode() to parse the JSON data.
  • The JSON data will contain information about the player’s followings.

Example Code (using RoProxy):

local http = game:GetService("HttpService")
local players = game:GetService("Players")

players.PlayerAdded:Connect(function(player)   
local result = http:GetAsync("https://friends.roproxy.com/v1/users/"..player.UserId.."/followings")  
local json = http:JSONDecode(result)    -- Process the JSON data to determine if the player is following another player.  
print(json) -- Example: Print the JSON response for debugging.end)
3 Likes

Thanks man! Ive tried it and it worked!

2 Likes

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