Why use a HubSpot email verification integration?

HubSpot offers some great tools to help marketing and sales teams reach new prospects. However, there's not much you can do if you don't have a valid email address for every contact.

And, while HubSpot will apply some simple rules to ensure every email follows the correct format, it has no way to check if a contact has used a fake or temporary address.

To keep your contact database free from junk and prevent your marketing emails from bouncing, you need a HubSpot email verification integration.

We support integration with HubSpot using Operations Hub or Zapier.

hubspotlogo-web-color

Email address verification for HubSpot Operations Hub

 

With the launch of HubSpot Operations Hub and programmable automation, advanced HubSpot users now have a way to access the Email Hippo MORE email verification API directly within HubSpot workflows.

This can be accomplished using the new "custom code" action.

  1. Sign up to Email Hippo, log in to the Email Hippo App and purchase a subscription to MORE, our API product (or start a free trial)
  2. Grab your MORE API key from your account in Email Hippo’s App
  3. In HubSpot create any additional HubSpot contact fields to store the email validation results
  4. Create a HubSpot workflow that enrols contacts whose emails you wish to verify
  5. Set up a custom code action in the workflow to verify the contact's email using our API 
  6. Add workflow steps to copy the values from the API response into your custom contact properties - you can copy as many or as few as you wish.

 

Below you’ll find an example workflow, new contact properties and custom code which validates new contact email addresses and stores the most popular fields from our MORE API response in Hubspot. 

Example configuration of additional Contact properties in HubSpot

Create additional contact properties for email validation results - part 1 Create additional contact properties for email validation results - part 2

 

Example custom code snippet for HubSpot workflows

Here's an example Python script you can use in a HubSpot workflow to verify a contact's email address.

First, add a Python 3.9 custom code action in your workflow. In the edit tab, create a secret called EHAPI with your Email Hippo API key as the value, and add Email under Property to include in code.

Then, set up data outputs for all the API response values you want to store in HubSpot, such as email validation status, spam assessment and Email Hippo trust score. (You can find the full result record schema here.)

import os
import requests
import json

def main(event):
  
  # Email to validate. Add the contact property Email to your custom code action under "Property to include in code" with the name email
  email_to_validate = event.get('inputFields').get('email')
  
  # URL to make the request. Add your Email Hippo API key to your custom code action as a secret with the name EHAPI
  url = 'https://api.hippoapi.com/v3/more/json/{}/{}'.format(os.getenv('EHAPI'),email_to_validate)
  
  # Request
  try:
    api_response = requests.request('GET', url)
    output = json.loads(api_response.text) 
  except api_response as e:
    print(e)
    # We will automatically retry when the code fails because of a rate limiting error from the HubSpot API.
    raise
  
  # Storing the necessary data in variables
  ea_validation_is_role = output['disposition']['isRole']

  ea_validation_is_freemail = output['disposition']['isFreeMail']

  ea_validation_primary_status = output['emailVerification']['mailboxVerification']['result']

  ea_validation_secondary_status = output['emailVerification']['mailboxVerification']['reason']

  ea_validation_send_assessment = output['sendAssess']['sendRecommendation']

  ea_validation_is_dark_web_email_address = output['spamAssess']['isDarkWebEmailAddress']

  ea_validation_is_gibberish_domain = output['spamAssess']['isGibberishDomain']

  ea_validation_is_gibberish_user = output['spamAssess']['isGibberishUser']

  ea_validation_spam_assessment = output['spamAssess']['actionRecomendation']

  ea_validation_spam_trap_assessment = output['spamTrapAssess']['isSpamTrap']

  ea_validation_eh_trust_score = output['hippoTrust']['score']

  ea_validation_eh_trust_score_level = output['hippoTrust']['level']
    
  ea_validation_infrastructure = output['infrastructure']['mail']['serviceTypeId']

  return {
    'outputFields': {
      'ea_validation_is_role': ea_validation_is_role, 
      'ea_validation_is_freemail': ea_validation_is_freemail,
      'ea_validation_primary_status': ea_validation_primary_status, 
      'ea_validation_secondary_status': ea_validation_secondary_status, 
      'ea_validation_send_assessment': ea_validation_send_assessment, 
      'ea_validation_is_dark_web_email_address': ea_validation_is_dark_web_email_address, 
      'ea_validation_is_gibberish_domain': ea_validation_is_gibberish_domain, 
      'ea_validation_is_gibberish_user': ea_validation_is_gibberish_user, 
      'ea_validation_spam_assessment': ea_validation_spam_assessment, 
      'ea_validation_spam_trap_assessment': ea_validation_spam_trap_assessment, 
      'ea_validation_eh_trust_score': ea_validation_eh_trust_score, 
      'ea_validation_eh_trust_score_level': ea_validation_eh_trust_score_level,
      'ea_validation_infrastructure': ea_validation_infrastructure
    }
  }

Example configuration of custom code panel in HubSpot

Create a custom code action in the workflow and add the code Setup the data outputs

 

Example configuration of workflow in HubSpot

Copy the data outputs from the code to your new contact fields - part 1 Copy the data outputs from the code to your new contact fields - part 2

 

HubSpot email verification with Zapier

Not a developer? No problem! With Zapier, non-developers can easily connect HubSpot to Email Hippo and set up an email verification Zap in a few clicks.

You just need a paid Zapier account and a paid or trial subscription to MORE, our API product.

  1. Connect HubSpot to Zapier using OAuth
  2. Connect Email Hippo to Zapier using your MORE API key
  3. Create a new Zap and set up a trigger from HubSpot (for example, when a contact is created or updated)
  4. Add a step to your Zap "Validate email address" from the Email Hippo app
  5. Add a final step to your Zap to manage the API response (for example, update the contact record)

Talk to us about your integration requirements

Want more information about a popular Email Hippo integration, or want to discuss an integration requirement that isn't covered here? Get in touch today and we'll help you find the best solution for you.

Not yet using Email Hippo for your email verification?

What are you waiting for?

Trial our email verification for freeRegister today for 100 free email validations. No credit card details needed to create your account.