Forum Discussion

Premify's avatar
Premify
Helper
10 years ago

REST API: Get kudos for a certain topic by date range?

Hello!
I've browsed the forum / REST API documentation for a couple of hours but didn't find the answer to my problem:

I would like to access the kudos count of a certain thread but limit that to a date range.
The API call for kudos count for a message doesn't seem to accept queries.

I've found a way to do it for messages count for a certain board:

http://community.spotify.com/restapi/vc/boards/id/spotifycontribute/search/messages/count?q=date:[1341341612%20TO%201341946412]

Now I would like to have something like this (does not work):

http://community.spotify.com/restapi/vc/threads/id/123456/search/kudos/count?q=date:[1341341612%20TO%201341946412]

Background: I'm a super user at the Spotify community that manages the incoming ideas and pings the staff when an idea needs an update. I've made a google spreadsheet and included the kudos count for each idea via ImportXML() that sorts them by defined priority (kudos, status, date). Works great but now I would like to have a column that displays the received kudos of a single idea for the last month / half year. I could make a kudos "database" in another spreadsheet but that seems like a very tiresome workaround. Any quick solution to that? Obviously I'm relying only on the REST API. ;)

4 Replies

  • Premify's avatar
    Premify
    Helper
    10 years ago

    VarunGrazitti wrote:

    @Premify - May be you should try this metrics API. I couldn't find a direct way to query for a certain thread though.


    VarunGrazitti Thanks for your fast reply!

    Unfortunately I can not use the metrics API, since I am merely a super user and not an admin. To my understanding, those can't be used in my spreadsheet - I always get "Permission denied". Also, as you've said, it seems you can only access the kudo count for boards and not a single topic.

     

    I was hoping for a call that can be accessed as normal user, like the kudo count per topic - just with a set date range.

     

    Thanks for spending the time to search though. ;)

    Cheers, Marco

  • Premify's avatar
    Premify
    Helper
    10 years ago

    1 last attempt :)

    After reflecting the usecase again I would need:

     

    A query with the REST API through an URL request:

    Kudos received for the root message (idea's 1st post) within a certain time frame, ideally the last x days.

    Is there any way to achieve that without admin rights?
    Any help would be highly appreciated!

  • Hi Premify,

     

    You need to have "Make REST API calls with read access" permission granted to make the rest api call through URL.

     

    Hope this would be alternative option that you can follow.

     

    Regards,

    Vishwajit Shinde.