Airtable-to-HubSpot Contact Sync Agent Setup Guide
What This Agent Does
This powerful automation agent synchronizes contact records from Airtable directly into HubSpot, automatically creating or updating companies and contacts based on email domain matching. Running on a customizable schedule, it eliminates manual data entry, ensures your CRM stays current, and creates a seamless bridge between your spreadsheet data and HubSpot's robust contact management system.
Key benefits include:
-
Automatic synchronization that runs on your schedule (hourly, daily, weekly, or custom intervals)
-
Intelligent company matching using email domain extraction to find or create companies in HubSpot
-
Time savings of 5-10 hours per week for teams managing contacts across multiple platforms
-
Error prevention through automated status tracking and conditional logic
-
Scalability to handle hundreds of contacts without manual intervention
Ideal use cases:
- Marketing teams syncing lead lists from Airtable forms into HubSpot
- Sales operations automating contact database updates
- Customer success teams maintaining accurate contact information across platforms
- Multi-source data consolidation into a single CRM source of truth
Who Is It For
This agent is perfect for growing teams that use both Airtable and HubSpot but want to eliminate the tedious manual work of copying contacts between platforms. You'll benefit most if you:
- Manage contact lists in Airtable (forms, databases, or imported CSVs)
- Need real-time or scheduled synchronization to HubSpot
- Want to automatically organize contacts by company
- Have team members who shouldn't manually access HubSpot
- Need audit trails showing which records were synced and when
No advanced technical skills required—this guide walks you through every step!
Required Integrations
Airtable
Why it's needed: Airtable serves as your source data repository. This agent reads contact records from your Airtable base and updates their sync status, creating a complete audit trail of what was processed.
Setup steps:
-
Access your Airtable workspace and identify the base containing your contact records
-
Locate your Base ID by opening your base and copying the ID from the URL (format:
appXXXXXXXXXXXXXX)
-
Identify your table name where contacts are stored (e.g., "Leads," "Contacts," "Prospects")
-
Note your column names that will be used:
- Email address column (required for domain extraction)
- First name and last name columns (for contact creation)
- Status column (for sync tracking—we recommend "Sync Status")
-
Generate a Personal Access Token:
- Go to airtable.com/account/tokens
- Click "Create token"
- Grant scopes:
data.records:read, data.records:write, schema.bases:read
- Copy the token immediately (you won't see it again)
Configuration in TaskAGI:
- Navigate to Integrations → Airtable
- Click Add New Connection
- Paste your Personal Access Token
- Name the connection (e.g., "Airtable Production")
- Click Test Connection to verify access
- Save and you're ready to configure nodes!
HubSpot
Why it's needed: HubSpot is your destination CRM. This agent creates companies based on email domains and creates or updates contacts with complete information, keeping your sales pipeline organized and current.
Setup steps:
-
Access your HubSpot account with admin privileges
-
Navigate to Settings → Integrations → Private Apps
-
Create a new private app:
- Click "Create app"
- Name it "TaskAGI Sync" (or your preference)
- Go to the Scopes tab
-
Grant required scopes:
- Under "CRM" section, enable:
-
crm.objects.companies.read
-
crm.objects.companies.write
-
crm.objects.contacts.read
-
crm.objects.contacts.write
- Click Save
-
Generate access token:
- Go to the Auth tab
- Click "Show token"
- Copy the token (starts with
pat-)
-
Install the app and confirm permissions
Configuration in TaskAGI:
- Navigate to Integrations → HubSpot
- Click Add New Connection
- Paste your private app access token
- Name the connection (e.g., "HubSpot Production")
- Click Test Connection to verify access
- Save and proceed to workflow configuration
Configuration Steps
Node 1-3: Information & Planning (Documentation Nodes)
These three notes help document your workflow. Fill them in for team clarity:
-
Agent Name Options: Enter a descriptive name like "Airtable Leads to HubSpot Sync"
-
Category & Industry: Specify "Sales Operations" or "Marketing Automation"
-
Workflow Overview: Write a brief description of what this agent does for your team
Node 4: Schedule Trigger Configuration
This node determines when your sync runs.
Configuration:
-
Trigger Type: Select "Schedule Interval"
-
Frequency options:
-
hourly - Syncs every hour (best for high-volume leads)
-
daily - Syncs once per day at specified time (recommended for most teams)
-
weekly - Syncs once per week (good for batch processing)
- Custom cron expression for advanced scheduling
Example: For daily syncs at 2 AM, set frequency to daily and time to 02:00
Node 5: Get Ready to Sync Records (Airtable Query)
This node retrieves all records from your Airtable base that need syncing.
Configuration:
-
Connection: Select your Airtable connection
-
Base ID: Paste your base ID (e.g.,
appXXXXXXXXXXXXXX)
-
Table Name: Enter your table name (e.g.,
Leads)
-
Filter Formula (optional): Use Airtable formula syntax to sync only certain records
- Example:
{Sync Status} = "Pending" (only syncs records marked as pending)
- Example:
{Email} != BLANK() (only syncs records with email addresses)
-
Output variable name: Set to
records for reference in later nodes
Node 6: Check Records Found (Conditional Logic)
This node validates that records exist before processing.
Configuration:
-
Condition:
records.length > 0
-
True path: Proceeds to sync (Node 8)
-
False path: Skips to completion (Node 7)
Node 7: No Records to Process (No Operation)
A placeholder node when no records need syncing. No configuration needed.
Node 8: Update Status to Syncing (Airtable Update)
This node marks records as "in progress" before processing begins.
Configuration:
-
Connection: Select your Airtable connection
-
Base ID & Table Name: Same as Node 5
-
Record ID: Use
records[0].id (or loop through records if available)
-
Fields to Update:
-
Sync Status: Set to "Syncing"
-
Last Sync Attempt: Set to NOW()
Node 9: Extract Email Domain (Function Node)
This node extracts the domain from email addresses (e.g., "john@acme.com" → "acme.com").
Configuration:
-
Function Type: JavaScript
-
Input:
records[0].fields.Email (adjust column name as needed)
-
Code example:
const email = input.email;
const domain = email.split('@')[1].toLowerCase();
return { domain: domain };
-
Output variable:
emailDomain
Node 10: Search Company by Domain (HubSpot Search)
This node searches HubSpot for an existing company matching the email domain.
Configuration:
-
Connection: Select your HubSpot connection
-
Search Type: Domain search
-
Domain: Use
emailDomain from Node 9
-
Output variable:
companySearchResult
Node 11: Check Company Found (Conditional Logic)
This node determines whether to create a new company or use the existing one.
Configuration:
-
Condition:
companySearchResult.length > 0
-
True path: Company exists (Node 13)
-
False path: Create new company (Node 12)
Node 12: Create Company (HubSpot Create)
This node creates a new company when no match is found.
Configuration:
-
Connection: Select your HubSpot connection
-
Company Name: Use
emailDomain or extract from email
-
Domain Name: Use
emailDomain
-
Output variable:
newCompany
Node 13: Merge Company Paths (Merge Node)
This node consolidates both paths (existing or newly created company).
Configuration:
-
Merge Type: Combine results
-
Input 1:
companySearchResult (from Node 11 true path)
-
Input 2:
newCompany (from Node 12)
-
Output variable:
selectedCompany
Node 14: Get Company ID (Function Node)
This node extracts the company ID for use in contact creation.
Configuration:
-
Function Type: JavaScript
-
Code:
const company = input.company;
const companyId = company.id || company.hs_object_id;
return { companyId: companyId };
-
Output variable:
companyId
Node 15: Create or Update Contact (HubSpot Upsert)
This node creates new contacts or updates existing ones in HubSpot.
Configuration:
-
Connection: Select your HubSpot connection
-
Email: Use
records[0].fields.Email
-
First Name: Use
records[0].fields.FirstName
-
Last Name: Use
records[0].fields.LastName
-
Company ID: Use
companyId from Node 14
-
Additional fields: Map any other Airtable columns to HubSpot properties
-
Output variable:
contactResult
Node 16: Update Airtable Success (Airtable Update)
This node marks the record as successfully synced.
Configuration:
-
Connection: Select your Airtable connection
-
Base ID & Table Name: Same as Node 5
-
Record ID: Use
records[0].id
-
Fields to Update:
-
Sync Status: Set to "Synced"
-
Last Sync Date: Set to NOW()
-
HubSpot Contact ID: Set to contactResult.id (for reference)
Node 17: Sync Complete (No Operation)
Final placeholder node indicating successful completion. No configuration needed.
Testing Your Agent
Step 1: Prepare Test Data
-
Create a test record in your Airtable base with:
- Valid email address (e.g., test@company.com)
- First and last name
- Sync Status set to "Pending"
-
Verify the company domain doesn't already exist in HubSpot (or note the existing company ID)
Step 2: Execute Test Run
- Navigate to your workflow in TaskAGI
- Click Test Execution or Run Now
- Monitor the execution in real-time
Step 3: Verify Each Step
Check Node 5 (Get Records):
- Confirm your test record appears in the output
- Verify all required fields are present
Check Node 10 (Search Company):
- Confirm the domain was extracted correctly
- Note whether company was found or not
Check Node 12 or 13 (Company Creation/Selection):
- Verify correct company ID in output
- Check HubSpot to confirm company exists
Check Node 15 (Contact Creation):
- Confirm contact was created/updated in HubSpot
- Verify all fields mapped correctly
Check Node 16 (Airtable Update):
- Return to Airtable and confirm Sync Status changed to "Synced"
- Verify Last Sync Date was updated
- Check HubSpot Contact ID field is populated
Step 4: Success Indicators
✅ Your agent is working correctly when:
- All nodes execute without errors (green checkmarks)
- Airtable record status changes to "Synced"
- Contact appears in HubSpot with correct company association
- Execution completes in under 30 seconds
- No duplicate contacts are created on subsequent runs
Step 5: Production Deployment
-
Test with multiple records (5-10 test records)
-
Verify no duplicates are created when running multiple times
-
Check field mappings are accurate for your use case
-
Enable the schedule trigger to activate automatic syncing
-
Monitor first week of automated runs for any issues
Congratulations! Your Airtable-to-HubSpot sync agent is now live and working to streamline your contact management! 🎉