Select to view content in your preferred language

Get all org tags for content visible to an organizational user.

269
0
05-10-2024 05:15 AM
Dirk_Vandervoort
Frequent Contributor

We would like to acquire all tags that are assigned to content that an organizational user can see.

Code to do this:

queryParams = new PortalQueryParams({
    filter: 'orgid:BlahBlahBlah',
    num: 100        
}); 
portal.queryItems(queryParams).then(function(results){
    for (let ii = 0; ii < results.results.length; ii++){
        console.log(results.results[ii].tags);
    }
}); 

The issue is that PortalQueryParams only allows a maximum of 100 results returns. We have potentially thousands of items to get tags from.

The question becomes: How can I gat all tags despite the 100-results limitation?

Yes, I can paginate the results. I just want the tags please.

0 Kudos
0 Replies