public HttpResponseMessage DeleteIntegralFee(HttpRequestMessage request, [FromBody] int integralFeeId) { return(GetHttpResponse(request, () => { HttpResponseMessage response = null; // not that calling the WCF service here will authenticate access to the data IntegralFee integralFee = _IFRSDataService.GetIntegralFee(integralFeeId); if (integralFee != null) { _IFRSDataService.DeleteIntegralFee(integralFeeId); response = request.CreateResponse(HttpStatusCode.OK); } else { response = request.CreateErrorResponse(HttpStatusCode.NotFound, "No IntegralFee found under that ID."); } return response; })); }