06-27-2020 09:06 AM
Hey all,
Long time lurker first time poster here.
I'm doing my DevNet Associate training and have come up against a brick wall when trying to determine how to generate the full URIs to GET/POST (more GET at this point! ha) on IOS-XE when using RESTCONF. I have queried the YANG capabilities using /restconf/data/netconf-state/capabilites and have returned a large list. When trying to query any of them I get an error - 'uri keypath not found'. I know from my training material that there is a URI for /restconf/data/ietf-interfaces:interfaces which returns data. However, without knowing that ietf-interfaces has a container of :interfaces, how would I generate a URI, for example for ietf-ipv4-unicast-routing or /Cisco-IOS-XE-acl?
I know of YANG Catalog and I have been able to locate both of those capabilities, but am wondering how do/would you or I determine the full URI? I.e. would you go to YANG catalog and find the module and locate the capabilities - or is there a way to determine it via a query?
Really apreciate the assit here.
~Jonny
06-29-2020 12:34 AM
Hi
Dont think you get containers from capabilities with restconf .. could be wrong .. but I have not seen any doc.
Use pyang or yang explorer to load/explore the yang model from yang catalogue on github to see the containers.
check out the uri construction section in these presentations -
https://www.ciscolive.com/c/dam/r/ciscolive/apjc/docs/2016/pdf/DEVNET-1081.pdf
06-29-2020 05:17 AM
03-02-2022 02:35 PM - edited 03-02-2022 02:36 PM
Hi
The DEVNET-1081 PDF is no longer available. Does anyone know where we can find it?
Thanks!
Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: