Querying the Version
DME
YANG
Copy
GET http://<IP_Address>/api/mo/sys/showversion.json
Response
{ "totalCount": "1", "imdata": [ { "sysmgrShowVersion": { "attributes": { "activePackage": "", "biosCompileTime": "12/07/2015", "biosVersion": "09.20", "bootflashSize": "51496280", "copyRight": "Cisco Nexus Operating System (NX-OS) Software\nTAC support: http://www.cisco.com/tac\nCopyright (C) 2002-2018, Cisco and/or its affiliates.\nAll rights reserved.\nThe copyrights to certain works contained in this software are\nowned by other third parties and used and distributed under their own\nlicenses, such as open source. This software is provided \"as is,\" and unless\notherwise stated, there is no warranty, express or implied, including but not\nlimited to warranties of merchantability and fitness for a particular purpose.\nCertain components of this software are licensed under\nthe GNU General Public License (GPL) version 2.0 or \nGNU General Public License (GPL) version 3.0 or the GNU\nLesser General Public License (LGPL) Version 2.1 or \nLesser General Public License (LGPL) Version 2.0. \nA copy of each such license is available at\nhttp://www.opensource.org/licenses/gpl-2.0.php and\nhttp://opensource.org/licenses/gpl-3.0.html and\nhttp://www.opensource.org/licenses/lgpl-2.1.php and\nhttp://www.gnu.org/licenses/old-licenses/library.txt.\n", "dn": "sys/showversion", "kernelUptime": "15 minute(s) 2 second(s) ", "lastResetReason": "Reset Requested by CLI command reload", "lastResetService": "", "lastResetSysVersion": "9.2(1)", "lastResetTime": "996434 usecs after Fri Jul 6 21:29:32 2018", "nxosCompileTime": " 7/5/2018 21:00:00", "nxosImageFile": "bootflash:///h232.bin", "nxosVersion": "9.2(1)", "plugin": "Core Plugin, Ethernet Plugin" } } } ] }
Copy
GET: http://<IP_Address>/restconf/data/Cisco-NX-OS-device:System/showversion-items/
<showversion-items> <activePackage/> <biosCompileTime>12/07/2015</biosCompileTime> <biosVersion>09.20</biosVersion> <bootflashSize>51496280</bootflashSize> <copyRight>Cisco Nexus Operating System (NX-OS) Software TAC support: http://www.cisco.com/tac Copyright (C) 2002-2018, Cisco and/or its affiliates. All rights reserved. The copyrights to certain works contained in this software are owned by other third parties and used and distributed under their own licenses, such as open source. This software is provided &quot;as is,&quot; and unless otherwise stated, there is no warranty, express or implied, including but not limited to warranties of merchantability and fitness for a particular purpose. Certain components of this software are licensed under the GNU General Public License (GPL) version 2.0 or GNU General Public License (GPL) version 3.0 or the GNU Lesser General Public License (LGPL) Version 2.1 or Lesser General Public License (LGPL) Version 2.0. A copy of each such license is available at http://www.opensource.org/licenses/gpl-2.0.php and http://opensource.org/licenses/gpl-3.0.html and http://www.opensource.org/licenses/lgpl-2.1.php and http://www.gnu.org/licenses/old-licenses/library.txt. </copyRight> <kernelUptime>16 minute(s) 2 second(s) </kernelUptime> <lastResetReason>Reset Requested by CLI command reload</lastResetReason> <lastResetService/> <lastResetSysVersion>9.2(1)</lastResetSysVersion> <lastResetTime>996434 usecs after Fri Jul 6 21:29:32 2018</lastResetTime> <nxosCompileTime> 7/5/2018 21:00:00</nxosCompileTime> <nxosImageFile>bootflash:///h232.bin</nxosImageFile> <nxosVersion>9.2(1)</nxosVersion> <plugin>Core Plugin, Ethernet Plugin</plugin> </showversion-items>