<?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: Method to get Event Data using AppDynamicsREST Python API in Splunk AppDynamics</title>
    <link>https://community.splunk.com/t5/Splunk-AppDynamics/Method-to-get-Event-Data-using-AppDynamicsREST-Python-API/m-p/719578#M1591</link>
    <description>&lt;P&gt;Hi ,&lt;BR /&gt;On which object I need to invoke this method ?&lt;/P&gt;
&lt;P&gt;Once the client is created like the following&amp;nbsp;&lt;/P&gt;

&lt;PRE&gt;client=AppDynamicsClient("URL","uid","pwd")
&lt;/PRE&gt;
&lt;P&gt;&lt;BR /&gt;The client has&amp;nbsp;methods like get_metrics,get_snapshots etc but not anything like get_events.&lt;/P&gt;
&lt;P&gt;Could you please explain bit further ?&lt;/P&gt;</description>
    <pubDate>Tue, 27 Jun 2017 09:28:22 GMT</pubDate>
    <dc:creator>CommunityUser</dc:creator>
    <dc:date>2017-06-27T09:28:22Z</dc:date>
    <item>
      <title>Method to get Event Data using AppDynamicsREST Python API</title>
      <link>https://community.splunk.com/t5/Splunk-AppDynamics/Method-to-get-Event-Data-using-AppDynamicsREST-Python-API/m-p/719576#M1589</link>
      <description>&lt;P&gt;Hi ,&lt;/P&gt;
&lt;P&gt;In AppDynamics we can get the Events Details using the REST URI like the following&lt;/P&gt;
&lt;P&gt;http://&amp;lt;IP:PORT&amp;gt;/controller/rest/applications/8/events?time-range-type=BEFORE_NOW&amp;amp;duration-in-mins=300&amp;amp;event-types=APPLICATION_CONFIG_CHANGE,APPLICATION_ERROR,DIAGNOSTIC_SESSION,APPLICATION_CONFIG_CHANGE,APPLICATION_DEPLOYMENT,APPLICATION_ERROR,APP_SERVER_RESTART&amp;amp;severities=ERROR,INFO,WARN&amp;amp;output=JSON&lt;/P&gt;

&lt;P&gt;I am looking for a method in the AppDynamicsREST Python API at&amp;nbsp;&lt;A href="http://appdynamicsrest.readthedocs.io/en/latest/api.html" target="_blank" rel="nofollow noopener noreferrer"&gt;http://appdynamicsrest.readthedocs.io/en/latest/api.html&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;But so far unable to to figure out any .&lt;/P&gt;
&lt;P&gt;Can anybody provide some pointer on this ?&lt;/P&gt;</description>
      <pubDate>Thu, 22 Jun 2017 15:10:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-AppDynamics/Method-to-get-Event-Data-using-AppDynamicsREST-Python-API/m-p/719576#M1589</guid>
      <dc:creator>CommunityUser</dc:creator>
      <dc:date>2017-06-22T15:10:47Z</dc:date>
    </item>
    <item>
      <title>Re: Method to get Event Data using AppDynamicsREST Python API</title>
      <link>https://community.splunk.com/t5/Splunk-AppDynamics/Method-to-get-Event-Data-using-AppDynamicsREST-Python-API/m-p/719577#M1590</link>
      <description>&lt;P&gt;Hi Ayan,&lt;/P&gt;

&lt;P&gt;Can you please try using the following API&lt;/P&gt;
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;def get_events(self, app_id=None, event_types='ALL', severities='ERROR', time_range_type='BEFORE_NOW',
                   duration_in_mins=15, start_time=None, end_time=None):
        """
        Retrieves events.

        :param int app_id: Application ID to retrieve nodes for. If :const:`None`, the value stored in the
            `app_id` property will be used.
        :param str event_types: CSV of the events types to search on
        :param str severities: CSV of the severities to search on
        :param str time_range_type: Must be one of :const:`BEFORE_NOW`, :const:`BEFORE_TIME`,
            :const:`AFTER_TIME`, or :const:`BETWEEN_TIMES`.
            See :ref:`time-range-types` for a full explanation.
        :param int duration_in_mins: Number of minutes before now. Only valid if the
            :attr:`time_range_type` is :const:`BEFORE_NOW`.
        :param long start_time: Start time, expressed in milliseconds since epoch. Only valid if the
            :attr:`time_range_type` is :const:`AFTER_TIME` or :const:`BETWEEN_TIMES`.
        :param long end_time: End time, expressed in milliseconds since epoch. Only valid if the
            :attr:`time_range_type` is :const:`BEFORE_TIME` or :const:`BETWEEN_TIMES`.
        :param bool rollup: If :const:`False`, return individual data points for each time slice in
            the given time range. If :const:`True`, aggregates the data and returns a single data point.
        :returns: A list of events for the specified app, filtered by the event type and severities desired.
        :rtype: appd.model.Events
        """
&lt;/PRE&gt;
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;GIT Hub reference link:&lt;/P&gt;
&lt;P&gt;&lt;A class="external-link" title="Follow link" href="https://github.com/Appdynamics/AppDynamicsREST" target="_blank" rel="nofollow noopener noreferrer"&gt;https://github.com/Appdynamics/AppDynamicsREST&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Thanks and Regards,&lt;/P&gt;
&lt;P&gt;Sajna&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 23 Jun 2017 09:09:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-AppDynamics/Method-to-get-Event-Data-using-AppDynamicsREST-Python-API/m-p/719577#M1590</guid>
      <dc:creator>Sajna_Sreenivas</dc:creator>
      <dc:date>2017-06-23T09:09:55Z</dc:date>
    </item>
    <item>
      <title>Re: Method to get Event Data using AppDynamicsREST Python API</title>
      <link>https://community.splunk.com/t5/Splunk-AppDynamics/Method-to-get-Event-Data-using-AppDynamicsREST-Python-API/m-p/719578#M1591</link>
      <description>&lt;P&gt;Hi ,&lt;BR /&gt;On which object I need to invoke this method ?&lt;/P&gt;
&lt;P&gt;Once the client is created like the following&amp;nbsp;&lt;/P&gt;

&lt;PRE&gt;client=AppDynamicsClient("URL","uid","pwd")
&lt;/PRE&gt;
&lt;P&gt;&lt;BR /&gt;The client has&amp;nbsp;methods like get_metrics,get_snapshots etc but not anything like get_events.&lt;/P&gt;
&lt;P&gt;Could you please explain bit further ?&lt;/P&gt;</description>
      <pubDate>Tue, 27 Jun 2017 09:28:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-AppDynamics/Method-to-get-Event-Data-using-AppDynamicsREST-Python-API/m-p/719578#M1591</guid>
      <dc:creator>CommunityUser</dc:creator>
      <dc:date>2017-06-27T09:28:22Z</dc:date>
    </item>
    <item>
      <title>Re: Method to get Event Data using AppDynamicsREST Python API</title>
      <link>https://community.splunk.com/t5/Splunk-AppDynamics/Method-to-get-Event-Data-using-AppDynamicsREST-Python-API/m-p/719579#M1592</link>
      <description>&lt;P&gt;Hi Ayan,&lt;/P&gt;
&lt;P&gt;Sorry for the late reply.&lt;/P&gt;
&lt;P&gt;The&amp;nbsp;client should have the method like&amp;nbsp;&lt;SPAN class="s1"&gt;get_events.For some reason it is missing in the&amp;nbsp;&lt;A href="http://appdynamicsrest.readthedocs.io/en/latest/api.html" target="_blank" rel="nofollow noopener noreferrer"&gt;http://appdynamicsrest.readthedocs.io/en/latest/api.html&lt;/A&gt;.I will look into it.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN class="s1"&gt;In your case, you can call it like&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;

&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;client=AppDynamicsClient("URL","uid","pwd")&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;resp = client.get_events(app_id=16,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;&lt;SPAN class="Apple-converted-space"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;event_types='APPLICATION_CONFIG_CHANGE',&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;&lt;SPAN class="Apple-converted-space"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;severities='INFO,WARN,ERROR',&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;&lt;SPAN class="Apple-converted-space"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;time_range_type='BEFORE_NOW',&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;&lt;SPAN class="Apple-converted-space"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;duration_in_mins='60000')&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN class="s1"&gt;Let me know whether it works.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;GIT Hub reference link:&lt;/P&gt;
&lt;P&gt;&lt;A class="external-link" title="Follow link" href="https://github.com/Appdynamics/AppDynamicsREST" target="_blank" rel="nofollow noopener noreferrer"&gt;https://github.com/Appdynamics/AppDynamicsREST&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;Thanks and Regards,&lt;/P&gt;
&lt;P&gt;Sajna Sreenivasan&lt;/P&gt;</description>
      <pubDate>Fri, 14 Jul 2017 05:58:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-AppDynamics/Method-to-get-Event-Data-using-AppDynamicsREST-Python-API/m-p/719579#M1592</guid>
      <dc:creator>Sajna_Sreenivas</dc:creator>
      <dc:date>2017-07-14T05:58:05Z</dc:date>
    </item>
  </channel>
</rss>

