POST login/users/reset password/email
From Social ID Developers
Revision as of 11:59, 10 December 2014 by Renato.neves (Talk | contribs)
Contents |
Description
Sends a reset password email for a user given its username or e-mail.
Resource URL
POST https://api.socialidnow.com/v1/marketing/login/users/reset_password_email
Parameters
JSON Parameters
username 1 | optional | username. |
---|---|---|
email_address 1 | optional | user e-mail. |
redirect_url | required | the url to redirect the user to inform the new password |
from | optional | the sender email |
logo_url | optional | the logo url to display in the email template |
description | optional | an introductory message to the user |
1 At least one of these fields must be given to identify the user.
Authentication
This API requires Social Login App authentication. See Authentication.
Response
Response Status
created (201) | The email was sent successfully. |
---|---|
unprocessable_entity (422) | Some required parameter was not informed. |
unauthorized (401) | The authentication is wrong. See Authentication. |
internal_server_error (500) | An unknown error happened. |
Examples
Using username
Request
curl -iX POST 'https://api.socialidnow.com/v1/marketing/login/users/reset_password' \ -d '{ "username": "new_user", "redirect_url":"http://www.example.com", "from":"contact@example.com", "logo_url":"http://www.example.com/logo.png", "description":"We received a request to reset your password for Example.com account." }' \ -H 'Content-type: application/json' \ --user 138:e8b9ca24f1b590af67e6271297d6e1f7226625d61c5b5daa1b2f215464e292cf
Response
Response Headers
HTTP/1.1 201 Created Status: 201
Using email_address
Request
curl -iX POST 'https://api.socialidnow.com/v1/marketing/login/users/reset_password' \ -d '{ "email_address": "new_user@user_domain.com", "redirect_url":"http://www.example.com", "from":"contact@example.com", "logo_url":"http://www.example.com/logo.png", "description":"We received a request to reset your password for Example.com account." }' \ -H 'Content-type: application/json' \ --user 138:e8b9ca24f1b590af67e6271297d6e1f7226625d61c5b5daa1b2f215464e292cf
Response
Response Headers
HTTP/1.1 201 Created Status: 201