JSON pentru programe, site-uri și altele

text
https://api.gamemonitoring.ro/servers/9721071
json
{
  "response": {
    "fps": 109,
    "fps_avg": 104,
    "entities_count": 68334,
    "world_seed": 7564928,
    "world_size": 3500,
    "steam_id": "90286472474423301",
    "domain": null,
    "id": 9721071,
    "ip": "216.114.75.56",
    "port": 28015,
    "query": 28017,
    "color": 0,
    "city": "Dallas",
    "description": "![LiQ Gaming |2X|Raidable Bases|No Offline Raid|PVP|](https://raw.githubusercontent.com/liquid-gaming/liquid-gaming.github.io/master/public/images/banner.jpg)\n- PvP\r\n- Vanilla-esque\r\n- bi-weekly map wipes\r\n- monthly BP wipe\r\n- 2x resources\r\n\r\nPlugins:\r\n -Raidable bases\r\n- Backpacks\r\n- Convoy\r\n- Quick smelt\r\n\r\nDiscord: https://liqgaming.com/discord\r\n\r\n== Rules ==\r\n\r\nLiQuid Gaming Server Rules:\r\n\r\n1. No Hate Speech: Speech that denigrates individuals or groups based on race, sexual orientation, or religion is prohibited. Offending instances lead to a ban by LiQ Admin.\r\n\r\n2. No Cheating: Glitching, hacking, or any form of cheating results in a ban by LiQ Admin.\r\n\r\n3. No Malicious Behavior: Real-life threats, doxing, or harmful actions lead to a ban by LiQ Admin.\r\n\r\n4. No Toxicity: Disrupting gameplay or other players' experiences beyond normal discussion results in warn/kick/ban by LiQ Admin.\r\n\r\n5. No Bunker Bases: Loot and TC must be accessible, no complete walling off. Non-compliant bases have structures deleted. Violation leads to warnings, kicks, then temporary bans.\r\n\r\n6. No Insiding: Betraying teammates results in a temporary ban.\r\n\r\n7. No Griefing: Blocking player bases or monuments is not allowed. Raided bases can't be blocked without intent to use. Violation leads to warnings, kicks, then temporary bans.\r\n\r\n8. No Loot Despawning: Preventing loot access via despawning is forbidden. Violation leads to kicks or temporary bans by LiQ Admin.\r\n\r\n9. No Offline Raiding - You can only online raid player bases. When you start the raid the player must be online. If a player logs off mid raid you may continue. We have a mod in place to protect player bases while offline, refunds for wasted boom will not be given. Logging out to prevent",
    "game": 252490,
    "owner": null,
    "boosts": 1,
    "last_offline": 1779372822,
    "last_online": 1780555230,
    "icon": null,
    "name": "LiQ Gaming |2X|Raidable Bases|No Offline Raid|PVP|",
    "connect": "216.114.75.56:28015",
    "request": "216.114.75.56:28017",
    "map": "Procedural Map",
    "gamemode": "Survival",
    "version": "2625",
    "numplayers": 0,
    "maxplayers": 50,
    "bots": 0,
    "secured": true,
    "private": false,
    "country": "US",
    "status": true,
    "votes": 0,
    "points": 60,
    "add_date": 1752139819,
    "last_update": 1780555230,
    "banned": false,
    "wipe": 1779373006,
    "official": null,
    "wipe_period": null,
    "next_wipe": null,
    "pve": 0,
    "pvp": null,
    "list_hidden": false,
    "hide_address": false,
    "hide_query": false,
    "position_game": 3087,
    "language": "en",
    "parked": false,
    "app": {
      "id": 12,
      "steam_id": 252490,
      "name": "Rust",
      "url": "rust"
    },
    "server_owner": null,
    "mods": [],
    "disabled_modules": []
  }
}

Exemple de cod

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