hi jonathan
for the first one, if you check the YANG model (in cisco-pnp) you can see the list is called "map" and the key is "id" -- which is the serial number...
list map {
key id;
description
"Map from device serial number to device name. This
information is used when mounting the device into the
NCS device tree.";
leaf id {
type string {
tailf:info "WORD;;Serial number of device";
length "1..32";
}
}
I've run a curl call on DELETE this way (based on above) -- say in your case you want to delete serial FGL210310NZ
you should be able to do:
curl -v -X DELETE -u admin:admin \
http://127.0.0.1:8080/api/running/map/FGL210310NZ
or
curl -v -X DELETE -u admin:admin \
-H "Accept: application/vnd.yang.data+json" \
http://127.0.0.1:8080/api/running/map/FGL210310NZ
*i did this awhile back prior to RESTCONF - but you should be able to convert it and should use RESTCONF preferably.
not sure about the branch one ( i don't have that running anywhere).
best,
gregg