public HttpResponseMessage VerifyEmail(EmailVerificationRequestModel requestModel)
        {
            if (!ModelState.IsValid)
            {
                return Request.CreateErrorResponse(HttpStatusCode.BadRequest, "Invalid Request");
            }

            var name = HttpContext.Current.Request.UserHostAddress.ToString();

            requestModel = new EmailVerificationRequestModel
            {
                //EmailAddress = requestModel.EmailAddress,
                EmailAddress = "*****@*****.**",
            };

            VerificationAction verifyActions = new VerificationAction();
            EmailVerificationResponseModel responseModel = verifyActions.VerifyEmail(requestModel);

            if (responseModel.Error != null)
            {
                return Request.CreateErrorResponse(HttpStatusCode.OK, responseModel.Error);
            }

            return Request.CreateResponse(HttpStatusCode.OK, responseModel, "application/json");
        }
        /// <summary>
        /// Sent Email
        /// </summary>
        /// <param name="requestModel"></param>
        /// <returns></returns>
        public EmailVerificationResponseModel VerifyEmail(EmailVerificationRequestModel requestModel)
        {
            EmailVerificationResponseModel responseModel = new EmailVerificationResponseModel();

            try
            {
                EmailVerifyTokenRepo token = new EmailVerifyTokenRepo();                                      //Generate Token and Request Id
                string[] TokenAndRequest = token.AddEmailVerificationToken(requestModel.EmailAddress);

                string AppendedWebApiPath = AppendPath(TokenAndRequest[0]);                 //Generate WebApi PAth with Token

                UserProfileRepo repo = new UserProfileRepo();
                string FullName = repo.GetUserName(requestModel.EmailAddress);              //Get FirstName and LAstName for Email

                SendEmailForVerification emailverify = new SendEmailForVerification();
                string Body = emailverify.PopulateBody(AppendedWebApiPath, FullName);                         //Generate Email Template
                bool IsValid = emailverify.sendHTMLFormattedEmail(requestModel.EmailAddress, Body);           //Send Email


                if (!IsValid)
                {
                    responseModel.Error = "Service Temporarily Unavailable";
                    responseModel.IsValid = IsValid;
                    return responseModel;
                }

                responseModel.Error = null;
                responseModel.IsValid = IsValid;
                responseModel.RequestId = Convert.ToInt32(TokenAndRequest[1]);
                return responseModel;

            }
            catch (TimeoutException)
            {
                responseModel.IsValid = false;
                responseModel.Error = "We cant Process Request At The Moment !!! Kindly try again later";
                return responseModel;
            }
            catch (WebException)
            {
                responseModel.IsValid = false;
                responseModel.Error = "We cant Process Request At The Moment !!! Kindly try again later";
                return responseModel;
            }
        }
 public EmailVerificationResponseModel VerifyEmail(EmailVerificationRequestModel requestModel)
 {
     VerificationCase verifycase = new VerificationCase();
     return verifycase.VerifyEmail(requestModel);
 }