HomeGetting startedRegistering with an HTTP keyGetting a credential without DiscordServer claim flowReport rules and the block windowVersion check and 426Authentication and server keysThe blocking modelError handlingRate limitsVersions and compatibilityPOST /v1/servers/claimPOST /v1/servers/reportPOST /v1/servers/revokePOST /plugin/v1/claimPOST /plugin/v1/reportGET /plugin/v1/versionGET /maps/{seed}GET /jobs/{seed}GET /seedsGET /stats/overviewGET /stats/protectionAPI changelog
Concepts
Rate limits
Limits are counted per request IP or per server key. Past a limit you get 429 {"error":"rate limited"}. A normal server stays well under a tenth of every limit.
Limits
| Endpoint | Limit | Keyed by | Notes |
|---|---|---|---|
| POST /api/v1/servers/claim | 1 / 5 min | IP | Spent only when a key is issued. Server checks 10 / min, 3 live keys per IP |
| POST /api/v1/servers/report | 12 / min | server key | Plus 120 / min per IP |
| POST /api/v1/servers/revoke | 20 / min | IP | |
| POST /api/plugin/v1/claim | 10 / min | IP | |
| POST /api/plugin/v1/report | 12 / min | server key | Plus 120 / min per IP |
| GET /api/plugin/v1/version | none | Cached 5 min | |
| GET /api/maps/{seed} | 20 / min | IP | Seeds not generated yet only. Generated seeds are unlimited |
| GET /api/jobs/{seed} | none | ||
| GET /api/seeds | none | ||
| GET /api/stats/* | 20 / min | IP | Cached 60 s. Cache hits are not counted |
How counting works
- Fixed windows. A window starts at the first request for that key, ends after the limit period, and the next request opens a new one.
- Requests past the limit still count. Resending right after a 429 keeps answering 429 until the window ends.
- Counters live in memory and reset when the service restarts. Only the self-claim 5-minute interval is also checked against the database.
- 429 responses carry a Retry-After header in seconds. For the self-claim interval it may state the whole interval (300) when the exact remainder is unknown.
The 5-minute self-claim interval
The interval is spent only when a key is issued. 400, 403, 409 and 503 answers and a failed server check give it back, so a wrong port can be fixed and resent at once. The server check itself is limited to 10 per minute per IP, and the 3 live keys per IP are never taken away.
Normal traffic
One server sends one round_start and one round_end per round. periodic at the 60-second default is one request per minute. The 12 per minute per key limit is ten times that. Do not use a periodic interval under 10 seconds; it can reach the limit.
SLMAPS is the seed-map viewer for SCP: Secret Laboratory. These pages describe the public API of slmaps.com.slmaps.com ·