HubSpot-LinkedIn Agent
An agent-based system that monitors HubSpot for recently modified contacts, fetches enriched data from LinkedIn, and updates HubSpot automatically.
Last updated
Was this helpful?
An agent-based system that monitors HubSpot for recently modified contacts, fetches enriched data from LinkedIn, and updates HubSpot automatically.
Last updated
Was this helpful?
Automate customer relationship management, internal company management, etc. with the ! Scale inference using the Lilypad network deploying any of the models supported by the .
This workflow serves as a proof of concept (PoC) illustrating the capabilities of agents to interface with platform APIs, specifically those of HubSpot and RapidAPI.
Github repo .
A guide to launch the HubSpot-LinkedIn agent locally and run inference on the Lilypad Network with the .
Python 3.8+
A HubSpot account with a Private App token
Steps: Log in > Settings > Integrations > Private Apps > Create private app > Name it > Scopes: crm.objects.contacts
(read/write contacts) > Create app > Click app name > Auth tab > View access token > Copy token
A RapidAPI account with a LinkedIn Data API key
Steps: Create an account > Subscribe to > Go to > Select "default-application" > Copy "Application Key"
An OpenAI-compatible API
(Sign up and generate an API key)'
Choose the model you would like to use
Clone the Repository
Install Dependencies
Note: If requirements.txt
is missing, install:
Configure Environment Variables
Create a .env
file:
Add your keys:
Start the Daemon
Checks HubSpot every minute for contacts modified in the last 7 days (or since last_processed.json
).
Fetches LinkedIn data and updates HubSpot.
Runs for 5 minutes (adjustable in main.py
).
Monitor Logs
Look for "Found X contacts", "HubSpot update: ...", "Attempting to save last_processed timestamp".
If no contacts are found, last_processed.json
won’t save—edit a HubSpot contact to test.
main.py
: Entry point and daemon logic.
/tools/hubspot_tools.py
: HubSpot API utilities (fetch/update contacts).
/tools/linkedin_tools.py
: LinkedIn API utility (fetch profile data).
/agents/hubspot_agent.py
: Agent for updating HubSpot.
/agents/linkedin_agent.py
: Agent for fetching LinkedIn data.