public HttpResponseMessage AddNew([FromBody] Contacts Detail) { GeolocationStack location = GetGeolocation(Detail.IP); Detail.Country = location.CountryName; Detail.Region = location.RegionName; Detail.City = location.City; var r = CBL.Add(Detail); if (!r) { return(this.Request.CreateResponse(HttpStatusCode.InternalServerError)); } else { return(this.Request.CreateResponse(HttpStatusCode.OK, r)); } }