I'm trying to log model passed to controller by doing something like this:
_log
.ForContext("Id", "XXXXXX-XXXX-XXXX-XXXXXXXXX")
.ForContext("Email", email)
.ForContext("UserId", userId)
.ForContext("Parameters", parameters)
.ForContext("Errors", errors.ToArray())
.ForContext("ActionArguments", actionArguments)
.Information(message);
where actionArguments is of type IDictionary<string, object> actionArguments. This is interpreted like
{
someProperty: "Some.Namespace.Dtos.Something.MyTypeDto"
}
and I really wish someProperty to be expanded to what complex type represents. Is it possible? How to do it?