Forum Discussion

iahiqosolutions's avatar
12 years ago

REST API: Retrieve user latest messages only for selected category or board

Hello folks,

 

My question is:

How to I can retrieve user latest messages only for selected category or board using Lithium REST API?

 

I found the following REST API method: users/id/%John_Doe%/topics/latest,

but it seems that it cannot restrict a search scope by specified category or board.

But I want to find topics that specified user posted in the specified category or board.

Any advice?

 

 

  • BoothF's avatar
    BoothF
    Khoros Staff

    Hi there,

     

    There is a knowledge base article here: that should help achieve exactly this.

     

    Hopefully this helps!

     

    Thanks!

    • Hello Booth,

       

      Unfortunately your example doesn't exactly match my problem.

      As understand you suggest the following:

       

      1. Find all user's tags in the specified location(category or board)
      2. Find all messages that are related for each of these tags
      3. Get details for all find messages separately.

      I guess that this solutions will not work for the following reasons:

      • When user make his post, it is not necessary that he assign some tags to it.
      • How we can find the total number of messages? If we will get all messages for each tags, I guess there are many messages will be duplicated. For example: if message has tags "Tag1" and "Tag2", then this message will be included in both search results(search results for "Tag1" and  search results for "Tag2")