API options
Every option the encrypt endpoint accepts.
POST /api/encrypt
Requires a logged-in session. Costs 1 token per call (admins encrypt for free). The response contains code, fileName and remaining tokens.
{
"code": "local noclip = false ...",
"fileName": "noclip.lua",
"options": {
"vm": true,
"serverShield": true,
"license": "MY-CUSTOMER-1",
"strings": true,
"numbers": true,
"flatten": true,
"rename": true,
"renameGlobals": false,
"preserve": ["Citizen"],
"seed": 1337
}
}Options reference
| vm | Use the custom bytecode VM (strongest protection). |
| strings | Encrypt all string literals. |
| numbers | Obfuscate numeric literals. |
| flatten | Apply control-flow flattening. |
| rename | Rename locals and labels. |
| renameGlobals | Also rename globals (except preserved). |
| preserve | Array of globals to keep readable (AEG_* macros are always preserved). |
| seed | Fixed seed for reproducible output. |
| serverShield | Server-side key delivery (license-bound runtime). |
| license | License fingerprint a ServerShield build must match. |
| envKey | Environment string a VM build locks onto (resource name / AEGIS_ENV / PlaceId). |
Runtime key endpoint
ServerShield builds call POST /api/runtime/key with {"id":"<buildId>","fp":"<license fingerprint>"}. The endpoint returns {"key":"..."} only when the fingerprint matches the license the build was created with, and is rate-limited per build.
History endpoint
GET /api/me/logs lists your last 50 encryptions. GET /api/me/logs/<id> returns the stored protected output so you can re-download a file without spending new tokens.