Skip to main content

1. Enable the API

1

Open the admin panel

Sign in at https://your-site.com/dashboard. This page requires the MANAGE_SETTINGS permission.
2

Open Settings → API

Turn on API Status. The change is saved immediately.
3

Copy the API key

Copy the value in the API Key field. You will use it in the plugin configuration and in your own integrations.
While the API is off or the key is empty, every /api request returns a 404 with an empty body. If your plugin says it cannot connect, check this setting first.

Panel settings

When you reset the key, everything that uses the old key stops working: game-server plugins, the Discord bot and your own integrations. After a reset, update every config file with the new key and restart the servers. If you suspect the key has leaked, reset it right away.
The API key is also used with LeaderOS’s external services (LeaderOS Connect, LeaderOS ID, LeaderOS AI). That is why the key is generated through leaderos.net rather than locally.

2. Your first request

A request with a form body:
curl -d sends the body as application/x-www-form-urlencoded automatically. If you send JSON (-H "Content-Type: application/json"), validation fails and you get a VALIDATION error.

3. Security recommendations

  • Keep the key on the server only (environment variable, config file on the server).
  • Do not commit the key to Git; remove it before sharing config files.
  • Nobody should see the key in game; do not print it in plugin messages or logs.
  • If your provider supports it, add a firewall rule that only accepts API requests from your game server’s IP (e.g. with Cloudflare).
  • Reset the key when staff changes or whenever in doubt.

Common errors

Next step

Usage examples

Call the API from your own plugin, bot or backend.