Customer API Verified Email

Solved
New Member
5 0 0

Hello, I've been using Shopify's customer API and been running some test, I created a fake account and it when I call the endpoint customers it returns this:

"customer": {"id": 2558592745538,"email": "ddddddd@ff.com","accepts_marketing": true,"created_at": "2019-10-14T15:34:12-04:00","updated_at": "2019-10-14T15:35:05-04:00","first_name": "Carlos","last_name": "Desarrollo","orders_count": 0,"state": "enabled","total_spent": "0.00","last_order_id": null,"note": "","verified_email": true,"multipass_identifier": null,"tax_exempt": false,"phone": "+18095555555","tags": "approved","last_order_name": null,"currency": "DOP"

 

"email": "ddddddd@ff.com" is a fake email yet it returns under "verified_email" = true.

 

Why is this? how could I fix it?

0 Likes
Shopify Staff
Shopify Staff
202 23 22

 

Hi @cramipeg 

 

Shopify validates emails in two ways, first with valid form and syntax. Next, we validate that the domain has a valid MX record. You can check these emails through one of the many online MX record lookups. Although you have made this email up, the domain does actually have MX records and therefore is able to be delivered mail. Without an MX record, there would be a certain failure, so this is the one main area we are checking for email.

Vix | Developer Support @ Shopify
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Click Accept as Solution 


0 Likes
New Member
5 0 0

Hi Vix, thanks for answering yet when reading the documentation of the customers API it says that: 

"verified_email": true :  Whether the customer has verified their email address.

Also this is the same answer a developer from an APP I'm using gave me, that verified_email it's set to true when the customer verifies their email by clicking the "verify button" in the email that they get when registering in a store, if we go by your answer(I know that's they way is actually working right now) then this button does nothing.  

0 Likes
Highlighted

Success.

Shopify Staff
Shopify Staff
202 23 22

 

Hi @cramipeg 

 

Apologies, I thought you were asking about email validation vs. the verified_email field. verified_email is almost always true — it is only false when a new customer is created by signing up for an account on the storefront and hasn’t yet clicked the account activation/password reset link in their email. This means that customers created through the admin or the API will return true. I will update the docs for clarification. 

Vix | Developer Support @ Shopify
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Click Accept as Solution 


0 Likes