Replicate과 Flux를 사용하여 이미지 생성
중급
이것은Content Creation, Multimodal AI분야의자동화 워크플로우로, 14개의 노드를 포함합니다.주로 Code, Merge, Aggregate, HttpRequest, ManualTrigger 등의 노드를 사용하며. Replicate와 Flux를 사용하여 이미지 생성
사전 요구사항
- •대상 API의 인증 정보가 필요할 수 있음
워크플로우 미리보기
노드 연결 관계를 시각적으로 표시하며, 확대/축소 및 이동을 지원합니다
워크플로우 내보내기
다음 JSON 구성을 복사하여 n8n에 가져오면 이 워크플로우를 사용할 수 있습니다
{
"meta": {
"instanceId": "52254486b159b349334953c1738da94e90477c7604aa8db2062d11afc0120739"
},
"nodes": [
{
"id": "a11410a3-6444-40f1-a564-7ee5707377b2",
"name": "이미지 업로드2",
"type": "n8n-nodes-base.httpRequest",
"position": [
640,
-16
],
"parameters": {
"url": "https://articles.emp0.com/wp-json/wp/v2/media",
"method": "POST",
"options": {},
"sendBody": true,
"contentType": "binaryData",
"sendHeaders": true,
"authentication": "predefinedCredentialType",
"headerParameters": {
"parameters": [
{
"name": "Content-Disposition",
"value": "=attachment; filename=\"img-{{ $('Code1').item.json.slug }}.jpg\""
}
]
},
"inputDataFieldName": "data",
"nodeCredentialType": "wordpressApi"
},
"credentials": {
"wordpressApi": {
"id": "G1G8jDdEoWAVytQb",
"name": "Wordpress - anya@emp0.com"
}
},
"retryOnFail": true,
"typeVersion": 4.2,
"waitBetweenTries": 5000
},
{
"id": "d1d5d3e3-72aa-49a3-9411-a8a2bcfdfbb9",
"name": "HTTP 요청1",
"type": "n8n-nodes-base.httpRequest",
"position": [
240,
-16
],
"parameters": {
"url": "= https://api.replicate.com/v1/models/{{ $json.model }}/predictions",
"method": "POST",
"options": {},
"jsonBody": "={{ $json.model_config }}",
"sendBody": true,
"sendHeaders": true,
"specifyBody": "json",
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth",
"headerParameters": {
"parameters": [
{
"name": "content-type",
"value": "application/json"
},
{
"name": "Prefer",
"value": "wait"
}
]
}
},
"credentials": {
"httpBearerAuth": {
"id": "JvhQAEa4Frw0CDoq",
"name": "Leonardo AI"
},
"httpHeaderAuth": {
"id": "rv80WUvVdf5qIJTg",
"name": "Header Auth - replicate"
}
},
"typeVersion": 4.2
},
{
"id": "41c272ef-26de-4481-8490-4bd37d7e52aa",
"name": "HTTP 요청2",
"type": "n8n-nodes-base.httpRequest",
"position": [
432,
-16
],
"parameters": {
"url": "={{ $json.output || $json.output[0] }}",
"options": {},
"sendHeaders": true,
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth",
"headerParameters": {
"parameters": [
{
"name": "accept",
"value": "application/json"
}
]
}
},
"credentials": {
"httpBearerAuth": {
"id": "JvhQAEa4Frw0CDoq",
"name": "Leonardo AI"
},
"httpHeaderAuth": {
"id": "rv80WUvVdf5qIJTg",
"name": "Header Auth - replicate"
}
},
"typeVersion": 4.2
},
{
"id": "0ceb522f-0c64-41f1-a207-9188bc70af6e",
"name": "스티커 노트",
"type": "n8n-nodes-base.stickyNote",
"position": [
192,
-112
],
"parameters": {
"color": 5,
"width": 384,
"height": 272,
"content": "## Generate image with replicate"
},
"typeVersion": 1
},
{
"id": "1289653b-9165-470b-b717-1a0649f5dbbd",
"name": "스티커 노트1",
"type": "n8n-nodes-base.stickyNote",
"position": [
592,
-112
],
"parameters": {
"color": 6,
"width": 342,
"height": 272,
"content": "## Upload"
},
"typeVersion": 1
},
{
"id": "26418c06-d385-4e56-a989-0ea71cf2ebd4",
"name": "스티커 노트2",
"type": "n8n-nodes-base.stickyNote",
"position": [
192,
176
],
"parameters": {
"color": 7,
"width": 768,
"height": 496,
"content": "## Image generated\n"
},
"typeVersion": 1
},
{
"id": "ccd10411-364b-4ea6-867a-d50063bfea83",
"name": "'워크플로 실행' 클릭 시",
"type": "n8n-nodes-base.manualTrigger",
"position": [
-144,
160
],
"parameters": {},
"typeVersion": 1
},
{
"id": "8057ae5d-d37b-47cd-829a-02e650b4e836",
"name": "코드",
"type": "n8n-nodes-base.code",
"position": [
1296,
-32
],
"parameters": {
"jsCode": "return {\n \"public_image_url\" :$input.first().json.data[0].guid.raw,\n \"wordpress\":$input.first().json.data[0],\n \"twitter\":$input.first().json.data[1]\n}"
},
"typeVersion": 2
},
{
"id": "adfdcc3f-d411-47a7-83cd-7c3fa8e224a1",
"name": "다른 워크플로에 의해 실행 시",
"type": "n8n-nodes-base.executeWorkflowTrigger",
"position": [
-144,
-16
],
"parameters": {
"workflowInputs": {
"values": [
{
"name": "prompt"
},
{
"name": "slug"
},
{
"name": "model"
}
]
}
},
"typeVersion": 1.1
},
{
"id": "97437ee7-8648-4807-82ed-44391787f9ad",
"name": "코드1",
"type": "n8n-nodes-base.code",
"position": [
64,
-16
],
"parameters": {
"jsCode": "const input = $input.first().json;\n\nconst models = {\n \"black-forest-labs/flux-dev\": {\n \"input\":{\n prompt: input.prompt,\n go_fast: true,\n guidance: 3.5,\n megapixels: \"1\",\n num_outputs: 1,\n aspect_ratio: \"16:9\",\n output_format: \"webp\",\n output_quality: 80,\n prompt_strength: 0.8,\n num_inference_steps: 28,\n }\n },\n \"black-forest-labs/flux-schnell\" : {\n \"input\": {\n \"prompt\": input.prompt,\n \"go_fast\": true,\n \"megapixels\": \"1\",\n \"num_outputs\": 1,\n \"aspect_ratio\": \"16:9\",\n \"output_format\": \"webp\",\n \"output_quality\": 80,\n \"num_inference_steps\": 4\n }\n },\n \"black-forest-labs/flux-1.1-pro\":{\n \"input\": {\n \"prompt\": input.prompt,\n \"aspect_ratio\": \"16:9\",\n \"output_format\": \"webp\",\n \"output_quality\": 100,\n \"safety_tolerance\": 2,\n \"prompt_upsampling\": true\n }\n }\n // You can define more models here\n};\n\nif (!models.hasOwnProperty(input.model)) {\n throw new Error(`Model \"${input.model}\" is not supported.`);\n}\n\nreturn {\n ...input,\n model: input.model,\n model_config: models[input.model],\n};\n"
},
"typeVersion": 2
},
{
"id": "0a7e0c9e-e149-4654-bc63-f5534244ce90",
"name": "병합",
"type": "n8n-nodes-base.merge",
"position": [
960,
-32
],
"parameters": {},
"typeVersion": 3.2
},
{
"id": "706c943b-9c62-4042-baaf-a08d5aeaa5ab",
"name": "미디어 업로드 (X)",
"type": "n8n-nodes-base.httpRequest",
"position": [
800,
-16
],
"parameters": {
"url": "https://upload.twitter.com/1.1/media/upload.json?media_category=TWEET_IMAGE",
"method": "POST",
"options": {
"response": {
"response": {
"responseFormat": "json"
}
}
},
"sendBody": true,
"contentType": "multipart-form-data",
"authentication": "predefinedCredentialType",
"bodyParameters": {
"parameters": [
{
"name": "media",
"parameterType": "formBinaryData",
"inputDataFieldName": "data"
}
]
},
"nodeCredentialType": "twitterOAuth1Api"
},
"credentials": {
"twitterOAuth1Api": {
"id": "HywNT47jE0Dh8NvQ",
"name": "X OAuth account"
}
},
"typeVersion": 4.2
},
{
"id": "8f0a060f-731d-4970-a2ec-0b48af4e2527",
"name": "집계",
"type": "n8n-nodes-base.aggregate",
"position": [
1120,
-32
],
"parameters": {
"options": {},
"aggregate": "aggregateAllItemData"
},
"typeVersion": 1
},
{
"id": "5ec62e6f-991f-4c59-b3b2-84cd6b8c168e",
"name": "스티커 노트3",
"type": "n8n-nodes-base.stickyNote",
"position": [
-176,
400
],
"parameters": {
"color": 6,
"width": 342,
"height": 272,
"content": "## Models & Pricing / img\n black-forest-labs/flux-schnell -> $0.003\n black-forest-labs/flux-dev -> $0.025\n black-forest-labs/flux-1.1-pro -> $0.04"
},
"typeVersion": 1
}
],
"pinData": {
"When clicking ‘Execute workflow’": [
{
"slug": "joker-watching-batman",
"model": "black-forest-labs/flux-1.1-pro",
"prompt": "joker watching a batman movie on his laptop"
}
]
},
"connections": {
"97437ee7-8648-4807-82ed-44391787f9ad": {
"main": [
[
{
"node": "d1d5d3e3-72aa-49a3-9411-a8a2bcfdfbb9",
"type": "main",
"index": 0
}
]
]
},
"0a7e0c9e-e149-4654-bc63-f5534244ce90": {
"main": [
[
{
"node": "8f0a060f-731d-4970-a2ec-0b48af4e2527",
"type": "main",
"index": 0
}
]
]
},
"8f0a060f-731d-4970-a2ec-0b48af4e2527": {
"main": [
[
{
"node": "8057ae5d-d37b-47cd-829a-02e650b4e836",
"type": "main",
"index": 0
}
]
]
},
"d1d5d3e3-72aa-49a3-9411-a8a2bcfdfbb9": {
"main": [
[
{
"node": "41c272ef-26de-4481-8490-4bd37d7e52aa",
"type": "main",
"index": 0
}
]
]
},
"41c272ef-26de-4481-8490-4bd37d7e52aa": {
"main": [
[
{
"node": "a11410a3-6444-40f1-a564-7ee5707377b2",
"type": "main",
"index": 0
},
{
"node": "706c943b-9c62-4042-baaf-a08d5aeaa5ab",
"type": "main",
"index": 0
}
]
]
},
"a11410a3-6444-40f1-a564-7ee5707377b2": {
"main": [
[
{
"node": "0a7e0c9e-e149-4654-bc63-f5534244ce90",
"type": "main",
"index": 0
}
]
]
},
"706c943b-9c62-4042-baaf-a08d5aeaa5ab": {
"main": [
[
{
"node": "0a7e0c9e-e149-4654-bc63-f5534244ce90",
"type": "main",
"index": 1
}
]
]
},
"adfdcc3f-d411-47a7-83cd-7c3fa8e224a1": {
"main": [
[
{
"node": "97437ee7-8648-4807-82ed-44391787f9ad",
"type": "main",
"index": 0
}
]
]
},
"ccd10411-364b-4ea6-867a-d50063bfea83": {
"main": [
[
{
"node": "97437ee7-8648-4807-82ed-44391787f9ad",
"type": "main",
"index": 0
}
]
]
}
}
}자주 묻는 질문
이 워크플로우를 어떻게 사용하나요?
위의 JSON 구성 코드를 복사하여 n8n 인스턴스에서 새 워크플로우를 생성하고 "JSON에서 가져오기"를 선택한 후, 구성을 붙여넣고 필요에 따라 인증 설정을 수정하세요.
이 워크플로우는 어떤 시나리오에 적합한가요?
중급 - 콘텐츠 제작, 멀티모달 AI
유료인가요?
이 워크플로우는 완전히 무료이며 직접 가져와 사용할 수 있습니다. 다만, 워크플로우에서 사용하는 타사 서비스(예: OpenAI API)는 사용자 직접 비용을 지불해야 할 수 있습니다.
관련 워크플로우 추천
콘텐츠생성기 v3
AI驱动블로그자동화:사용GPT-4생성并게시SEO기사至WordPress및Twitter
If
Set
Code
+
If
Set
Code
144 노드Jay Emp0
콘텐츠 제작
웹 데이터 기반 AI 차트 생성 및 WordPress 업로드
웹 데이터 기반 AI 기반 차트 생성, GPT-4o 사용 및 WordPress에 업로드
Code
Http Request
Manual Trigger
+
Code
Http Request
Manual Trigger
15 노드Jay Emp0
콘텐츠 제작
Leonardo AI와 WordPress를 사용하여 블로그 이미지 생성 및 업로드
Leonardo AI와 WordPress를 사용하여 블로그 이미지를 생성 및 업로드
Code
Wait
Http Request
+
Code
Wait
Http Request
12 노드Jay Emp0
콘텐츠 제작
WordPress 블로그 자동화 프로페셔널 에디션(심층 연구) v2.1 마켓
GPT-4o, Perplexity AI 및 다국어 지원을 사용한 SEO 최적화 블로그 생성 자동화
If
Set
Xml
+
If
Set
Xml
125 노드Daniel Ng
콘텐츠 제작
콘텐츠 집계
Gemini AI로 웹사이트 글에서 소셜 미디어 게시물 자동 생성 및 LinkedIn 및 X/Twitter에 게시
If
Set
Xml
+
If
Set
Xml
34 노드Vadim
콘텐츠 제작
OpenAI, ElevenLabs 및 Fal.ai를 사용한 비디오, 팟캐스트 및 ASMR용 바이럴 콘텐츠 제작 자동화
OpenAI, ElevenLabs 및 Fal.ai를 사용한 비디오, 팟캐스트 및 ASMR용 바이럴 콘텐츠 제작 자동화
Set
Code
Wait
+
Set
Code
Wait
97 노드Adam Crafts
콘텐츠 제작
워크플로우 정보
난이도
중급
노드 수14
카테고리2
노드 유형7
저자
Jay Emp0
@jay-emp0AI and Automation developer. Im implementing n8n and ai tools to automate marketing and sales in companies
외부 링크
n8n.io에서 보기 →
이 워크플로우 공유