// GET: api/Home/5 public HttpResponseMessage GetUserDetails(string id) { try { var bll = new Idbll(); var userDetail = bll.GetIdUserDetailByIdNumber(id); return Request.CreateResponse(HttpStatusCode.OK, userDetail); } catch (Exception exception) { return Request.CreateResponse(HttpStatusCode.InternalServerError, exception.Message); } }
// GET: api/Home public HttpResponseMessage Get() { try { var bll = new Idbll(); var id = bll.GetValidGeneratedId(); return Request.CreateResponse(HttpStatusCode.OK, id); } catch (Exception exception) { return Request.CreateResponse(HttpStatusCode.InternalServerError, exception.Message); } }