<?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: Create a workflow that runs a script to a port based on port displayname in Scripting</title>
    <link>https://community.extremenetworks.com/t5/scripting/create-a-workflow-that-runs-a-script-to-a-port-based-on-port/m-p/97248#M531</link>
    <description>&lt;P&gt;Hi Coders, Help please &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Trying to run this function that checks through an API call if the mac address is a CISCO MAC, but I keep getting errors in XMC:&lt;/P&gt;&lt;P&gt;SyntaxError: ('no viable alternative at input \'"{base_url}/{mac_address}"\'', ('&amp;lt;string&amp;gt;', 35, 33, ' response = requests.get(f"{base_url}/{mac_address}", headers=headers) # Escape double quotes with a backslash\n'))&lt;/P&gt;&lt;P&gt;Here is code, I kept line numbers to see problem:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Chad5_0-1695416193920.png" style="width: 400px;"&gt;&lt;img src="https://community.extremenetworks.com/t5/image/serverpage/image-id/6674iEF9E85075F06E306/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Chad5_0-1695416193920.png" alt="Chad5_0-1695416193920.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Any ideas, please help.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 22 Sep 2023 20:56:42 GMT</pubDate>
    <dc:creator>Chad5</dc:creator>
    <dc:date>2023-09-22T20:56:42Z</dc:date>
    <item>
      <title>Create a workflow that runs a script to a port based on port displayname</title>
      <link>https://community.extremenetworks.com/t5/scripting/create-a-workflow-that-runs-a-script-to-a-port-based-on-port/m-p/97198#M528</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Wondering if anyone has a script that can run on EXOS switches to look for a certain name configured on a port (display port name), and then when found, it will run on that port some cli commands.&lt;/P&gt;&lt;P&gt;For example, if I have a port 1:40, with name "WAN". the script will save 1:40 in a variable for that switch, and then run:&lt;/P&gt;&lt;P&gt;configure port 1:40 ....etc&lt;/P&gt;&lt;P&gt;And repeat for other switches...&lt;/P&gt;&lt;P&gt;If I can get the script commands to connect to an IP, run CLI commands and get the CLI command output where I can process.. then I can prob do the rest. Just not sure how to connect, run commands, then close.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 18 Sep 2023 21:10:38 GMT</pubDate>
      <guid>https://community.extremenetworks.com/t5/scripting/create-a-workflow-that-runs-a-script-to-a-port-based-on-port/m-p/97198#M528</guid>
      <dc:creator>Chad5</dc:creator>
      <dc:date>2023-09-18T21:10:38Z</dc:date>
    </item>
    <item>
      <title>Re: Create a workflow that runs a script to a port based on port displayname</title>
      <link>https://community.extremenetworks.com/t5/scripting/create-a-workflow-that-runs-a-script-to-a-port-based-on-port/m-p/97202#M529</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I suggest to you to have a look of the system workflow already present in Site Engine, or on GitHub in the Extreme Networks's channel and there are a lot of examples that can help you on this development.&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;</description>
      <pubDate>Tue, 19 Sep 2023 12:14:10 GMT</pubDate>
      <guid>https://community.extremenetworks.com/t5/scripting/create-a-workflow-that-runs-a-script-to-a-port-based-on-port/m-p/97202#M529</guid>
      <dc:creator>Antonio_Opromol</dc:creator>
      <dc:date>2023-09-19T12:14:10Z</dc:date>
    </item>
    <item>
      <title>Re: Create a workflow that runs a script to a port based on port displayname</title>
      <link>https://community.extremenetworks.com/t5/scripting/create-a-workflow-that-runs-a-script-to-a-port-based-on-port/m-p/97231#M530</link>
      <description>&lt;P&gt;Thanks. Yeah, did that and with some help from chatGPT I was able to do a basic code to do it. I was hoping for some documents that discussed the XMC specific commands and libraries. But will use the examples for now.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;</description>
      <pubDate>Thu, 21 Sep 2023 19:48:17 GMT</pubDate>
      <guid>https://community.extremenetworks.com/t5/scripting/create-a-workflow-that-runs-a-script-to-a-port-based-on-port/m-p/97231#M530</guid>
      <dc:creator>Chad5</dc:creator>
      <dc:date>2023-09-21T19:48:17Z</dc:date>
    </item>
    <item>
      <title>Re: Create a workflow that runs a script to a port based on port displayname</title>
      <link>https://community.extremenetworks.com/t5/scripting/create-a-workflow-that-runs-a-script-to-a-port-based-on-port/m-p/97248#M531</link>
      <description>&lt;P&gt;Hi Coders, Help please &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Trying to run this function that checks through an API call if the mac address is a CISCO MAC, but I keep getting errors in XMC:&lt;/P&gt;&lt;P&gt;SyntaxError: ('no viable alternative at input \'"{base_url}/{mac_address}"\'', ('&amp;lt;string&amp;gt;', 35, 33, ' response = requests.get(f"{base_url}/{mac_address}", headers=headers) # Escape double quotes with a backslash\n'))&lt;/P&gt;&lt;P&gt;Here is code, I kept line numbers to see problem:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Chad5_0-1695416193920.png" style="width: 400px;"&gt;&lt;img src="https://community.extremenetworks.com/t5/image/serverpage/image-id/6674iEF9E85075F06E306/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Chad5_0-1695416193920.png" alt="Chad5_0-1695416193920.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Any ideas, please help.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 22 Sep 2023 20:56:42 GMT</pubDate>
      <guid>https://community.extremenetworks.com/t5/scripting/create-a-workflow-that-runs-a-script-to-a-port-based-on-port/m-p/97248#M531</guid>
      <dc:creator>Chad5</dc:creator>
      <dc:date>2023-09-22T20:56:42Z</dc:date>
    </item>
    <item>
      <title>Re: Create a workflow that runs a script to a port based on port displayname</title>
      <link>https://community.extremenetworks.com/t5/scripting/create-a-workflow-that-runs-a-script-to-a-port-based-on-port/m-p/98980#M540</link>
      <description>&lt;P&gt;first,&lt;BR /&gt;please don't mix different topics under the same thread.&amp;nbsp;&lt;/P&gt;&lt;P&gt;second,&lt;BR /&gt;XIQ-SE Workflow &amp;amp; Python scripting using Python 2.7!&lt;BR /&gt;You syntax error tells you that the Python 2.7 interpreter don't understand your instruction, because is a instruction from Python 3.x.&lt;BR /&gt;Please use following syntax&lt;BR /&gt;&lt;BR /&gt;test1 = "Hello"&lt;BR /&gt;test2 = "World"&lt;BR /&gt;print("%s %s!" % (test1,test2))&lt;/P&gt;</description>
      <pubDate>Mon, 22 Jan 2024 11:29:39 GMT</pubDate>
      <guid>https://community.extremenetworks.com/t5/scripting/create-a-workflow-that-runs-a-script-to-a-port-based-on-port/m-p/98980#M540</guid>
      <dc:creator>Markus_Nikulski</dc:creator>
      <dc:date>2024-01-22T11:29:39Z</dc:date>
    </item>
  </channel>
</rss>

