✈️ CarbonInterface API와 GPT-4o를 사용한 비즈니스 여행 CO2 배출량 계산
중급
이것은Other, AI, IT Ops분야의자동화 워크플로우로, 12개의 노드를 포함합니다.주로 SplitOut, HttpRequest, GmailTrigger, GoogleSheets, SplitInBatches 등의 노드를 사용하며인공지능 기술을 결합하여 스마트 자동화를 구현합니다. ✈️ Carbon Interface API와 GPT-4o를 통해 비즈니스 여행二氧化碳 배출 계산
사전 요구사항
- •대상 API의 인증 정보가 필요할 수 있음
- •Google 계정 및 Gmail API 인증 정보
- •Google Sheets API 인증 정보
- •OpenAI API Key
사용된 노드 (12)
워크플로우 미리보기
노드 연결 관계를 시각적으로 표시하며, 확대/축소 및 이동을 지원합니다
워크플로우 내보내기
다음 JSON 구성을 복사하여 n8n에 가져오면 이 워크플로우를 사용할 수 있습니다
{
"id": "1H8R2Hvre2Z1LuTG",
"meta": {
"instanceId": "",
"templateCredsSetupCompleted": true
},
"name": "✈️ CO2 Emissions of Business Travels with CarbonInterface API and GPT-4o",
"tags": [],
"nodes": [
{
"id": "16cb6418-383a-409e-ac18-8ba78aba031b",
"name": "Gmail 트리거",
"type": "n8n-nodes-base.gmailTrigger",
"position": [
-320,
415
],
"parameters": {
"simple": false,
"filters": {},
"options": {
"downloadAttachments": false
},
"pollTimes": {
"item": [
{
"mode": "everyMinute"
}
]
}
},
"credentials": {
"gmailOAuth2": {
"id": "",
"name": ""
}
},
"notesInFlow": true,
"typeVersion": 1.2
},
{
"id": "5c7c052e-9a71-4867-9d05-492dac9a8b7c",
"name": "구조화 출력 파서",
"type": "@n8n/n8n-nodes-langchain.outputParserStructured",
"position": [
140,
600
],
"parameters": {
"jsonSchemaExample": "{\n \"traveler_name\": \"Samir Saci\",\n \"trip_purpose\": \"Sustainability Client Workshop\",\n \"trip_id\": \"LG-TRIP-2025-0624\",\n \"flights\": [\n {\n \"type\": \"departure\",\n \"from\": \"Paris Charles de Gaulle (CDG)\",\n \"to\": \"Toronto Pearson International (YYZ)\",\n \"from_code\": \"CDG\",\n \"to_code\": \"YYZ\",\n \"date\": \"2025-06-24\",\n \"flight_number\": \"AF356\"\n },\n {\n \"type\": \"return\",\n \"from\": \"Toronto Pearson International (YYZ)\",\n \"to\": \"Paris Charles de Gaulle (CDG)\",\n \"from_code\": \"YYZ\",\n \"to_code\": \"CDG\",\n \"date\": \"2025-06-28\",\n \"flight_number\": \"AC880\"\n }\n ],\n \"hotel_booked\": false,\n \"ground_transport_booked\": false\n}\n"
},
"typeVersion": 1.2
},
{
"id": "c0eeae42-d3dd-400e-8d19-1068f4ab999d",
"name": "AI 에이전트 파서",
"type": "@n8n/n8n-nodes-langchain.agent",
"position": [
-100,
415
],
"parameters": {
"text": "=Extract the structured trip details from the following email:\n\n{{ $json.text }}\n",
"options": {
"systemMessage": "=You are a travel assistant. When provided with the body of a business trip confirmation email, extract the following structured JSON object.\n\nReturn **only** a JSON object with the following fields:\n\n{\n \"traveler_name\": string,\n \"trip_purpose\": string,\n \"trip_id\": string,\n \"flights\": [\n {\n \"type\": \"departure\" or \"return\",\n \"from\": string,\n \"from_code\": string (e.g., \"CDG\"),\n \"to\": string,\n \"to_code\": string (e.g., \"YYZ\"),\n \"date\": string (ISO 8601, e.g., \"2025-06-24\"),\n \"flight_number\": string\n }\n ],\n \"hotel_booked\": boolean,\n \"ground_transport_booked\": boolean\n}\n\n- Extract the 3-letter airport codes (IATA format) from the airport names and populate `from_code` and `to_code`.\n- If hotel or ground transport is marked “Not booked,” return `false`, otherwise `true`.\n- Always include both departure and return flights as separate items in the \"flights\" array.\n- Return only the JSON object, no extra text.\n"
},
"promptType": "define",
"hasOutputParser": true
},
"typeVersion": 1.9
},
{
"id": "2a30a34e-76d2-4d89-a5f9-cf48f97f490e",
"name": "OpenAI 채팅 모델2",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"position": [
-100,
620
],
"parameters": {
"model": {
"__rl": true,
"mode": "list",
"value": "gpt-4o-mini"
},
"options": {}
},
"credentials": {
"openAiApi": {
"id": "",
"name": ""
}
},
"typeVersion": 1.2
},
{
"id": "f0eb3490-4f5f-42ca-83fa-0a562a08d630",
"name": "분할 출력",
"type": "n8n-nodes-base.splitOut",
"position": [
320,
420
],
"parameters": {
"options": {},
"fieldToSplitOut": "output.flights"
},
"typeVersion": 1
},
{
"id": "c7bb9d8b-a972-4d53-8217-8e77c29dda81",
"name": "비행 정보 기록",
"type": "n8n-nodes-base.googleSheets",
"position": [
840,
360
],
"parameters": {
"columns": {
"value": {
"To": "={{ $json.to }}",
"From": "={{ $json.from }}",
"To Code": "={{ $json.to_code }}",
"Trip ID": "={{ $('AI Agent Parser').item.json.output.trip_id }}_{{ $json.type }}",
"From Code": "={{ $json.from_code }}",
"Flight Date": "={{ $json.date }}",
"Flight Type": "={{ $json.type }}",
"Hotel Booked": "={{ $('AI Agent Parser').item.json.output.hotel_booked }}",
"Trip Purpose": "={{ $('AI Agent Parser').item.json.output.trip_purpose }}",
"Flight Number": "={{ $json.flight_number }}",
"Traveler Name": "={{ $('AI Agent Parser').item.json.output.traveler_name }}",
"Ground Transport Booked": "={{ $('AI Agent Parser').item.json.output.ground_transport_booked }}"
},
"schema": [
{
"id": "Traveler Name",
"type": "string",
"display": true,
"required": false,
"displayName": "Traveler Name",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Trip Purpose",
"type": "string",
"display": true,
"required": false,
"displayName": "Trip Purpose",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Trip ID",
"type": "string",
"display": true,
"required": false,
"displayName": "Trip ID",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Hotel Booked",
"type": "string",
"display": true,
"required": false,
"displayName": "Hotel Booked",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Ground Transport Booked",
"type": "string",
"display": true,
"required": false,
"displayName": "Ground Transport Booked",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Flight Type",
"type": "string",
"display": true,
"required": false,
"displayName": "Flight Type",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "From",
"type": "string",
"display": true,
"required": false,
"displayName": "From",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "From Code",
"type": "string",
"display": true,
"removed": false,
"required": false,
"displayName": "From Code",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "To",
"type": "string",
"display": true,
"required": false,
"displayName": "To",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "To Code",
"type": "string",
"display": true,
"removed": false,
"required": false,
"displayName": "To Code",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Flight Date",
"type": "string",
"display": true,
"required": false,
"displayName": "Flight Date",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Flight Number",
"type": "string",
"display": true,
"required": false,
"displayName": "Flight Number",
"defaultMatch": false,
"canBeUsedToMatch": true
}
],
"mappingMode": "defineBelow",
"matchingColumns": [],
"attemptToConvertTypes": false,
"convertFieldsToString": false
},
"options": {},
"operation": "append",
"sheetName": {
"__rl": true,
"mode": "list",
"value": "gid=0",
"cachedResultUrl": "",
"cachedResultName": "Flight"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "1Unyl-tEDYwtrILjNLOX7IbBP-TAYy8gcmqcZahPpiEI",
"cachedResultUrl": "",
"cachedResultName": "Carbon Emissions"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"id": "",
"name": ""
}
},
"notesInFlow": true,
"typeVersion": 4.6
},
{
"id": "9a3da134-6af3-4130-9420-7efbd4d47d17",
"name": "비행 목록 순환",
"type": "n8n-nodes-base.splitInBatches",
"position": [
540,
420
],
"parameters": {
"options": {}
},
"typeVersion": 3
},
{
"id": "8fa6af96-da24-449f-ab07-7c26eebf82e1",
"name": "CO2 배출량 수집",
"type": "n8n-nodes-base.httpRequest",
"position": [
1040,
360
],
"parameters": {
"url": "https://www.carboninterface.com/api/v1/estimates",
"method": "POST",
"options": {},
"jsonBody": "={\n \"type\": \"flight\",\n \"passengers\": 1,\n \"legs\": [\n {\n \"departure_airport\": \"{{ $json['From Code'] }}\",\n \"destination_airport\": \"{{ $json['To Code'] }}\"\n }\n ]\n}\n",
"sendBody": true,
"sendHeaders": true,
"specifyBody": "json",
"headerParameters": {
"parameters": [
{
"name": "Authorization",
"value": "Bearer YOUR_API_LEY"
},
{
"name": "Content-Type",
"value": "application/json"
}
]
}
},
"notesInFlow": true,
"typeVersion": 4.2
},
{
"id": "0a297fa4-3ea0-485d-901e-48f8e3d32840",
"name": "결과 로드",
"type": "n8n-nodes-base.googleSheets",
"position": [
1300,
420
],
"parameters": {
"columns": {
"value": {
"Trip ID": "={{ $('Record Flights Information').item.json['Trip ID'] }}",
"CO2 (kg)": "={{ $json.data.attributes.carbon_kg }}",
"Distance (km)": "={{ $json.data.attributes.distance_value }}",
"Estimation Time": "={{ $json.data.attributes.estimated_at }}"
},
"schema": [
{
"id": "Traveler Name",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "Traveler Name",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Trip Purpose",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "Trip Purpose",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Trip ID",
"type": "string",
"display": true,
"removed": false,
"required": false,
"displayName": "Trip ID",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Hotel Booked",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "Hotel Booked",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Ground Transport Booked",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "Ground Transport Booked",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Flight Type",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "Flight Type",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "From",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "From",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "From Code",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "From Code",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "To",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "To",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "To Code",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "To Code",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Flight Date",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "Flight Date",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Flight Number",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "Flight Number",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Distance (km)",
"type": "string",
"display": true,
"required": false,
"displayName": "Distance (km)",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "CO2 (kg)",
"type": "string",
"display": true,
"required": false,
"displayName": "CO2 (kg)",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Estimation Time",
"type": "string",
"display": true,
"required": false,
"displayName": "Estimation Time",
"defaultMatch": false,
"canBeUsedToMatch": true
}
],
"mappingMode": "defineBelow",
"matchingColumns": [
"Trip ID"
],
"attemptToConvertTypes": false,
"convertFieldsToString": false
},
"options": {},
"operation": "appendOrUpdate",
"sheetName": {
"__rl": true,
"mode": "list",
"value": "gid=0",
"cachedResultUrl": "",
"cachedResultName": "Flight"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "1Unyl-tEDYwtrILjNLOX7IbBP-TAYy8gcmqcZahPpiEI",
"cachedResultUrl": "",
"cachedResultName": "Carbon Emissions"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"id": "",
"name": ""
}
},
"notesInFlow": true,
"typeVersion": 4.6
},
{
"id": "943097a7-84b2-4be1-a65a-711a8350daad",
"name": "스티키 노트1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-360,
-60
],
"parameters": {
"color": 7,
"width": 180,
"height": 820,
"content": "### 1. Workflow Trigger with Gmail Trigger\nThe workflow is triggered by a new email received in your Gmail mailbox dedicated to process **flight schedules**.\n\n#### How to setup?\n- **Gmail Trigger Node:** set up your Gmail API credentials\n[Learn more about the Gmail Trigger Node](https://docs.n8n.io/integrations/builtin/trigger-nodes/n8n-nodes-base.gmailtrigger)\n"
},
"typeVersion": 1
},
{
"id": "38d4649e-87c0-4bd6-b822-b88ff68309cc",
"name": "스티키 노트2",
"type": "n8n-nodes-base.stickyNote",
"position": [
-160,
-60
],
"parameters": {
"color": 7,
"width": 440,
"height": 820,
"content": "### 2. AI Agent to trip schedule report\nThis node will analyze the content of the email to extract information about the trip including **departure** and **return** trips with **airport codes** and booking information. \n\n#### How to setup?\n- **AI Agent with the Chat Model**:\n 1. Add a **chat model** with the required credentials *(Example: Open AI 4o-mini)*\n 2. Adapt the system prompt to the format of emails you expect to receive *(type of information included)*\n [Learn more about the AI Agent Node](https://docs.n8n.io/integrations/builtin/cluster-nodes/root-nodes/n8n-nodes-langchain.agent)\n"
},
"typeVersion": 1
},
{
"id": "01acc971-5482-4e00-846b-584660ec30ab",
"name": "스티키 노트",
"type": "n8n-nodes-base.stickyNote",
"position": [
300,
-60
],
"parameters": {
"color": 7,
"width": 1180,
"height": 820,
"content": "### 3. Record Shipment Request Information and fetch distance and driving time using Open Route API\nThis starts by recording all the information parsed by the AI node. Then, we use the **Open Route API** to complete with **geocoding data** *(GPS Coordinates)* that will be used to fetch **driving distance and time**.\n\n#### How to setup?\n- **Setup Carbone Interface API Credentials**\n 1. Get your free API key: [Carbon Interface API Documentation](https://docs.carboninterface.com/#/)\n 2. Fill the API key in the HTTP request node\n- **Load records in the Google Sheet Node**:\n 1. Add your Google Sheet API credentials to access the Google Sheet file\n 2. Select the file using the list, an URL or an ID\n 3. Select the sheet in which you want to record your working sessions\n 4. Map the fields: **traveler_name**, **trip_purpose**, **trip_id**, **hotel_booked**, **ground_transport_booked**, **flight_type**, **from**, **from_code**, **to**, **to_code**, **flight_date**, **flight_number**, **distance_km**, **carbon_kg**, **estimated_at**\n\t\t\t\t\t\t\t\t\t\t\t\t\t\n [Learn more about the Google Sheet Node](https://docs.n8n.io/integrations/builtin/app-nodes/n8n-nodes-base.googlesheets)\n\nDistance, carbon emissions and estimation time will be fetched from the **Carbone Interface API**.\n"
},
"typeVersion": 1
}
],
"active": false,
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"versionId": "8a89f371-efb3-4bd0-8909-8fb802f7826d",
"connections": {
"f0eb3490-4f5f-42ca-83fa-0a562a08d630": {
"main": [
[
{
"node": "9a3da134-6af3-4130-9420-7efbd4d47d17",
"type": "main",
"index": 0
}
]
]
},
"0a297fa4-3ea0-485d-901e-48f8e3d32840": {
"main": [
[
{
"node": "9a3da134-6af3-4130-9420-7efbd4d47d17",
"type": "main",
"index": 0
}
]
]
},
"16cb6418-383a-409e-ac18-8ba78aba031b": {
"main": [
[
{
"node": "c0eeae42-d3dd-400e-8d19-1068f4ab999d",
"type": "main",
"index": 0
}
]
]
},
"c0eeae42-d3dd-400e-8d19-1068f4ab999d": {
"main": [
[
{
"node": "f0eb3490-4f5f-42ca-83fa-0a562a08d630",
"type": "main",
"index": 0
}
]
]
},
"9a3da134-6af3-4130-9420-7efbd4d47d17": {
"main": [
[],
[
{
"node": "c7bb9d8b-a972-4d53-8217-8e77c29dda81",
"type": "main",
"index": 0
}
]
]
},
"2a30a34e-76d2-4d89-a5f9-cf48f97f490e": {
"ai_languageModel": [
[
{
"node": "c0eeae42-d3dd-400e-8d19-1068f4ab999d",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"8fa6af96-da24-449f-ab07-7c26eebf82e1": {
"main": [
[
{
"node": "0a297fa4-3ea0-485d-901e-48f8e3d32840",
"type": "main",
"index": 0
}
]
]
},
"5c7c052e-9a71-4867-9d05-492dac9a8b7c": {
"ai_outputParser": [
[
{
"node": "c0eeae42-d3dd-400e-8d19-1068f4ab999d",
"type": "ai_outputParser",
"index": 0
}
]
]
},
"c7bb9d8b-a972-4d53-8217-8e77c29dda81": {
"main": [
[
{
"node": "8fa6af96-da24-449f-ab07-7c26eebf82e1",
"type": "main",
"index": 0
}
]
]
}
}
}자주 묻는 질문
이 워크플로우를 어떻게 사용하나요?
위의 JSON 구성 코드를 복사하여 n8n 인스턴스에서 새 워크플로우를 생성하고 "JSON에서 가져오기"를 선택한 후, 구성을 붙여넣고 필요에 따라 인증 설정을 수정하세요.
이 워크플로우는 어떤 시나리오에 적합한가요?
중급 - 기타, 인공지능, IT 운영
유료인가요?
이 워크플로우는 완전히 무료이며 직접 가져와 사용할 수 있습니다. 다만, 워크플로우에서 사용하는 타사 서비스(예: OpenAI API)는 사용자 직접 비용을 지불해야 할 수 있습니다.
관련 워크플로우 추천
화물을 이용하여 Carbon Interface API와 GPT-4o를 통해 CO2 배출량을 계산합니다.
화물 배송량의 CO2 배출량을 Carbon Interface API와 GPT-4o를 사용하여 계산합니다.
Http Request
Gmail Trigger
Google Sheets
+
Http Request
Gmail Trigger
Google Sheets
10 노드Samir Saci
인공지능
🤖🚚 GPT-4o와 오픈 라이트 API를 기반으로 한 운송 주문 관리 AI 대리인
🤖🚚 GPT-4o와 오픈 라이트 API를 기반으로 한 운송 주문 관리 AI 대리인
Set
Wait
Gmail
+
Set
Wait
Gmail
26 노드Samir Saci
인공지능
🗞️ AI로운 지속 가능한 마케팅 브리핑(gmail, GPT-4o 사용)
🗞️ AI 주도의 지속 가능성 마케팅 브리핑( Gmail, GPT-4o 사용)
If
Set
Code
+
If
Set
Code
21 노드Samir Saci
인공지능
🉑 Google Translate와 GPT-4o를 사용한 언어 학습 Anki 플래시 카드 생성
🉑 구글 번역과 GPT-4o를 사용하여 언어 학습 Anki 플래시 카드 생성
If
Set
Merge
+
If
Set
Merge
21 노드Samir Saci
기타
시각화 참조 라이브러리에서 n8n 노드를 탐색
可视化 참조 라이브러리에서 n8n 노드를 탐색
If
Ftp
Set
+
If
Ftp
Set
113 노드I versus AI
기타
🌲 Gmail과 GPT-40를 사용한 지속 가능한 개발 보고서审计 AI 대리자
🌲 Gmail과 GPT-40를 사용하여 지속 가능성 보고서 감사의 AI 대리자
If
Code
Gmail
+
If
Code
Gmail
14 노드Samir Saci
기타
워크플로우 정보
난이도
중급
노드 수12
카테고리3
노드 유형9
저자
Samir Saci
@samirsaciAutomation, AI and Analytics for Supply Chain & Business Optimization Helping businesses streamline operations using n8n, AI agents, and data science to enhance efficiency and sustainability. Linkedin: www.linkedin.com/in/samir-saci
외부 링크
n8n.io에서 보기 →
이 워크플로우 공유