public object Get([FromBody] QueryModel QueryModel) { object result = string.Empty; try { if (QueryModel.Parameters == null || QueryModel.Parameters.Count == 0) { throw new RestMagicExcpetion("Call to FindDataByModel contained no parameters."); } result = DataModelService.GetData(QueryModel); } catch (Exception e) { Logger.LogError(e); result = e.Message; } return(result); }