面向程序、网站等的 JSON

text
https://api.gamemonitoring.cn/servers/8587945
json
{
  "response": {
    "fps": 122,
    "fps_avg": 120,
    "entities_count": 119048,
    "world_seed": 167789117,
    "world_size": 4250,
    "steam_id": "90285669957019676",
    "domain": null,
    "id": 8587945,
    "ip": "15.204.34.9",
    "port": 28015,
    "query": 28016,
    "color": 0,
    "city": "Hillsboro",
    "description": "![West Coast Fun PVE 2.5](https://cdn.discordapp.com/attachments/809514136194646036/809650422431481866/image0.jpg)\nPlease go to discord BEFORE joining to read the #rules(blue button below will join the discord)Active Admins\r\nNext wipe - June 4th \r\nPlease read the rules on our discord before playing\r\nignorance of the rules is NOT an excuse for breaking them \r\nhttps://discord.gg/CumrnnqwD8\r\nCheck our our Wiki for list of commands, features and other useful info\r\nwiki.WestCoastFunPVE.com",
    "game": 252490,
    "owner": null,
    "boosts": 1,
    "last_offline": 1778608980,
    "score": 0,
    "last_online": 1778686820,
    "icon": null,
    "name": "West Coast Fun PVE 2.5",
    "connect": "15.204.34.9:28015",
    "request": "15.204.34.9:28016",
    "map": "Procedural Map",
    "gamemode": "Survival",
    "version": "2625",
    "numplayers": 1,
    "maxplayers": 50,
    "bots": 0,
    "secured": true,
    "private": false,
    "country": "US",
    "status": true,
    "votes": 0,
    "points": 61,
    "add_date": 1744840036,
    "last_update": 1778686820,
    "banned": false,
    "wipe": 1778193978,
    "official": null,
    "wipe_period": null,
    "next_wipe": null,
    "pve": 0,
    "pvp": null,
    "list_hidden": false,
    "hide_address": false,
    "hide_query": false,
    "position_game": 2248,
    "language": "en",
    "parked": false,
    "app": {
      "id": 12,
      "steam_id": 252490,
      "name": "Rust",
      "url": "rust"
    },
    "server_owner": null,
    "mods": [],
    "disabled_modules": []
  }
}

代码示例

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