Hubspot -> Salesforce - 최종판
이것은Sales, AI분야의자동화 워크플로우로, 11개의 노드를 포함합니다.주로 Code, Merge, Filter, Hubspot, Salesforce 등의 노드를 사용하며인공지능 기술을 결합하여 스마트 자동화를 구현합니다. Explorium.ai를 사용한 HubSpot에서 Salesforce로의 연락처 정보 강화 자동화
- •HubSpot API Key
- •Salesforce OAuth 인증 정보
- •대상 API의 인증 정보가 필요할 수 있음
{
"id": "A1ANYPPCR58x29nH",
"meta": {
"instanceId": "0a70652f43c1b29dd16c35b61a38fd31c8004f58bc7e723bf43262a797407c77",
"templateCredsSetupCompleted": true
},
"name": "Hubspot -> Salesforce - final",
"tags": [],
"nodes": [
{
"id": "306813bf-056d-48fc-ba8b-e64ddb01beda",
"name": "Match_prospect",
"type": "n8n-nodes-base.httpRequest",
"position": [
-1820,
360
],
"parameters": {
"url": "https://api.explorium.ai/v1/prospects/match",
"method": "POST",
"options": {},
"jsonBody": "={\n \"prospects_to_match\": [\n {\n \"full_name\": \"{{ ($json.properties.firstname.value || '') + ' ' + ($json.properties.lastname.value || '') }}\",\n \"company_name\": \"{{ ($json.properties.company.value || '').trim() }}\",\n \"email\": \"{{ $json['identity-profiles'][0].identities.find(id => id.type === 'EMAIL').value }}\"\n }\n ]\n}",
"sendBody": true,
"jsonHeaders": "{\n \"Content-Type\": \"application/json\",\n \"Accept\": \"application/json\"\n}",
"sendHeaders": true,
"specifyBody": "json",
"authentication": "genericCredentialType",
"specifyHeaders": "json",
"genericAuthType": "httpHeaderAuth"
},
"credentials": {
"httpHeaderAuth": {
"id": "85mkGmNNdK1951hF",
"name": "Header Auth Connection"
}
},
"typeVersion": 4.2
},
{
"id": "08e9aa3a-6957-4f88-9ad7-f492652046e4",
"name": "Extract Prospect IDs from Matched Results",
"type": "n8n-nodes-base.code",
"position": [
-1380,
360
],
"parameters": {
"jsCode": "const allItems = $input.all();\nconst prospectIds = allItems.map(item => \n item.json.matched_prospects.map(prospect => prospect.prospect_id)\n).flat();\n\nreturn [{\n json: {\n prospect_ids: prospectIds\n }\n}];"
},
"typeVersion": 2
},
{
"id": "e786a130-996c-414a-b87c-aec3a61a960e",
"name": "Explorium Enrich Contacts Information",
"type": "n8n-nodes-base.httpRequest",
"position": [
-1160,
260
],
"parameters": {
"url": "https://api.explorium.ai/v1/prospects/contacts_information/bulk_enrich",
"method": "POST",
"options": {},
"jsonBody": "={{ { \"prospect_ids\": $json.prospect_ids } }}",
"sendBody": true,
"jsonHeaders": "{\n \"Content-Type\": \"application/json\",\n \"Accept\": \"application/json\"\n}",
"sendHeaders": true,
"specifyBody": "=json",
"authentication": "genericCredentialType",
"bodyParameters": {
"parameters": [
{}
]
},
"specifyHeaders": "json",
"genericAuthType": "httpHeaderAuth"
},
"credentials": {
"httpHeaderAuth": {
"id": "85mkGmNNdK1951hF",
"name": "Header Auth Connection"
}
},
"typeVersion": 4.2
},
{
"id": "205c6a21-e0fd-4963-aacf-8498eba0e838",
"name": "병합",
"type": "n8n-nodes-base.merge",
"position": [
-940,
360
],
"parameters": {
"mode": "combine",
"options": {},
"fieldsToMatchString": "data[0].prospect_id"
},
"typeVersion": 3.1
},
{
"id": "faa070fd-841b-460c-b25f-0e3bed266f17",
"name": "HubSpot Trigger",
"type": "n8n-nodes-base.hubspotTrigger",
"position": [
-2260,
360
],
"webhookId": "d359fd68-9568-4787-93dd-192be0fda279",
"parameters": {
"eventsUi": {
"eventValues": [
{}
]
},
"additionalFields": {}
},
"credentials": {
"hubspotDeveloperApi": {
"id": "MpQJKDhz8ijUUHzc",
"name": "HubSpot Developer account"
}
},
"typeVersion": 1
},
{
"id": "76b419d5-f31d-4657-8157-a26d83564b2d",
"name": "HubSpot",
"type": "n8n-nodes-base.hubspot",
"position": [
-2040,
360
],
"parameters": {
"contactId": {
"__rl": true,
"mode": "id",
"value": "={{ $input.item.json.contactId }}"
},
"operation": "get",
"authentication": "appToken",
"additionalFields": {}
},
"credentials": {
"hubspotAppToken": {
"id": "cBozD4139iWohcJ2",
"name": "HubSpot App Token account"
}
},
"typeVersion": 2.1
},
{
"id": "17e5e938-690b-41f0-b9b1-10981f109f20",
"name": "Salesforce",
"type": "n8n-nodes-base.salesforce",
"position": [
-500,
360
],
"parameters": {
"company": "={{ $json.experience[0].company.name }}",
"lastname": "={{ $json.full_name }}",
"additionalFields": {
"city": "={{ $json.city || null }}",
"email": "={{ $json.professions_email || null }}",
"phone": "={{ $json.phone_numbers?.[0]?.phone_number || \"null\" }}\n",
"state": "={{ $json.region_name || '' }}",
"title": "={{ $json.experience?.[0]?.title?.name || null }}",
"country": "={{ $json.country_name || null }}",
"website": "={{ $json.experience?.[0]?.company?.website || null }}",
"mobilePhone": "={{ $json.mobile_phone }}"
}
},
"credentials": {
"salesforceOAuth2Api": {
"id": "unhmsSbB64eNwCMO",
"name": "Salesforce account"
}
},
"typeVersion": 1
},
{
"id": "53699185-4fe8-4add-8b6f-4825e481dcf3",
"name": "코드 - flatten",
"type": "n8n-nodes-base.code",
"position": [
-720,
360
],
"parameters": {
"jsCode": "return $input.all().map(item => \n item.json.data.map(prospect => ({\n prospect_id: prospect.prospect_id,\n ...prospect.data\n }))\n ).flat()"
},
"typeVersion": 2
},
{
"id": "a39d10c7-e80e-4493-a555-f1fe36216c59",
"name": "메모",
"type": "n8n-nodes-base.stickyNote",
"position": [
-3320,
80
],
"parameters": {
"width": 960,
"height": 2800,
"content": "# Automatically enrich prospect data from HubSpot using Explorium and create leads in Salesforce\n\nThis n8n workflow streamlines the process of enriching prospect information by automatically pulling data from HubSpot, processing it through Explorium's AI-powered tools, and creating new leads in Salesforce with enhanced prospect details.\n\n## Credentials Required\n\nTo use this workflow, set up the following credentials in your n8n environment:\n\n### HubSpot\n- **Type**: App Token (or OAuth2 for broader compatibility)\n- **Used for**: triggering on new contacts, fetching contact data\n\n### Explorium API\n- **Type**: Generic Header Auth\n- **Header**: Authorization\n- **Value**: Bearer YOUR_API_KEY\n\n### Salesforce\n- **Type**: OAuth2 or Username/Password\n- **Used for**: creating new lead records\n\nGo to Settings → Credentials, create these three credentials, and assign them in the respective nodes before running the workflow.\n\n## Workflow Overview\n\n### Node 1: HubSpot Trigger\nThis node listens for real-time events from the connected HubSpot account. Once triggered, the node passes metadata about the event to the next step in the flow.\n\n### Node 2: HubSpot\nThis node fetches contact details from HubSpot after the trigger event.\n\n- **Credential**: Connected using a HubSpot App Token\n- **Resource**: Contact\n- **Operation**: Get Contact\n- **Return All**: Disabled\n\nThis node retrieves the full contact details needed for further processing and enrichment.\n\n### Node 3: Match prospect\nThis node sends each contact's data to Explorium's AI-powered prospect matching API in real time.\n\n- **Method**: POST\n- **Endpoint**: https://api.explorium.ai/v1/prospects/match\n- **Authentication**: Generic Header Auth (using a configured credential)\n- **Headers**: Content-Type: application/json\n\nThe request body is dynamically built from contact data, typically including: full_name, company_name, email, phone_number, linkedin. These fields are matched against Explorium's intelligence graph to return enriched or validated profiles.\n\n**Response Output**: total_matches, matched_prospects, and a prospect_id. Each response is used downstream to enrich, validate, or create lead information.\n\n### Node 4: Filter\nThis node filters the output from the Match prospect step to ensure that only valid, matched results continue in the flow. Only records that contain at least one matched prospect with a non-null prospect_id are passed forward.\n\n**Status**: Currently deactivated (as shown by the \"Deactivate\" label)\n\n### Node 5: Extract Prospect IDs from Matched Results\nThis node extracts all valid prospect_id values from previously matched prospects and compiles them into a flat array. It loops over all matched items, extracts each prospect_id from the matched_prospects array and returns a single object with an array of all prospect_ids.\n\n### Node 6: Explorium Enrich Contacts Information\nThis node performs bulk enrichment of contacts by querying Explorium with a list of matched prospect_ids.\n\n**Node Configuration:**\n- **Method**: POST\n- **Endpoint**: https://api.explorium.ai/v1/prospects/contacts_information/bulk_enrich\n- **Authentication**: Header Auth (using saved credentials)\n- **Headers**: \"Content-Type\": \"application/json\", \"Accept\": \"application/json\"\n\nReturns enriched contact information, such as:\n- **emails**: professional/personal email addresses\n- **phone_numbers**: mobile and work numbers\n- **professions_email**, **professional_email_status**, **mobile_phone**\n\n### Node 7: Explorium Enrich Profiles\nThis additional enrichment node provides supplementary contact data enhancement, running in parallel with the primary enrichment process.\n\n### Node 8: Merge\nThis node combines multiple data streams from the parallel enrichment processes into a single output, allowing you to consolidate data from different Explorium enrichment endpoints. The \"combine\" setting indicates it will merge the incoming data streams rather than overwriting them.\n\n### Node 9: Code - flatten\nThis custom code node processes and transforms the merged enrichment data before creating the Salesforce lead. It can be used to:\n- Flatten nested data structures\n- Format data according to Salesforce field requirements\n- Apply business logic or data validation\n- Map Explorium fields to Salesforce lead properties\n- Handle data type conversions\n\n### Node 10: Salesforce\nThis final node creates new leads in Salesforce using the enriched data returned by Explorium.\n\n- **Credential**: Salesforce OAuth2 or Username/Password\n- **Resource**: Lead\n- **Operation**: Create Lead\n\nThe node creates new lead records with enriched information including contact details, company information, and professional data obtained through the Explorium enrichment process.\n\n## Workflow Flow Summary\n\n1. **Trigger**: HubSpot webhook triggers on new/updated contacts\n2. **Fetch**: Retrieve contact details from HubSpot\n3. **Match**: Find prospect matches using Explorium\n4. **Filter**: Keep only successfully matched prospects (currently deactivated)\n5. **Extract**: Compile prospect IDs for bulk enrichment\n6. **Enrich**: Parallel enrichment of contact information through multiple Explorium endpoints\n7. **Merge**: Combine enrichment results\n8. **Transform**: Flatten and prepare data for Salesforce (Code node)\n9. **Create**: Create new lead records in Salesforce\n\nThis workflow ensures comprehensive data enrichment while maintaining data quality and providing a seamless integration between HubSpot prospect data and Salesforce lead creation. The parallel enrichment structure maximizes data collection efficiency before creating high-quality leads in your CRM system."
},
"typeVersion": 1
},
{
"id": "60f1e6d3-7bbe-435a-85af-59c79f81aa5f",
"name": "필터 - non matched",
"type": "n8n-nodes-base.filter",
"position": [
-1600,
360
],
"parameters": {
"options": {},
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "6896e951-8d66-41b1-87a5-a96d2e049675",
"operator": {
"type": "boolean",
"operation": "true",
"singleValue": true
},
"leftValue": "={{ $json.matched_prospects.some(prospect => prospect.prospect_id !== null).toBoolean() }}",
"rightValue": "null"
}
]
}
},
"typeVersion": 2.2
},
{
"id": "459bb55b-663d-4913-b11a-b3be6b16de06",
"name": "Explorium Enrich Profiles",
"type": "n8n-nodes-base.httpRequest",
"position": [
-1160,
460
],
"parameters": {
"url": "https://api.explorium.ai/v1/prospects/profiles/bulk_enrich",
"method": "POST",
"options": {},
"jsonBody": "={{ { \"prospect_ids\": $json.prospect_ids } }}",
"sendBody": true,
"jsonHeaders": "{\n \"Content-Type\": \"application/json\",\n \"Accept\": \"application/json\"\n}",
"sendHeaders": true,
"specifyBody": "=json",
"authentication": "genericCredentialType",
"bodyParameters": {
"parameters": [
{}
]
},
"specifyHeaders": "json",
"genericAuthType": "httpHeaderAuth"
},
"credentials": {
"httpHeaderAuth": {
"id": "85mkGmNNdK1951hF",
"name": "Header Auth Connection"
}
},
"typeVersion": 4.2
}
],
"active": true,
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"versionId": "d2824b55-3ef6-41ac-a550-ef8701401167",
"connections": {
"Merge": {
"main": [
[
{
"node": "Code - flatten",
"type": "main",
"index": 0
}
]
]
},
"76b419d5-f31d-4657-8157-a26d83564b2d": {
"main": [
[
{
"node": "306813bf-056d-48fc-ba8b-e64ddb01beda",
"type": "main",
"index": 0
}
]
]
},
"Code - flatten": {
"main": [
[
{
"node": "17e5e938-690b-41f0-b9b1-10981f109f20",
"type": "main",
"index": 0
}
]
]
},
"306813bf-056d-48fc-ba8b-e64ddb01beda": {
"main": [
[
{
"node": "Filter - non matched",
"type": "main",
"index": 0
}
]
]
},
"faa070fd-841b-460c-b25f-0e3bed266f17": {
"main": [
[
{
"node": "76b419d5-f31d-4657-8157-a26d83564b2d",
"type": "main",
"index": 0
}
]
]
},
"Filter - non matched": {
"main": [
[
{
"node": "08e9aa3a-6957-4f88-9ad7-f492652046e4",
"type": "main",
"index": 0
}
]
]
},
"459bb55b-663d-4913-b11a-b3be6b16de06": {
"main": [
[
{
"node": "Merge",
"type": "main",
"index": 1
}
]
]
},
"e786a130-996c-414a-b87c-aec3a61a960e": {
"main": [
[
{
"node": "Merge",
"type": "main",
"index": 0
}
]
]
},
"08e9aa3a-6957-4f88-9ad7-f492652046e4": {
"main": [
[
{
"node": "e786a130-996c-414a-b87c-aec3a61a960e",
"type": "main",
"index": 0
},
{
"node": "459bb55b-663d-4913-b11a-b3be6b16de06",
"type": "main",
"index": 0
}
]
]
}
}
}이 워크플로우를 어떻게 사용하나요?
위의 JSON 구성 코드를 복사하여 n8n 인스턴스에서 새 워크플로우를 생성하고 "JSON에서 가져오기"를 선택한 후, 구성을 붙여넣고 필요에 따라 인증 설정을 수정하세요.
이 워크플로우는 어떤 시나리오에 적합한가요?
중급 - 영업, 인공지능
유료인가요?
이 워크플로우는 완전히 무료이며 직접 가져와 사용할 수 있습니다. 다만, 워크플로우에서 사용하는 타사 서비스(예: OpenAI API)는 사용자 직접 비용을 지불해야 할 수 있습니다.
관련 워크플로우 추천
explorium
@exploriumExplorium empowers businesses to build high-performance GTM agents with specialized data infrastructure. Our seamless API integrations and high-quality data drive faster agent development and better results. With years of experience and robust data sets, we deliver context-aware solutions, helping AI agents achieve human-level support. Explorium is the essential data partner for teams building agent-driven technologies.
이 워크플로우 공유