How to use the Anymail Email Finder API in Google Sheets

Here’s a quick tutorial showing you how to find and verify/validate email addresses in Google Sheets using the Anymail finder API and the Apipheny API integrator.

You can use the Anymail finder API to look up email addresses, for example, if you plan on cold emailing people for sales or lead generation.

Here’s the steps we’ll be covering in this tutorial:

  1. Install the Apipheny API integrator for Google Sheets
  2. Sign up for Anymail Finder
  3. Get your API key
  4. Enter your API request in Apipheny and run the request

Step 1.) Install the Apipheny API integrator

To find and verify email addresses directly in our Google Sheets, we need to connect the Anymail Finder API to your Google Sheet. An API is just a data pipeline between two softwares, and we can use an API to make the Anymail finder software talk to the Google Sheets software.

To connect an API to Google Sheets, we first need to install Apipheny. Apipheny is an API integrator add-on for Google Sheets. Click here for more info. Apipheny is free for 30 days, then $19-29/month.

To install Apipheny, just click the following link and then click the “Install” button on the next page: https://gsuite.google.com/marketplace/app/apipheny/966163326746

2. After you’ve installed Apipheny, open a Google Sheet and then click on the Add-Ons option in the top menu. In the add-ons menu, you should see Apipheny. Click Apipheny > Import API to open the Apipheny sidebar in your Google Sheets.

Opening Apipheny
Opening Apipheny

Step 2.) Sign up for Anymail finder

Anymail finder is one of the most popular email address finders because Anymail finder is focused on returning only verified email addresses.

The Anymail finder REST API has 3 POST endpoints you can query:

  1. Look up someone’s email address from their name and domain
  2. Validate/verify email addresses
  3. Find email addresses from any url or company name

Click here to create an account and sign up for Anymail finder, if you haven’t already.

After you’ve signed up, you need to verify your email address by clicking the link in your email. Once you verify you email and log in, you’ll be asked to choose a payment plan, or you can choose the “Free Trial” button, which will give you 20 free credits so you can try it out before committing to a paid plan.

Step 3.) Get your API key

Okay, now that you’ve signed up for your Anymail finder account, you need to get your API key.

To get your API key, click the “My Account” button, then click “API” in the left menu, then click “Enable API”:

Enable Anymail Finder API
Enable Anymail Finder API

After you click Enable API, you’ll see your API key. Just copy and paste your API key somewhere safe because you’re going to need it in a moment.

Step 4.) Enter your API request into Apipheny and run the request

As I mentioned in Step 2, the Anymail Finder API has 3 POST endpoints that you can query.

Now I’m going to show you how to query all three endpoints by entering your API request into Apipheny then just run the request by clicking the “Run” button at the bottom of the Apipheny add-on.

Click here to read the Anymail finder API documentation.

1. Look up a persons email address

Method: POST

API URL: https://api.anymailfinder.com/v4.0/search/person.json

Headers:

Key: X-Api-Key
Value: The API key from your account

POST Body:

{
"full_name": "Tim Cook",
"company_name": "Apple"
}

Just replace “Tim Cook” and “Apple” with the person and company you want to actually search for.

Parameters you can use for this endpoint:

FieldTypeDescription
full_nameStringThe full name of the person you’re searching for
first_nameStringThe first name of the person to you’re searching for
last_nameStringThe last name of the person you’re searching for
domainStringThe domain of the company to search the email at
company_nameStringThe name of the company to search the email at

Either full_name or both first_name and last_name are required. You must also use either the domain or company_name parameter in your POST body.

Here’s what the API request should look like in Apipheny:

Anymail finder API request entered in Apipheny
Anymail finder API request entered in Apipheny

Then just click the “Run” button at the bottom of the Apipheny add-on and the results of your API request will populate in your Google Sheet.

2. Validate an email address

Method: POST

API URL: https://api.anymailfinder.com/v4.0/validate.json

Headers:

Key: X-Api-Key
Value: The API key from your account

POST Body:

{
"email": "tim@apple.com"
}

Just replace “tim@apple.com” with the email address you actually want to search.

3. Find email addresses by company name

Method: POST

API URL: https://api.anymailfinder.com/v4.0/search/company.json

Headers:

Key: X-Api-Key
Value: The API key from your account

POST Body:

{
"domain": "acme.com"
}

For this request, domain or company name is required.

FieldTypeDescription
domainStringThe domain (URL) to search for emails
company_nameStringThe company name to search for emails at

4. Find email addresses by job title

Method: POST

API URL: https://api.anymailfinder.com/v4.1/search/employees.json

Headers:

Key: X-Api-Key
Value: The API key from your account

POST body:

{
"domain": "acme.com"
"job_title": "co-founder"
}

Just replace the domain and job title with the domain and job title you actually want to search for.

Create API request based on value(s) entered in spreadsheet

If you want to make an API request to the Anymail finder API based on the value of a cell in your spreadsheet, you can replace the name or email address in your POST body with {{{Sheet1!A1}}}.

For example, let’s say you have an email address or a name entered in Sheet 1 cell A1 of your Google Sheet. You can reference that cell in your POST body by wrapping the sheet and cell value with 3 curly braces, like this: {{{Sheet1!A1}}}.

Example POST body with variable entered:

{
"full_name": "{{{Sheet1!A1}}}",
"company_name": "Apple"
}

So when making this API request, the value of Sheet 1 cell A1 will be referenced for the “full_name” parameter. You could do the same with the company name, domain, or email parameters.

Final words

That’s how you can use the Apipheny API integrator to make POST API request to the Anymail finder API to search for and validate email addresses.

If you want to learn more about the Anymail finder API, click here to read the full documentation.

Related articles:

Related Posts

Leave a Comment