8
n8n 한국어amn8n.com

Strava 소셜 관리자 (AI 제목 및 설명 생성)

중급

이것은Other, AI분야의자동화 워크플로우로, 13개의 노드를 포함합니다.주로 Set, Code, Strava, StravaTrigger, Agent 등의 노드를 사용하며인공지능 기술을 결합하여 스마트 자동화를 구현합니다. DeepSeek AI를 사용하여 개인화된 Strava 라이딩 제목 및 설명 생성

사전 요구사항
  • AI 서비스 API Key(예: OpenAI, Anthropic 등)

카테고리

워크플로우 미리보기
노드 연결 관계를 시각적으로 표시하며, 확대/축소 및 이동을 지원합니다
워크플로우 내보내기
다음 JSON 구성을 복사하여 n8n에 가져오면 이 워크플로우를 사용할 수 있습니다
{
  "id": "SoJXbESQ4lWQWcVt",
  "meta": {
    "instanceId": "89af474e60c70a1e45bf242e266e9ca1446dd974ab86f6d185b8ccded3effed2",
    "templateCredsSetupCompleted": true
  },
  "name": "Strava Social Manager (AI Title & Description Generation)",
  "tags": [
    {
      "id": "NabIyPgRf7ZggE5B",
      "name": "Showcase",
      "createdAt": "2025-06-03T15:41:30.076Z",
      "updatedAt": "2025-06-03T15:41:30.076Z"
    }
  ],
  "nodes": [
    {
      "id": "58ef8481-49d7-4522-9797-f191db60fa33",
      "name": "모든 요소 결합",
      "type": "n8n-nodes-base.code",
      "position": [
        -80,
        340
      ],
      "parameters": {
        "jsCode": "// Recursive function to flatten JSON into a single string\nfunction flattenJson(obj, prefix = '') {\n    let str = '';\n    for (const key in obj) {\n        if (typeof obj[key] === 'object' && obj[key] !== null) {\n            str += flattenJson(obj[key], `${prefix}${key}.`);\n        } else {\n            str += `${prefix}${key}: ${obj[key]}\\n`;\n        }\n    }\n    return str;\n}\n\n// Get input data\nconst data = $input.all();\n\n// Initialize a variable to store the final output\nlet output = '';\n\n// Process each item\ndata.forEach(item => {\n    output += flattenJson(item.json);\n    output += '\\n---\\n'; // Separator between records\n});\n\n// Return the merged string as output\nreturn [{ json: { data: output } }];\n"
      },
      "typeVersion": 2
    },
    {
      "id": "d81a3699-09c6-4114-ad6e-652ce34854e8",
      "name": "코드",
      "type": "n8n-nodes-base.code",
      "position": [
        -300,
        340
      ],
      "parameters": {
        "jsCode": "// Loop over input items and add a new field called 'myNewField' to the JSON of each one\nfor (const item of $input.all()) {\n  item.json.myNewField = 1;\n}\n\nreturn $input.all();"
      },
      "typeVersion": 2
    },
    {
      "id": "ee87a5ae-331f-4066-84e8-43acdfaaf038",
      "name": "OpenRouter 채팅 모델",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenRouter",
      "position": [
        160,
        520
      ],
      "parameters": {
        "model": "deepseek/deepseek-r1:free",
        "options": {}
      },
      "credentials": {
        "openRouterApi": {
          "id": "3wCQ4jmvYFl3hV0y",
          "name": "OpenRouter account"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "7690c43e-282c-4fc6-af91-ba468040fdba",
      "name": "Strava 트리거",
      "type": "n8n-nodes-base.stravaTrigger",
      "position": [
        -520,
        340
      ],
      "webhookId": "d5e76c3e-5828-45f6-ae2a-ab70d8bfa93f",
      "parameters": {
        "event": "create",
        "object": "activity",
        "options": {}
      },
      "credentials": {
        "stravaOAuth2Api": {
          "id": "Em3MTnOr8JDr8Wnk",
          "name": "Strava account"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "b0dbf6f6-d3c9-43e3-997a-3593229e891e",
      "name": "필드 편집",
      "type": "n8n-nodes-base.set",
      "position": [
        520,
        340
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "fe37d921-5f51-4809-8fa9-e93b0983a566",
              "name": "Name",
              "type": "string",
              "value": "={{ $json.output.split('\\n')[0].split(': ')[1] }}"
            },
            {
              "id": "528a732c-7b96-47c1-8c8e-4354258569d9",
              "name": "Description",
              "type": "string",
              "value": "={{ $json.output.split('\\n')[1].split(': ')[1] }}"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "38316beb-1f92-43e5-ac48-ac982be6407f",
      "name": "Strava",
      "type": "n8n-nodes-base.strava",
      "position": [
        740,
        340
      ],
      "parameters": {
        "operation": "update",
        "activityId": "={{ $('Strava Trigger').item.json.object_id }}",
        "updateFields": {
          "name": "={{ $json.Name }}",
          "description": "={{ $json.Description }}"
        }
      },
      "credentials": {
        "stravaOAuth2Api": {
          "id": "Em3MTnOr8JDr8Wnk",
          "name": "Strava account"
        }
      },
      "typeVersion": 1.1
    },
    {
      "id": "4be1f7de-7f50-45fb-8aa0-4707d25a23fb",
      "name": "Strava 소셜 관리자",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        140,
        340
      ],
      "parameters": {
        "text": "=Tu es un assistant virtuel passionné de cyclisme.  \nÀ partir des informations ci-dessous sur ma sortie vélo, génère :\n- Un **titre accrocheur** (max 10 mots), original et adapté au contexte de la sortie.\n- Une **description** motivante, détaillée et personnalisée (3 à 5 phrases), qui met en valeur les aspects marquants de la sortie (lieux traversés, météo, performance, sensations, anecdotes, etc.).  \n\nUtilise un ton positif, dynamique et inspirant, comme si tu écrivais pour un carnet d’aventure cycliste.  \n\n**Données de la sortie :**\n- Distance : [X] km\n- Durée : [X] h [X] min\n- Dénivelé : [X] m\n- Vitesse moyenne : [X] km/h\n- Lieu/départ : [Ville/lieu]\n- Météo : [ensoleillé, pluvieux, vent, etc.]\n- Ressenti : [facile, difficile, super sensations, etc.]\n- Particularités : [découverte d’un nouveau parcours, sortie en groupe, crevaison, etc.]\n\n**Format attendu :**\n```\nTitre : [Titre généré]\nDescription : [Description générée]\n```\n\n---\n\nVoici les données de l'activité : \n{{ $json.data }}",
        "agent": "conversationalAgent",
        "options": {},
        "promptType": "define"
      },
      "typeVersion": 1.7
    },
    {
      "id": "f2941949-f743-4214-88a6-37899770e4df",
      "name": "스티커 메모",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -940,
        0
      ],
      "parameters": {
        "color": 5,
        "width": 340,
        "height": 680,
        "content": "### **Step 0 – Connecting to the Strava API**\nBefore anything else, connect your Strava account to n8n via OAuth2:\n- Go to **Credentials** > **Strava OAuth2 API** in n8n.\n- Enter the Client ID and Client Secret obtained from the Strava developer portal.\n- Authorize the necessary scopes (`activity:read_all`, `activity:write`).\n- This connection allows n8n to securely access and modify your Strava activities.\n"
      },
      "typeVersion": 1
    },
    {
      "id": "885370b1-7f2f-4411-b35e-3090dcbec2b8",
      "name": "스티커 메모1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -580,
        0
      ],
      "parameters": {
        "width": 220,
        "height": 680,
        "content": "### **Step 1 – Strava Trigger**\nThis node automatically monitors the creation of new activities on your Strava account.\n- For each new activity, it retrieves all associated data (distance, duration, elevation gain, etc.).\n- It serves as the workflow’s entry point and passes the raw activity data to the next steps."
      },
      "typeVersion": 1
    },
    {
      "id": "28121d2d-ddd0-422b-b56d-099a32708216",
      "name": "스티커 메모2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -340,
        0
      ],
      "parameters": {
        "width": 420,
        "height": 680,
        "content": "### **Step 2a – Data Processing (Code)**\nA Code node (JavaScript) adds or modifies fields in the activity data.\n- Example: Adding a custom field `myNewField` to enrich or prepare the data for use by the AI or other nodes.\n\n### **Step 2b – Data Flattening and Formatting (Combine Everything)**\nThis Code node \"flattens\" the complex Strava activity JSON structure into a simple text string.\n- It makes the data easily usable by the AI by presenting it as a readable, well-structured text.\n- Each activity key/value is listed on a line, making contextual analysis easier."
      },
      "typeVersion": 1
    },
    {
      "id": "fb1139ae-b154-49fa-a2f0-dd9e1d440f17",
      "name": "스티커 메모3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        100,
        0
      ],
      "parameters": {
        "width": 340,
        "height": 680,
        "content": "### **Step 3 – AI Generation of Title and Description (Strava Social Manager)**\nThis node calls an AI agent (via OpenRouter or other service) with a detailed prompt:\n- It sends the activity data (flattened previously) to the AI.\n- The AI generates a catchy title and a personalized description, inspired by the context, performance, and highlights of the ride.\n- The prompt is designed to get an inspiring result tailored to the cycling community."
      },
      "typeVersion": 1
    },
    {
      "id": "c2897c26-5e64-44a4-8201-12f25f3a8e13",
      "name": "스티커 메모4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        460,
        0
      ],
      "parameters": {
        "height": 680,
        "content": "### **Step 4 – Extracting AI Results (Edit Fields)**\nThe Set node extracts the AI-generated title and description from the output text.\n- It splits the text to isolate the title and description, storing them in separate fields.\n- This step prepares the data for updating on Strava.\n"
      },
      "typeVersion": 1
    },
    {
      "id": "88418116-adc3-4438-8fa5-0fbfd399495b",
      "name": "스티커 메모5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        720,
        0
      ],
      "parameters": {
        "height": 680,
        "content": "### **Step 5 – Automatic Update of the Activity on Strava**\nThe Strava node updates the relevant activity with the generated title and description.\n- It uses the activity ID provided by the initial trigger.\n- The `name` (title) and `description` fields are updated directly on Strava, making the ride more attractive and personalized."
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "faf93495-ffbf-40f8-8dfe-89be52af5ba1",
  "connections": {
    "d81a3699-09c6-4114-ad6e-652ce34854e8": {
      "main": [
        [
          {
            "node": "58ef8481-49d7-4522-9797-f191db60fa33",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "b0dbf6f6-d3c9-43e3-997a-3593229e891e": {
      "main": [
        [
          {
            "node": "38316beb-1f92-43e5-ac48-ac982be6407f",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "7690c43e-282c-4fc6-af91-ba468040fdba": {
      "main": [
        [
          {
            "node": "d81a3699-09c6-4114-ad6e-652ce34854e8",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "58ef8481-49d7-4522-9797-f191db60fa33": {
      "main": [
        [
          {
            "node": "4be1f7de-7f50-45fb-8aa0-4707d25a23fb",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "ee87a5ae-331f-4066-84e8-43acdfaaf038": {
      "ai_languageModel": [
        [
          {
            "node": "4be1f7de-7f50-45fb-8aa0-4707d25a23fb",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "4be1f7de-7f50-45fb-8aa0-4707d25a23fb": {
      "main": [
        [
          {
            "node": "b0dbf6f6-d3c9-43e3-997a-3593229e891e",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
자주 묻는 질문

이 워크플로우를 어떻게 사용하나요?

위의 JSON 구성 코드를 복사하여 n8n 인스턴스에서 새 워크플로우를 생성하고 "JSON에서 가져오기"를 선택한 후, 구성을 붙여넣고 필요에 따라 인증 설정을 수정하세요.

이 워크플로우는 어떤 시나리오에 적합한가요?

중급 - 기타, 인공지능

유료인가요?

이 워크플로우는 완전히 무료이며 직접 가져와 사용할 수 있습니다. 다만, 워크플로우에서 사용하는 타사 서비스(예: OpenAI API)는 사용자 직접 비용을 지불해야 할 수 있습니다.

워크플로우 정보
난이도
중급
노드 수13
카테고리2
노드 유형7
난이도 설명

일정 경험을 가진 사용자를 위한 6-15개 노드의 중간 복잡도 워크플로우

저자
Thibaud

Thibaud

@tderouze

Automation consultant with over 10 years experience helping Sales & Marketing teams to streamline their processes.

외부 링크
n8n.io에서 보기

이 워크플로우 공유

카테고리

카테고리: 34