0

Forumbee Search API does not return count of results.

We're using the Search API for posts. We're getting a response with an object "data" that has all the posts with the matching keyword. We were adding pagination to it and also wanted to use the "Total Count" of the search. 
However, the current API does not respond with count, but it does provide a feature where we can add a parameter value fields . This helps us to get the count by passing the following value : 

fields: "paging.count" 

The drawback of this param value is when I add fields, It only responds with the total count of the articles ( with the keyword ) and does not give me the data object with all the articles/posts listed. 
Is there anyway I can get all the articles/post from the search and also a total count value for pagination? 

API reference : Link

2replies Oldest first
  • Oldest first
  • Newest first
  • Active threads
  • Popular
  •  Hi Raghav Mishra , thanks for your question. When using the fields parameter, you need to specify all of the fields you want to include. For example:

    fields=title,textPlain,url,paging.count
    Like 1
    • Forumbee Support Thanks, 
      This gives the exact expected response. 

      Like
Like Follow
  • Status Answered
  • 3 mths agoLast active
  • 2Replies
  • 30Views
  • 2 Following