Luau key check library

No, we designed this library to be completely safe to use in open source code, nothing private has to be given to the library
Due to us not needing any form of api key, only basic key info is returned

If you wanted to check a users key in advance

Example uses:

  • Make a custom enter key ui where you can verify the key entered
  • Load a different script depending on if there whitelisted or not

Check out our la_init macro for how to run code before the auth

No, LuaAuth protected scripts will automatically verify users keys
This library just gives you an option to verify keys if you need it for something else

Library url

https://api.luaauth.com/luaulibrary

Loadstring this url to load the library

Example:

local library = loadstring(game:HttpGet('https://api.luaauth.com/luaulibrary'))()

Setup

The only thing you need to give this library for setup is your scripts id
Your script ids can be found in the dashboards projects tab

to give it your script id just do:

library.script_id = 'YOUR_SCRIPT_ID'

Functions

Syntax: library.check_key(key: string)

Validates and returns info about the provided key

Return data:

Syntax: library.load_script(key: string)

Loads the script for the id you provided in setup and sets the users key to the key provided

Example:

local ui = loadstring(...)()

local library = loadstring(game:HttpGet('https://api.luaauth.com/luaulibrary'))()
library.script_id = 'YOUR_SCRIPT_ID'

ui.onSubmit:Connect(function(key)
    local result = library.check_key(key)
    
    if result.status == 'key_valid' then
        ui:delete()
        library.load_script(key)
    elseif result.status == 'key_blacklisted' then
		game:GetService('Players').LocalPlayer:Kick('You are blacklisted for ' .. result.user.blacklist_reason)
    elseif result.status == 'invalid_fingerprint' then
        ui:showText('Key is linked to another fingerprint, reset your fingerprint then try again')
	elseif result.status == 'key_expired' then
		ui:showText('Key expired, buy a new one at discord.gg/EXAMPLE')
	elseif result.status == 'invalid_script_id' then
		ui:showText('This script no longer exists')
    end
end)