AI-Bilder mit APImage generieren und zu Google Drive hochladen

Fortgeschritten

Dies ist ein Content Creation, Multimodal AI-Bereich Automatisierungsworkflow mit 8 Nodes. Hauptsächlich werden FormTrigger, GoogleDrive, HttpRequest und andere Nodes verwendet. Mit APImage KI-Bilder erstellen und in Google Drive hochladen

Voraussetzungen
  • Google Drive API-Anmeldedaten
  • Möglicherweise sind Ziel-API-Anmeldedaten erforderlich
Workflow-Vorschau
Visualisierung der Node-Verbindungen, mit Zoom und Pan
Workflow exportieren
Kopieren Sie die folgende JSON-Konfiguration und importieren Sie sie in n8n
{
  "meta": {
    "instanceId": "cba9e349b601c19a1409b9fd06680aff0a77829be13c8aad9a858d4cea7ff290",
    "templateCredsSetupCompleted": true
  },
  "nodes": [
    {
      "id": "e67847ce-f519-45a3-bba6-380af6cdd648",
      "name": "Bild herunterladen",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        96,
        64
      ],
      "parameters": {
        "url": "={{ $json.images[0] }}",
        "options": {
          "response": {
            "response": {
              "responseFormat": "file",
              "outputPropertyName": "generated_image"
            }
          }
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "e380ad74-2cc6-4d1e-ae30-d1fca03cb39e",
      "name": "Notiz",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -416,
        -208
      ],
      "parameters": {
        "width": 976,
        "height": 252,
        "content": "## ✨ How To Get Started\n\n1. Double-click the **APImage API** node to open it.  \n2. Replace `YOUR_API_KEY` with your actual API Key (keep the `\"Bearer\"` prefix).  \n3. Use the **Generate Image** node to submit a request.\n\n> ℹ️ You can find your API Key inside the Dashboard of your APImage account.\n\n🔗 [Open the Dashboard 🡥](https://apimage.org/dashboard)\n"
      },
      "typeVersion": 1
    },
    {
      "id": "9ea17920-9c28-4d21-9f48-e64193fec34e",
      "name": "Notiz2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        80,
        256
      ],
      "parameters": {
        "width": 480,
        "height": 304,
        "content": "### 📤 Choose Your Destination\n\nYou can replace the **\"Upload to Google Drive\"** node with any other service where you'd like to upload the AI-generated image — such as **Dropbox**, **WordPress**, **Shopify**, or **Notion**.\n\nJust make sure to use the correct **file name**, as defined in the **\"Download Image\"** node (Put Output in Field).\n\n\n\n\n\n\n\n\n[How to set up Google Drive credentials 🡥](https://docs.n8n.io/integrations/builtin/app-nodes/n8n-nodes-base.googledrive/?utm_source=n8n_app&utm_medium=node_settings_modal-credential_link&utm_campaign=n8n-nodes-base.googleDrive)"
      },
      "typeVersion": 1
    },
    {
      "id": "82a45985-c85e-404e-b202-6344d34c933c",
      "name": "Notiz3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -416,
        256
      ],
      "parameters": {
        "width": 480,
        "height": 304,
        "content": "### 🧩 Choose Your Input\n\nYou can replace the **\"Generate Image\"** node with any other node that sends data to the **\"APImage API\"** node.  \nJust make sure the following parameters are set:\n\n- **`prompt`** – any text, up to **1000 characters**\n- **`dimensions`** – choose one of:  \n  `Square`, `Landscape`, `Portrait`\n- **`model`** – choose one of:  \n  `Basic`, `Premium` *(available for APImage Pro and business customers)*\n\n[View API Documentation 🡥](https://apimage.org/docs)"
      },
      "typeVersion": 1
    },
    {
      "id": "b48797c6-7c96-4e9a-827b-d05c435dbe13",
      "name": "APImage API",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -128,
        64
      ],
      "parameters": {
        "url": "https://apimage.org/api/ai-image-generate",
        "method": "POST",
        "options": {},
        "jsonBody": "={\n  \"prompt\": \"{{ $json['Describe the image you want'] }}\",\n  \"dimensions\": \"{{ $json['Dimensions'] }}\",\n  \"model\": \"{{ $json['AI Model'] }}\"\n}",
        "sendBody": true,
        "sendHeaders": true,
        "specifyBody": "json",
        "headerParameters": {
          "parameters": [
            {
              "name": "Authorization",
              "value": "Bearer YOUR_API_KEY"
            }
          ]
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "3d77e24e-cf80-4ace-9a58-faa4dd3a4f09",
      "name": "Bild generieren",
      "type": "n8n-nodes-base.formTrigger",
      "position": [
        -352,
        64
      ],
      "webhookId": "b7487db2-4581-4fd6-b4e0-afac3d8466fb",
      "parameters": {
        "options": {},
        "formTitle": "APImage AI Image Generator",
        "formFields": {
          "values": [
            {
              "fieldLabel": "Describe the image you want",
              "requiredField": true
            },
            {
              "fieldType": "dropdown",
              "fieldLabel": "Dimensions",
              "fieldOptions": {
                "values": [
                  {
                    "option": "Square"
                  },
                  {
                    "option": "Landscape"
                  },
                  {
                    "option": "Portrait"
                  }
                ]
              },
              "requiredField": true
            },
            {
              "fieldType": "dropdown",
              "fieldLabel": "AI Model",
              "fieldOptions": {
                "values": [
                  {
                    "option": "Basic"
                  },
                  {
                    "option": "Premium"
                  }
                ]
              },
              "requiredField": true
            }
          ]
        },
        "formDescription": "Generate images in seconds"
      },
      "typeVersion": 2.2
    },
    {
      "id": "1a9c4e5a-b223-4c71-98b6-d88306cc974a",
      "name": "Datei hochladen",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        320,
        64
      ],
      "parameters": {
        "name": "generated_image",
        "driveId": {
          "__rl": true,
          "mode": "list",
          "value": "My Drive"
        },
        "options": {},
        "folderId": {
          "__rl": true,
          "mode": "list",
          "value": "root",
          "cachedResultName": "/ (Root folder)"
        },
        "inputDataFieldName": "generated_image"
      },
      "typeVersion": 3
    },
    {
      "id": "358d7fe8-6e82-4e77-a7e4-788e94b79e40",
      "name": "Notiz1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -416,
        640
      ],
      "parameters": {
        "color": 7,
        "width": 672,
        "height": 352,
        "content": "### 🐞 Debug Support\n\n**504 Gateway Timeout Error**  \nThis error typically occurs when n8n reaches its maximum wait time for a job to complete. To resolve it, increase the value of the **Timeout** setting (in milliseconds). For example, setting it to `180000` allows up to 3 minutes.\n\nThis issue is most common on the cloud-hosted version of n8n, where stricter limits apply. On self-hosted instances, the error rarely occurs, as you have full control over execution settings.\n\nBut no worries, even if this error occurs, APImage is still able to generate the image, you will find every image inside your APImage Dashboard → Usage Data → Image Generations\n\nIf you experience any issues regarding the APImage API itself, contact: \n\n✉ [ask@support@apimage.org](mailto:ask@support@apimage.org)"
      },
      "typeVersion": 1
    }
  ],
  "pinData": {},
  "connections": {
    "b48797c6-7c96-4e9a-827b-d05c435dbe13": {
      "main": [
        [
          {
            "node": "e67847ce-f519-45a3-bba6-380af6cdd648",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "e67847ce-f519-45a3-bba6-380af6cdd648": {
      "main": [
        [
          {
            "node": "1a9c4e5a-b223-4c71-98b6-d88306cc974a",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "3d77e24e-cf80-4ace-9a58-faa4dd3a4f09": {
      "main": [
        [
          {
            "node": "b48797c6-7c96-4e9a-827b-d05c435dbe13",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
Häufig gestellte Fragen

Wie verwende ich diesen Workflow?

Kopieren Sie den obigen JSON-Code, erstellen Sie einen neuen Workflow in Ihrer n8n-Instanz und wählen Sie "Aus JSON importieren". Fügen Sie die Konfiguration ein und passen Sie die Anmeldedaten nach Bedarf an.

Für welche Szenarien ist dieser Workflow geeignet?

Fortgeschritten - Content-Erstellung, Multimodales KI

Ist es kostenpflichtig?

Dieser Workflow ist völlig kostenlos. Beachten Sie jedoch, dass Drittanbieterdienste (wie OpenAI API), die im Workflow verwendet werden, möglicherweise kostenpflichtig sind.

Verwandte Workflows

Workflow-Informationen
Schwierigkeitsgrad
Fortgeschritten
Anzahl der Nodes8
Kategorie2
Node-Typen4
Schwierigkeitsbeschreibung

Für erfahrene Benutzer, mittelkomplexe Workflows mit 6-15 Nodes

Autor
Gegenfeld

Gegenfeld

@gegenfeld

We at Gegenfeld are an EdTech platform dedicated to delivering high-quality on-demand courses and interactive training sessions for professional development at all skill levels. With our commitment to "Accelerate your future," we empower professionals to enhance their expertise through engaging, industry-focused learning experiences. On n8n, we share some of the workflows used in our interactive training to provide deeper insights and practical applications.

Externe Links
Auf n8n.io ansehen

Diesen Workflow teilen

Kategorien

Kategorien: 34