public ActionResult <siteSetupStructure> Put([FromBody] siteSetupStructure newSetupStructure) { var service = new SmartDASService(); try { service.Connect(); service.setConfigData(newSetupStructure); var structure = service.getConfigData(); service.Disconnect(); return(structure); } catch (Exception e) { return(StatusCode(500, e)); } }