ThumbAPI logoThumbAPI

ThumbAPI + n8n: The Ultimate Thumbnail Automation Guide

Transform your content workflow by connecting ThumbAPI to n8n. The fastest path is the official ThumbAPI community node — drop it on your canvas and you're generating thumbnails in under a minute. If your n8n instance doesn't allow community nodes or you prefer raw HTTP control, the manual setup is documented further down.

Use the Official ThumbAPI Community Node

Recommended

Install the dedicated n8n-nodes-thumbapi package and use ThumbAPI as a native n8n node — one drop-in, no Code node, no manual base64 decoding. The node returns the generated image as n8n binary data, ready to flow into Google Drive, S3, WordPress, Slack, or any downstream node that accepts files.

Install (60 seconds)

  1. In n8n, open Settings → Community Nodes
  2. Click Install
  3. Enter n8n-nodes-thumbapi
  4. Accept the risk notice → Install

The ThumbAPI node appears in your nodes panel and is searchable as "ThumbAPI".

Verify the connection (no signup, no credits)

Drop the ThumbAPI node onto your canvas. At the top of the parameters panel, enable Use Public Test Key. The default title is already filled in — just pick a format and click Execute step. You'll get a placeholder thumbnail back in seconds, no credential required.

Switch to your real API key

Disable Use Public Test Key, then create a new ThumbAPI credential with your real key from the ThumbAPI dashboard → API Setup. That's it — every generated thumbnail flows out as binary data on the node's output.

Node parameters

  • Title, Format, Category, Model, Output Format — the basics
  • Use Saved Photo / Use Saved Logo — toggle on to include your saved Personal Photo or brand Logo (upload once in the dashboard)
  • Custom Assets ID — point to a saved reference dataset for brand-consistent styling
  • Additional Options → Inline Photo / Logo — pass a per-request base64 image to override saved assets
  • Put Output In Binary — when on (default), the base64 response is auto-decoded into n8n binary data

Alternative: Manual HTTP Request Setup

If you can't install community nodes (some n8n Cloud tiers restrict this until a node is verified), prefer raw HTTP control, or want to understand what's happening under the hood — here's how to wire ThumbAPI manually using the built-in HTTP Request and Code nodes.

Step 1: Secure Authentication

ThumbAPI uses a dedicated header for API security. In your n8n instance, go to Credentials > Add Credential. Search for and select Header Auth, then fill in the following:

Credential Type: Header Auth

Name: ThumbAPI
Header Name: x-api-key
Header Value: YOUR_API_KEY

Find your API key in your ThumbAPI Dashboard. Storing credentials in n8n's credential manager keeps your API key encrypted and separate from workflow definitions.

Step 2: Plug & Play Workflow (Copy/Paste)

Copy the JSON block below and paste it directly into your n8n editor. This workflow includes a Code Node specifically designed to handle ThumbAPI's Base64 response and prepare a clean binary image file.

{
  "nodes": [
    {
      "parameters": {
        "values": {
          "string": [
            {
              "name": "title",
              "value": "How to Build a SaaS in 2026"
            }
          ]
        }
      },
      "name": "Set Test Title",
      "type": "n8n-nodes-base.set",
      "typeVersion": 1,
      "position": [450, 300]
    },
    {
      "parameters": {
        "method": "POST",
        "url": "https://api.thumbapi.dev/v1/generate",
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth",
        "sendBody": true,
        "specifyBody": "json",
        "jsonBody": "={\n  \"title\": \"{{ $json.title }}\",\n  \"format\": \"youtube\",\n  \"outputFormat\": \"webp\"\n}"
      },
      "name": "ThumbAPI Request",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 3,
      "position": [670, 300]
    },
    {
      "parameters": {
        "jsCode": "const base64String = $input.item.json.image;\nconst base64Data = base64String.includes(',') ? base64String.split(',')[1] : base64String;\n\nreturn {\n  json: {\n    format: $input.item.json.format,\n    outputFormat: $input.item.json.outputFormat\n  },\n  binary: {\n    data: {\n      data: base64Data,\n      fileName: `thumbnail.${$input.item.json.outputFormat || 'webp'}`,\n      mimeType: `image/${$input.item.json.outputFormat || 'webp'}`\n    }\n  }\n};"
      },
      "name": "Process Image",
      "type": "n8n-nodes-base.code",
      "typeVersion": 1,
      "position": [890, 300]
    }
  ],
  "connections": {
    "Set Test Title": {
      "main": [
        [
          {
            "node": "ThumbAPI Request",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "ThumbAPI Request": {
      "main": [
        [
          {
            "node": "Process Image",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}

The workflow contains three nodes: Set Test Title provides a sample title to get you started, ThumbAPI Request sends the generation request, and Process Image converts the Base64 response into a clean binary file you can pass to any downstream node (Google Drive, S3, Slack, WordPress, etc.). Replace the Set node with your own trigger in production.

Before you import: the workflow references the ThumbAPI Header Auth credential from Step 1. If you haven't created your own credential yet, attach the workflow to a credential with your real API key from app.thumbapi.dev (free tier: 50 credits/month, no credit card). Or, if you just want to verify the wiring without signing up, use the Quick Test workflow further down with the public test key thumbapi_test — that one returns a static placeholder image and does not require an account.

Step 3: Choose Your Automation Style

Switch between different visual approaches by toggling the usePhoto and useLogo flags in the request body. Omit both for the default faceless look.

Option A: Personal Branding (Influencer Style)

Perfect for creators who want their face on every thumbnail. Upload your photo once to the ThumbAPI Dashboard, then set "usePhoto": true. ThumbAPI automatically removes the background from your photo and places it professionally next to the title.

{
  "title": "{{ $json.title }}",
  "format": "youtube",
  "usePhoto": true,
  "outputFormat": "webp"
}

Option B: Corporate Branding (Logo Style)

Best for SaaS founders and companies. Upload your brand logo to the dashboard, then set "useLogo": true. Thumbnails are generated with your logo placed consistently for brand recognition.

{
  "title": "{{ $json.title }}",
  "format": "youtube",
  "useLogo": true,
  "outputFormat": "webp"
}

Option C: Faceless (Clean & Minimal)

Ideal for quick automation and faceless YouTube channels. Omit both usePhoto and useLogo for a high-impact, text-centric design that focuses on the curiosity gap. No assets required.

{
  "title": "{{ $json.title }}",
  "format": "youtube",
  "outputFormat": "webp"
}

Step 4: Platform Optimization

Control the dimensions of your output by setting the format parameter.

FormatDimensionsBest For
youtube1280x720Main YouTube thumbnails.
instagram1024x1024Square social media posts.
x1200x675Twitter feed and link previews.
blogpost1200x630Article headers and Open Graph images.

Pro Developer Tip: Dynamic Asset Overrides

If you are building a tool for third parties, you don't have to rely on dashboard assets. You can pass a photoImage (max 2MB) or logoImage (max 1MB) as a Base64 string directly in your n8n request body. This allows your workflow to generate unique thumbnails for different guests or products on the fly.

{
  "title": "{{ $json.title }}",
  "format": "youtube",
  "usePhoto": true,
  "photoImage": "{{ $json.guestPhotoBase64 }}",
  "outputFormat": "webp"
}

Quick Test (No Account Needed)

Want to test the workflow without creating an account or using your credits? Use our Public Test Key:

  • Header Name: x-api-key
  • Test Value: thumbapi_test

This key returns a static “Success” placeholder image so you can verify your n8n connection before using real credits. It does not generate real thumbnails — for that you need to sign up at app.thumbapi.dev (free tier: 50 credits/month) and swap thumbapi_test for your real API key.

Copy the test workflow below, paste it into n8n, and create a Header Auth credential with the test key above:

{
  "nodes": [
    {
      "parameters": {
        "values": {
          "string": [
            {
              "name": "title",
              "value": "Testing ThumbAPI Connection"
            }
          ]
        }
      },
      "name": "Set Test Title",
      "type": "n8n-nodes-base.set",
      "typeVersion": 1,
      "position": [450, 300]
    },
    {
      "parameters": {
        "method": "POST",
        "url": "https://api.thumbapi.dev/v1/generate",
        "sendHeaders": true,
        "headerParameters": {
          "parameters": [
            {
              "name": "x-api-key",
              "value": "thumbapi_test"
            }
          ]
        },
        "sendBody": true,
        "specifyBody": "json",
        "jsonBody": "={\n  \"title\": \"{{ $json.title }}\",\n  \"format\": \"youtube\",\n  \"outputFormat\": \"webp\"\n}"
      },
      "name": "ThumbAPI Request",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 3,
      "position": [670, 300]
    },
    {
      "parameters": {
        "jsCode": "const base64String = $input.item.json.image;\nconst base64Data = base64String.includes(',') ? base64String.split(',')[1] : base64String;\n\nreturn {\n  json: {\n    format: $input.item.json.format,\n    outputFormat: $input.item.json.outputFormat\n  },\n  binary: {\n    data: {\n      data: base64Data,\n      fileName: `thumbnail.${$input.item.json.outputFormat || 'webp'}`,\n      mimeType: `image/${$input.item.json.outputFormat || 'webp'}`\n    }\n  }\n};"
      },
      "name": "Process Image",
      "type": "n8n-nodes-base.code",
      "typeVersion": 1,
      "position": [890, 300]
    }
  ],
  "connections": {
    "Set Test Title": {
      "main": [
        [
          {
            "node": "ThumbAPI Request",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "ThumbAPI Request": {
      "main": [
        [
          {
            "node": "Process Image",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}