面向程序、网站等的 JSON

text
https://api.gamemonitoring.cn/servers/1204795
json
{
  "response": {
    "fps": 117,
    "fps_avg": 119,
    "entities_count": 141824,
    "world_seed": 141064932,
    "world_size": 4500,
    "steam_id": "90286747823893521",
    "domain": null,
    "id": 1204795,
    "ip": "107.193.75.154",
    "port": 28015,
    "query": 28018,
    "project_id": null,
    "color": 0,
    "city": "Imperial",
    "description": "![The Green Card PvE 2X - Zombies|RaidBases|Events|Perks|Kits](https://i.imgur.com/bgwWllj.jpg)\n★ Thank you for joining us!   This is a laid back, quiet, low-poop PvE server ★\r\n★ There is no PvP anywhere, no Building Decay or Upkeep, and no Radiation ★\r\n          ★ Zombies will spawn in at sundown!  NPCs are always on patrol ★\r\n       ★ Personal Vehicles | Kits | Raidable Bases | Monument Events ★\r\n                          ★ Virtual Quarries : Pumpjacks : Berry Farms ★\r\n★ Supply Drops, Hackable Crates, Pumpjacks & Giant Excavator lock to you ★\r\n    ★ Player Perks - Leveling System (/XP) and Playtime Ranking (/ranks) ★\r\n         ★ Vanilla Gather Rates | Modified Stack Sizes | Monthly Wipe ★",
    "game": 252490,
    "owner": null,
    "boosts": 1,
    "last_offline": 1780914861,
    "last_online": 1780918828,
    "icon": null,
    "name": "The Green Card PvE 2X - Zombies|RaidBases|Events|Perks|Kits",
    "connect": "107.193.75.154:28015",
    "request": "107.193.75.154:28018",
    "map": "HQM In My Pockets!",
    "gamemode": "Survival",
    "version": "2627",
    "numplayers": 1,
    "maxplayers": 25,
    "bots": 0,
    "secured": true,
    "private": false,
    "country": "US",
    "status": true,
    "votes": 0,
    "points": 62,
    "add_date": 1691954647,
    "last_update": 1780918828,
    "banned": false,
    "wipe": 1780595531,
    "official": null,
    "wipe_period": null,
    "next_wipe": null,
    "pve": 0,
    "pvp": null,
    "list_hidden": false,
    "hide_address": false,
    "hide_query": false,
    "position_game": 1564,
    "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/1204795");
$data = json_decode($json, true);
var_dump($data);