Skip to content

Request password reset

POST
/api/website/customers/password/forgot
curl --request POST \
--url https://api.petanqueai.com/api/website/customers/password/forgot \
--header 'Content-Type: application/json' \
--header 'x-storefront-token: <x-storefront-token>' \
--data '{ "email": "hello@example.com", "resetUrl": "example" }'

Emails a reset link if the address has an account. It always answers 202 so it cannot be used to find out which addresses are registered.

resetUrl is the page on your site that receives the link (?token=… is appended); its origin must be on your allowed origins. The link is valid for 1 hour.

object
email
required
string format: email
<= 200 characters
resetUrl
required
string
>= 1 characters <= 2048 characters

Example generated

{
"email": "hello@example.com",
"resetUrl": "example"
}