面向程序、网站等的 JSON

text
https://api.gamemonitoring.cn/servers/10216196
json
{
  "response": {
    "steam_id": "90285111193777171",
    "domain": null,
    "id": 10216196,
    "ip": "72.180.69.87",
    "port": 27015,
    "query": 27016,
    "color": 0,
    "city": "San Marcos",
    "description": null,
    "game": 593600,
    "owner": null,
    "boosts": 1,
    "last_offline": 1777239202,
    "score": 0,
    "last_online": 1777515044,
    "icon": null,
    "name": "DejectedLand - (v1.223)",
    "connect": "72.180.69.87:27015",
    "request": "72.180.69.87:27016",
    "map": "CubeWorld_Light",
    "gamemode": "CW_GameMode_C",
    "version": "1.0.0.0",
    "numplayers": 0,
    "maxplayers": 40,
    "bots": 0,
    "secured": true,
    "private": false,
    "country": "US",
    "status": true,
    "votes": 0,
    "points": 30,
    "add_date": 1756581907,
    "last_update": 1777515044,
    "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": 120,
    "language": "en",
    "parked": false,
    "app": {
      "id": 188,
      "steam_id": 593600,
      "name": "PixARK",
      "url": "pixark"
    },
    "server_owner": null,
    "mods": [],
    "disabled_modules": []
  }
}

代码示例

php
<?php
$json = file_get_contents("https://api.gamemonitoring.cn/servers/10216196");
$data = json_decode($json, true);
var_dump($data);