ronnie 0.7.6 → 0.8.0
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +28 -134
- data/banner.txt +79 -0
- data/lib/ronnie/client.rb +4 -0
- data/lib/ronnie/client/activities.rb +17 -0
- data/lib/ronnie/client/albums.rb +35 -1
- data/lib/ronnie/client/artists.rb +27 -1
- data/lib/ronnie/client/playlists.rb +8 -0
- data/lib/ronnie/client/tokens.rb +13 -0
- data/lib/ronnie/client/tracks.rb +8 -0
- data/lib/ronnie/version.rb +1 -1
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_activities/Retrieve_everyone_Activity_Stream/.yml +562 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_activities/Retrieve_friends_Activity_Stream/.yml +242 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_activities/Retrieve_user_Activity_Stream/.yml +339 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/{_user/Retrieve_User → _create_token/create_playback_token_}/.yml +18 -15
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_find_user/Find_user_by_e-mail_address_/.yml +64 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_follow/{Follow_a_User → Follow_a_user_}/.yml +16 -10
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_followers/Retrieve_followers_of_a_user_/.yml +95 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_following/Retrieve_users_following_another_user_/.yml +95 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_following/Retrieve_users_following_authorized_user_/.yml +156 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_follows_/Authorized_user_is_following_a_user_/.yml +156 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_heavily_rotated_albums/retrieve_heavily_rotated_albums_/.yml +165 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_heavily_rotated_artists/retrieve_heavily_rotated_artists_/.yml +101 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_heavy_rotation/Retrieve_the_most_popular_albums_for_a_user_/.yml +160 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_heavy_rotation/Retrieve_the_most_popular_albums_for_a_user_s_friends_/.yml +167 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_heavy_rotation/Retrieve_the_most_popular_albums_for_everyone_/.yml +165 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_heavy_rotation/Retrieve_the_most_popular_artists_for_a_user_/.yml +102 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_heavy_rotation/Retrieve_the_most_popular_artists_for_a_user_s_friends_/.yml +165 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_heavy_rotation/Retrieve_the_most_popular_artists_for_everyone_/.yml +165 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_new_releases/Retrieve_new_releases_/.yml +274 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_search_users/Search_users_/.yml +66 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_top_albums/retrieve_the_site-wide_most_popular_albums_/.yml +265 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_top_artists/retrieve_the_site-wide_most_popular_artists_/.yml +141 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_top_playlists/retrieve_the_site-wide_most_popular_playlists_/.yml +184 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_top_tracks/retrieve_the_site-wide_most_popular_tracks_/.yml +255 -0
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_unfollow/{Unfollow_a_User → Unfollow_a_user_}/.yml +15 -9
- data/spec/fixtures/cassettes/Ronnie_Client_Users/{_followers/Retrieve_Followers_of_a_User → _user/Retrieve_authorized_user_}/.yml +21 -15
- data/spec/fixtures/cassettes/Ronnie_Client_Users/_user/Retrieve_user_/.yml +64 -0
- data/spec/ronnie/client/activities_spec.rb +32 -0
- data/spec/ronnie/client/albums_spec.rb +26 -2
- data/spec/ronnie/client/artists_spec.rb +17 -1
- data/spec/ronnie/client/collections_spec.rb +1 -1
- data/spec/ronnie/client/playlists_spec.rb +9 -1
- data/spec/ronnie/client/tokens_spec.rb +22 -0
- data/spec/ronnie/client/tracks_spec.rb +10 -2
- data/spec/ronnie/client/users_spec.rb +17 -17
- metadata +63 -10
@@ -0,0 +1,255 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: post
|
5
|
+
uri: http://api.rdio.com/1/
|
6
|
+
body:
|
7
|
+
encoding: US-ASCII
|
8
|
+
string: method=getTopCharts&type=Track
|
9
|
+
headers:
|
10
|
+
Authorization:
|
11
|
+
- OAuth oauth_consumer_key="ub9ebmvf7aee3pxcms9e5mh3", oauth_nonce="57e6fad84869c026d29b50c4f46aab74",
|
12
|
+
oauth_signature="oMzGWdImCFjC5969pulqzRsrGGw%3D", oauth_signature_method="HMAC-SHA1",
|
13
|
+
oauth_timestamp="1351732236", oauth_token="ute6gf7jk4y5734hx42uxspfnhdkt42qt8habah6tkyvx4ay2xvhpt5faa2ddqc6",
|
14
|
+
oauth_version="1.0"
|
15
|
+
Content-Type:
|
16
|
+
- application/x-www-form-urlencoded
|
17
|
+
Accept:
|
18
|
+
- ! '*/*'
|
19
|
+
User-Agent:
|
20
|
+
- Ruby
|
21
|
+
response:
|
22
|
+
status:
|
23
|
+
code: 200
|
24
|
+
message: OK
|
25
|
+
headers:
|
26
|
+
X-Mashery-Responder:
|
27
|
+
- mashery-web3-lax.mashery.com
|
28
|
+
Content-Type:
|
29
|
+
- application/json
|
30
|
+
Vary:
|
31
|
+
- Accept-Encoding
|
32
|
+
- Accept-Language, Cookie
|
33
|
+
Content-Language:
|
34
|
+
- en
|
35
|
+
Cache-Control:
|
36
|
+
- no-cache
|
37
|
+
Access-Control-Allow-Origin:
|
38
|
+
- ! '*'
|
39
|
+
X-Version:
|
40
|
+
- '720'
|
41
|
+
Accept-Ranges:
|
42
|
+
- bytes
|
43
|
+
Date:
|
44
|
+
- Thu, 01 Nov 2012 01:10:34 GMT
|
45
|
+
Server:
|
46
|
+
- Mashery Proxy
|
47
|
+
Content-Length:
|
48
|
+
- '17307'
|
49
|
+
X-Cache:
|
50
|
+
- MISS from 172.19.134.2
|
51
|
+
X-Cache-Lookup:
|
52
|
+
- MISS from 172.19.134.2:3128
|
53
|
+
Via:
|
54
|
+
- 1.0 172.19.134.2:3128 (squid/2.6.STABLE14)
|
55
|
+
Connection:
|
56
|
+
- close
|
57
|
+
body:
|
58
|
+
encoding: US-ASCII
|
59
|
+
string: ! '{"status": "ok", "result": [{"baseIcon": "album/e/8/f/00000000001d2f8e/5/square-200.jpg",
|
60
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/Psy/", "duration": 219,
|
61
|
+
"album": "Gangnam Style (\uac15\ub0a8\uc2a4\ud0c0\uc77c)", "isClean": true,
|
62
|
+
"albumUrl": "/artist/Psy/album/Gangnam_Style_(%EA%B0%95%EB%82%A8%EC%8A%A4%ED%83%80%EC%9D%BC)/",
|
63
|
+
"shortUrl": "http://rd.io/x/QV76fDdeaWAT", "albumArtist": "Psy", "canStream":
|
64
|
+
true, "embedUrl": "https://rd.io/e/QV76fDdeaWAT", "type": "t", "price": "1.29",
|
65
|
+
"trackNum": 1, "albumArtistKey": "r315997", "key": "t20652375", "icon": "http://cdn3.rd.io/album/e/8/f/00000000001d2f8e/5/square-200.jpg",
|
66
|
+
"canSample": true, "name": "Gangnam Style (\uac15\ub0a8\uc2a4\ud0c0\uc77c)",
|
67
|
+
"isExplicit": false, "artistKey": "r315997", "url": "/artist/Psy/album/Gangnam_Style_(%EA%B0%95%EB%82%A8%EC%8A%A4%ED%83%80%EC%9D%BC)/track/Gangnam_Style_(%EA%B0%95%EB%82%A8%EC%8A%A4%ED%83%80%EC%9D%BC)/",
|
68
|
+
"albumKey": "a1912718", "artist": "Psy", "canDownload": true, "length": 1,
|
69
|
+
"canTether": true}, {"baseIcon": "album/6/8/5/0000000000185586/1/square-200.jpg",
|
70
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/Xymphoni/", "duration":
|
71
|
+
252, "album": "Giggilo", "isClean": false, "albumUrl": "/artist/Xymphoni/album/Giggilo/",
|
72
|
+
"shortUrl": "http://rd.io/x/QV76fDdeX1Nb", "albumArtist": "Xymphoni", "canStream":
|
73
|
+
true, "embedUrl": "https://rd.io/e/QV76fDdeX1Nb", "type": "t", "price": "0.99",
|
74
|
+
"trackNum": 1, "albumArtistKey": "r403818", "key": "t17633823", "icon": "http://cdn3.rd.io/album/6/8/5/0000000000185586/1/square-200.jpg",
|
75
|
+
"canSample": true, "name": "Giggilo", "isExplicit": false, "artistKey": "r403818",
|
76
|
+
"url": "/artist/Xymphoni/album/Giggilo/track/Giggilo/", "albumKey": "a1594758",
|
77
|
+
"artist": "Xymphoni", "canDownload": true, "length": 1, "canTether": true},
|
78
|
+
{"baseIcon": "album/9/8/0/00000000001be089/5/square-200.jpg", "canDownloadAlbumOnly":
|
79
|
+
true, "artistUrl": "/artist/Taylor_Swift/", "duration": 193, "album": "We
|
80
|
+
Are Never Ever Getting Back Together", "isClean": true, "albumUrl": "/artist/Taylor_Swift/album/We_Are_Never_Ever_Getting_Back_Together/",
|
81
|
+
"shortUrl": "http://rd.io/x/QV76fDdef6bI", "albumArtist": "Taylor Swift",
|
82
|
+
"canStream": true, "embedUrl": "https://rd.io/e/QV76fDdef6bI", "type": "t",
|
83
|
+
"price": "1.29", "trackNum": 1, "albumArtistKey": "r99292", "key": "t19785612",
|
84
|
+
"icon": "http://cdn3.rd.io/album/9/8/0/00000000001be089/5/square-200.jpg",
|
85
|
+
"canSample": true, "name": "We Are Never Ever Getting Back Together", "isExplicit":
|
86
|
+
false, "artistKey": "r99292", "url": "/artist/Taylor_Swift/album/We_Are_Never_Ever_Getting_Back_Together/track/We_Are_Never_Ever_Getting_Back_Together/",
|
87
|
+
"albumKey": "a1826953", "artist": "Taylor Swift", "canDownload": true, "length":
|
88
|
+
1, "canTether": true}, {"baseIcon": "album/f/0/b/0000000000152b0f/7/square-200.jpg",
|
89
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/fun./", "duration": 277,
|
90
|
+
"album": "Some Nights", "isClean": false, "albumUrl": "/artist/fun./album/Some_Nights/",
|
91
|
+
"shortUrl": "http://rd.io/x/QV76fDexPMY", "albumArtist": "fun.", "canStream":
|
92
|
+
true, "embedUrl": "https://rd.io/e/QV76fDexPMY", "type": "t", "price": "1.29",
|
93
|
+
"trackNum": 2, "albumArtistKey": "r500780", "key": "t15625863", "icon": "http://cdn3.rd.io/album/f/0/b/0000000000152b0f/7/square-200.jpg",
|
94
|
+
"canSample": true, "name": "Some Nights", "isExplicit": false, "artistKey":
|
95
|
+
"r500780", "url": "/artist/fun./album/Some_Nights/track/Some_Nights/", "albumKey":
|
96
|
+
"a1387279", "artist": "fun.", "canDownload": true, "length": 1, "canTether":
|
97
|
+
true}, {"baseIcon": "album/b/2/0/00000000001e502b/3/square-200.jpg", "canDownloadAlbumOnly":
|
98
|
+
true, "artistUrl": "/artist/Rihanna/", "duration": 225, "album": "Diamonds",
|
99
|
+
"isClean": true, "albumUrl": "/artist/Rihanna/album/Diamonds/", "shortUrl":
|
100
|
+
"http://rd.io/x/QV76fDdeFMus", "albumArtist": "Rihanna", "canStream": true,
|
101
|
+
"embedUrl": "https://rd.io/e/QV76fDdeFMus", "type": "t", "price": "1.29",
|
102
|
+
"trackNum": 1, "albumArtistKey": "r93801", "key": "t21400296", "icon": "http://cdn3.rd.io/album/b/2/0/00000000001e502b/3/square-200.jpg",
|
103
|
+
"canSample": true, "name": "Diamonds", "isExplicit": false, "artistKey": "r93801",
|
104
|
+
"url": "/artist/Rihanna/album/Diamonds/track/Diamonds/", "albumKey": "a1986603",
|
105
|
+
"artist": "Rihanna", "canDownload": true, "length": 1, "canTether": true},
|
106
|
+
{"baseIcon": "album/a/e/d/00000000001dedea/6/square-200.jpg", "canDownloadAlbumOnly":
|
107
|
+
true, "artistUrl": "/artist/Ke%24ha/", "duration": 213, "album": "Die Young",
|
108
|
+
"isClean": false, "albumUrl": "/artist/Ke%24ha/album/Die_Young/", "shortUrl":
|
109
|
+
"http://rd.io/x/QV76fDdeEOEK", "albumArtist": "Ke$ha", "canStream": true,
|
110
|
+
"embedUrl": "https://rd.io/e/QV76fDdeEOEK", "type": "t", "price": "1.29",
|
111
|
+
"trackNum": 1, "albumArtistKey": "r184075", "key": "t21143630", "icon": "http://cdn3.rd.io/album/a/e/d/00000000001dedea/6/square-200.jpg",
|
112
|
+
"canSample": true, "name": "Die Young", "isExplicit": false, "artistKey":
|
113
|
+
"r184075", "url": "/artist/Ke%24ha/album/Die_Young/track/Die_Young/", "albumKey":
|
114
|
+
"a1961450", "artist": "Ke$ha", "canDownload": true, "length": 1, "canTether":
|
115
|
+
true}, {"baseIcon": "album/0/b/f/00000000001eafb0/4/square-200.jpg", "canDownloadAlbumOnly":
|
116
|
+
true, "artistUrl": "/artist/Kendrick_Lamar/", "duration": 310, "album": "good
|
117
|
+
kid, m.A.A.d city (Deluxe)", "isClean": false, "albumUrl": "/artist/Kendrick_Lamar/album/good_kid%2C_m.A.A.d_city_(Deluxe)/",
|
118
|
+
"shortUrl": "http://rd.io/x/QV76fDdeGCJj", "albumArtist": "Kendrick Lamar",
|
119
|
+
"canStream": true, "embedUrl": "https://rd.io/e/QV76fDdeGCJj", "type": "t",
|
120
|
+
"price": "1.29", "trackNum": 2, "albumArtistKey": "r619646", "key": "t21652263",
|
121
|
+
"icon": "http://cdn3.rd.io/album/0/b/f/00000000001eafb0/4/square-200.jpg",
|
122
|
+
"canSample": true, "name": "Bitch, Don\u2019t Kill My Vibe", "isExplicit":
|
123
|
+
true, "artistKey": "r619646", "url": "/artist/Kendrick_Lamar/album/good_kid%2C_m.A.A.d_city_(Deluxe)/track/Bitch%2C_Don%E2%80%99t_Kill_My_Vibe/",
|
124
|
+
"albumKey": "a2011056", "artist": "Kendrick Lamar", "canDownload": true, "length":
|
125
|
+
1, "canTether": true}, {"baseIcon": "album/0/1/c/000000000018ac10/4/square-200.jpg",
|
126
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/Justin_Bieber/", "duration":
|
127
|
+
229, "album": "Believe (Deluxe Edition)", "isClean": true, "albumUrl": "/artist/Justin_Bieber/album/Believe_(Deluxe_Edition)/",
|
128
|
+
"shortUrl": "http://rd.io/x/QV76fDdeQg54", "albumArtist": "Justin Bieber",
|
129
|
+
"canStream": true, "embedUrl": "https://rd.io/e/QV76fDdeQg54", "type": "t",
|
130
|
+
"price": "1.29", "trackNum": 3, "albumArtistKey": "r184130", "key": "t17846076",
|
131
|
+
"icon": "http://cdn3.rd.io/album/0/1/c/000000000018ac10/4/square-200.jpg",
|
132
|
+
"canSample": true, "name": "As Long As You Love Me", "isExplicit": false,
|
133
|
+
"artistKey": "r184130", "url": "/artist/Justin_Bieber/album/Believe_(Deluxe_Edition)/track/As_Long_As_You_Love_Me/",
|
134
|
+
"albumKey": "a1616912", "artist": "Justin Bieber", "canDownload": true, "length":
|
135
|
+
1, "canTether": true}, {"baseIcon": "album/0/a/b/000000000018cba0/6/square-200.jpg",
|
136
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/Maroon_5/", "duration":
|
137
|
+
219, "album": "One More Night", "isClean": true, "albumUrl": "/artist/Maroon_5/album/One_More_Night/",
|
138
|
+
"shortUrl": "http://rd.io/x/QV76fDdeQzEd", "albumArtist": "Maroon 5", "canStream":
|
139
|
+
true, "embedUrl": "https://rd.io/e/QV76fDdeQzEd", "type": "t", "price": "1.29",
|
140
|
+
"trackNum": 1, "albumArtistKey": "r91336", "key": "t17920089", "icon": "http://cdn3.rd.io/album/0/a/b/000000000018cba0/6/square-200.jpg",
|
141
|
+
"canSample": true, "name": "One More Night", "isExplicit": false, "artistKey":
|
142
|
+
"r91336", "url": "/artist/Maroon_5/album/One_More_Night/track/One_More_Night/",
|
143
|
+
"albumKey": "a1624992", "artist": "Maroon 5", "canDownload": true, "length":
|
144
|
+
1, "canTether": true}, {"baseIcon": "album/0/b/f/00000000001eafb0/4/square-200.jpg",
|
145
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/Kendrick_Lamar/", "duration":
|
146
|
+
212, "album": "good kid, m.A.A.d city (Deluxe)", "isClean": false, "albumUrl":
|
147
|
+
"/artist/Kendrick_Lamar/album/good_kid%2C_m.A.A.d_city_(Deluxe)/", "shortUrl":
|
148
|
+
"http://rd.io/x/QV76fDdeGCJ1", "albumArtist": "Kendrick Lamar", "canStream":
|
149
|
+
true, "embedUrl": "https://rd.io/e/QV76fDdeGCJ1", "type": "t", "price": "1.29",
|
150
|
+
"trackNum": 3, "albumArtistKey": "r619646", "key": "t21652273", "icon": "http://cdn3.rd.io/album/0/b/f/00000000001eafb0/4/square-200.jpg",
|
151
|
+
"canSample": true, "name": "Backseat Freestyle", "isExplicit": true, "artistKey":
|
152
|
+
"r619646", "url": "/artist/Kendrick_Lamar/album/good_kid%2C_m.A.A.d_city_(Deluxe)/track/Backseat_Freestyle/",
|
153
|
+
"albumKey": "a2011056", "artist": "Kendrick Lamar", "canDownload": true, "length":
|
154
|
+
1, "canTether": true}, {"baseIcon": "album/0/b/f/00000000001eafb0/4/square-200.jpg",
|
155
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/Kendrick_Lamar/", "duration":
|
156
|
+
300, "album": "good kid, m.A.A.d city (Deluxe)", "isClean": false, "albumUrl":
|
157
|
+
"/artist/Kendrick_Lamar/album/good_kid%2C_m.A.A.d_city_(Deluxe)/", "shortUrl":
|
158
|
+
"http://rd.io/x/QV76fDdeGCIM", "albumArtist": "Kendrick Lamar", "canStream":
|
159
|
+
true, "embedUrl": "https://rd.io/e/QV76fDdeGCIM", "type": "t", "price": "1.29",
|
160
|
+
"trackNum": 6, "albumArtistKey": "r619646", "key": "t21652296", "icon": "http://cdn3.rd.io/album/0/b/f/00000000001eafb0/4/square-200.jpg",
|
161
|
+
"canSample": true, "name": "Poetic Justice", "isExplicit": true, "artistKey":
|
162
|
+
"r619646", "url": "/artist/Kendrick_Lamar/album/good_kid%2C_m.A.A.d_city_(Deluxe)/track/Poetic_Justice/",
|
163
|
+
"albumKey": "a2011056", "artist": "Kendrick Lamar", "canDownload": true, "length":
|
164
|
+
1, "canTether": true}, {"baseIcon": "album/e/8/f/00000000001a8f8e/4/square-200.jpg",
|
165
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/Frank_Ocean/", "duration":
|
166
|
+
201, "album": "channel ORANGE", "isClean": true, "albumUrl": "/artist/Frank_Ocean/album/channel_ORANGE_1/",
|
167
|
+
"shortUrl": "http://rd.io/x/QV76fDdecrlZ", "albumArtist": "Frank Ocean", "canStream":
|
168
|
+
true, "embedUrl": "https://rd.io/e/QV76fDdecrlZ", "type": "t", "price": "1.29",
|
169
|
+
"trackNum": 2, "albumArtistKey": "r1009235", "key": "t18937885", "icon": "http://cdn3.rd.io/album/e/8/f/00000000001a8f8e/4/square-200.jpg",
|
170
|
+
"canSample": true, "name": "Thinkin Bout You", "isExplicit": false, "artistKey":
|
171
|
+
"r1009235", "url": "/artist/Frank_Ocean/album/channel_ORANGE_1/track/Thinkin_Bout_You/",
|
172
|
+
"albumKey": "a1740686", "artist": "Frank Ocean", "canDownload": true, "length":
|
173
|
+
1, "canTether": true}, {"baseIcon": "album/1/6/e/00000000001b5e61/4/square-200.jpg",
|
174
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/2_Chainz/", "duration":
|
175
|
+
307, "album": "Based On A T.R.U. Story (Deluxe Version)", "isClean": false,
|
176
|
+
"albumUrl": "/artist/2_Chainz/album/Based_On_A_T.R.U._Story_(Deluxe_Version)/",
|
177
|
+
"shortUrl": "http://rd.io/x/QV76fDdeevgE", "albumArtist": "2 Chainz", "canStream":
|
178
|
+
true, "embedUrl": "https://rd.io/e/QV76fDdeevgE", "type": "t", "price": "1.29",
|
179
|
+
"trackNum": 5, "albumArtistKey": "r964657", "key": "t19446080", "icon": "http://cdn3.rd.io/album/1/6/e/00000000001b5e61/4/square-200.jpg",
|
180
|
+
"canSample": true, "name": "Birthday Song", "isExplicit": true, "artistKey":
|
181
|
+
"r964657", "url": "/artist/2_Chainz/album/Based_On_A_T.R.U._Story_(Deluxe_Version)/track/Birthday_Song/",
|
182
|
+
"albumKey": "a1793633", "artist": "2 Chainz", "canDownload": true, "length":
|
183
|
+
1, "canTether": true}, {"baseIcon": "album/3/d/4/00000000001d34d3/3/square-200.jpg",
|
184
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/Kanye_West%2C_JAY_Z%2C_Big_Sean/",
|
185
|
+
"duration": 293, "album": "Clique", "isClean": false, "albumUrl": "/artist/Kanye_West%2C_JAY_Z%2C_Big_Sean/album/Clique/",
|
186
|
+
"shortUrl": "http://rd.io/x/QV76fDdeaR8c", "albumArtist": "Kanye West, JAY
|
187
|
+
Z, Big Sean", "canStream": true, "embedUrl": "https://rd.io/e/QV76fDdeaR8c",
|
188
|
+
"type": "t", "price": "1.29", "trackNum": 1, "albumArtistKey": "r2245898",
|
189
|
+
"key": "t20667992", "icon": "http://cdn3.rd.io/album/3/d/4/00000000001d34d3/3/square-200.jpg",
|
190
|
+
"canSample": true, "name": "Clique", "isExplicit": true, "artistKey": "r2245898",
|
191
|
+
"url": "/artist/Kanye_West%2C_JAY_Z%2C_Big_Sean/album/Clique/track/Clique/",
|
192
|
+
"albumKey": "a1914067", "artist": "Kanye West, JAY Z, Big Sean", "canDownload":
|
193
|
+
true, "length": 1, "canTether": true}, {"baseIcon": "album/b/a/d/00000000001eddab/6/square-200.jpg",
|
194
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/Bruno_Mars/", "duration":
|
195
|
+
233, "album": "Locked Out Of Heaven", "isClean": false, "albumUrl": "/artist/Bruno_Mars/album/Locked_Out_Of_Heaven/",
|
196
|
+
"shortUrl": "http://rd.io/x/QV76fDdeHgYa", "albumArtist": "Bruno Mars", "canStream":
|
197
|
+
true, "embedUrl": "https://rd.io/e/QV76fDdeHgYa", "type": "t", "price": "1.29",
|
198
|
+
"trackNum": 1, "albumArtistKey": "r271106", "key": "t21776222", "icon": "http://cdn3.rd.io/album/b/a/d/00000000001eddab/6/square-200.jpg",
|
199
|
+
"canSample": true, "name": "Locked Out Of Heaven", "isExplicit": false, "artistKey":
|
200
|
+
"r271106", "url": "/artist/Bruno_Mars/album/Locked_Out_Of_Heaven/track/Locked_Out_Of_Heaven/",
|
201
|
+
"albumKey": "a2022827", "artist": "Bruno Mars", "canDownload": true, "length":
|
202
|
+
1, "canTether": true}, {"baseIcon": "album/0/b/f/00000000001eafb0/4/square-200.jpg",
|
203
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/Kendrick_Lamar/", "duration":
|
204
|
+
313, "album": "good kid, m.A.A.d city (Deluxe)", "isClean": false, "albumUrl":
|
205
|
+
"/artist/Kendrick_Lamar/album/good_kid%2C_m.A.A.d_city_(Deluxe)/", "shortUrl":
|
206
|
+
"http://rd.io/x/QV76fDdeGCIk", "albumArtist": "Kendrick Lamar", "canStream":
|
207
|
+
true, "embedUrl": "https://rd.io/e/QV76fDdeGCIk", "type": "t", "price": "1.29",
|
208
|
+
"trackNum": 9, "albumArtistKey": "r619646", "key": "t21652320", "icon": "http://cdn3.rd.io/album/0/b/f/00000000001eafb0/4/square-200.jpg",
|
209
|
+
"canSample": true, "name": "Swimming Pools (Drank) (Extended Version)", "isExplicit":
|
210
|
+
true, "artistKey": "r619646", "url": "/artist/Kendrick_Lamar/album/good_kid%2C_m.A.A.d_city_(Deluxe)/track/Swimming_Pools_(Drank)_(Extended_Version)/",
|
211
|
+
"albumKey": "a2011056", "artist": "Kendrick Lamar", "canDownload": true, "length":
|
212
|
+
1, "canTether": true}, {"baseIcon": "album/0/b/f/00000000001eafb0/4/square-200.jpg",
|
213
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/Kendrick_Lamar/", "duration":
|
214
|
+
386, "album": "good kid, m.A.A.d city (Deluxe)", "isClean": false, "albumUrl":
|
215
|
+
"/artist/Kendrick_Lamar/album/good_kid%2C_m.A.A.d_city_(Deluxe)/", "shortUrl":
|
216
|
+
"http://rd.io/x/QV76fDdeGCJ5", "albumArtist": "Kendrick Lamar", "canStream":
|
217
|
+
true, "embedUrl": "https://rd.io/e/QV76fDdeGCJ5", "type": "t", "price": "1.29",
|
218
|
+
"trackNum": 5, "albumArtistKey": "r619646", "key": "t21652285", "icon": "http://cdn3.rd.io/album/0/b/f/00000000001eafb0/4/square-200.jpg",
|
219
|
+
"canSample": true, "name": "Money Trees", "isExplicit": true, "artistKey":
|
220
|
+
"r619646", "url": "/artist/Kendrick_Lamar/album/good_kid%2C_m.A.A.d_city_(Deluxe)/track/Money_Trees/",
|
221
|
+
"albumKey": "a2011056", "artist": "Kendrick Lamar", "canDownload": true, "length":
|
222
|
+
1, "canTether": true}, {"baseIcon": "album/0/b/f/00000000001eafb0/4/square-200.jpg",
|
223
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/Kendrick_Lamar/", "duration":
|
224
|
+
273, "album": "good kid, m.A.A.d city (Deluxe)", "isClean": false, "albumUrl":
|
225
|
+
"/artist/Kendrick_Lamar/album/good_kid%2C_m.A.A.d_city_(Deluxe)/", "shortUrl":
|
226
|
+
"http://rd.io/x/QV76fDdeGCJm", "albumArtist": "Kendrick Lamar", "canStream":
|
227
|
+
true, "embedUrl": "https://rd.io/e/QV76fDdeGCJm", "type": "t", "price": "1.29",
|
228
|
+
"trackNum": 1, "albumArtistKey": "r619646", "key": "t21652258", "icon": "http://cdn3.rd.io/album/0/b/f/00000000001eafb0/4/square-200.jpg",
|
229
|
+
"canSample": true, "name": "Sherane a.k.a Master Splinter\u2019s Daughter",
|
230
|
+
"isExplicit": true, "artistKey": "r619646", "url": "/artist/Kendrick_Lamar/album/good_kid%2C_m.A.A.d_city_(Deluxe)/track/Sherane_a.k.a_Master_Splinter%E2%80%99s_Daughter/",
|
231
|
+
"albumKey": "a2011056", "artist": "Kendrick Lamar", "canDownload": true, "length":
|
232
|
+
1, "canTether": true}, {"baseIcon": "album/0/6/2/000000000015c260/8/square-200.jpg",
|
233
|
+
"canDownloadAlbumOnly": true, "artistUrl": "/artist/The_Lumineers/", "duration":
|
234
|
+
163, "album": "The Lumineers", "isClean": false, "albumUrl": "/artist/The_Lumineers/album/The_Lumineers/",
|
235
|
+
"shortUrl": "http://rd.io/x/QV76fDercoU", "albumArtist": "The Lumineers",
|
236
|
+
"canStream": true, "embedUrl": "https://rd.io/e/QV76fDercoU", "type": "t",
|
237
|
+
"price": "0.99", "trackNum": 5, "albumArtistKey": "r1865990", "key": "t15999172",
|
238
|
+
"icon": "http://cdn3.rd.io/album/0/6/2/000000000015c260/8/square-200.jpg",
|
239
|
+
"canSample": true, "name": "Ho Hey", "isExplicit": false, "artistKey": "r1865990",
|
240
|
+
"url": "/artist/The_Lumineers/album/The_Lumineers/track/Ho_Hey/", "albumKey":
|
241
|
+
"a1426016", "artist": "The Lumineers", "canDownload": true, "length": 1, "canTether":
|
242
|
+
true}, {"baseIcon": "album/0/b/f/00000000001eafb0/4/square-200.jpg", "canDownloadAlbumOnly":
|
243
|
+
true, "artistUrl": "/artist/Kendrick_Lamar/", "duration": 350, "album": "good
|
244
|
+
kid, m.A.A.d city (Deluxe)", "isClean": false, "albumUrl": "/artist/Kendrick_Lamar/album/good_kid%2C_m.A.A.d_city_(Deluxe)/",
|
245
|
+
"shortUrl": "http://rd.io/x/QV76fDdeGCIS", "albumArtist": "Kendrick Lamar",
|
246
|
+
"canStream": true, "embedUrl": "https://rd.io/e/QV76fDdeGCIS", "type": "t",
|
247
|
+
"price": "1.29", "trackNum": 8, "albumArtistKey": "r619646", "key": "t21652310",
|
248
|
+
"icon": "http://cdn3.rd.io/album/0/b/f/00000000001eafb0/4/square-200.jpg",
|
249
|
+
"canSample": true, "name": "m.A.A.d city", "isExplicit": true, "artistKey":
|
250
|
+
"r619646", "url": "/artist/Kendrick_Lamar/album/good_kid%2C_m.A.A.d_city_(Deluxe)/track/m.A.A.d_city/",
|
251
|
+
"albumKey": "a2011056", "artist": "Kendrick Lamar", "canDownload": true, "length":
|
252
|
+
1, "canTether": true}]}'
|
253
|
+
http_version:
|
254
|
+
recorded_at: Thu, 01 Nov 2012 01:10:37 GMT
|
255
|
+
recorded_with: VCR 2.2.5
|
data/spec/fixtures/cassettes/Ronnie_Client_Users/_unfollow/{Unfollow_a_User → Unfollow_a_user_}/.yml
RENAMED
@@ -8,9 +8,9 @@ http_interactions:
|
|
8
8
|
string: method=removeFriend&user=s2913931
|
9
9
|
headers:
|
10
10
|
Authorization:
|
11
|
-
- OAuth oauth_consumer_key="ub9ebmvf7aee3pxcms9e5mh3", oauth_nonce="
|
12
|
-
oauth_signature="
|
13
|
-
oauth_timestamp="
|
11
|
+
- OAuth oauth_consumer_key="ub9ebmvf7aee3pxcms9e5mh3", oauth_nonce="859932c007618fa2886189efd07cee1d",
|
12
|
+
oauth_signature="og6FZd5NTn%2FY9BgBN2OUIgQ9j4w%3D", oauth_signature_method="HMAC-SHA1",
|
13
|
+
oauth_timestamp="1351731382", oauth_token="ute6gf7jk4y5734hx42uxspfnhdkt42qt8habah6tkyvx4ay2xvhpt5faa2ddqc6",
|
14
14
|
oauth_version="1.0"
|
15
15
|
Content-Type:
|
16
16
|
- application/x-www-form-urlencoded
|
@@ -27,8 +27,6 @@ http_interactions:
|
|
27
27
|
- mashery-web3-lax.mashery.com
|
28
28
|
Content-Type:
|
29
29
|
- application/json
|
30
|
-
Connection:
|
31
|
-
- keep-alive
|
32
30
|
Content-Language:
|
33
31
|
- en
|
34
32
|
Vary:
|
@@ -41,15 +39,23 @@ http_interactions:
|
|
41
39
|
- '720'
|
42
40
|
Accept-Ranges:
|
43
41
|
- bytes
|
44
|
-
Content-Length:
|
45
|
-
- '32'
|
46
42
|
Date:
|
47
|
-
-
|
43
|
+
- Thu, 01 Nov 2012 00:56:19 GMT
|
48
44
|
Server:
|
49
45
|
- Mashery Proxy
|
46
|
+
Content-Length:
|
47
|
+
- '32'
|
48
|
+
X-Cache:
|
49
|
+
- MISS from 172.19.134.2
|
50
|
+
X-Cache-Lookup:
|
51
|
+
- MISS from 172.19.134.2:3128
|
52
|
+
Via:
|
53
|
+
- 1.0 172.19.134.2:3128 (squid/2.6.STABLE14)
|
54
|
+
Connection:
|
55
|
+
- close
|
50
56
|
body:
|
51
57
|
encoding: US-ASCII
|
52
58
|
string: ! '{"status": "ok", "result": true}'
|
53
59
|
http_version:
|
54
|
-
recorded_at:
|
60
|
+
recorded_at: Thu, 01 Nov 2012 00:56:22 GMT
|
55
61
|
recorded_with: VCR 2.2.5
|
@@ -5,12 +5,12 @@ http_interactions:
|
|
5
5
|
uri: http://api.rdio.com/1/
|
6
6
|
body:
|
7
7
|
encoding: US-ASCII
|
8
|
-
string: method=
|
8
|
+
string: method=currentUser
|
9
9
|
headers:
|
10
10
|
Authorization:
|
11
|
-
- OAuth oauth_consumer_key="ub9ebmvf7aee3pxcms9e5mh3", oauth_nonce="
|
12
|
-
oauth_signature="
|
13
|
-
oauth_timestamp="
|
11
|
+
- OAuth oauth_consumer_key="ub9ebmvf7aee3pxcms9e5mh3", oauth_nonce="9a05aa4a619e7b0e7cf95605323540da",
|
12
|
+
oauth_signature="eiXH%2BCsxn10J18xkZEbuy9e5IJI%3D", oauth_signature_method="HMAC-SHA1",
|
13
|
+
oauth_timestamp="1351729827", oauth_token="ute6gf7jk4y5734hx42uxspfnhdkt42qt8habah6tkyvx4ay2xvhpt5faa2ddqc6",
|
14
14
|
oauth_version="1.0"
|
15
15
|
Content-Type:
|
16
16
|
- application/x-www-form-urlencoded
|
@@ -24,11 +24,9 @@ http_interactions:
|
|
24
24
|
message: OK
|
25
25
|
headers:
|
26
26
|
X-Mashery-Responder:
|
27
|
-
- mashery-
|
27
|
+
- mashery-web3-lax.mashery.com
|
28
28
|
Content-Type:
|
29
29
|
- application/json
|
30
|
-
Connection:
|
31
|
-
- keep-alive
|
32
30
|
Content-Language:
|
33
31
|
- en
|
34
32
|
Vary:
|
@@ -41,18 +39,26 @@ http_interactions:
|
|
41
39
|
- '720'
|
42
40
|
Accept-Ranges:
|
43
41
|
- bytes
|
44
|
-
Content-Length:
|
45
|
-
- '327'
|
46
42
|
Date:
|
47
|
-
-
|
43
|
+
- Thu, 01 Nov 2012 00:30:25 GMT
|
48
44
|
Server:
|
49
45
|
- Mashery Proxy
|
46
|
+
Content-Length:
|
47
|
+
- '330'
|
48
|
+
X-Cache:
|
49
|
+
- MISS from 172.19.134.2
|
50
|
+
X-Cache-Lookup:
|
51
|
+
- MISS from 172.19.134.2:3128
|
52
|
+
Via:
|
53
|
+
- 1.0 172.19.134.2:3128 (squid/2.6.STABLE14)
|
54
|
+
Connection:
|
55
|
+
- close
|
50
56
|
body:
|
51
57
|
encoding: US-ASCII
|
52
|
-
string: ! '{"status": "ok", "result":
|
53
|
-
"gender": "m", "url": "/people/
|
54
|
-
"
|
55
|
-
"http://cdn3.rd.io/user/
|
58
|
+
string: ! '{"status": "ok", "result": {"firstName": "Allen", "baseIcon": "user/3/2/8/000000000001b823/1/square-100.jpg",
|
59
|
+
"gender": "m", "url": "/people/allengoodman/", "key": "s112675", "lastName":
|
60
|
+
"Goodman", "libraryVersion": 297, "isProtected": false, "type": "s", "icon":
|
61
|
+
"http://cdn3.rd.io/user/3/2/8/000000000001b823/1/square-100.jpg"}}'
|
56
62
|
http_version:
|
57
|
-
recorded_at:
|
63
|
+
recorded_at: Thu, 01 Nov 2012 00:30:28 GMT
|
58
64
|
recorded_with: VCR 2.2.5
|
@@ -0,0 +1,64 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: post
|
5
|
+
uri: http://api.rdio.com/1/
|
6
|
+
body:
|
7
|
+
encoding: US-ASCII
|
8
|
+
string: method=get&keys=s112675
|
9
|
+
headers:
|
10
|
+
Authorization:
|
11
|
+
- OAuth oauth_consumer_key="ub9ebmvf7aee3pxcms9e5mh3", oauth_nonce="9c3c7e1e68b94c1f4527ea59c6daad94",
|
12
|
+
oauth_signature="33h1my5Crn%2B6z4J3A1CUvPbHSW8%3D", oauth_signature_method="HMAC-SHA1",
|
13
|
+
oauth_timestamp="1351731192", oauth_token="ute6gf7jk4y5734hx42uxspfnhdkt42qt8habah6tkyvx4ay2xvhpt5faa2ddqc6",
|
14
|
+
oauth_version="1.0"
|
15
|
+
Content-Type:
|
16
|
+
- application/x-www-form-urlencoded
|
17
|
+
Accept:
|
18
|
+
- ! '*/*'
|
19
|
+
User-Agent:
|
20
|
+
- Ruby
|
21
|
+
response:
|
22
|
+
status:
|
23
|
+
code: 200
|
24
|
+
message: OK
|
25
|
+
headers:
|
26
|
+
X-Mashery-Responder:
|
27
|
+
- mashery-web1-lax.mashery.com
|
28
|
+
Content-Type:
|
29
|
+
- application/json
|
30
|
+
Content-Language:
|
31
|
+
- en
|
32
|
+
Vary:
|
33
|
+
- Accept-Language, Cookie
|
34
|
+
Cache-Control:
|
35
|
+
- no-cache
|
36
|
+
Access-Control-Allow-Origin:
|
37
|
+
- ! '*'
|
38
|
+
X-Version:
|
39
|
+
- '720'
|
40
|
+
Accept-Ranges:
|
41
|
+
- bytes
|
42
|
+
Date:
|
43
|
+
- Thu, 01 Nov 2012 00:53:10 GMT
|
44
|
+
Server:
|
45
|
+
- Mashery Proxy
|
46
|
+
Content-Length:
|
47
|
+
- '343'
|
48
|
+
X-Cache:
|
49
|
+
- MISS from 172.19.134.2
|
50
|
+
X-Cache-Lookup:
|
51
|
+
- MISS from 172.19.134.2:3128
|
52
|
+
Via:
|
53
|
+
- 1.0 172.19.134.2:3128 (squid/2.6.STABLE14)
|
54
|
+
Connection:
|
55
|
+
- close
|
56
|
+
body:
|
57
|
+
encoding: US-ASCII
|
58
|
+
string: ! '{"status": "ok", "result": {"s112675": {"firstName": "Allen", "baseIcon":
|
59
|
+
"user/3/2/8/000000000001b823/1/square-100.jpg", "gender": "m", "url": "/people/allengoodman/",
|
60
|
+
"key": "s112675", "lastName": "Goodman", "libraryVersion": 297, "isProtected":
|
61
|
+
false, "type": "s", "icon": "http://cdn3.rd.io/user/3/2/8/000000000001b823/1/square-100.jpg"}}}'
|
62
|
+
http_version:
|
63
|
+
recorded_at: Thu, 01 Nov 2012 00:53:13 GMT
|
64
|
+
recorded_with: VCR 2.2.5
|
@@ -0,0 +1,32 @@
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
require 'spec_helper'
|
3
|
+
|
4
|
+
describe Ronnie::Client::Users do
|
5
|
+
before do
|
6
|
+
@client = Ronnie::Client.new consumer_key: ENV['CONSUMER_KEY'],
|
7
|
+
consumer_secret: ENV['CONSUMER_SECRET']
|
8
|
+
|
9
|
+
@client.token = ENV['OAUTH_TOKEN']
|
10
|
+
@client.token_secret = ENV['OAUTH_TOKEN_SECRET']
|
11
|
+
end
|
12
|
+
|
13
|
+
describe '.activities', :vcr do
|
14
|
+
context 'Retrieve `user` Activity Stream' do
|
15
|
+
let(:activities) { @client.activities('s112675', 'user') }
|
16
|
+
|
17
|
+
it { expect(activities.user.firstName).to eq('Allen') }
|
18
|
+
end
|
19
|
+
|
20
|
+
context 'Retrieve `friends` Activity Stream' do
|
21
|
+
let(:activities) { @client.activities('s112675', 'friends') }
|
22
|
+
|
23
|
+
it { expect(activities.user.firstName).to eq('Allen') }
|
24
|
+
end
|
25
|
+
|
26
|
+
context 'Retrieve `everyone` Activity Stream' do
|
27
|
+
let(:activities) { @client.activities('s112675', 'everyone') }
|
28
|
+
|
29
|
+
it { expect(activities.user.firstName).to eq('Allen') }
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|