Hi, I have two zaps set up. One is that after moving a card in Trello to the appropriate list, Zapier triggers a search for a phone number using the text "Customer Contact" and if there is a phone number, it sends an SMS via Twilio, if there is no phone number, it stops. The second is the same, but it looks for an email address, if there is, it sends an email from Gmail, if there is not, it stops. The problem is that it does not always work, and we always add the same "Customer Contact:" and the number or email. Zap works sometimes, sometimes it does not. Please help, the problem may lie in the pattern, but I do not know how to solve it.
Trigger for send SMS Kontakt klienta:\s*(\+?\d{1,3}\s?\d{3}\s?\d{3}\s?\d{3})
Trigger for send e-mail Kontakt klienta:\s*(\a-zA-Z0-9._%+-]+@-a-zA-Z0-9.-]+\.]a-zA-Z]{2,})
Hi there
Hmm, the regex pattern used for the phone numbers seem to be looking for numbers in only one format (e,g. +123 456 789 012). If the phone numbers you’re attempting to extract don’t always get added in that same exact format, then that could be why the regex pattern isn’t extracting the phone number.
You could try changing your Formatter action to use the following regex pattern, which should help it to pick up phone numbers that are supplied in different formats:
\+?\d{1,3}>\s.-]?\(?\d{2,4}\)?.\s.-]?\d{3,4}\\s.-]?\d+
That said, you could try using Formatter’s Extract Phone Number transform. Similarly for the email addresses, you could use Formatter’s Extract Email Address transform:
These would not require you to input a specific regex pattern. You can learn more about those actions here: Extract data in Zaps
Can you give them a try and let us know if they work better?
Hey
If you’re still stuck at all, just let me know—want to make sure you’re all set!
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.