获取豆瓣FM的数据(频道列表,歌曲列表)

通过下面的API可以获取豆瓣电台的歌曲数据,返回结果是json格式。

1,获取频道列表数据
地址: http://www.douban.com/j/app/radio/channels
返回数据如下:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
{  
  "channels" : [
         {
             "name_en" "Personal Radio" ,
             "seq_id" : 0,
             "abbr_en" "My" ,
             "name" "私人兆赫" ,
             "channel_id" : 0
         },
         {
             "name" "华语" ,
             "seq_id" : 0,
             "abbr_en" "" ,
             "channel_id" "1" ,
             "name_en" ""
         },
         {
             "name" "欧美" ,
             "seq_id" : 1,
             "abbr_en" "" ,
             "channel_id" "2" ,
             "name_en" ""
         }
     ]
}

2,获取频道内歌曲列表的数据 
地址: http://douban.fm/j/mine/playlist?type=n&channel=1&from=mainsite
返回数据如下:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
{
     "r" : 0,
     "is_show_quick_start" : 0,
     "song" : [
         {
             "album" "/subject/20378872/" ,
             "picture" "http://img5.douban.com/lpic/s26810968.jpg" ,
             "ssid" "8182" ,
             "artist" "张靓颖" ,
             "url" "http://mr3.douban.com/201504220953/515bf283c74b3d4267cb65ddf862290a/view/song/small/p1839390.mp4" ,
             "company" "少城时代" ,
             "title" "感谢" ,
             "rating_avg" : 3.66253,
             "length" : 245,
             "subtype" "" ,
             "public_time" "2013" ,
             "songlists_count" : 8,
             "sid" "1839390" ,
             "aid" "20378872" ,
             "sha256" "6cbbf75173098071bf88213ba0b8e75b1d6dbc276e62f6d9beb097e3562f7b6f" ,
             "kbps" "64" ,
             "albumtitle" "感谢" ,
             "like" : 0
         },
         {
             "album" "/subject/10354836/" ,
             "picture" "http://img5.douban.com/lpic/s7033517.jpg" ,
             "ssid" "7e45" ,
             "artist" "游鸿明" ,
             "url" "http://mr3.douban.com/201504220953/cec525e325b259c54511865096308adf/view/song/small/p1774787.mp4" ,
             "company" "当然娱乐" ,
             "title" "每个人都在变" ,
             "rating_avg" : 3.3211,
             "length" : 246,
             "subtype" "" ,
             "public_time" "2011" ,
             "songlists_count" : 1,
             "sid" "1774787" ,
             "aid" "10354836" ,
             "sha256" "9f13a3a89e1f26b2bac9d6280cfe15d78341bcfd7a17c81f1588bcc2a2284872" ,
             "kbps" "64" ,
             "albumtitle" "每个人都在变" ,
             "like" : 0
         }
     ]
}

你可能感兴趣的:(豆瓣,json,api,数据)