public IHttpActionResult PostReserveSeat(BookingSeat bookingSeat) { var res = bookingRepository.ConfirmReserving(bookingSeat, Request.Properties["vendor"] as Vendor); if (res == "invalid request") { return(StatusCode(HttpStatusCode.BadRequest)); } else if (res == "already booked") { return(StatusCode(HttpStatusCode.Conflict)); } else { return(Ok(bookingSeat)); } }