Push Snitcher company data to the Google Tag Manager dataLayer, making it available for use in tags, triggers, and variables throughout your GTM container.
Setup Overview
- Configure the Spotter callback to push data to the dataLayer
- Create Data Layer Variables in GTM
- Use those variables in your tags
Step 1: Push Data to dataLayer
Using getSpotterIdentification() (Recommended)
Snitcher.on('initialized', async function() {
const identification = await Snitcher.getSpotterIdentification();
if (identification && identification.success) {
const data = identification.data;
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
event: 'snitcher_identified',
snitcher: {
name: data.name,
domain: data.website,
industry: data.industry,
size: data.size
}
});
}
});
Using Callback (Legacy)
Define SpotterSettings before the Snitcher script loads:
<script>
window.SpotterSettings = {
callback: function(identification) {
// Ignore ISP identifications
if (identification && identification.type !== "isp") {
var company = identification.company;
// Push to dataLayer
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
event: 'snitcher_identified',
snitcher: {
name: company.name,
domain: company.domain,
industry: company.industry,
size: company.employee_range
}
});
}
}
};
</script>
<!-- Snitcher tracking script loads after -->
No API token is required. Spotter uses your tracker’s profile ID for authentication automatically.
Step 2: Create Data Layer Variables in GTM
- Sign in to Google Tag Manager
- Navigate to Variables → User-Defined Variables → New
- Configure each variable:
| Variable Name | Data Layer Variable Name | Version |
|---|
| SnitcherCompanyName | snitcher.name | Version 2 |
| SnitcherCompanyDomain | snitcher.domain | Version 2 |
| SnitcherCompanyIndustry | snitcher.industry | Version 2 |
| SnitcherCompanySize | snitcher.size | Version 2 |
For each variable:
- Click Variable Configuration → Data Layer Variable
- Enter the Data Layer Variable Name from the table
- Set Data Layer Version to Version 2
- Click Save
Step 3: Create a Trigger (Optional)
To fire tags when a company is identified:
- Go to Triggers → New
- Choose Custom Event
- Set Event name to
snitcher_identified
- Save the trigger
Using the Variables
Once configured, use {{"{{SnitcherCompanyName}}"}}, {{"{{SnitcherCompanyIndustry}}"}}, etc. in any tag:
Example: GA4 Event
Create a GA4 Event tag with these event parameters:
| Parameter Name | Value |
|---|
| company_name | {{"{{SnitcherCompanyName}}"}} |
| company_industry | {{"{{SnitcherCompanyIndustry}}"}} |
| company_size | {{"{{SnitcherCompanySize}}"}} |
Example: LinkedIn Insight Tag
Use company data to build retargeting audiences based on company attributes.
Available Data
| Variable | Description |
|---|
snitcher.name | Company name |
snitcher.domain | Primary domain |
snitcher.industry | Industry category |
snitcher.size | Employee range |
You can extend the callback to include additional fields as needed. See Spotter API documentation for the full response structure.