Skip to content

api id not recognised? #19

Description

@dorienh

Hello,

Thanks for your assistance before. I have been trying to get track info from an mp3 at a certain location, which I upload first. But I get the following error code (my ID is correct btw). Perhaps it makes more sense to you?

Fatal error: Uncaught exception 'EchoNest_HttpClient_Exception' with message '1|Invalid key: Unknown' in /home/suneesto/addons/drupalfun.com/dance/php-echonest-api-master/lib/EchoNest/HttpClient.php:110 Stack trace: #0 /home/suneesto/addons/drupalfun.com/dance/php-echonest-api-master/lib/EchoNest/HttpClient.php(78): EchoNest_HttpClient->request('track/upload', Array, 'POST', Array) #1 /home/suneesto/addons/drupalfun.com/dance/php-echonest-api-master/lib/EchoNest/Client.php(97): EchoNest_HttpClient->post('track/upload', Array, Array) #2 /home/suneesto/addons/drupalfun.com/dance/php-echonest-api-master/lib/EchoNest/Api/Track.php(105): EchoNest_Client->post('track/upload', Array) #3 /home/suneesto/addons/drupalfun.com/dance/uploader.php(24): EchoNest_Api_Track->upload('http://drupalfu...', true, 'mp3', NULL, NULL) #4 {main} thrown in /home/suneesto/addons/drupalfun.com/dance/php-echonest-api-master/lib/EchoNest/HttpClient.php on line 110

This is my code:

require_once 'php-echonest-api-master/lib/EchoNest/Autoloader.php';
EchoNest_Autoloader::register();
$echonest = new EchoNest_Client();
$apikey = 'XXXmycorrectkey';
$echonest->authenticate($apiKey);

$url='http://drupalfun.com/dance/fastcar.mp3';
$trackApi = $echonest->getTrackApi()->upload($url, $wait = true, $filetype = mp3, $bucket = null, $track = null);

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions