i want to make a dynmamic class in C# out of a Json.
I Know i can you deserialize to convert the json but my problem is:
If i know how the json looks like (e.g. { "id": "5", "name": "Example" } i can call the value with obj.id or obj.name
BUT
i have a JSON with one property Array that could be diffrent in every instance. E.G.
{
"id": "5",
"name": "Example",
},
"config": {
"Time": "13:23",
"Days": ["Monday", "Thuesday"]
}
or
{
"id": "5",
"name": "Example",
},
"config": {
"ServerURL": "https://example.com",
"Category": "API"
}
So how i can convert this diffrent JSONs to ONE dynamic object?