ami4get.php 723 B

123456789101112131415161718192021222324252627
  1. <?php
  2. header("Content-Type: application/json");
  3. header("Access-Control-Allow-Origin: *");
  4. include "data/config.php";
  5. $real_requests = apcu_fetch("real_requests");
  6. $bot_requests = apcu_fetch("captcha_gen");
  7. echo json_encode(
  8. [
  9. "status" => "ok",
  10. "service" => "4get",
  11. "server" => [
  12. "name" => config::SERVER_NAME,
  13. "description" => config::SERVER_LONG_DESCRIPTION,
  14. "bot_protection" => config::BOT_PROTECTION,
  15. "real_requests" => $real_requests === false ? 0 : $real_requests,
  16. "bot_requests" => $bot_requests === false ? 0 : $bot_requests,
  17. "api_enabled" => config::API_ENABLED,
  18. "alt_addresses" => config::ALT_ADDRESSES,
  19. "version" => config::VERSION
  20. ],
  21. "instances" => config::INSTANCES
  22. ]
  23. );