Soundcloud API returns incorrect values ​​for Likes and Follows

Soundcloud API returns incorrect counts for select (like) and following.

Does anyone know how to fix it or if this is something on the soundclouds side?

Example: User 29084746 - George Smith, she is 29 years old. https://soundcloud.com/jorjasmith

But

https://api.soundcloud.com/users/29084746/favorites?client_id=XXX&page_size=200&linked_partitioning=1

      

returns 17 likes.

Edit: just to clarify, this happens to every user I test, not just this example.

+3


source to share


2 answers


Using this question (asked in 2016) as a reference, I found that:

There is an option for the Premium account that may prevent the track from showing in quality as in third party software .

So, some of the tracks are most likely hidden from third parties and therefore from the API.



it happens to every user . I am testing

Well, maybe they now allow each user to hide their messages from API access, as stated by sauntimo's answer .

+5


source


I found the API key (took maybe 37 seconds on google ...) and got this user from the API and got them stuck in a table in this fiddle . I went through the list until I found one on the site that had no API API returned. The first one was this track "Sharpness" . It is also a good joy for me to feel tragically uncomfortable reading some of this musical material that I do not understand.

Anyway, I found the Artist ID for the missing track "sharpness" by doing a user search like this . Note that track_count

in the returned object 79

. Then I got the executors like this ( as per the API docs ) and was intrigued to see what [ ]

was returned. I noticed that this user was in a free plan as per the answer, so it doesn't look like it has to do with the artist having a premium account. Also, Jora has a premium account , it seems unlikely that this will only hide some sympathy.

I then repeated this process for the other missing track, "the U-the GO-I of-the GO" , found the artist here with track_count : 32

and then got his tracks , who returned as an empty array again [ ]

.

In conclusion, it seems that users should be set to deny API access to the tracks they download. Then, when another user likes one of those user tracks, those tracks are not returned by requests for second users, so there is a mismatch between the number of likes on the site and the API returned for your original user Jora Smith .



Also, there is an article in the help center about Disabling Application Playback which says

If you want to restrict playback of your track, you can disable playback of the application through the "Permissions" tab. This means your track will only play on SoundCloud and SoundCloud, instead of websites or apps that use our API.

Soundcloud Screenshot

I suspect this means that when the download user has disabled "app playback", these tracks are completely inaccessible to the api. Note that it definitely seems like you are loading the custom permission settings that are causing the inconsistency, not the user who likes what you are retrieving.

+1


source







All Articles