Kraken/clips/top HTTP request failed, + basic question

Use cURL and specify headers.

With no headers it defaults to v3 and theres no clips endpoints on v3.

Also on most hosts file_get_contents over HTTP is blocked as it’s unsafe.

It looks like it should work with your code, but just don’t use file_get_contents as a rule

However the correct opts is:

$opts = [
        "http" => [
            "method" => "GET",
            "header" => "Client-ID: ".$this->client_id . "\r\n"
                        "Accept: application/vnd.twitchtv.v5+json\r\n"
        ]
    ];
1 Like