API Documentation
Welcome to the M79 Climb API. All endpoints are prefixed with /api. Responses are plain text unless noted as JSON.
Get Best Caps for a Map
Endpoint: GET /api/besttimes/{mapName}/{count}/json
Description: Returns the top count best times for a map (one per player, fastest first) as JSON.
Parameters:
mapName— exact map name, e.g.m79_Hardplancount— how many results (integer)
Examples:
GET /api/besttimes/m79_Hardplan/3/json GET /api/besttimes/m79_Easy/10/json
curl:
curl https://m79climb.bakakats.team/api/besttimes/m79_Hardplan/3/json
Response (JSON):
[
{ "name": "Player1", "time": "01:15:124", "ticks": 4509, "date": "2025-02-19T14:33:21" },
{ "name": "Player2", "time": "02:30:853", "ticks": 9051, "date": "2025-01-15T08:12:45" },
{ "name": "Player3", "time": "02:05:229", "ticks": 7514, "date": "2025-01-11T22:01:10" }
]
Returns an empty array [] if the map has no caps.
Get a Player's Best Caps
Endpoint: GET /api/times/{playerName}/{mapName}/{count}/json
Description: Returns the top count times for a specific player on a given map, sorted fastest first, as JSON.
Parameters:
playerName— player name (case-sensitive)mapName— exact map namecount— how many results
Examples:
GET /api/times/Nequs/m79_Hardplan/5/json GET /api/times/Player1/m79_Easy/3/json
curl:
curl https://m79climb.bakakats.team/api/times/Nequs/m79_Hardplan/5/json
Response (JSON):
[
{ "name": "Nequs", "time": "00:05:824", "ticks": 349, "date": "2025-02-19T01:12:12" },
{ "name": "Nequs", "time": "00:06:112", "ticks": 367, "date": "2025-02-18T21:15:53" },
{ "name": "Nequs", "time": "00:07:330", "ticks": 440, "date": "2025-01-11T22:32:53" }
]
Returns an empty array [] if no caps exist for that player/map.
Get Player Stats
Endpoint: GET /api/playerstats/{playerName}
Description: Returns lifetime stats for a player: top placements, grenades thrown, M79 shots fired, time on server, server visits, and respawns.
Examples:
GET /api/playerstats/Nequs GET /api/playerstats/Player1
curl:
curl https://m79climb.bakakats.team/api/playerstats/Nequs
Response (JSON):
{
"top1": 5,
"top2": 3,
"top3": 2,
"totalCaps": 142,
"grenadesThrown": 1200,
"m79ShotsFired": 850,
"timeSpentOnServer": "12:34:56",
"serverVisits": 47,
"respawns": 310
}
Returns No player found (plain text) if the player does not exist.
Get Textures
Endpoint: GET /api/textures
Description: Returns a JSON array of all available textures from the server's texture library.
curl:
curl https://m79climb.bakakats.team/api/textures
Response (JSON):
[
{ "id": 12345, "name": "default", "path": "/images/textures/default.bmp" },
{ "id": 67890, "name": "cytryna", "path": "/images/textures/cytryna.bmp" },
{ "id": 11111, "name": "grass01", "path": "/images/textures/grass01.png" }
]
Returns an empty array [] if no textures have been uploaded yet.
Get Scenery
Endpoint: GET /api/scenery
Description: Returns a JSON array of all available scenery/prop images.
curl:
curl https://m79climb.bakakats.team/api/scenery
Response (JSON):
[
{ "name": "K-Arrow", "path": "/images/scenery/K-Arrow.bmp" },
{ "name": "K-Barrel-01", "path": "/images/scenery/K-Barrel-01.bmp" },
{ "name": "tree_large", "path": "/images/scenery/tree_large.png" }
]
Returns an empty array [] if no scenery has been uploaded.
Download Map Pack
Endpoint: GET /api/download/mappack
Description: Downloads all server maps as a single .zip archive containing every .pms file.
curl:
curl -O https://m79climb.bakakats.team/api/download/mappack
Response: Binary file m79climb_mappack.zip (application/zip).
Download Server Scripts
Endpoint: GET /api/download/scripts
Description: Downloads the Soldat server scripts as a .zip archive. Sensitive values (API keys, passwords) are automatically sanitized.
curl:
curl -O https://m79climb.bakakats.team/api/download/scripts
Response: Binary file m79climb_scripts.zip (application/zip).
Download soldat.ini
Endpoint: GET /api/download/soldatini
Description: Downloads a sanitized copy of the server's soldat.ini configuration (admin password replaced with a public placeholder).
curl:
curl -O https://m79climb.bakakats.team/api/download/soldatini
Response: Plain text file soldat.ini.
Download weapons.ini
Endpoint: GET /api/download/weaponsini
Description: Downloads the server's weapons.ini file as-is.
curl:
curl -O https://m79climb.bakakats.team/api/download/weaponsini
Response: Plain text file weapons.ini.
Error Handling
When a request fails the API returns an appropriate HTTP status code and a message body:
| Code | Meaning | Example body |
|---|---|---|
200 |
Success | JSON or plain text data |
400 |
Bad request / invalid input | "No file provided." or "Invalid file type." |
401 |
Unauthorized (missing/wrong key) | "Invalid key" |
404 |
Resource not found | { "message": "Textures directory not found" } |
500 |
Internal server error | { "error": "..." } or { "message": "..." } |
The besttimes and times endpoints return an empty array [] when there is no matching data. The playerstats endpoint returns No player found.
Contact _nequs on Discord if you have any suggestions or problems!