Skip to content

Members: Reset Password

michael-e edited this page May 11, 2011 · 9 revisions

Example Error XML:

<members-reset-password result="error">
  <username type="invalid" message="Member not found." label="USERNAME" />
  <email type="invalid" message="Member not found." label="EMAIL" />
  <error type="invalid" message="No Identity field found." />
  <password type="missing" message="PASSWORD is a required field." label="PASSWORD" />
  <password type="invalid" message="PASSWORD is too short. It must be at least CONFIGURED characters." label="PASSWORD" />
  <password type="invalid" message="PASSWORD is not strong enough." label="PASSWORD" />
  <password type="invalid" message="PASSWORD confirmation does not match." label="PASSWORD" />
  <password type="invalid" message="No recovery code found." label="PASSWORD" />
  <error type="invalid" message="No Authentication field found."/>
  <error type="invalid" message="No Identity field found." />
  <post-values>
    <username>Hello</username>
    <email>[email protected]</email>
    <password>
      <recovery-code>fb7bdd247c3e262bb657c1a0722f7c37c7c33fa4</recovery-code>
    </password>
  </post-values>
</members-reset-password>

Example Success XML:

<members-reset-password result="success">
  <post-values>
    <email>[email protected]</email>
    <password>
      <password>HelloPassword</password>
      <confirm>HelloPassword</confirm>
      <recovery-code>70b9a071758b7753552dddf4888664ca8dc2bb73</recovery-code>
    </password>
  </post-values>
</members-reset-password>

Detailed list of possible error responses

Error if no identity field value is found:

<members-reset-password result="error">
  <error type="invalid" message="No Identity field found." />
  <post-values>
    <password>
      <recovery-code>fb7bdd247c3e262bb657c1a0722f7c37c7c33fa4</recovery-code>
    </password>
  </post-values>
</members-reset-password>

Error if username field is used and the member is not found:

<members-reset-password result="error">
  <username type="invalid" message="Member not found." label="USERNAME" />
  <post-values>
    <username>Hellooo</username>
    <password>
      <recovery-code>fb7bdd247c3e262bb657c1a0722f7c37c7c33fa4</recovery-code>
    </password>
  </post-values>
</members-reset-password>

Errors if email field is used and the member is not found:

<members-reset-password result="error">
  <email type="invalid" message="Member not found." label="EMAIL" />
  <post-values>
    <email>[email protected]</email>
    <password>
      <recovery-code>fb7bdd247c3e262bb657c1a0722f7c37c7c33fa4</recovery-code>
    </password>
  </post-values>
</members-reset-password>

Error if username field is used and recovery code is wrong:

<members-reset-password result="error">
  <password type="invalid" message="No recovery code found." label="PASSWORD" />
  <post-values>
    <username>Hello</username>
    <password>
      <recovery-code>70b9a071758b7753552dddf4888664ca8dc2bb73x</recovery-code>
    </password>
  </post-values>
</members-reset-password>

Error if email field is used and recovery code is wrong:

<members-reset-password result="error">
  <password type="invalid" message="No recovery code found." label="PASSWORD" />
  <post-values>
    <email>[email protected]</email>
    <password>
      <recovery-code>70b9a071758b7753552dddf4888664ca8dc2bb73x</recovery-code>
    </password>
  </post-values>
</members-reset-password>

Error if identity field and recovery code are OK but new password is missing:

<members-reset-password result="error">
  <password type="missing" message="PASSWORD is a required field." label="PASSWORD" />
  <post-values>
    <username>Hello</username>
    <password>
      <recovery-code>70b9a071758b7753552dddf4888664ca8dc2bb73</recovery-code>
    </password>
  </post-values>
</members-reset-password>

Error if identity field and recovery code are OK but new password is invalid:

<members-reset-password result="error">
  <password type="invalid" message="PASSWORD is not strong enough." label="PASSWORD" />
  <post-values>
    <username>Hello</username>
    <password>
      <recovery-code>70b9a071758b7753552dddf4888664ca8dc2bb73</recovery-code>
    </password>
  </post-values>
</members-reset-password>

Error if identity field, recovery code and new password are OK but new password confirmation does not match:

<members-reset-password result="error">
<password type="invalid" message="PASSWORD confirmation does not match." label="PASSWORD" />
  <post-values>
    <username>Hello</username>
    <password>
      <recovery-code>70b9a071758b7753552dddf4888664ca8dc2bb73</recovery-code>
    </password>
  </post-values>
</members-reset-password>
Clone this wiki locally