Okay so I have a custom leader board in which I have incorporated a drop down menu with buttons including: Send Friend Request, follow and report. I have been looking far and wide for some sort of a function or service that will allow players to send a friend request from my custom leaderboard.
I found a service called FriendService but theres no documentation of a function to send a friend request.
Is this a core script only functionality?
It is impossible to make a report user button, as Roblox uses :ReportAbuse method from Players service, this method can only be used in the command bar, and will error if used in scripts or localscripts, there is currently no known method to send friend request/follow someone with custom leaderboards, FriendService is only used with Roblox's Core scripts as described here:
https://developer.roblox.com/api-reference/class/FriendService
A service which is used to send, cancel, accept and decline friend requests in-game. It is primarily used by the PlayerListScript to send friend requests with the leaderboard.
I figured it out. You can use Roblox's SetCore function nto prompt a friend request.
It can be used like so:
game.StarterGui:SetCore("PromptSendFriendRequest", player)
Answered my own question