I'm trying to get the song profile of some mp3 via the Echonest API. With the /song/identify endpoint being removed (anybody knows why? since when?) I'm using the /track/upload and the /track/profile endpoints with success.
However with all mp3s I tried I never got a song_id field in the responses. And trying to access the /song/profile with a track_id parameter fails with the message "The Identifier specified does not exist".
I have no clue why this is happening. Isn't the /track/upload and /song/profile combination supposed to replace /song/identify? Or is there a mistake in my API usage?
Example session
/track/upload:
$ curl -X POST -H "Content-Type:application/octet-stream" "http://developer.echonest.com/api/v4/track/upload?api_key={API_KEY}&filetype=mp3" --data-binary "@some.mp3"
{"response" : {
"track" : {
"bitrate" : 128,
"status" : "pending",
"samplerate" : 44100,
"release" : "",
"audio_md5" : "a778192f46b14aff8b77fd90ff3674bb",
"artist" : "Michael Jackson",
"analyzer_version" : "3.2.2",
"title" : "Billie Jean",
"id" : "TRAWIST152E4579002",
"md5" : "b231bfa7d4ee4102e52b4495b10f4769"
},
"status" : {
"version" : "4.2",
"message" : "Success",
"code" : 0
}}}
/track/profile:
curl http://developer.echonest.com/api/v4/track/profile\?api_key\={API_KEY}\&format\=json\&id\=TRAWIST152E4579002\&bucket\=audio_summary
{"response" : {
"track" : {
"bitrate" : 128,
"status" : "complete",
"samplerate" : 44100,
"audio_summary" : {
"speechiness" : 0.0425334097439946,
"energy" : 0.591133932705891,
"instrumentalness" : 0.0294479646761868,
"valence" : 0.869460920263482,
"danceability" : 0.928799121110435,
"mode" : 0,
"tempo" : 117.099,
"duration" : 294.06041,
"loudness" : -6.027,
"key" : 11,
"time_signature" : 4,
"liveness" : 0.038297571421371,
"acousticness" : 0.0121077539216603,
"analysis_url" : "http://echonest-analysis.s3.amazonaws.com/TR/TRAWIST152E4579002/3/full.json?AWSAccessKeyId=AKI...&Expires=1455532971&Signature=ooy..."
},
"audio_md5" : "a778192f46b14aff8b77fd90ff3674bb",
"artist" : "Michael Jackson",
"analyzer_version" : "3.2.2",
"title" : "Billie Jean",
"id" : "TRAWIST152E4579002",
"md5" : "b231bfa7d4ee4102e52b4495b10f4769"
},
"status" : {
"version" : "4.2",
"message" : "Success",
"code" : 0
}}}
/song/profile:
curl http://developer.echonest.com/api/v4/song/profile\?api_key\={API_KEY}\&format\=json\&track_id\=TRAWIST152E4579002\&bucket\=audio_summary
{"response" : {
"status" : {
"version" : "4.2",
"message" : "The Identifier specified does not exist: TRAWIST152E4579002",
"code" : 5
}}}
I find nothing wrong with your API requests. There is a note in the API however, under Track/Profile header: Analysis Status, that seems to point to the fact that tracks doesn't get resolved into EchoNest songs, see below.
What you can do is create a Taste Profile using the track:id and it would get resolve into a EchoNest:song:id.
But this is a long way around, and considering the rate-limit is now down to 20/min, I don't know if I would bother. After EchoNest got bought by Spotify the public services are becoming deprecated and limited.