Joao Correia
Driving Growth & Innovation With Data

Account-based marketing is changing how B2B companies market and sell their products and services.

The foundation of account-based marketing (ABM) is the identification of potential customers, and their interactions with your digital assets (website, email, apps) to inform marketing/sales strategy.

In this post, I'll cover how to identify your users using Snowplow and Clearbit.

What ABM can do for you

Account-based marketing can help you improve the efficiency of your marketing and sales by creating a better understanding of who your potential customers are and how they use your digital properties.

Here's what ABM can do for you:

ABM adds a previously hidden layer to all digital behavior, the who. Note that ABM primary goal is to identify accounts, not individuals.

Tracking your digital assets

To build a complete view of your potential customers, you need a tool that can track events across your digital assets and a measurement strategy.

Snowplow allows you to track email, websites, applications, display ads, IoT, and pretty much anything that is digital in one single data warehouse, which is critical to create a unified view of the customer.

The measurement strategy should specify the different stages of the customer journey and the track key actions that qualify an account, e.g., download PDF X, read blog post Y, etc.

Identifying customers with Clearbit

As users interact with your digital assets, Snowplow records each event with more than 100 properties, among which is the IP address.

Clearbit Reveal is an API that enriches anonymous visitors to your website with a full company firmographic and technographic profile, based on the visitor IP address.

When integrated with Snowplow, Clearbit enriches your event data with company name, industry, revenue, employees, location, and many others data points.

Below is a partial response from Clearbit API Reveal for an IP address.

  {
    "ip": "72.15.55.102",
    "domain": "shutterstock.com",
    "fuzzy": true,
    "company": {
        "id": "1869aeb1-d94b-4886-a398-8e8730bbda6c",
        "name": "Shutterstock",
        "legalName": "Shutterstock Inc",
        "domain": "shutterstock.com"
        ],
        "site": {
            "phoneNumbers": [
                "+1 866-663-3954",
                "+353 57 868 4757",
                "+1 646-419-4452"
            ],
            "emailAddresses": [
                "privacy@shutterstock.com"
            ]
        },
        "category": {
            "sector": "Information Technology",
            "industryGroup": "Software & Services",
            "industry": "Internet Software & Services",
            "subIndustry": "Internet",
            "sicCode": "73",
            "naicsCode": "54"
        },
        "tags": [
            "Internet",
            "Technology",
            "B2C"
        ],
        ...
        

Configure Clearbit Enrichment With Snowplow

The first step is to get your Clearbit Reveal secret key, the API service that translates IP address to company metadata.

Use the template below, and create a file named api_request_enrichment_config.json and place it in your Snowplow enrichments/ directory.

If you use Redshift or Postgres, you'll need to create the Clearbit company table under the atomic schema. Don't forget to assign ownership of the table to the loader username.

{
  "schema": "iglu:com.snowplowanalytics.snowplow.enrichments/api_request_enrichment_config/jsonschema/1-0-0",

  "data": {
    "enabled": true,
    "vendor": "com.snowplowanalytics.snowplow.enrichments",
    "name": "api_request_enrichment_config",
    "parameters": {
      "inputs": [
        {
          "key": "ipaddress",
          "pojo": {
            "field": "user_ipaddress"
          }
        }
      ],
      "api": {
        "http": {
          "method": "GET",
          "uri": "https://reveal.clearbit.com/v1/companies/find?ip=",
          "timeout": 15000,
          "authentication": {
            "httpBasic": {
              "username": "sk_xxxxxxxxxxxxxxxxxxxxxxx",
              "password": ""
            }
          }
        }
      },
      "outputs": [ 
        {
          "schema": "iglu:com.clearbit.enrichment/company/jsonschema/1-0-0",
          "json": {
            "jsonPath": "$.company"
          }
        }        
      ],
      "cache": {
        "size": 5000,
        "ttl": 86400
      }
    }
  }
}

You're ready! The next time you run Snowplow EMR, or after restarting the enricher if you use the real-time pipeline, Snowplow will lookup each hit IP address and enrich it with the corresponding company data from Clearbit.

You can now query the Snowplow events and Clearbit tables and see who is using your digital assets, and how.

SELECT DATE_TRUNC('day',e.collector_tstamp)::date AS date
      ,c.domain AS company_domain
      ,c.name AS company_name
      ,c."metrics.employees"
      ,e.page_url
      ,e.se_category
      ,e.se_action
      ,e.se_label
      ,e.geo_city
      ,e.geo_country
FROM atomic.events e

LEFT JOIN com_clearbit_enrichment_company_1 c
ON e.collector_tstamp = c.root_tstamp AND e.event_id = c.root_id
  
WHERE (e.app_id = 'igloo' OR e.app_id = 'snwcat')
AND e.event!='page_ping'
  
GROUP BY 1,2,3,4,5,6,7,8,9,10
ORDER BY 1 DESC
  
LIMIT 1000
Example Results

Need help getting started with Snowplow? Contact us.

Share your comments below

Share your view in the comments section below.

Hi,

No Data Engineers? No problem.

START TRIAL Snowcat Cloud, Hosted Snowplow Analytics