How to have a WCF DataContract with a json dynamic member

WCF (as of 4.5) doesn't support deserializing arbitrary JSON as part of a data contract. You'll need to use another serializer which does that - JSON.NET is one which I personally like. To be able to change the serializer, you can use a different message formatter, and in the post at https://github.com/microsoftarchive/msdn-code-gallery-community-s-z/tree/master/Supporting%20different%20data%20and%20serialization%20formats%20in%20WCF I have a sample which does exactly that - replaces the default serialization used by WCF with JSON.NET.

Notice that to receive arbitrary JSON using that library, you'll need to change the type of the "json" property to the equivalent of arbitrary JSON in JSON.NET, JToken:

public class Contract 
{ 
    [DataMember] 
    public int clientId; 
    [DataMember] 
    public Newtonsoft.Json.Linq.JToken json; 
}