Country code issue - Whatsapp notification

I setup whatsapp notification for shopify orders so its sent to customers. I put the country code infront of the phone number variable so it becomes in the correct format for whatsapp but some customers also enter thier country code in the checkout form which makes it a problem. How can remove a certain country code if it's already in the phone address?
 

Preeti Paryani

Well-known member
Staff member
Hello @ahmadalkhudairi,

You can use the Number Formatter: Spreadsheet Formula action to extract only the phone number, regardless of whether it includes the country code or not. This will ensure a consistent format.

Once the number is extracted, you can manually add the static country code before mapping the formatted number in the Send Message action. This way, even if customers enter their country code during checkout, it won’t interfere with your message formatting.

1738323018863.png


Let us know if you need further assistance!
 
Top