How do I fetch email pattern from a website on Hunter.io?

#1

How would I use dashdash to receive email patterns from Hunter.io?

Lead generation: Get the name and email of people with 'job title' at 'company'. Use Mattermark and Hunter.io APIs
#2

I would also like to be able to input the first name and last name of a contact and receive the email address of the contact in the form of the pattern. Is this possible?

#3

Hello @michael.hayes

Great questions. To receive email patterns from hunter.io, you can follow these steps:

1. Fetch an API Key

Grab an API from hunter.io.

2. Perform a domain search

A1: 400a831434ba40...    (your API Key)
A2: www.bookatiger.com       (the domain you want to fetch the email pattern from)
A3: =GET("https://api.hunter.io/v2/domain-search?domain="&A2&"&api_key="&$A$1)

3. Extract the domain pattern

A3 will receive the response from hunter.io. To extract the pattern you need to pick up properties pattern and domain (shortened), so you should add:

A4: =parse(A3,"data.pattern")&"@"&parse(A3,"data.domain")

A4 will output {first}@bookatiger.com, which is your pattern.

4. Find an email for a person.

Additionally, you can check if a particular email works:

A5: John    (first name)
A6: Lewis   (surname) 
A7: =GET("https://api.hunter.io/v2/email-finder?domain="&A2&"&first_name="&A5&"&last_name="&A6&"&api_key="& $A$1)
A8: =parse(A7,"data.email")

A8 will return john@bookatiger.com.

You could also avoid doing another web request and just have used the email pattern to extract first name, last name, first letter of first name, etc etc, but that’s not so much fun.

5. Verify deliverability of an email

Finally, you may want to check if the proposed email will work. Hunter.io also has a service for that.

A9: =get("https://api.hunter.io/v2/email-verifier?email="&A8&"&api_key="&$A$1)
A10: =parse(A9,"data.result")

A10 will return deliverable, meaning that the email is approved.

Important tip: if you’re only interested in checking an email and its deliverability, you only need to do steps 4 and 5!!