Forum Discussion

msanders's avatar
13 years ago

Lithium blog API. Can't list by post time

I noticed a problem with the order of blog posts that are retrieved from the Lithium api. I'm attempting to get a list of messages in order of "post time", but when I make the call, it seems to be returning in order of "edit time". Below is the call that I am making. Am I passing an incorrect param or if it's possible to achieve what I am trying?

 

http://tfhf.stage.lithium.com/restapi/vc/blogs/id/TeamUSA/messages/linear?restapi.format_detail=full_list_element&xslt=json.xsl&message_view.topic_sort_order=last_post_date

 

Thanks very much

  • AdamN's avatar
    AdamN
    Khoros Oracle

    Hi msanders,

     

    The first thing I noticed is that you're trying to use the parameter "message_view.topic_sort_order". The parameter name is actually "message_viewer.topic_sort_order".

     

    However, I think you may want to use "message_viewer.message_sort_order" instead since you're dealing with a list of messages. Try using this instead:

    message_viewer.message_sort_order=thread_descending

    Hopefully that should give you what you're looking for.

     

    -Adam 

     

     

     

  • Is it possible to do the same but sorting by "last_edit_time" instead of post time for blogs, forum, idea...?