JSON pentru programe, site-uri și altele

text
https://api.gamemonitoring.ro/servers/10733932
json
{
  "response": {
    "channels": {
      "onlinecount": 16,
      "items": [
        {
          "clients": 0,
          "id": 96,
          "items": [],
          "name": "[spacer1]",
          "order": 0,
          "parent_id": 0,
          "topic": ""
        },
        {
          "clients": 0,
          "id": 91,
          "items": [],
          "name": "FREE CHANNELS",
          "order": 1,
          "parent_id": 0,
          "topic": ""
        },
        {
          "clients": 0,
          "id": 95,
          "items": [],
          "name": "[spacer0]",
          "order": 91,
          "parent_id": 0,
          "topic": ""
        },
        {
          "clients": 0,
          "id": 97,
          "items": [],
          "name": "Sala do Homem - straight",
          "order": 95,
          "parent_id": 0,
          "topic": ""
        },
        {
          "clients": 1,
          "id": 1,
          "items": [],
          "name": "EXILUS \\p GG",
          "order": 96,
          "parent_id": 0,
          "topic": ""
        },
        {
          "clients": 0,
          "id": 102,
          "items": [],
          "name": "godfors",
          "order": 97,
          "parent_id": 0,
          "topic": ""
        },
        {
          "clients": 0,
          "id": 104,
          "items": [],
          "name": "GUEST IS DNR",
          "order": 102,
          "parent_id": 0,
          "topic": ""
        },
        {
          "clients": 0,
          "id": 107,
          "items": [],
          "name": "SuRRi",
          "order": 104,
          "parent_id": 0,
          "topic": ""
        },
        {
          "clients": 0,
          "id": 114,
          "items": [],
          "name": "skill sf2",
          "order": 107,
          "parent_id": 0,
          "topic": ""
        },
        {
          "clients": 1,
          "id": 116,
          "items": [],
          "name": "TaskForceRadio",
          "order": 114,
          "parent_id": 0,
          "topic": ""
        },
        {
          "clients": 0,
          "id": 120,
          "items": [
            {
              "clients": 0,
              "id": 124,
              "items": [],
              "name": "CS",
              "order": 0,
              "parent_id": 120,
              "topic": "CS"
            },
            {
              "clients": 0,
              "id": 126,
              "items": [],
              "name": "PUBG",
              "order": 124,
              "parent_id": 120,
              "topic": "PUBG"
            },
            {
              "clients": 0,
              "id": 139,
              "items": [],
              "name": "WINS",
              "order": 126,
              "parent_id": 120,
              "topic": ""
            }
          ],
          "name": "ASSOBIADELA",
          "order": 116,
          "parent_id": 0,
          "topic": "ASSOBIADELA"
        },
        {
          "clients": 1,
          "id": 137,
          "items": [],
          "name": "AntiGalegagem",
          "order": 120,
          "parent_id": 0,
          "topic": ""
        },
        {
          "clients": 0,
          "id": 560,
          "items": [],
          "name": "barraco",
          "order": 137,
          "parent_id": 0,
          "topic": ""
        }
      ]
    },
    "external_id": "m4ebKZoGgYF4J4yYfMeFczfg7JI=",
    "platform": "Linux",
    "created": 1701270415,
    "uptime": 710802,
    "steam_id": null,
    "domain": "ts.exilus.org",
    "id": 10733932,
    "ip": "94.23.74.237",
    "port": 9987,
    "query": 9987,
    "color": 0,
    "city": "Lisbon",
    "description": null,
    "game": 9000043,
    "owner": null,
    "boosts": 1,
    "last_offline": 1775646703,
    "score": 0,
    "last_online": 1776360042,
    "icon": null,
    "name": "Exilus - TS3 Server",
    "connect": "ts.exilus.org:9987",
    "request": "94.23.74.237:9987",
    "map": null,
    "gamemode": null,
    "version": "3.13.7 Build: 1655727713",
    "numplayers": 3,
    "maxplayers": 32,
    "bots": 0,
    "secured": null,
    "private": false,
    "country": "PT",
    "status": true,
    "votes": 0,
    "points": 34,
    "add_date": 1765927640,
    "last_update": 1776360042,
    "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": 164,
    "language": "pt",
    "parked": false,
    "app": {
      "id": 1629110,
      "steam_id": 9000043,
      "name": "Teamspeak 3",
      "url": "teamspeak-3"
    },
    "server_owner": null,
    "mods": [],
    "disabled_modules": []
  }
}

Exemple de cod

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