I try to convert excel file to a python dictionary.
The excel looks like below

The dictionary I would like to have is as below
[
{
"ipam.prefixes": [
{
"10.0.1.0/28": {
"prefix": "10.0.1.0/28",
"status": "container",
"vlan": {"vid": 200}
}
}
]
]
If the excel data is flat, like "prefix" and "status" I can convert them, but with extra level of data, I could not figure out how to make it. Most of the data in the excel are basic key/value pair, but some random item will be key:{key1:value} or key:{key1:value1, key2:value2}, I try to find a generic way to convert them to proper dictionary ragardless what does user enter. It is ok to change the format of the excel if it makes the python code easy to manipulate the data.