コード例 #1
0
        public HttpResponseMessage PostPasswordReset([FromBody] JObject username)
        {
            if (username == null || !username.ContainsKey("username") || username.GetValue("username").ToString().IsEmpty())
            {
                return(Request.CreateResponse(HttpStatusCode.BadRequest, "Invalid Request"));
            }

            AuthUser.RequestPasswordReset(username.GetValue("username").ToString());

            return(Request.CreateResponse(HttpStatusCode.Created, "Email Sent"));
        }