Select to view content in your preferred language

Portal Item Number of Views (numviews)

650
3
01-23-2024 02:19 AM
frm
by
New Contributor

The numViews property in the Sharing API returns the number of item views since item creation. 

Example:

request: https://...../portal/sharing/rest/content/items/1e02627438d4450c9ba28cab07e620cb?f=pjson

response: 

"numViews": 6

 Is there a way to get the number of views for say the last 3 months?

Regards, 

Marcel

Tags (3)
3 Replies
ToddW_stl
Esri Contributor

No, numViews is not tied to any specific timeframe.  This is a simple theory, but perhaps you could try some kind of script/attribute rule to copy numViews to a new field every day and add a date/time field.

0 Kudos
BlakeMorrison
Frequent Contributor

I'm trying to find a way to do the same thing.

 

I'm using the notebook from here: https://www.esri.com/arcgis-blog/products/arcgis-online/administration/managing-arcgis-online-conten...

I've also found this: https://support.esri.com/en-us/knowledge-base/how-to-identify-the-usage-of-items-in-arcgis-online-us...

 

I'm gonna try combine the two. I'm just hacking away though so would appreciate anyone's ideas.

0 Kudos
ToddW_stl
Esri Contributor

I'm not sure if this will help you, but if you need to reset/baseline your views back to zero in order to implement some kind of temporal tracking aspect, I posted some steps of how to modify numViews via ArcGIS Portal's backend PostgresSQL database here - good luck!

0 Kudos