面向程序、网站等的 JSON

text
https://api.gamemonitoring.cn/servers/7471964
json
{
  "response": {
    "steam_id": null,
    "domain": null,
    "id": 7471964,
    "ip": null,
    "port": null,
    "query": null,
    "color": 0,
    "city": null,
    "description": null,
    "game": 221100,
    "owner": 49396,
    "boosts": 1,
    "last_offline": 1758284167,
    "score": 0,
    "last_online": 1754276434,
    "icon": null,
    "name": "STALKER Echo of Zone PVE",
    "connect": null,
    "request": null,
    "map": "ExclusionZone",
    "gamemode": null,
    "version": null,
    "numplayers": 0,
    "maxplayers": 20,
    "bots": 0,
    "secured": false,
    "private": false,
    "country": "RU",
    "status": false,
    "votes": 0,
    "points": 0,
    "add_date": 1739258867,
    "last_update": 1758284167,
    "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": 4401,
    "language": "ru",
    "parked": true,
    "app": {
      "id": 63,
      "steam_id": 221100,
      "name": "DayZ",
      "url": "dayz"
    },
    "server_owner": {
      "username": "kvanback",
      "avatar": "a9965aca-97b5-4f6a-977b-6eb98af1349f.jpg",
      "last_online": 1739394121
    },
    "mods": [],
    "disabled_modules": []
  }
}

代码示例

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