Using HttpClient I post a json document to my controller.
public async Task<string> PostAsync<T>(string url, T doc)
{
var json = JsonConvert.SerializeObject(doc);
var response = await mHttp.PostAsync(url, new StringContent(json));
}
When I inspect the controller here:
public async Task<ActionResult> Post([FromBody] object doc,string fid)
The object doc has this format:
ValueKind = Object : "{"id": "101zsdfgfgh","fid": "test1",......
}
How can Ideserialize this if the type is unknown?