Rust in Peace - Hub Island 的 API
面向程序、网站等的 JSON
text
json
{
"response": {
"fps": 60,
"fps_avg": 60,
"entities_count": 147,
"world_seed": 1234,
"world_size": 2750,
"steam_id": "90286412809121816",
"domain": null,
"id": 8884852,
"ip": "168.100.162.12",
"port": 28015,
"query": 28014,
"color": 0,
"city": "Dallas",
"description": "\nWelcome to the hub server for Rust in Peace!\r\n\r\nPlayers are automatically redirected here during main server restarts, and sent back to avoid getting disconnected!\r\n\r\nWant to play Rust in Peace? Join discord.gg/rustinpeace",
"game": 252490,
"owner": null,
"boosts": 1,
"last_offline": 1777913013,
"last_online": 1780570232,
"icon": null,
"name": "Rust in Peace - Hub Island",
"connect": "168.100.162.12:28015",
"request": "168.100.162.12:28014",
"map": "discord.gg/rustinpeace",
"gamemode": "Survival",
"version": "2625",
"numplayers": 0,
"maxplayers": 500,
"bots": 0,
"secured": true,
"private": false,
"country": "US",
"status": true,
"votes": 0,
"points": 60,
"add_date": 1746405525,
"last_update": 1780570232,
"banned": false,
"wipe": 1778246802,
"official": null,
"wipe_period": null,
"next_wipe": null,
"pve": 0,
"pvp": null,
"list_hidden": false,
"hide_address": false,
"hide_query": false,
"position_game": 3116,
"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/8884852");
$data = json_decode($json, true);
var_dump($data);