// Initialize cURL. $ch = curl_init(); // Set the URL that you want to GET by using the CURLOPT_URL option. curl_setopt($ch, CURLOPT_URL, 'https://phonevalidation.abstractapi.com/v1/?api_key=138004ba5a1d48fd866a26a417a8e5a4&phone=14152007986'); // Set CURLOPT_RETURNTRANSFER so that the content is returned as a variable. curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); // Set CURLOPT_FOLLOWLOCATION to true to follow redirects. curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true); // Execute the request. $data = curl_exec($ch); // Close the cURL handle. curl_close($ch); // Print the data out onto the page. echo $data;