API dla Thorns Back2Basics
JSON dla programów, stron i innych
text
json
{
"response": {
"steam_id": "85568392935298004",
"domain": null,
"id": 11578755,
"ip": "172.240.74.92",
"port": 25678,
"query": 25678,
"color": 0,
"city": "San Jose",
"description": null,
"game": 304930,
"owner": null,
"boosts": 1,
"last_offline": 1780559012,
"last_online": 1780200165,
"icon": "https://file.garden/abG7jBTYwQRw87uv/Thorn%E2%80%99s%20Back2Basics%20(1).png",
"name": "Thorns Back2Basics",
"connect": "172.240.74.92:25678",
"request": "172.240.74.92:25678",
"map": "California2",
"gamemode": "PVE with minimal mods or plugins, just the right amount.",
"version": "3.26.3.2",
"numplayers": 0,
"maxplayers": 24,
"bots": 0,
"secured": true,
"private": false,
"country": "US",
"status": false,
"votes": 0,
"points": 0,
"add_date": 1779356935,
"last_update": 1780559012,
"banned": false,
"wipe": null,
"official": null,
"wipe_period": null,
"next_wipe": null,
"pve": null,
"pvp": null,
"list_hidden": false,
"hide_address": false,
"hide_query": false,
"position_game": 2161,
"language": "en",
"parked": false,
"app": {
"id": 48,
"steam_id": 304930,
"name": "Unturned",
"url": "unturned"
},
"server_owner": null,
"mods": [],
"disabled_modules": []
}
}Przykłady kodu
php
<?php
$json = file_get_contents("https://api.gamemonitoring.pl/servers/11578755");
$data = json_decode($json, true);
var_dump($data);