Use YANG with NETCONF and RESTCONF to provide the desired solution for automated and programmable network operations.
Use the following RPC to create a NETCONF GET request for reload history data:
<nc:rpc xmlns:nc="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:da15955f-5bb7-437c-aeb5-0fc7901a1e9e">
<nc:get>
<nc:filter>
<device-hardware-data xmlns="http://cisco.com/ns/yang/Cisco-IOS-XE-device-hardware-oper">
<device-hardware>
<device-system-data>
<reload-history/>
</device-system-data>
</device-hardware>
</device-hardware-data>
</nc:filter>
</nc:get>
</nc:rpc>
<rpc-reply message-id="urn:uuid:da15955f-5bb7-437c-aeb5-0fc7901a1e9e" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" xmlns:nc="urn:ietf:params:xml:ns:netconf:base:1.0">
<data>
<device-hardware-data xmlns="http://cisco.com/ns/yang/Cisco-IOS-XE-device-hardware-oper">
<device-hardware>
<device-system-data>
<reload-history>
<rl-history>
<reload-category>rc-rld</reload-category>
<reload-desc>Reload Command</reload-desc>
<reload-time>2022-11-30T01:33:44+00:00</reload-time>
<reload-severity>normal</reload-severity>
</rl-history>
<rl-history>
<reload-category>rc-crit-proc-fault</reload-category>
<reload-desc>Critical process stack_mgr fault on rp_0_0 (rc=137), system report at bootflash:core/Yang_Test-system-report_20221130-012929-UTC.tar.gz</reload-desc>
<reload-time>2022-11-30T01:31:11+00:00</reload-time>
<reload-severity>abnormal</reload-severity>
</rl-history>
<rl-history>
<reload-category>rc-img-install</reload-category>
<reload-desc>Image Install </reload-desc>
<reload-time>2022-11-30T01:25:03+00:00</reload-time>
<reload-severity>normal</reload-severity>
</rl-history>
<rl-history>
<reload-category>rc-crit-proc-fault</reload-category>
<reload-desc>Critical process rif_mgr fault on rp_0_0 (rc=137), system report at bootflash:core/Yang_Test-system-report_20221130-011127-UTC.tar.gz</reload-desc>
<reload-time>2022-11-30T01:13:08+00:00</reload-time>
<reload-severity>abnormal</reload-severity>
</rl-history>
<rl-history>
<reload-category>rc-rld</reload-category>
<reload-desc>Reload Command</reload-desc>
<reload-time>2022-11-30T01:08:26+00:00</reload-time>
<reload-severity>normal</reload-severity>
</rl-history>
<rl-history>
<reload-category>rc-crit-proc-fault</reload-category>
<reload-desc>Critical process wncmgrd fault on rp_0_0 (rc=137), system report at bootflash:core/Yang_Test-system-report_20221130-010338-UTC.tar.gz</reload-desc>
<reload-time>2022-11-30T01:05:23+00:00</reload-time>
<reload-severity>abnormal</reload-severity>
</rl-history>
<rl-history>
<reload-category>rc-rld</reload-category>
<reload-desc>Reload Command</reload-desc>
<reload-time>2022-11-30T01:01:09+00:00</reload-time>
<reload-severity>normal</reload-severity>
</rl-history>
<rl-history>
<reload-category>rc-rld</reload-category>
<reload-desc>Reload Command</reload-desc>
<reload-time>2022-11-30T00:57:27+00:00</reload-time>
<reload-severity>normal</reload-severity>
</rl-history>
<rl-history>
<reload-category>rc-rld</reload-category>
<reload-desc>Reload Command</reload-desc>
<reload-time>2022-11-30T00:22:34+00:00</reload-time>
<reload-severity>normal</reload-severity>
</rl-history>
<rl-history>
<reload-category>rc-force-switchover</reload-category>
<reload-desc>redundancy force-switchover</reload-desc>
<reload-time>2022-11-29T23:40:01+00:00</reload-time>
<reload-severity>normal</reload-severity>
</rl-history>
</reload-history>
</device-system-data>
</device-hardware>
</device-hardware-data>
</data>
</rpc-reply>
For more information about the YANG models, see the following documents: The Cisco IOS XE Programmability Configuration Guide
at https://www.cisco.com/c/en/us/support/wireless/catalyst-9800-series-wireless-controllers/products-installation-and-configuration-guides-list.html
The YANG Data Models on Github at https://github.com/YangModels/yang/tree/main/vendor/cisco/xe.
Contact the Developer Support Community for NETCONF and YANG features at:
https://developer.cisco.com/