Adding this three years later in case anybody else ends up here from a search.
Since .NET 7 there is a proper way of doing this. You just use the JsonDerivedType attribute on the base class, e.g.
[JsonDerivedType(typeof(TypeAClient))]
[JsonDerivedType(typeof(TypeBClient))]
[JsonDerivedType(typeof(TypeCClient))]
public class Client {
}
You have to include all the sub-types that you might want to serialise.