Important Update: Community URLs redirect issues are partially resolved. Learn More. .

cancel
Showing results for 
Search instead for 
Did you mean: 

How to retrieve most recent records using contentapi?

ApoorvaIyengar
Contributor III

I am trying to build report on Power BI for control self assessments that has excess of 70000+ records.

When I make content API call, it retrieves first 1000 records, but is there a way to pull the most recent 1000 records instead of the old ones? 

@Anonymous @Anonymous 

5 REPLIES 5

Anonymous
Not applicable

@ApoorvaIyengar,

Maybe playing with OData query will help here. @JeffLetterman is the best OData specialist here.

ApoorvaIyengar
Contributor III

@JeffLetterman  is the $filter function available? 

JeffLetterman
Archer Employee
Archer Employee

Unfortunately, the Content API only supports a couple of OData options: $top and $skip.  
https://help.archerirm.cloud/platform_612/en-us/content/api/contentapi/contentapi_get_level_metadata.htm

ApoorvaIyengar
Contributor III

@JeffLetterman  I still don't get the most recent records when I use $top. Do you have any other suggestions on how I can retrieve most recent 1000 records from over a 70000+ records? 

JeffLetterman
Archer Employee
Archer Employee

To control the sort order and top X records, I recommend using the Archer web services methods, ExecuteSearch or SearchRecordsByReport.  The downside is the data is in XML format. 

Please check out and vote up https://www.archerirm.community/t5/archer-ideas/create-rest-api-functionality-to-perform-record-searches-and-run/idi-p/574447.