Sell FiveM scripts. Keep them on paying servers.
A key for every Tebex sale, a server limit, chargebacks handled.
Free plan · No credit card · Set up in minutes
Coding with an AI agent? Paste one prompt- FiveM
- RedM
- Lua
- ESX
- QBCore
- Tebex
- Discord
Built for how you sell.
Keys from Tebex
Each payment issues a key and emails it.
Chargebacks handled
Refunds revoke, disputes suspend, wins restore.
Servers per key
1, 2 or 5 servers per license.
TOO_MANY_MACHINESLua SDK and template
Reads a convar, re-checks every 6 hours.
sunlicense.luaSupport in Discord
Buyer roles and server slot resets.
/claimSentinel spots shared keys
Too many places, or used after a refund.
Lite & StandardLive before your next release.
- 1Create a free account
- 2Connect your Tebex packages
- 3Drop in sunlicense.lua
-- server.cfg: set my_garage_license "AX8P-XXXX-XXXX-XXXX"
local resource = GetCurrentResourceName()
local SunLicense = load(LoadResourceFile(resource, 'lib/sunlicense.lua'))()
local client = SunLicense.new({ baseUrl = 'https://api.sunlicense.com', token = SunLicenseSettings.apiKey })
client:validate(GetConvar('my_garage_license', ''), { host = serverId() }, function(ok, status, body)
if ok then
print(('^2[%s] License valid, starting.^7'):format(resource))
startFeatures()
elseif status == 400 then
print(('^1[%s] License denied: %s^7'):format(resource, body:match('"code":"([%w_]+)"') or '?'))
StopResource(resource)
else
startFeatures() -- no answer is not a no: keep running
end
end)Questions, answered.
How do I stop my FiveM scripts from being leaked?
Give each buyer their own key and check it when the resource starts. If a copy leaks, the key it runs on is the leaker's: revoke that license and the copy stops at its next check (the template re-checks every 6 hours), while paying servers keep running. Upload through Tebex's asset escrow as well, so buyers can't read or edit the check.
Does it work with Tebex?
Yes. Map Tebex package IDs to a policy and add a webhook: every completed payment issues a license, refunds and lost disputes revoke it, and open disputes suspend it. Buyers get the key by email, or on your redeem page with their tbx- transaction ID and email.
Does it work with ESX, QBCore and RedM?
Yes. The check runs in a server script with FiveM's own PerformHttpRequest, so it doesn't depend on a framework. For RedM, set game to 'rdr3' in fxmanifest.lua.
What happens if SunLicense can't be reached?
The template keeps the resource running and tries again every 10 minutes; one setting makes it wait for an answer instead. Only a real rejection, like a revoked or unknown key, stops the resource. Lua has no built-in Ed25519, so FiveM resources don't use offline license files.
SunLicense