<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Programatically check if Portal items are being used. in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/programatically-check-if-portal-items-are-being/m-p/445669#M34902</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I don't know how reliable this is, but I have used the numViews property for Portal items to get an idea of usage over time. I ran a script every day to capture daily view count, then use some other functions to see activity over time. Hope this helps!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;DIV style="color: #d4d4d4; background-color: #1e1e1e; font-weight: normal; font-size: 14px;"&gt;&lt;DIV&gt;&lt;SPAN style="color: #c586c0;"&gt;from&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;&amp;nbsp;arcgis.gis&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="color: #c586c0;"&gt;import&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;&amp;nbsp;GIS&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt;gis&amp;nbsp;=&amp;nbsp;GIS(portal_url,&amp;nbsp;username,&amp;nbsp;password)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN style="color: #6a9955;"&gt;#&amp;nbsp;find&amp;nbsp;all&amp;nbsp;items&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt;items&amp;nbsp;=&amp;nbsp;gis.content.search(&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;''&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;,&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;''&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;,&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="color: #9cdcfe;"&gt;max_items&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #b5cea8;"&gt;10000&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #c586c0;"&gt;for&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;&amp;nbsp;item&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="color: #c586c0;"&gt;in&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;&amp;nbsp;items:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="color: #dcdcaa;"&gt;print&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;(item.numViews)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 19 Aug 2020 18:42:06 GMT</pubDate>
    <dc:creator>JasonBartley1</dc:creator>
    <dc:date>2020-08-19T18:42:06Z</dc:date>
    <item>
      <title>Programatically check if Portal items are being used.</title>
      <link>https://community.esri.com/t5/python-questions/programatically-check-if-portal-items-are-being/m-p/445668#M34901</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am trying to figure out a way to check if items in the Portal are being used.&amp;nbsp;I want to be able to flag items for removal if they are not being used. There is the &lt;STRONG&gt;&lt;EM&gt;usage&lt;/EM&gt;&lt;/STRONG&gt; method in the GIS module that does what I want, however it is for ArcGIS Online only.&amp;nbsp; "&lt;SPAN style="color: #404040; background-color: #fcfcfc;"&gt;For item owners and administrators, &lt;STRONG&gt;usage&lt;/STRONG&gt; provides usage details about an item that help you gauge its popularity. Usage details show how many times the item has been used for the time period you select.&lt;SPAN&gt;&amp;nbsp;" Is there something like this for the Portal? #python #gis() #usage #portal&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Aug 2020 16:42:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/programatically-check-if-portal-items-are-being/m-p/445668#M34901</guid>
      <dc:creator>JaredCleghorn</dc:creator>
      <dc:date>2020-08-12T16:42:51Z</dc:date>
    </item>
    <item>
      <title>Re: Programatically check if Portal items are being used.</title>
      <link>https://community.esri.com/t5/python-questions/programatically-check-if-portal-items-are-being/m-p/445669#M34902</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I don't know how reliable this is, but I have used the numViews property for Portal items to get an idea of usage over time. I ran a script every day to capture daily view count, then use some other functions to see activity over time. Hope this helps!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;DIV style="color: #d4d4d4; background-color: #1e1e1e; font-weight: normal; font-size: 14px;"&gt;&lt;DIV&gt;&lt;SPAN style="color: #c586c0;"&gt;from&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;&amp;nbsp;arcgis.gis&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="color: #c586c0;"&gt;import&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;&amp;nbsp;GIS&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt;gis&amp;nbsp;=&amp;nbsp;GIS(portal_url,&amp;nbsp;username,&amp;nbsp;password)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN style="color: #6a9955;"&gt;#&amp;nbsp;find&amp;nbsp;all&amp;nbsp;items&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt;items&amp;nbsp;=&amp;nbsp;gis.content.search(&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;''&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;,&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;''&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;,&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="color: #9cdcfe;"&gt;max_items&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #b5cea8;"&gt;10000&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #c586c0;"&gt;for&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;&amp;nbsp;item&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="color: #c586c0;"&gt;in&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;&amp;nbsp;items:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="color: #dcdcaa;"&gt;print&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;(item.numViews)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Aug 2020 18:42:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/programatically-check-if-portal-items-are-being/m-p/445669#M34902</guid>
      <dc:creator>JasonBartley1</dc:creator>
      <dc:date>2020-08-19T18:42:06Z</dc:date>
    </item>
    <item>
      <title>Re: Programatically check if Portal items are being used.</title>
      <link>https://community.esri.com/t5/python-questions/programatically-check-if-portal-items-are-being/m-p/445670#M34903</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Jason, thanks for your response. This is the exact same solution I came up with so far. I was&amp;nbsp;hoping there was a built in method like &lt;STRONG&gt;&lt;EM&gt;usage&lt;/EM&gt;&lt;/STRONG&gt;&amp;nbsp;for ArcGIS Online so I would not have to store the number of views over time myself.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Aug 2020 19:09:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/programatically-check-if-portal-items-are-being/m-p/445670#M34903</guid>
      <dc:creator>JaredCleghorn</dc:creator>
      <dc:date>2020-08-19T19:09:13Z</dc:date>
    </item>
  </channel>
</rss>

