AutomationFlowsSocial Media › Auto Clip & Publish to Tiktok/youtube

Auto Clip & Publish to Tiktok/youtube

Auto Clip & Publish to TikTok/YouTube. Uses httpRequest, executeCommand, youtube. Manual trigger; 6 nodes.

Manual trigger★★★★☆ complexity6 nodesHTTP RequestExecute CommandYouTube
Social Media Trigger: Manual Nodes: 6 Complexity: ★★★★☆ Added:

This workflow follows the Executecommand → HTTP Request recipe pattern — see all workflows that pair these two integrations.

The workflow JSON

Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →

Download .json
{
  "name": "Auto Clip & Publish to TikTok/YouTube",
  "nodes": [
    {
      "parameters": {
        "url": "https://www.googleapis.com/youtube/v3/search?channelId=<YOUR_CHANNEL_ID>&part=snippet,id&order=date&key=<YOUR_YOUTUBE_API_KEY>",
        "options": {}
      },
      "name": "YouTube Trigger",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 1,
      "position": [
        200,
        300
      ]
    },
    {
      "parameters": {
        "command": "yt-dlp -f best -o '/tmp/{{ $json['id']['videoId'] }}.mp4' {{ $json['id']['videoId'] }}"
      },
      "name": "Download Video",
      "type": "n8n-nodes-base.executeCommand",
      "typeVersion": 1,
      "position": [
        400,
        300
      ]
    },
    {
      "parameters": {
        "requestMethod": "POST",
        "url": "https://api.gemini-ai.com/extract-clips",
        "jsonParameters": true,
        "options": {},
        "bodyParametersJson": "{ \"video_path\": \"/tmp/{{ $json['id']['videoId'] }}.mp4\", \"format\": \"vertical\", \"clips_count\": 3 }"
      },
      "name": "AI Clip Extraction",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 1,
      "position": [
        600,
        300
      ]
    },
    {
      "parameters": {
        "command": "ffmpeg -i /tmp/{{ $json['clip_name'] }}.mp4 -vf \"scale=1080:1920\" /tmp/final_{{ $json['clip_name'] }}.mp4"
      },
      "name": "FFmpeg Resize",
      "type": "n8n-nodes-base.executeCommand",
      "typeVersion": 1,
      "position": [
        800,
        300
      ]
    },
    {
      "parameters": {
        "requestMethod": "POST",
        "url": "https://api.tiktok.com/upload/video",
        "jsonParameters": true,
        "bodyParametersJson": "{ \"video_path\": \"/tmp/final_{{ $json['clip_name'] }}.mp4\", \"caption\": \"#shorts #viral\", \"tags\": [\"gaming\", \"fun\"] }"
      },
      "name": "Upload to TikTok",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 1,
      "position": [
        1000,
        300
      ]
    },
    {
      "parameters": {
        "resource": "video",
        "operation": "upload",
        "additionalFields": {},
        "title": "{{$json['title']}}",
        "description": "{{$json['description']}}",
        "tags": [
          "shorts",
          "viral"
        ],
        "filePath": "/tmp/final_{{$json['clip_name']}}.mp4"
      },
      "name": "Upload to YouTube Shorts",
      "type": "n8n-nodes-base.youtube",
      "typeVersion": 1,
      "position": [
        1000,
        500
      ]
    }
  ],
  "connections": {
    "YouTube Trigger": {
      "main": [
        [
          {
            "node": "Download Video",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Download Video": {
      "main": [
        [
          {
            "node": "AI Clip Extraction",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI Clip Extraction": {
      "main": [
        [
          {
            "node": "FFmpeg Resize",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "FFmpeg Resize": {
      "main": [
        [
          {
            "node": "Upload to TikTok",
            "type": "main",
            "index": 0
          },
          {
            "node": "Upload to YouTube Shorts",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
Pro

For the full experience including quality scoring and batch install features for each workflow upgrade to Pro

About this workflow

Auto Clip & Publish to TikTok/YouTube. Uses httpRequest, executeCommand, youtube. Manual trigger; 6 nodes.

Source: https://gist.github.com/steamfara-ux/4a54852f4065f17e14f183125bbc50a1 — original creator credit. Request a take-down →

More Social Media workflows → · Browse all categories →

Related workflows

Workflows that share integrations, category, or trigger type with this one. All free to copy and import.

Social Media

Invite LinkedIn Connections to Follow Your Company Page. Uses googleSheets, httpRequest. Manual trigger; 22 nodes.

Google Sheets, HTTP Request
Social Media

Content Publishing - Blog to Social. Uses filesWatcher, readFile, httpRequest, twitter. Manual trigger; 8 nodes.

Files Watcher, Read File, HTTP Request +4
Social Media

• RSS feed monitors your blog for new posts automatically • Extracts and cleans full article content from the blog post • AI Chain (GPT-4o) transforms content into 5 platform-optimized formats (Linked

RSS Feed Read, HTTP Request, Chain Llm +6
Social Media

This n8n workflow automatically shares content from a Telegram Channel to multiple platforms like WordPress, Facebook, X/Twitter, and LinkedIn. It uses a Switch node to detect the type of content—text

Telegram Trigger, Telegram, WordPress +5
Social Media

Disclaimer: this workflow only works on self-hosted instances due to the file system usage.

Execute Workflow Trigger, HTTP Request, Form Trigger +3