So this code does replay data:
<?php
$channelsApi = 'https://api.twitch.tv/kraken/users?login=';
$channelName = 'traceapaldinxxl';
$clientId = 'xxx';
$ch = curl_init();
**$apiVers = '&api_version=5';**
curl_setopt_array($ch, array(
CURLOPT_HTTPHEADER => array(
'Client-ID: ' . $clientId
),
CURLOPT_RETURNTRANSFER => true,
CURLOPT_URL => $channelsApi . $channelName . **$apiVers**
));
$response = curl_exec($ch);
if($response == true) {
echo "Stream is Online";
}
else {
echo "Stream is Offline";
}
echo"</br>";
var_dump(json_decode($response, true));
?>