@widgetic/editor 3.10.36 → 3.10.37
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -7,11 +7,11 @@ config = {
|
|
|
7
7
|
# for '/connect' endpoint
|
|
8
8
|
client_id : 'aed0aa63baf747a83ad0b6b246acddca'
|
|
9
9
|
redirect_uri: 'https://widgetic.com/connect/soundcloud',
|
|
10
|
-
response_type: 'code',
|
|
11
|
-
state: 'encrypted_session_info',
|
|
10
|
+
# response_type: 'code',
|
|
11
|
+
# state: 'encrypted_session_info',
|
|
12
12
|
# for '/oauth2/token' endpoint
|
|
13
13
|
grant_type: 'refresh_token',
|
|
14
|
-
client_secret: '3173e3098379153d42084aba06fe3ec4',
|
|
14
|
+
# client_secret: '3173e3098379153d42084aba06fe3ec4',
|
|
15
15
|
# local options
|
|
16
16
|
api_url: 'https://api.soundcloud.com',
|
|
17
17
|
}
|
|
@@ -30,7 +30,7 @@ class SoundCloudService extends Service
|
|
|
30
30
|
|
|
31
31
|
SCGet: (path) ->
|
|
32
32
|
url = "#{SC.api_url}" + path
|
|
33
|
-
|
|
33
|
+
console.log("SCGet path:", path, SC.auth_token)
|
|
34
34
|
$.ajax(url: url, type: 'GET', dataType: 'json', headers: {'Authorization': 'OAuth ' + SC.auth_token})
|
|
35
35
|
|
|
36
36
|
auth: (interactive) =>
|
|
@@ -147,10 +147,10 @@ class SoundCloudService extends Service
|
|
|
147
147
|
getURL: (entry, callback) ->
|
|
148
148
|
# console.log("getURL", entry.stream_url)
|
|
149
149
|
# callback "#{entry.stream_url}?client_id=#{SC.client_id}"
|
|
150
|
-
@SCGet("/tracks/#{entry.id}/
|
|
150
|
+
@SCGet("/tracks/#{entry.id}/stream")
|
|
151
151
|
.then((streams) =>
|
|
152
|
-
|
|
153
|
-
callback streams
|
|
152
|
+
console.log("fetchTrackStreams result:", streams);
|
|
153
|
+
callback streams
|
|
154
154
|
).catch (error) =>
|
|
155
155
|
console.log 'Fetch Track Streams error: ' + error
|
|
156
156
|
|