report.getTable to gather usage metrics?

reportgettable

#1

Brand new to Kaltura and development using node.js, lots of learning ahead.

The report.GetTalble has two reports that I want metrics for - TopContent and UserEngagement.

However, I need to pull a decent number of records. If I am understanding correctly, if I set PageIndex to 50 and PageSize to 10000, I should be ok, right? I seem to get random unhandeled promise rejection errors when using node.js for this large of a dataset. I can simply change PageIndex and PageSize to 1 and pull a single record just fine.

FWIW, I did set PageIndex to 2 and PageSize to 600 and had no issue with records coming down.

Thanks for any advice!
-Mike


#2

Hello @wired137,

The max PageSize you can use is 500. You need to iterate over each page, cycle through the records in the returned dataset and increment PageIndex by one at the end of each iteration.

If the total number of records is higher than 10,000, you’d have to use smaller date ranges as that’s the max number of results you can get at one go, regardless of pagination.


#3

Thanks Jess. Any pointers as to where on the forum where someone else is already doing something similar? I’ll dig as well, thanks for the response.