The Steam Profile Info Grabber script is a powerful utility for FiveM servers that fetches and stores Steam profile information for players. It allows server owners to display player avatars, account age check, and profile URLs while ensuring optimized performance with caching and rate limit handling. This script helps enhance server security, improve user experience, and enforce steam account age restrictions if necessary.
resources
directory.mysql-async / OxMysql
is installed and running.server.cfg
:Config.SteamAPIKey = GetConvar(‘steam_webApiKey’, ”) — Steam API Key
Config.RefreshInterval = 1 — Refresh profile data every X days
Config.ApiRequestInterval = 1 — Prevents API rate limit issues
Config.DefaultProfileImage = “https://someimage.com/default.png” — Default profile picture
Config.MinimumSteamAgeToJoin = 0 — Minimum Steam account age in days (0 = No restriction)
You can retrieve Steam profile information using the following exports:
local profile = exports[‘steam_profile_info’]:GetPlayerSteamProfile(steamID) — ALL PROFILE DATA IN TABLE FORMAT
local image = exports[‘steam_profile_info’]:GetPlayerSteamImage(steamID)
local profileURL = exports[‘steam_profile_info’]:GetPlayerProfileURL(steamID)
local accountAge = exports[‘steam_profile_info’]:GetPlayerAccountAge(steamID)
Commands
🔹 /updatesteamprofile [playerID]
Manually force an update for a player’s Steam profile.
🔹 /getprofileage [playerID]
Displays the account age of the specified player in days.
🔹 /getNewSteams [days]
Display all online players with steam account smaller theX days ( usefull to find cheaters / abusers )
If a player’s profile is private or unavailable, a default profile image is used.
*It uses the official CFX escrow encryption that ensures buyer’s and seller’s protection but the more important funtions are free to edit!