���� ������������������������������������ 'Missing clientpoint ID']); exit; } if (!$api_key) { http_response_code(400); echo json_encode(['error' => 'Missing API key']); exit; } // Prepare external API call (replace with real endpoint and key) $apiUrl = "https://api.clientpoint.net/v4/clientpoint/get-link/$clientpointId/?api_key=$api_key&type=view"; $ch = curl_init($apiUrl); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_HTTPHEADER, [ 'Content-Type: application/json', // 'Authorization: Bearer YOUR_API_KEY' if needed ]); $response = curl_exec($ch); $httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE); curl_close($ch); // Return response http_response_code($httpCode); echo $response;