When a customer starts the checkout process he has to fill his email address, shipping address and then click "continue".
Plus he has a checkbox to "subscribe to updates and deals"
now after this step, Shopify will send a webhook for new customer created.
Just to note the problem is in case the user doesn't complete the checkout.
Now the problem:
- the user checked the "accepts marketing" checkbox
- the user submits to the next step
- user doesn't complete the full checkout
- Shopify send a customer webhook with the email and address
- the user object on the webhook has "accepts_marketing" as FALSE even though the customer checked it as he accepts marketing.
Is there a reason for that? or its a bug on Shopify?
Solved! Go to the solution
This is an accepted solution.
I believe this is to be expected. When they begin the order, the customer creation is completed and the webhook is fired off with accepts_marketing false. If the customer completes the order, this will be updated to a truthy state, otherwise it will stay as false.