Skip to main content
Question

Course list pagination

  • September 15, 2025
  • 4 replies
  • 81 views

Hi , I' am working list of courses,

I need the details related to pagination ,

I applied the pagination concept in mulesoft and try to fetch the all page mandatory course available in Docebo, but not able fetch all the course lists pls help me on this. any blogs any implementation would be helpful.

Thanks.

4 replies

  • Helper I
  • September 15, 2025

Hey ​@Swapna ,

 

In most of the Docebo API’s that work with Paged results, you’ll see two query parameters you can add:  page and page_size.   For starters, most of the api’s support a max page_size of 200, and the pages start at 1 (not zero).  So basically, if you’re listing the courses, you’d have:

GET {{base_Url}}/learn/v1/courses?page=1&page_size=100

when that returns, you’ll see a JSON payload with a [“data”] element:

{“data”: {“items”:[...],

"count": 100,

"has_more_data": true,

"cursor": "<long string value>",

"current_page": 1,

"current_page_size": 100,

"total_page_count": 10,

"total_count": 991,{…. other stuff ...}

So basically, you have a number of items to look at here:  

  • has_more_data -- if true, you need to increase the page # and call the API again (i.e. GET {{base_Url}}/learn/v1/courses?page=2&page_size=100
  • total_count -- tells you how many records to expect -- you can basically increment a “count” variable to make sure you’ve gathered everything.  once the count of items you’ve processed equals total count (and/or has_more_data is false), then you’re done.

 

 


  • Author
  • Novice II
  • September 16, 2025

 Hi ​@rterakedis  Thanks a lot!!… its working now.

also is there any way to fetch the trainings / courses based on end_date rather than checking all the list of the courses.?

Thanks in advance.

 


  • Helper I
  • September 18, 2025

Hi ​@Swapna - Unfortunately, from what I can tell this appears to be a “no.”  The /learn/v1/courses allows you to SORT by the date_end attribute, but it doesn’t appear that any of the APIs in /learn/v1 or /course/v1 (i.e. “learn” or “course” services) allow you to search by date_end as a search attribute.   


  • Author
  • Novice II
  • September 19, 2025

Okay Thanks ​@rterakedis .!!!