<?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 Values for Endpoints defined in the setup.xml file are not refreshed in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Values-for-Endpoints-defined-in-the-setup-xml-file-are-not/m-p/439027#M76547</link>
    <description>&lt;P&gt;I have created a 3 attributes (url1, user&amp;amp; snow_password) in the setup.xml for my custom alert action app. &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; &amp;lt;input field="param.url1"&amp;gt;
    &amp;lt;label&amp;gt;Enter your url&amp;lt;/label&amp;gt;
    &amp;lt;type&amp;gt;text&amp;lt;/type&amp;gt;
 &amp;lt;/input&amp;gt;   
&amp;lt;input field="param.user"&amp;gt;
  &amp;lt;label&amp;gt;enter user name&amp;lt;/label&amp;gt;
  &amp;lt;type&amp;gt;text&amp;lt;/type&amp;gt;
&amp;lt;/input&amp;gt;
&amp;lt;input field="param.snow_credentials"&amp;gt;
  &amp;lt;label&amp;gt;enter password&amp;lt;/label&amp;gt;
  &amp;lt;type&amp;gt;password&amp;lt;/type&amp;gt;
&amp;lt;/input&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I am using these parameters in the Python script which calls a REST API method. I am retrieving the values for these parameters as below in Python script&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;    snow_url = settings['configuration'].get('url1')
    user = settings['configuration'].get('user')
    password = settings['configuration'].get('snow_credentials')
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The issue I am facing is, when I set the parameter values for the 1st time using Setup screen the values are correctly retrieved by the script. But when I update them using the setup screen and run the script as a alert action it still retrieves the old values of the parameter and not new once.&lt;/P&gt;

&lt;P&gt;I tried to check the values using URL&lt;BR /&gt;
&lt;A href="https://localhost:8089/servicesNS/nobody//alerts/alert_actions/"&gt;https://localhost:8089/servicesNS/nobody//alerts/alert_actions/&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;I can see the updated values. I also tried to reload them and try but still the script is getting old values only. Is there anything basic I am missing here?&lt;/P&gt;</description>
    <pubDate>Wed, 13 Mar 2019 08:01:47 GMT</pubDate>
    <dc:creator>santosh_sshanbh</dc:creator>
    <dc:date>2019-03-13T08:01:47Z</dc:date>
    <item>
      <title>Values for Endpoints defined in the setup.xml file are not refreshed</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Values-for-Endpoints-defined-in-the-setup-xml-file-are-not/m-p/439027#M76547</link>
      <description>&lt;P&gt;I have created a 3 attributes (url1, user&amp;amp; snow_password) in the setup.xml for my custom alert action app. &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; &amp;lt;input field="param.url1"&amp;gt;
    &amp;lt;label&amp;gt;Enter your url&amp;lt;/label&amp;gt;
    &amp;lt;type&amp;gt;text&amp;lt;/type&amp;gt;
 &amp;lt;/input&amp;gt;   
&amp;lt;input field="param.user"&amp;gt;
  &amp;lt;label&amp;gt;enter user name&amp;lt;/label&amp;gt;
  &amp;lt;type&amp;gt;text&amp;lt;/type&amp;gt;
&amp;lt;/input&amp;gt;
&amp;lt;input field="param.snow_credentials"&amp;gt;
  &amp;lt;label&amp;gt;enter password&amp;lt;/label&amp;gt;
  &amp;lt;type&amp;gt;password&amp;lt;/type&amp;gt;
&amp;lt;/input&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I am using these parameters in the Python script which calls a REST API method. I am retrieving the values for these parameters as below in Python script&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;    snow_url = settings['configuration'].get('url1')
    user = settings['configuration'].get('user')
    password = settings['configuration'].get('snow_credentials')
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The issue I am facing is, when I set the parameter values for the 1st time using Setup screen the values are correctly retrieved by the script. But when I update them using the setup screen and run the script as a alert action it still retrieves the old values of the parameter and not new once.&lt;/P&gt;

&lt;P&gt;I tried to check the values using URL&lt;BR /&gt;
&lt;A href="https://localhost:8089/servicesNS/nobody//alerts/alert_actions/"&gt;https://localhost:8089/servicesNS/nobody//alerts/alert_actions/&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;I can see the updated values. I also tried to reload them and try but still the script is getting old values only. Is there anything basic I am missing here?&lt;/P&gt;</description>
      <pubDate>Wed, 13 Mar 2019 08:01:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Values-for-Endpoints-defined-in-the-setup-xml-file-are-not/m-p/439027#M76547</guid>
      <dc:creator>santosh_sshanbh</dc:creator>
      <dc:date>2019-03-13T08:01:47Z</dc:date>
    </item>
    <item>
      <title>Re: Values for Endpoints defined in the setup.xml file are not refreshed</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Values-for-Endpoints-defined-in-the-setup-xml-file-are-not/m-p/439028#M76548</link>
      <description>&lt;P&gt;Above mentioned XML data is located inside below tags.&lt;/P&gt;</description>
      <pubDate>Wed, 13 Mar 2019 08:42:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Values-for-Endpoints-defined-in-the-setup-xml-file-are-not/m-p/439028#M76548</guid>
      <dc:creator>santosh_sshanbh</dc:creator>
      <dc:date>2019-03-13T08:42:13Z</dc:date>
    </item>
    <item>
      <title>Re: Values for Endpoints defined in the setup.xml file are not refreshed</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Values-for-Endpoints-defined-in-the-setup-xml-file-are-not/m-p/439029#M76549</link>
      <description>&lt;P&gt;When you setup the parameters via setup page, I assume they are getting added under your app's local/ta_*settings.conf file. Does this get updated when you update the params via setup again? check your default/restmap.conf for handler actions - edit and list [ you need both]. Are you using add-on builder?&lt;/P&gt;</description>
      <pubDate>Wed, 13 Mar 2019 11:14:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Values-for-Endpoints-defined-in-the-setup-xml-file-are-not/m-p/439029#M76549</guid>
      <dc:creator>lakshman239</dc:creator>
      <dc:date>2019-03-13T11:14:30Z</dc:date>
    </item>
    <item>
      <title>Re: Values for Endpoints defined in the setup.xml file are not refreshed</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Values-for-Endpoints-defined-in-the-setup-xml-file-are-not/m-p/439030#M76550</link>
      <description>&lt;P&gt;I am not using add-on builder. I started creating my app by using the reference of hipchat_alerts example.&lt;/P&gt;

&lt;P&gt;When I update the parameters, they get updated in alert_actions.conf file in apps local directory. I have just added a validation rule in restmap.conf file, nothing about the setup parameters.&lt;/P&gt;

&lt;P&gt;I do observed that, when I create a new alert it is getting updated values of setup parameters. So I think the json paylod passed to PYTHON script is sending old values only. I may have to use Splunk SDK to read endpoint values unless there is no alternative.&lt;/P&gt;</description>
      <pubDate>Wed, 13 Mar 2019 11:50:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Values-for-Endpoints-defined-in-the-setup-xml-file-are-not/m-p/439030#M76550</guid>
      <dc:creator>santosh_sshanbh</dc:creator>
      <dc:date>2019-03-13T11:50:43Z</dc:date>
    </item>
  </channel>
</rss>

