Test B42.19 的 API
面向程序、网站等的 JSON
text
json
{
"response": {
"steam_id": "90286848959746052",
"domain": null,
"id": 11718979,
"ip": "77.239.252.99",
"port": 16261,
"query": 16261,
"project_id": null,
"color": 0,
"city": "Moscow",
"description": "For some development. Has local mods, you cannot join!",
"game": 108600,
"owner": null,
"boosts": 1,
"last_offline": 1780917261,
"last_online": 1781120433,
"icon": null,
"name": "Test B42.19",
"connect": "77.239.252.99:16261",
"request": "77.239.252.99:16261",
"map": "Maplewood;Muldraugh, KY",
"gamemode": "Project Zomboid",
"version": "42.19",
"numplayers": 0,
"maxplayers": 12,
"bots": 0,
"secured": true,
"private": false,
"country": "RU",
"status": true,
"votes": 0,
"points": 60,
"add_date": 1780324237,
"last_update": 1781120433,
"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": 3035,
"language": "ru",
"parked": false,
"app": {
"id": 71,
"steam_id": 108600,
"name": "Project Zomboid",
"url": "project-zomboid"
},
"server_owner": null,
"mods": [],
"disabled_modules": []
}
}代码示例
php
<?php
$json = file_get_contents("https://api.gamemonitoring.cn/servers/11718979");
$data = json_decode($json, true);
var_dump($data);