Gestion de campagnes d'influenceurs sur les médias sociaux avec notation IA et promotion via Gmail

Intermédiaire

Ceci est unSocial Media, AI Summarizationworkflow d'automatisation du domainecontenant 15 nœuds.Utilise principalement des nœuds comme If, Set, Code, Wait, Gmail. utilisationAI评分etGmail推广gestionréseaux sociaux影响者活动

Prérequis
  • Compte Google et informations d'identification Gmail API
  • Point de terminaison HTTP Webhook (généré automatiquement par n8n)
  • Peut nécessiter les informations d'identification d'authentification de l'API cible
  • Informations d'identification Google Sheets API
Aperçu du workflow
Visualisation des connexions entre les nœuds, avec support du zoom et du déplacement
Exporter le workflow
Copiez la configuration JSON suivante dans n8n pour importer et utiliser ce workflow
{
  "nodes": [
    {
      "id": "1",
      "name": "Brief de Campagne Webhook",
      "type": "n8n-nodes-base.webhook",
      "position": [
        240,
        300
      ],
      "parameters": {
        "path": "campaign-brief",
        "options": {},
        "httpMethod": "POST"
      },
      "typeVersion": 1
    },
    {
      "id": "2",
      "name": "Note Adhésive",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        140,
        180
      ],
      "parameters": {
        "width": 240,
        "height": 160,
        "content": "## Influencer Campaign Setup\n\n⚙️ **Configure campaign parameters:**\n- Target audience demographics\n- Budget allocation per platform\n- Content requirements\n- Timeline and deliverables"
      },
      "typeVersion": 1
    },
    {
      "id": "3",
      "name": "Paramètres de Campagne",
      "type": "n8n-nodes-base.set",
      "position": [
        440,
        300
      ],
      "parameters": {
        "values": {
          "number": [
            {
              "name": "totalBudget",
              "value": "{{ $json.budget }}"
            },
            {
              "name": "minFollowers",
              "value": 10000
            },
            {
              "name": "maxFollowers",
              "value": 500000
            },
            {
              "name": "minEngagementRate",
              "value": 3
            }
          ],
          "string": [
            {
              "name": "campaignName",
              "value": "{{ $json.campaign_name }}"
            },
            {
              "name": "targetAudience",
              "value": "{{ $json.target_audience }}"
            },
            {
              "name": "brandEmail",
              "value": "partnerships@yourbrand.com"
            }
          ]
        }
      },
      "typeVersion": 1
    },
    {
      "id": "4",
      "name": "Rechercher des Influenceurs Instagram",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        640,
        200
      ],
      "parameters": {
        "qs": {
          "q": "{{ $json.targetAudience }}",
          "count": 50
        },
        "url": "https://api.instagram.com/v1/users/search",
        "method": "GET",
        "headers": {
          "Authorization": "Bearer {{ $credentials.instagram.accessToken }}"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "5",
      "name": "Rechercher des Influenceurs TikTok",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        640,
        300
      ],
      "parameters": {
        "qs": {
          "limit": 50,
          "keyword": "{{ $json.targetAudience }}"
        },
        "url": "https://api.tiktok.com/v1/users/search",
        "method": "GET",
        "headers": {
          "Authorization": "Bearer {{ $credentials.tiktok.accessToken }}"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "6",
      "name": "Rechercher des Influenceurs YouTube",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        640,
        400
      ],
      "parameters": {
        "qs": {
          "q": "{{ $json.targetAudience }}",
          "type": "channel",
          "maxResults": 50
        },
        "url": "https://api.youtube.com/v3/search",
        "method": "GET",
        "headers": {
          "Authorization": "Bearer {{ $credentials.youtube.accessToken }}"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "7",
      "name": "Noter et Qualifier les Influenceurs",
      "type": "n8n-nodes-base.code",
      "position": [
        840,
        300
      ],
      "parameters": {
        "jsCode": "// Advanced influencer scoring and qualification algorithm\nconst campaignSettings = $node['Campaign Settings'].json;\nconst allInfluencers = [];\n\n// Process Instagram influencers\nconst instagramData = $node['Search Instagram Influencers'].json;\nif (instagramData.data) {\n  instagramData.data.forEach(influencer => {\n    allInfluencers.push({\n      platform: 'instagram',\n      username: influencer.username,\n      follower_count: influencer.follower_count,\n      engagement_rate: influencer.engagement_rate,\n      profile_url: `https://instagram.com/${influencer.username}`,\n      bio: influencer.bio,\n      raw_data: influencer\n    });\n  });\n}\n\n// Process TikTok influencers\nconst tiktokData = $node['Search TikTok Influencers'].json;\nif (tiktokData.data) {\n  tiktokData.data.forEach(influencer => {\n    allInfluencers.push({\n      platform: 'tiktok',\n      username: influencer.username,\n      follower_count: influencer.follower_count,\n      engagement_rate: influencer.engagement_rate,\n      profile_url: `https://tiktok.com/@${influencer.username}`,\n      bio: influencer.bio,\n      raw_data: influencer\n    });\n  });\n}\n\n// Process YouTube influencers\nconst youtubeData = $node['Search YouTube Influencers'].json;\nif (youtubeData.items) {\n  youtubeData.items.forEach(channel => {\n    allInfluencers.push({\n      platform: 'youtube',\n      username: channel.snippet.channelTitle,\n      follower_count: channel.statistics?.subscriberCount || 0,\n      engagement_rate: (channel.statistics?.viewCount / channel.statistics?.subscriberCount) * 100,\n      profile_url: `https://youtube.com/channel/${channel.id}`,\n      bio: channel.snippet.description,\n      raw_data: channel\n    });\n  });\n}\n\n// Filter and score influencers\nconst qualifiedInfluencers = allInfluencers\n  .filter(influencer => {\n    return influencer.follower_count >= campaignSettings.minFollowers &&\n           influencer.follower_count <= campaignSettings.maxFollowers &&\n           influencer.engagement_rate >= campaignSettings.minEngagementRate;\n  })\n  .map(influencer => {\n    let score = 0;\n    \n    // Follower count scoring (30% weight)\n    const followerScore = Math.min((influencer.follower_count / campaignSettings.maxFollowers) * 30, 30);\n    score += followerScore;\n    \n    // Engagement rate scoring (40% weight)\n    const engagementScore = Math.min((influencer.engagement_rate / 10) * 40, 40);\n    score += engagementScore;\n    \n    // Platform preference scoring (20% weight)\n    const platformScores = { instagram: 20, tiktok: 15, youtube: 18 };\n    score += platformScores[influencer.platform] || 10;\n    \n    // Bio relevance scoring (10% weight)\n    const targetKeywords = campaignSettings.targetAudience.toLowerCase().split(' ');\n    const bioRelevance = targetKeywords.filter(keyword => \n      influencer.bio?.toLowerCase().includes(keyword)\n    ).length;\n    score += Math.min(bioRelevance * 3, 10);\n    \n    // Calculate estimated cost per post\n    let costPerPost = 0;\n    if (influencer.platform === 'instagram') {\n      costPerPost = (influencer.follower_count / 1000) * 10; // $10 per 1k followers\n    } else if (influencer.platform === 'tiktok') {\n      costPerPost = (influencer.follower_count / 1000) * 8; // $8 per 1k followers\n    } else if (influencer.platform === 'youtube') {\n      costPerPost = (influencer.follower_count / 1000) * 25; // $25 per 1k subscribers\n    }\n    \n    return {\n      ...influencer,\n      score: Math.round(score),\n      estimated_cost: Math.round(costPerPost),\n      cost_per_engagement: Math.round(costPerPost / (influencer.follower_count * influencer.engagement_rate / 100)),\n      campaign_id: `${campaignSettings.campaignName}_${Date.now()}`,\n      qualified_at: new Date().toISOString()\n    };\n  })\n  .sort((a, b) => b.score - a.score)\n  .slice(0, 20); // Top 20 influencers\n\nreturn qualifiedInfluencers;"
      },
      "typeVersion": 1
    },
    {
      "id": "8",
      "name": "Filtrer les Meilleurs Influenceurs",
      "type": "n8n-nodes-base.if",
      "position": [
        1040,
        300
      ],
      "parameters": {
        "conditions": {
          "options": {
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "conditions": [
            {
              "operator": {
                "type": "number",
                "operation": "gte"
              },
              "leftValue": "={{ $json.score }}",
              "rightValue": 70
            }
          ]
        }
      },
      "typeVersion": 2
    },
    {
      "id": "9",
      "name": "Générer le Contenu de Prise de Contact",
      "type": "n8n-nodes-base.code",
      "position": [
        1240,
        300
      ],
      "parameters": {
        "jsCode": "// Generate personalized outreach email content\nconst influencer = $json;\nconst campaignSettings = $node['Campaign Settings'].json;\n\n// Create personalized subject line\nconst subjectLines = [\n  `Partnership Opportunity with ${campaignSettings.campaignName}`,\n  `Collaboration Proposal - ${influencer.platform.toUpperCase()} Creator`,\n  `Exciting Brand Partnership for ${influencer.username}`,\n  `${campaignSettings.campaignName} x ${influencer.username} - Let's Create Magic!`\n];\n\nconst randomSubject = subjectLines[Math.floor(Math.random() * subjectLines.length)];\n\n// Determine deliverables based on platform\nlet deliverables = [];\nif (influencer.platform === 'instagram') {\n  deliverables = ['1 Feed Post', '3 Stories', '1 Reel'];\n} else if (influencer.platform === 'tiktok') {\n  deliverables = ['1 Video Post', '2 Story Updates'];\n} else if (influencer.platform === 'youtube') {\n  deliverables = ['1 Sponsored Video', '1 Community Post'];\n}\n\n// Calculate campaign timeline\nconst startDate = new Date();\nconst endDate = new Date(startDate.getTime() + 14 * 24 * 60 * 60 * 1000); // 2 weeks\n\nreturn {\n  ...influencer,\n  outreach_subject: randomSubject,\n  deliverables: deliverables,\n  campaign_start: startDate.toISOString(),\n  campaign_end: endDate.toISOString(),\n  proposal_sent_at: new Date().toISOString()\n};"
      },
      "typeVersion": 1
    },
    {
      "id": "10",
      "name": "Extraire les Coordonnées",
      "type": "n8n-nodes-base.code",
      "position": [
        1440,
        300
      ],
      "parameters": {
        "jsCode": "// Find or create influencer email\nconst influencer = $json;\nlet email = null;\n\n// Try to extract email from bio\nconst emailRegex = /\\b[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\\.[A-Z|a-z]{2,}\\b/;\nconst bioMatch = influencer.bio?.match(emailRegex);\n\nif (bioMatch) {\n  email = bioMatch[0];\n} else {\n  // Generate likely email patterns\n  const username = influencer.username.toLowerCase().replace(/[^a-z0-9]/g, '');\n  const possibleEmails = [\n    `${username}@gmail.com`,\n    `${username}@outlook.com`,\n    `${username}@yahoo.com`,\n    `contact@${username}.com`,\n    `hello@${username}.com`,\n    `${username}@${influencer.platform}.com`\n  ];\n  \n  // Use the first pattern as fallback\n  email = possibleEmails[0];\n}\n\nreturn {\n  ...influencer,\n  email: email,\n  email_verified: bioMatch ? true : false\n};"
      },
      "typeVersion": 1
    },
    {
      "id": "11",
      "name": "Envoyer l'E-mail de Prise de Contact",
      "type": "n8n-nodes-base.gmail",
      "position": [
        1640,
        300
      ],
      "parameters": {
        "sendTo": "={{ $json.email }}",
        "message": "=<!DOCTYPE html>\n<html>\n<head>\n  <style>\n    body { font-family: Arial, sans-serif; margin: 20px; background-color: #f8f9fa; }\n    .container { max-width: 600px; margin: 0 auto; background: white; padding: 30px; border-radius: 10px; }\n    .header { background: linear-gradient(45deg, #667eea, #764ba2); color: white; padding: 20px; text-align: center; margin: -30px -30px 30px -30px; border-radius: 10px 10px 0 0; }\n    .campaign-details { background: #e8f4f8; padding: 20px; margin: 20px 0; border-radius: 8px; }\n    .deliverables { background: #f8f9fa; padding: 15px; margin: 15px 0; border-radius: 5px; }\n    .compensation { background: #d4edda; padding: 15px; margin: 15px 0; border-radius: 5px; border-left: 4px solid #28a745; }\n    .cta { background: #007bff; color: white; padding: 15px 30px; text-decoration: none; border-radius: 5px; display: inline-block; margin: 20px 0; }\n    .stats { background: #fff3cd; padding: 15px; margin: 15px 0; border-radius: 5px; }\n  </style>\n</head>\n<body>\n  <div class=\"container\">\n    <div class=\"header\">\n      <h2>🤝 Partnership Opportunity</h2>\n      <p>We'd love to collaborate with you!</p>\n    </div>\n    \n    <p>Hi {{ $json.username }},</p>\n    \n    <p>We've been following your {{ $json.platform }} content and are impressed by your authentic engagement with your audience. We'd love to partner with you for our {{ $node['Campaign Settings'].json.campaignName }} campaign!</p>\n    \n    <div class=\"stats\">\n      <h3>📊 Why We Chose You</h3>\n      <p><strong>Engagement Rate:</strong> {{ $json.engagement_rate }}%</p>\n      <p><strong>Followers:</strong> {{ $json.follower_count.toLocaleString() }}</p>\n      <p><strong>Platform:</strong> {{ $json.platform.toUpperCase() }}</p>\n      <p><strong>Match Score:</strong> {{ $json.score }}/100</p>\n    </div>\n    \n    <div class=\"campaign-details\">\n      <h3>🎯 Campaign Details</h3>\n      <p><strong>Campaign:</strong> {{ $node['Campaign Settings'].json.campaignName }}</p>\n      <p><strong>Duration:</strong> {{ new Date($json.campaign_start).toLocaleDateString() }} - {{ new Date($json.campaign_end).toLocaleDateString() }}</p>\n      <p><strong>Target Audience:</strong> {{ $node['Campaign Settings'].json.targetAudience }}</p>\n    </div>\n    \n    <div class=\"deliverables\">\n      <h3>📝 What We're Looking For</h3>\n      <ul>\n        {{#each $json.deliverables}}\n        <li>{{ this }}</li>\n        {{/each}}\n      </ul>\n      <p><em>All content subject to approval, but we trust your creative vision!</em></p>\n    </div>\n    \n    <div class=\"compensation\">\n      <h3>💰 Compensation</h3>\n      <p><strong>Payment:</strong> ${{ $json.estimated_cost }} per campaign</p>\n      <p><strong>Cost per engagement:</strong> ${{ $json.cost_per_engagement }}</p>\n      <p><em>Payment processed within 7 days of content delivery</em></p>\n    </div>\n    \n    <div style=\"text-align: center;\">\n      <a href=\"mailto:{{ $node['Campaign Settings'].json.brandEmail }}?subject=Re: {{ $json.outreach_subject }}\" class=\"cta\">\n        💌 I'm Interested!\n      </a>\n    </div>\n    \n    <p>We're excited about the possibility of working together and would love to hear your thoughts!</p>\n    \n    <p style=\"color: #666; font-size: 14px; margin-top: 30px;\">\n      Best regards,<br>\n      {{ $node['Campaign Settings'].json.campaignName }} Team<br>\n      {{ $node['Campaign Settings'].json.brandEmail }}\n    </p>\n  </div>\n</body>\n</html>",
        "options": {
          "contentType": "html"
        },
        "subject": "={{ $json.outreach_subject }}"
      },
      "typeVersion": 1
    },
    {
      "id": "12",
      "name": "Attendre 3 Jours",
      "type": "n8n-nodes-base.wait",
      "position": [
        1840,
        300
      ],
      "parameters": {
        "unit": "days",
        "amount": 3
      },
      "typeVersion": 1
    },
    {
      "id": "13",
      "name": "Envoyer l'E-mail de Relance",
      "type": "n8n-nodes-base.gmail",
      "position": [
        2040,
        300
      ],
      "parameters": {
        "sendTo": "={{ $json.email }}",
        "message": "=<!DOCTYPE html>\n<html>\n<head>\n  <style>\n    body { font-family: Arial, sans-serif; margin: 20px; background-color: #f8f9fa; }\n    .container { max-width: 600px; margin: 0 auto; background: white; padding: 30px; border-radius: 10px; }\n    .follow-up { background: #6f42c1; color: white; padding: 20px; text-align: center; margin: -30px -30px 30px -30px; border-radius: 10px 10px 0 0; }\n    .quick-recap { background: #e8f4f8; padding: 15px; margin: 15px 0; border-radius: 5px; }\n    .cta { background: #28a745; color: white; padding: 15px 30px; text-decoration: none; border-radius: 5px; display: inline-block; margin: 20px 0; }\n  </style>\n</head>\n<body>\n  <div class=\"container\">\n    <div class=\"follow-up\">\n      <h2>👋 Quick Follow-up</h2>\n      <p>Just checking in about our partnership opportunity</p>\n    </div>\n    \n    <p>Hi {{ $json.username }},</p>\n    \n    <p>I wanted to follow up on the collaboration opportunity I sent a few days ago. I know you probably get a lot of partnership requests, but I genuinely think this could be a great fit for your audience.</p>\n    \n    <div class=\"quick-recap\">\n      <h3>📋 Quick Recap</h3>\n      <p><strong>Campaign:</strong> {{ $node['Campaign Settings'].json.campaignName }}</p>\n      <p><strong>Compensation:</strong> ${{ $json.estimated_cost }}</p>\n      <p><strong>Timeline:</strong> 2 weeks</p>\n      <p><strong>Deliverables:</strong> {{ $json.deliverables.join(', ') }}</p>\n    </div>\n    \n    <p>Would you be interested in a quick 15-minute call to discuss this further? I'm flexible with timing and would love to answer any questions you might have.</p>\n    \n    <div style=\"text-align: center;\">\n      <a href=\"mailto:{{ $node['Campaign Settings'].json.brandEmail }}?subject=Re: {{ $json.outreach_subject }}\" class=\"cta\">\n        📞 Let's Chat\n      </a>\n    </div>\n    \n    <p>Thanks for considering, and I look forward to hearing from you!</p>\n    \n    <p style=\"color: #666; font-size: 14px; margin-top: 30px;\">\n      Best,<br>\n      {{ $node['Campaign Settings'].json.campaignName }} Team\n    </p>\n  </div>\n</body>\n</html>",
        "options": {
          "contentType": "html"
        },
        "subject": "Following up on our collaboration opportunity"
      },
      "typeVersion": 1
    },
    {
      "id": "14",
      "name": "Note Adhésive1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1940,
        160
      ],
      "parameters": {
        "width": 240,
        "height": 160,
        "content": "## Campaign Tracking\n\n📊 **Monitor progress:**\n- Response rates by platform\n- Cost per acquisition\n- Engagement analytics\n- ROI optimization"
      },
      "typeVersion": 1
    },
    {
      "id": "15",
      "name": "Suivre l'Avancement de la Campagne",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1640,
        450
      ],
      "parameters": {
        "values": {
          "values": [
            "={{ $json.campaign_id }}",
            "={{ $json.username }}",
            "={{ $json.platform }}",
            "={{ $json.follower_count }}",
            "={{ $json.engagement_rate }}",
            "={{ $json.score }}",
            "={{ $json.estimated_cost }}",
            "={{ $json.email }}",
            "={{ $json.proposal_sent_at }}",
            "pending_response"
          ]
        },
        "resource": "sheet",
        "operation": "appendRow",
        "sheetName": "Influencer Outreach Tracking",
        "documentId": "your-google-sheet-id"
      },
      "typeVersion": 1
    }
  ],
  "connections": {
    "1": {
      "main": [
        [
          {
            "node": "3",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "3": {
      "main": [
        [
          {
            "node": "4",
            "type": "main",
            "index": 0
          },
          {
            "node": "5",
            "type": "main",
            "index": 0
          },
          {
            "node": "6",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "4": {
      "main": [
        [
          {
            "node": "7",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "5": {
      "main": [
        [
          {
            "node": "7",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "6": {
      "main": [
        [
          {
            "node": "7",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "7": {
      "main": [
        [
          {
            "node": "8",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "8": {
      "main": [
        [
          {
            "node": "9",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "9": {
      "main": [
        [
          {
            "node": "10",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "10": {
      "main": [
        [
          {
            "node": "11",
            "type": "main",
            "index": 0
          },
          {
            "node": "15",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "11": {
      "main": [
        [
          {
            "node": "12",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "12": {
      "main": [
        [
          {
            "node": "13",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
Foire aux questions

Comment utiliser ce workflow ?

Copiez le code de configuration JSON ci-dessus, créez un nouveau workflow dans votre instance n8n et sélectionnez "Importer depuis le JSON", collez la configuration et modifiez les paramètres d'authentification selon vos besoins.

Dans quelles scénarios ce workflow est-il adapté ?

Intermédiaire - Réseaux sociaux, Résumé IA

Est-ce payant ?

Ce workflow est entièrement gratuit et peut être utilisé directement. Veuillez noter que les services tiers utilisés dans le workflow (comme l'API OpenAI) peuvent nécessiter un paiement de votre part.

Informations sur le workflow
Niveau de difficulté
Intermédiaire
Nombre de nœuds15
Catégorie2
Types de nœuds9
Description de la difficulté

Adapté aux utilisateurs expérimentés, avec des workflows de complexité moyenne contenant 6-15 nœuds

Liens externes
Voir sur n8n.io

Partager ce workflow

Catégories

Catégories: 34