Echonest跟踪配置文件请求始终返回空的audio_summary

时间:2016-01-22 07:25:48

标签: echonest

我要求bucket=audio_summary获得在热情方面排名很高的歌曲。 前100首hotttessst歌曲都返回track.status: 'complete'但音频摘要始终是空对象。

如何获取time_signaturetempo等音频摘要数据?没有track.status: complete暗示这些信息应该包含在回复中吗?

Can't Feel My Face 
https://developer.echonest.com/api/v4/track/profile?api_key=*****************&format=json&id=SOMVZDS14DDE5909E7&bucket=audio_summary

  {
    "response": {
      "status": {
        "version": "4.2",
        "code": 0,
        "message": "Success"
      },
      "track": {
        "status": "complete",
        "id": "SOZOIDR14C02B654D4",
        "audio_summary": {}
      }
    }
  }

1 个答案:

答案 0 :(得分:1)

看起来你有这首歌的SongId而不是TrackId。如果您在查询中将'track'替换为'song',您将获得预期的结果。

此:     https://developer.echonest.com/api/v4/song/profile?api_key= *****************&安培;格式= JSON和ID = SOMVZDS14DDE5909E7&安培;斗= audio_summary

返回:

{  
   "response":{  
      "status":{  
         "version":"4.2",
         "code":0,
         "message":"Success"
      },
      "songs":[  
         {  
            "artist_id":"ARYUDWF12F2B89BB33",
            "artist_name":"The Weeknd",
            "id":"SOMVZDS14DDE5909E7",
            "audio_summary":{  
               "key":9,
               "analysis_url":"http://echonest-analysis.s3.amazonaws.com/TR/A7NwGAWSmhnc53M8w1rLk-eA_tsN8OUHaqV5C5FTbb9BnCPZVnxWOGld1wLxJJ-xdNV8xKJbbZlCRSKJc%3D/3/full.json?AWSAccessKeyId=AKIAJRDFEY23UEVW42BQ&Expires=1454028841&Signature=HeUxbEJt4f0ncipjD1Gamtuj08E%3D",
               "energy":0.781735,
               "liveness":0.12022,
               "tempo":107.954,
               "speechiness":0.042317,
               "acousticness":0.124391,
               "instrumentalness":0.0,
               "mode":0,
               "time_signature":4,
               "duration":216.46667,
               "loudness":-5.528,
               "audio_md5":"",
               "valence":0.586261,
               "danceability":0.713659
            },
            "title":"Can't Feel My Face"
         }
      ]
   }
}

我能够追踪到这一点的唯一原因是,将任何ID投入到跟踪API中会返回您看到的存根响应,并且我能够使用spotify id获取此歌曲的audio_summary,所以我知道它是可用。