Request sign in code
POST
/ store/ v1/ customers/ sign-in-codes- Idempotency-Key supported
Send a six-digit sign-in code (valid 10 minutes) to an email address, or by SMS or WhatsApp to a mobile number. Answers alike whether or not the address belongs to a customer: new ones get an account when they sign in. Limited to three codes per address per ten minutes.
Headers
Idempotency-KeystringSend the same key to retry safely: the first answer is replayed for 24 hours.
shop-api-versionYYYY-MMThe version to answer in. Without it, your app’s pinned version, else the newest.
Body
emailstring · or nullphonestring · or nullAny usual form (
0501234567,+966 50 123 4567), read in the store's country.channelenum · or nullFor a phone:
smsorwhatsapp; the first the store offers when absent.- sms
localestring · or nullLanguage of the message when the customer has none on file (BCP 47).
Returns
202 The code is on its way.
Errors
- 409The store does not send codes on this channel.
- 422
validation_failedMalformed email or phone number. - 429
rate_limitedToo many requests.