I want to delete any JSON element by using their key. For example,
This is my JSON data:
{
"CreateprivateNetwork": {
"description": "Creatinganetwork.",
"input": {
"body": {
"network": {
"name": "$.networkname",
"admin_state_up": "sdfdsf"
}
}
},
"action": "neutron.create_network",
"publish": {}
}
}
I want to delete the element "name" from this JSON
PATH TO DELETE : "CreateprivateNetwork.input.body.network.name".
Please help me to solve this problem.
Note: This path may change Dynamically. So I have to delete any elements from dynamic JSON.