protected static string ModelToJson(object model)
        {
            var formatter = new RPCJsonOutputFormatter(new JsonSerializerSettings(), System.Buffers.ArrayPool <char> .Create());
            var sw        = new StringWriter();

            formatter.WriteObject(sw, model);
            string json = sw.ToString();

            return(json);
        }