Online System and files
Mod feature switches, floating text and Online Lib files.
Running mods read these values on their next key check.
Keep in mind
Get online
https://dev.mod.wtf/api/v2/action
methodget-online
Read the Online System: mod feature switches, mod name, status and floating text.
Body
-
soft_idinteger requiredID of a software you own
Errors it can return
POST /api/v2/action HTTP/1.1
Host: dev.mod.wtf
Content-Type: application/json
Accept: application/json
{
"api_key": "YOUR_API_KEY",
"method": "get-online",
"soft_id": 123
}
curl -sS -X POST 'https://dev.mod.wtf/api/v2/action' \
-H 'Content-Type: application/json' \
-d '{
"api_key": "YOUR_API_KEY",
"method": "get-online",
"soft_id": 123
}'
const response = await fetch("https://dev.mod.wtf/api/v2/action", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"api_key": "YOUR_API_KEY",
"method": "get-online",
"soft_id": 123
}),
});
const result = await response.json();
$ch = curl_init('https://dev.mod.wtf/api/v2/action');
curl_setopt_array($ch, [
CURLOPT_POST => true,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Content-Type: application/json'],
CURLOPT_POSTFIELDS => json_encode([
'api_key' => 'YOUR_API_KEY',
'method' => 'get-online',
'soft_id' => 123,
]),
]);
$result = json_decode(curl_exec($ch), true);
import requests
response = requests.post(
"https://dev.mod.wtf/api/v2/action",
json={
"api_key": "YOUR_API_KEY",
"method": "get-online",
"soft_id": 123,
},
timeout=10,
)
result = response.json()
{
"ok": true,
"data": {
"soft_id": 123,
"features": {
"esp": true,
"items": true,
"aim": true
},
"mod_name": "SUCCESS",
"safe": true,
"mod_status": "Safe",
"floating_text": "Powered by Modkey Platform"
}
}
{
"ok": false,
"error": "not_found",
"message": "soft not found or not yours"
}
{
"ok": false,
"error": "unauthorized",
"message": "Invalid or missing api_key"
}
Update online
https://dev.mod.wtf/api/v2/action
methodedit-online
Change Online System values. Send only what changes; running mods get them on the next check.
Body
-
soft_idinteger requiredID of a software you own
-
featuresobject optionalObject of esp, items, aim, silent_aim, bullet_track, memory, floating, settings: booleans
-
mod_nameoptionalString
-
mod_statusstring optionalSafe or High
-
floating_textoptionalString
Errors it can return
POST /api/v2/action HTTP/1.1
Host: dev.mod.wtf
Content-Type: application/json
Accept: application/json
{
"api_key": "YOUR_API_KEY",
"method": "edit-online",
"soft_id": 123,
"features": {
"esp": false
},
"mod_status": "Safe"
}
curl -sS -X POST 'https://dev.mod.wtf/api/v2/action' \
-H 'Content-Type: application/json' \
-d '{
"api_key": "YOUR_API_KEY",
"method": "edit-online",
"soft_id": 123,
"features": {
"esp": false
},
"mod_status": "Safe"
}'
const response = await fetch("https://dev.mod.wtf/api/v2/action", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"api_key": "YOUR_API_KEY",
"method": "edit-online",
"soft_id": 123,
"features": {
"esp": false
},
"mod_status": "Safe"
}),
});
const result = await response.json();
$ch = curl_init('https://dev.mod.wtf/api/v2/action');
curl_setopt_array($ch, [
CURLOPT_POST => true,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Content-Type: application/json'],
CURLOPT_POSTFIELDS => json_encode([
'api_key' => 'YOUR_API_KEY',
'method' => 'edit-online',
'soft_id' => 123,
'features' => [
'esp' => false,
],
'mod_status' => 'Safe',
]),
]);
$result = json_decode(curl_exec($ch), true);
import requests
response = requests.post(
"https://dev.mod.wtf/api/v2/action",
json={
"api_key": "YOUR_API_KEY",
"method": "edit-online",
"soft_id": 123,
"features": {
"esp": False,
},
"mod_status": "Safe",
},
timeout=10,
)
result = response.json()
{
"ok": true,
"data": {
"soft_id": 123,
"features": {
"esp": false
},
"mod_status": "Safe"
}
}
{
"ok": false,
"error": "validation",
"message": "features.esp must be true or false"
}
{
"ok": false,
"error": "unauthorized",
"message": "Invalid or missing api_key"
}
List files
https://dev.mod.wtf/api/v2/action
methodget-files
List Online Lib files of a software with their public links.
Body
-
soft_idinteger requiredID of a software you own
Errors it can return
POST /api/v2/action HTTP/1.1
Host: dev.mod.wtf
Content-Type: application/json
Accept: application/json
{
"api_key": "YOUR_API_KEY",
"method": "get-files",
"soft_id": 123
}
curl -sS -X POST 'https://dev.mod.wtf/api/v2/action' \
-H 'Content-Type: application/json' \
-d '{
"api_key": "YOUR_API_KEY",
"method": "get-files",
"soft_id": 123
}'
const response = await fetch("https://dev.mod.wtf/api/v2/action", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"api_key": "YOUR_API_KEY",
"method": "get-files",
"soft_id": 123
}),
});
const result = await response.json();
$ch = curl_init('https://dev.mod.wtf/api/v2/action');
curl_setopt_array($ch, [
CURLOPT_POST => true,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Content-Type: application/json'],
CURLOPT_POSTFIELDS => json_encode([
'api_key' => 'YOUR_API_KEY',
'method' => 'get-files',
'soft_id' => 123,
]),
]);
$result = json_decode(curl_exec($ch), true);
import requests
response = requests.post(
"https://dev.mod.wtf/api/v2/action",
json={
"api_key": "YOUR_API_KEY",
"method": "get-files",
"soft_id": 123,
},
timeout=10,
)
result = response.json()
{
"ok": true,
"data": {
"soft_id": 123,
"limit": 10,
"max_bytes": 14680064,
"items": [
{
"token": "<TOKEN>",
"name": "libmod.so",
"link": "libmod.so",
"url": "https://mod.wtf/lib/libmod.so",
"version": "1.0.0",
"size": 1048576,
"available": true
}
]
}
}
{
"ok": false,
"error": "not_found",
"message": "soft not found or not yours"
}
{
"ok": false,
"error": "unauthorized",
"message": "Invalid or missing api_key"
}
Upload files
https://dev.mod.wtf/api/v2/action
methodupload-files
Upload library files. Send multipart/form-data with the method in the query string: POST /api/v2/action?method=upload-files. Up to 10 files and 14 MB per upload.
Body
-
soft_idinteger requiredID of a software you own
-
files[]required.so, .a, .dll, .dylib or .lib files
-
versionstring optionalUp to 32 characters
Errors it can return
POST /api/v2/action HTTP/1.1
Host: dev.mod.wtf
Content-Type: application/json
Accept: application/json
{
"api_key": "YOUR_API_KEY",
"method": "upload-files",
"soft_id": 123,
"version": "1.0.0"
}
curl -sS -X POST 'https://dev.mod.wtf/api/v2/action' \
-H 'Content-Type: application/json' \
-d '{
"api_key": "YOUR_API_KEY",
"method": "upload-files",
"soft_id": 123,
"version": "1.0.0"
}'
const response = await fetch("https://dev.mod.wtf/api/v2/action", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"api_key": "YOUR_API_KEY",
"method": "upload-files",
"soft_id": 123,
"version": "1.0.0"
}),
});
const result = await response.json();
$ch = curl_init('https://dev.mod.wtf/api/v2/action');
curl_setopt_array($ch, [
CURLOPT_POST => true,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Content-Type: application/json'],
CURLOPT_POSTFIELDS => json_encode([
'api_key' => 'YOUR_API_KEY',
'method' => 'upload-files',
'soft_id' => 123,
'version' => '1.0.0',
]),
]);
$result = json_decode(curl_exec($ch), true);
import requests
response = requests.post(
"https://dev.mod.wtf/api/v2/action",
json={
"api_key": "YOUR_API_KEY",
"method": "upload-files",
"soft_id": 123,
"version": "1.0.0",
},
timeout=10,
)
result = response.json()
{
"ok": true,
"data": {
"soft_id": 123,
"items": [
{
"token": "<TOKEN>",
"name": "libmod.so"
}
]
}
}
{
"ok": false,
"error": "validation",
"message": "You can store up to 10 files. Delete files to free up space."
}
{
"ok": false,
"error": "unauthorized",
"message": "Invalid or missing api_key"
}
Rename file
https://dev.mod.wtf/api/v2/action
methodrename-file
Change the public link name of a file. Old links keep working.
Body
-
soft_idinteger requiredID of a software you own
-
tokenstring requiredFile token from get-files
-
linkstring requiredNew file name
Errors it can return
POST /api/v2/action HTTP/1.1
Host: dev.mod.wtf
Content-Type: application/json
Accept: application/json
{
"api_key": "YOUR_API_KEY",
"method": "rename-file",
"soft_id": 123,
"token": "<TOKEN>",
"link": "libmod-v2.so"
}
curl -sS -X POST 'https://dev.mod.wtf/api/v2/action' \
-H 'Content-Type: application/json' \
-d '{
"api_key": "YOUR_API_KEY",
"method": "rename-file",
"soft_id": 123,
"token": "<TOKEN>",
"link": "libmod-v2.so"
}'
const response = await fetch("https://dev.mod.wtf/api/v2/action", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"api_key": "YOUR_API_KEY",
"method": "rename-file",
"soft_id": 123,
"token": "<TOKEN>",
"link": "libmod-v2.so"
}),
});
const result = await response.json();
$ch = curl_init('https://dev.mod.wtf/api/v2/action');
curl_setopt_array($ch, [
CURLOPT_POST => true,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Content-Type: application/json'],
CURLOPT_POSTFIELDS => json_encode([
'api_key' => 'YOUR_API_KEY',
'method' => 'rename-file',
'soft_id' => 123,
'token' => '<TOKEN>',
'link' => 'libmod-v2.so',
]),
]);
$result = json_decode(curl_exec($ch), true);
import requests
response = requests.post(
"https://dev.mod.wtf/api/v2/action",
json={
"api_key": "YOUR_API_KEY",
"method": "rename-file",
"soft_id": 123,
"token": "<TOKEN>",
"link": "libmod-v2.so",
},
timeout=10,
)
result = response.json()
{
"ok": true,
"data": {
"soft_id": 123,
"items": [
{
"token": "<TOKEN>",
"link": "libmod-v2.so"
}
]
}
}
{
"ok": false,
"error": "validation",
"message": "Enter a valid filename ending in .so, .a, .dll, .dylib or .lib."
}
{
"ok": false,
"error": "unauthorized",
"message": "Invalid or missing api_key"
}
Replace file
https://dev.mod.wtf/api/v2/action
methodreplace-file
Replace a file. Send multipart/form-data with the method in the query string: POST /api/v2/action?method=replace-file. Its links keep working.
Body
-
soft_idinteger requiredID of a software you own
-
tokenstring requiredFile token from get-files
-
filerequiredThe new file
-
versionstring optionalUp to 32 characters
Errors it can return
POST /api/v2/action HTTP/1.1
Host: dev.mod.wtf
Content-Type: application/json
Accept: application/json
{
"api_key": "YOUR_API_KEY",
"method": "replace-file",
"soft_id": 123,
"token": "<TOKEN>",
"version": "1.0.1"
}
curl -sS -X POST 'https://dev.mod.wtf/api/v2/action' \
-H 'Content-Type: application/json' \
-d '{
"api_key": "YOUR_API_KEY",
"method": "replace-file",
"soft_id": 123,
"token": "<TOKEN>",
"version": "1.0.1"
}'
const response = await fetch("https://dev.mod.wtf/api/v2/action", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"api_key": "YOUR_API_KEY",
"method": "replace-file",
"soft_id": 123,
"token": "<TOKEN>",
"version": "1.0.1"
}),
});
const result = await response.json();
$ch = curl_init('https://dev.mod.wtf/api/v2/action');
curl_setopt_array($ch, [
CURLOPT_POST => true,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Content-Type: application/json'],
CURLOPT_POSTFIELDS => json_encode([
'api_key' => 'YOUR_API_KEY',
'method' => 'replace-file',
'soft_id' => 123,
'token' => '<TOKEN>',
'version' => '1.0.1',
]),
]);
$result = json_decode(curl_exec($ch), true);
import requests
response = requests.post(
"https://dev.mod.wtf/api/v2/action",
json={
"api_key": "YOUR_API_KEY",
"method": "replace-file",
"soft_id": 123,
"token": "<TOKEN>",
"version": "1.0.1",
},
timeout=10,
)
result = response.json()
{
"ok": true,
"data": {
"soft_id": 123,
"items": [
{
"token": "<TOKEN>",
"version": "1.0.1"
}
]
}
}
{
"ok": false,
"error": "validation",
"message": "send exactly one file in the multipart field file"
}
{
"ok": false,
"error": "unauthorized",
"message": "Invalid or missing api_key"
}
Delete file
https://dev.mod.wtf/api/v2/action
methoddelete-file
Delete one file, or every file of the software with all=true. Their links stop working.
Body
-
soft_idinteger requiredID of a software you own
-
tokenstring optionalFile token from get-files
-
alloptionalBoolean
Errors it can return
POST /api/v2/action HTTP/1.1
Host: dev.mod.wtf
Content-Type: application/json
Accept: application/json
{
"api_key": "YOUR_API_KEY",
"method": "delete-file",
"soft_id": 123,
"token": "<TOKEN>"
}
curl -sS -X POST 'https://dev.mod.wtf/api/v2/action' \
-H 'Content-Type: application/json' \
-d '{
"api_key": "YOUR_API_KEY",
"method": "delete-file",
"soft_id": 123,
"token": "<TOKEN>"
}'
const response = await fetch("https://dev.mod.wtf/api/v2/action", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"api_key": "YOUR_API_KEY",
"method": "delete-file",
"soft_id": 123,
"token": "<TOKEN>"
}),
});
const result = await response.json();
$ch = curl_init('https://dev.mod.wtf/api/v2/action');
curl_setopt_array($ch, [
CURLOPT_POST => true,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Content-Type: application/json'],
CURLOPT_POSTFIELDS => json_encode([
'api_key' => 'YOUR_API_KEY',
'method' => 'delete-file',
'soft_id' => 123,
'token' => '<TOKEN>',
]),
]);
$result = json_decode(curl_exec($ch), true);
import requests
response = requests.post(
"https://dev.mod.wtf/api/v2/action",
json={
"api_key": "YOUR_API_KEY",
"method": "delete-file",
"soft_id": 123,
"token": "<TOKEN>",
},
timeout=10,
)
result = response.json()
{
"ok": true,
"data": {
"soft_id": 123,
"items": []
}
}
{
"ok": false,
"error": "not_found",
"message": "file not found"
}
{
"ok": false,
"error": "unauthorized",
"message": "Invalid or missing api_key"
}