<?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: Admin Down switch ports via API in Network Platform API</title>
    <link>https://community.cisco.com/t5/network-platform-api/admin-down-switch-ports-via-api/m-p/5455277#M8402</link>
    <description>&lt;P&gt;Sorry, I pasted the wrong endpoint first time, see the updated posting.&lt;/P&gt;</description>
    <pubDate>Mon, 27 Jan 2025 19:21:38 GMT</pubDate>
    <dc:creator>sungod</dc:creator>
    <dc:date>2025-01-27T19:21:38Z</dc:date>
    <item>
      <title>Admin Down switch ports via API</title>
      <link>https://community.cisco.com/t5/network-platform-api/admin-down-switch-ports-via-api/m-p/5455274#M8399</link>
      <description>&lt;P&gt;Is there a way to run a shut command on all unused MS switch ports that are not used via an API call?  We want to tighten our security so no one can gain unauthorized access to our network.  Right now, if you plug into the MS, you get access.&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;</description>
      <pubDate>Mon, 27 Jan 2025 18:33:01 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/admin-down-switch-ports-via-api/m-p/5455274#M8399</guid>
      <dc:creator>tjh188</dc:creator>
      <dc:date>2025-01-27T18:33:01Z</dc:date>
    </item>
    <item>
      <title>Re: Admin Down switch ports via API</title>
      <link>https://community.cisco.com/t5/network-platform-api/admin-down-switch-ports-via-api/m-p/5455275#M8400</link>
      <description>&lt;P&gt;You can use&lt;A href="https://developer.cisco.com/meraki/api-v1/get-organization-switch-ports-statuses-by-switch/" target="_blank" rel="noopener nofollow noreferrer"&gt; https://developer.cisco.com/meraki/api-v1/get-organization-switch-ports-statuses-by-switch/&lt;/A&gt; to get all the current port details.&lt;/P&gt;&lt;P&gt;Then parse that to choose which ports to shut down... &lt;A href="https://developer.cisco.com/meraki/api-v1/update-device-switch-port/" target="_blank" rel="noopener nofollow noreferrer"&gt;https://developer.cisco.com/meraki/api-v1/update-device-switch-port/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;The update action can also be done in an action batch to speed things up.&lt;/P&gt;&lt;P&gt;But there's a risk if the port is used but not currently connected that you'd block a needed port, you'd really need to keep some table of 'protected' ports to leave alone, or tag such ports and look out for the tag when deciding. I don't think the statuses endpoint gets the tags but you could use &lt;A href="https://developer.cisco.com/meraki/api-v1/get-organization-switch-ports-by-switch/" target="_blank" rel="nofollow noopener noreferrer"&gt;https://developer.cisco.com/meraki/api-v1/get-organization-switch-ports-by-switch/&lt;/A&gt; to retrieve them.&lt;/P&gt;&lt;P&gt;Bear in mind that if an attacker has physical access, they could simply pull the cable from a live port and still gain access that way. Using access policies would be better, see... &lt;A href="https://documentation.meraki.com/MS/Access_Control/MS_Switch_Access_Policies_(802.1X)" target="_blank" rel="noopener nofollow noreferrer"&gt;https://documentation.meraki.com/MS/Access_Control/MS_Switch_Access_Policies_(802.1X)&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 27 Jan 2025 18:59:44 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/admin-down-switch-ports-via-api/m-p/5455275#M8400</guid>
      <dc:creator>sungod</dc:creator>
      <dc:date>2025-01-27T18:59:44Z</dc:date>
    </item>
    <item>
      <title>Re: Admin Down switch ports via API</title>
      <link>https://community.cisco.com/t5/network-platform-api/admin-down-switch-ports-via-api/m-p/5455276#M8401</link>
      <description>&lt;P&gt;The &lt;A href="https://developer.cisco.com/meraki/api-v1/get-organization-switch-ports-by-switch/" target="_blank" rel="noopener nofollow noreferrer"&gt;https://developer.cisco.com/meraki/api-v1/get-organization-switch-ports-by-switch/&lt;/A&gt; does not show if anything is plugged into it or not.  Is there another call that will show if anything is plugged in currently?&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;I think that we are close.&lt;/P&gt;</description>
      <pubDate>Mon, 27 Jan 2025 19:16:20 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/admin-down-switch-ports-via-api/m-p/5455276#M8401</guid>
      <dc:creator>tjh188</dc:creator>
      <dc:date>2025-01-27T19:16:20Z</dc:date>
    </item>
    <item>
      <title>Re: Admin Down switch ports via API</title>
      <link>https://community.cisco.com/t5/network-platform-api/admin-down-switch-ports-via-api/m-p/5455277#M8402</link>
      <description>&lt;P&gt;Sorry, I pasted the wrong endpoint first time, see the updated posting.&lt;/P&gt;</description>
      <pubDate>Mon, 27 Jan 2025 19:21:38 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/admin-down-switch-ports-via-api/m-p/5455277#M8402</guid>
      <dc:creator>sungod</dc:creator>
      <dc:date>2025-01-27T19:21:38Z</dc:date>
    </item>
    <item>
      <title>Re: Admin Down switch ports via API</title>
      <link>https://community.cisco.com/t5/network-platform-api/admin-down-switch-ports-via-api/m-p/5455278#M8403</link>
      <description>&lt;P&gt;Good Morning, &lt;/P&gt;&lt;P&gt;I can run the &lt;SPAN&gt; &lt;/SPAN&gt;&lt;A href="https://developer.cisco.com/meraki/api-v1/get-organization-switch-ports-by-switch/" target="_blank" rel="noopener nofollow noreferrer"&gt;https://developer.cisco.com/meraki/api-v1/get-organization-switch-ports-by-switch/&lt;/A&gt; and it displays only some of the switches in my organization.  I have over 700 that I want to pull.  What is the easiest way to do that?  I would be targetting my Templates in bulk so if there is a way to pull all of the switchports within an individual template, that would be great!&lt;/P&gt;</description>
      <pubDate>Mon, 03 Feb 2025 15:29:41 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/admin-down-switch-ports-via-api/m-p/5455278#M8403</guid>
      <dc:creator>tjh188</dc:creator>
      <dc:date>2025-02-03T15:29:41Z</dc:date>
    </item>
    <item>
      <title>Re: Admin Down switch ports via API</title>
      <link>https://community.cisco.com/t5/network-platform-api/admin-down-switch-ports-via-api/m-p/5455279#M8404</link>
      <description>&lt;P&gt;That endpoint returns a maximum of 50 records per call, are you following the pagination process to get all the pages?&lt;/P&gt;&lt;P&gt;&lt;A href="https://developer.cisco.com/meraki/api-v1/pagination/#pagination" target="_blank" rel="noopener nofollow noreferrer"&gt;https://developer.cisco.com/meraki/api-v1/pagination/#pagination&lt;/A&gt;&lt;/P&gt;&lt;P&gt;If you are using Python, the Meraki Python library can handle pagination for you...&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/meraki/dashboard-api-python" target="_blank" rel="noopener nofollow noreferrer"&gt;https://github.com/meraki/dashboard-api-python&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 03 Feb 2025 18:20:21 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/admin-down-switch-ports-via-api/m-p/5455279#M8404</guid>
      <dc:creator>sungod</dc:creator>
      <dc:date>2025-02-03T18:20:21Z</dc:date>
    </item>
  </channel>
</rss>

