Logo

API Documentation

Key Authentication Integration (Lua)

Easily integrate our robust key system into your scripts. Load the API library directly from our servers, verify the user's key, and execute the protected script.

-- 1. Load the API Library from our servers
local api = loadstring(game:HttpGet("http://luatiger.kro.kr/Library.lua"))()
--> Returns a table with methods that you can use.

-- 2. Initialize it with your Project ID and Script ID
-- You can find these in the dashboard under the Projects and Scripts sections.
api.project_id = "YOUR_PROJECT_ID_HERE"
api.script_id = "YOUR_SCRIPT_ID_HERE"

-- 3. Make the API request to check the key
local script_key = "USER_INPUT_KEY_HERE"
local status = api.check_key(script_key)

-- 'status' returns a table: {code: <string>, message: <string>, data?: <table>}
print(status.code)

-- 4. Custom Logic based on authentication result
if (status.code == "KEY_VALID") then
    -- Fetch basic info about the key (only available if KEY_VALID)
    -- auth_expire is a UNIX timestamp. We subtract os.time() to get seconds left.
    local seconds_left = status.data.auth_expire - os.time()
    print("Welcome! Seconds left: " .. seconds_left)
    print("Total executions: " .. status.data.total_executions)
    print("Is key from ad system? " .. (status.data.note == "Ad Reward" and "YES" or "NO"))
    
    -- Execute the script based on the script_id you put above.
    api.load_script()
    return
    
elseif (status.code == "KEY_HWID_LOCKED") then
    print("Key linked to a different HWID. Please reset it using our bot.")
    return
    
elseif (status.code == "KEY_INCORRECT") then
    print("Key is wrong or deleted!")
    return    

elseif (status.code == "KEY_EXPIRED") then
    print("Your key has expired!")
    return
    
elseif (status.code == "EXECUTION_CAP_REACHED") then
    print("You have reached the maximum execution limit for this key.")
    return
    
else
    -- Fallback for anything else (e.g., blacklisted, rate-limited, emulator blocked)
    local player = game:GetService("Players").LocalPlayer
    player:Kick("Key check failed: " .. status.message .. " | Code: " .. status.code)
end

Response Codes

Code Description
KEY_VALID The key is valid and the user is authenticated. data object is provided.
KEY_INCORRECT The provided key does not exist or the project ID is invalid.
KEY_HWID_LOCKED The key is already bound to another device/HWID.
KEY_EXPIRED The key's time limit has passed.
EXECUTION_CAP_REACHED The key has hit the enterprise execution limit configured in settings.
EMULATOR_BLOCKED Enterprise emulator blocking prevented the execution.
RATE_LIMITED The user is sending requests too quickly.