$image_id = "ID_OF_YOUR_IMAGE";
function get_image($image_id) {
$url = "https://api.autoenhance.ai/v3/images/$image_id";
$options = array(
'http' => array(
'method' => 'GET',
),
);
$context = stream_context_create($options);
$result = file_get_contents($url, false, $context);
if ($result === FALSE) {
return 'Error getting image';
}
$image = json_decode($result, true);
return $image;
}