fork download
  1. <?php
  2. // Define the API URL and the IP you want to test
  3. $ip = "51.158.234.140"; // Replace with the IP you want to check
  4. $api_key = "asifjamali83"; // Replace with your API key
  5.  
  6. // Construct the API URL
  7. $api_url = "https://s...content-available-to-author-only...t.ws/api.php?ip=" . $ip . "&apikey=" . $api_key;
  8.  
  9. // Send the GET request to the API
  10. $response = file_get_contents($api_url);
  11.  
  12. // Check if the response is not empty and then output it
  13. if ($response !== false) {
  14. // Decode the JSON response
  15. $data = json_decode($response, true);
  16.  
  17. // Check if the fraud score exists in the response
  18. if (isset($data['fraud_score'])) {
  19. echo "IP: " . $data['ip'] . "<br>";
  20. echo "Fraud Score: " . $data['fraud_score'] . "<br>";
  21. } else {
  22. echo "No fraud score found in the response.";
  23. }
  24. } else {
  25. echo "Error: Could not retrieve data from the API.";
  26. }
  27. ?>
  28.  
Success #stdin #stdout #stderr 0.03s 26184KB
stdin
Standard input is empty
stdout
Error: Could not retrieve data from the API.
stderr
PHP Warning:  file_get_contents(): php_network_getaddresses: getaddrinfo failed: Temporary failure in name resolution in /home/1eaUz2/prog.php on line 10
PHP Warning:  file_get_contents(https://s...content-available-to-author-only...t.ws/api.php?ip=51.158.234.140&apikey=asifjamali83): failed to open stream: php_network_getaddresses: getaddrinfo failed: Temporary failure in name resolution in /home/1eaUz2/prog.php on line 10