How can i get a avatar from people, for example if i type &username=lolgc1 it shows the avatar lolgc1
It should be loaded i PHP
If you want to go with the new Twitch API route just use the Get Users endpoint. it will return the url to the image a json object under the property profile_image_url
shitty example, something simple
<?php
$name = $_GET['username'];
$client_id = ""; //app client id
$json = json_decode(file_get_contents('https://api.twitch.tv/kraken/channels/'. $name .'?client_id='. $client_id));
echo $json->logo;
?>
1 Like
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.