Skip to content

Reset a customer password ​

Endpoint: https://my-store.youcan.shop/api/customers/reset

Method: POST

Sets a new password with the id and token of the reset link. The Recover endpoint sends the link. The reset revokes all tokens of the customer and returns a new one.

Parameters ​

Param NameParam TypeDescriptionRequired
idstringThe id of the reset linkyes
tokenstringThe token of the reset linkyes
passwordstringThe new password, 6 to 72 charactersyes
password_confirmationstringThe same passwordyes

Response ​

[200] OK

json
{
    "token": "1f3c9a…",
    "token_type": "bearer",
    "expires_in": 2592000
}

[422] Unprocessable Entity

json
{
    "status": 422,
    "detail": "The given data was invalid.",
    "meta": {
        "fields": {
            "token": [
                "The reset token is invalid or expired."
            ]
        }
    }
}