n8n, açık kaynaklı (open-source) bir otomasyon ve entegrasyon aracıdır. No-code/low-code yaklaşımıyla çalışır ve farklı uygulamaları, servisleri ve verileri birbirine bağlayarak iş akışları (workflow) oluşturmanıza olanak tanır.
Kısaca, “kendi Zapier’inizi kurmak” gibi düşünebilirsiniz. 🚀
🔹 n8n Nedir?
- Açık kaynak: Ücretsiz kullanabilir, kendi sunucunuza kurabilirsiniz.
- Otomasyon: Tekrar eden işleri otomatik hale getirir (ör. form doldurulunca e-posta atmak).
- Entegrasyon: 400’den fazla hazır uygulama entegrasyonu vardır (Google Sheets, Slack, Airtable, Notion, WhatsApp API, OpenAI vb.).
- Esnek: Kendi kodunuzu (JavaScript/TypeScript) yazarak özelleştirme yapabilirsiniz.
- Kendi sunucunuzda: Verileriniz 3. parti servislerde kalmaz, kontrol sizdedir.
🔹 Nasıl Kullanılır?
1. Kurulum Yöntemleri
- Bulut sürüm (n8n Cloud): n8n’in resmi sitesinden hesap açıp direkt kullanabilirsiniz. (Ücretli/deneme sürümü mevcut)
- Self-hosting (ücretsiz):
- Docker ile kurulum (en çok kullanılan yöntem)
- Node.js üzerinden kurulum (
npm install n8n -g
) - Sunucuya (VPS, kendi bilgisayarınız) kurarak web arayüzünden erişebilirsiniz.
2. Çalışma Mantığı
n8n’de Workflow (iş akışı) oluşturulur. Her workflow:
- Trigger (tetikleyici): İş akışını başlatır. Örn: Yeni bir e-posta geldiğinde, webhook çağrıldığında, cron zamanlayıcı çalıştığında.
- Node’lar (adımlar): İşlemleri tanımlar. Örn:
- Google Sheets’e veri ekle
- Slack’e mesaj gönder
- OpenAI ile içerik oluştur
- API’den veri çek
- Output (sonuç): İşlemin bittiği noktadır.
3. Örnek Senaryolar
- E-ticaret: Sipariş gelince müşteriye WhatsApp mesajı + Google Sheet’e kaydet.
- Sosyal medya: RSS’ten blog yazısı çek → otomatik Instagram / Twitter paylaşımı.
- CRM entegrasyonu: Web form doldurulunca → HubSpot’a kaydet → ekibe Slack bildirimi gönder.
- Yapay zeka: OpenAI API ile içerik üret → Notion’a otomatik kaydet.
4. Avantajları
✅ Ücretsiz & açık kaynak
✅ Kendi sunucunuzda barındırabilirsiniz (veri güvenliği)
✅ Sınırsız workflow oluşturabilirsiniz
✅ Geliştiricilere açık (custom node, script yazılabiliyor)
Harika 👍 O zaman sana n8n kurulumu için adım adım komutları ve ardından örnek bir workflow hazırlayayım.
🔹 1. n8n Kurulum (Docker ile en kolay yöntem)
Önce sunucuna veya bilgisayarına Docker + Docker Compose kurulu olmalı.
Kuruluysa şu adımları izle:
Adım 1: Klasör oluştur
mkdir n8n-docker
cd n8n-docker
Adım 2: docker-compose.yml
dosyası oluştur
version: "3"
services:
n8n:
image: n8nio/n8n
ports:
- "5678:5678"
environment:
- N8N_BASIC_AUTH_ACTIVE=true
- N8N_BASIC_AUTH_USER=admin
- N8N_BASIC_AUTH_PASSWORD=strongpassword
- N8N_HOST=localhost
- N8N_PORT=5678
- N8N_PROTOCOL=http
volumes:
- ~/.n8n:/home/node/.n8n
👉 Burada:
admin
→ kullanıcı adıstrongpassword
→ giriş şifren
Adım 3: Çalıştır
docker compose up -d
Adım 4: Tarayıcıdan aç
👉 http://localhost:5678
Artık giriş yapabilirsin 🎉
🔹 2. Örnek Workflow Senaryosu
Senaryo:
Bir Google Form doldurulunca → veriler Google Sheets’e kaydedilsin → ekibin Slack kanalına mesaj gitsin.
Adım Adım:
- Trigger Node:
- “Google Sheets Trigger” ya da “Webhook” ekle (form yanıtları için).
- Google Sheets Node:
- Gelen form verilerini istediğin sheet’e yazdır.
- Slack Node:
- “Yeni kayıt geldi” şeklinde mesaj gönder.
👉 Böylece otomatik CRM akışı kurmuş oluyorsun.
🔹 3. Alternatif Kurulum (Node.js ile)
Eğer Docker kullanmak istemezsen:
npm install n8n -g
n8n
Sonra yine http://localhost:5678
adresinden erişebilirsin.
Bunu n8n arayüzünde → Import Workflow → Paste JSON bölümüne yapıştırıp direkt çalıştırabilirsin.
📄 Örnek Workflow JSON
Senaryo: Webhook üzerinden gelen form yanıtı → Google Sheets’e kaydet → Slack kanalına mesaj at.
{
"name": "Form -> Google Sheets -> Slack",
"nodes": [
{
"parameters": {
"httpMethod": "POST",
"path": "form-webhook",
"options": {}
},
"id": "1",
"name": "Webhook",
"type": "n8n-nodes-base.webhook",
"typeVersion": 1,
"position": [250, 300],
"webhookId": "abc123"
},
{
"parameters": {
"operation": "append",
"sheetId": "YOUR_GOOGLE_SHEET_ID",
"range": "Sheet1!A:C",
"options": {},
"valueInputMode": "RAW",
"data": "={{ [$json[\"name\"], $json[\"email\"], $json[\"message\"]] }}"
},
"id": "2",
"name": "Google Sheets",
"type": "n8n-nodes-base.googleSheets",
"typeVersion": 2,
"position": [550, 300],
"credentials": {
"googleApi": "YOUR_GOOGLE_CREDENTIALS"
}
},
{
"parameters": {
"channel": "#general",
"text": "Yeni form kaydı geldi! 👤 {{$json[\"name\"]}} ({{$json[\"email\"]}})"
},
"id": "3",
"name": "Slack",
"type": "n8n-nodes-base.slack",
"typeVersion": 1,
"position": [850, 300],
"credentials": {
"slackApi": "YOUR_SLACK_CREDENTIALS"
}
}
],
"connections": {
"Webhook": {
"main": [
[
{
"node": "Google Sheets",
"type": "main",
"index": 0
},
{
"node": "Slack",
"type": "main",
"index": 0
}
]
]
}
},
"active": false,
"settings": {},
"id": "workflow-form-google-slack"
}
⚙️ Kullanım
- n8n arayüzüne gir → Import Workflow → bu JSON’u yapıştır.
- Google Sheets için kendi
sheetId
ve Google API bağlantını gir. - Slack için kendi
Slack Bot Token
bilgini ekle. - Workflow’u aktif et.
- Artık
POST http://localhost:5678/webhook/form-webhook
adresine{"name":"Ali","email":"[email protected]","message":"Merhaba"}
gibi JSON gönderirsen:- Google Sheet’e kayıt eklenir,
- Slack kanalına bildirim düşer. 🎉
Anladım 👍 O zaman sana daha basit bir workflow JSON hazırlayayım:
👉 Senaryo: Webhook’tan gelen bir form yanıtı → otomatik olarak e-posta gönderilsin.
📄 Örnek Workflow JSON (Webhook → Email)
{
"name": "Webhook -> Email",
"nodes": [
{
"parameters": {
"httpMethod": "POST",
"path": "send-email",
"options": {}
},
"id": "1",
"name": "Webhook",
"type": "n8n-nodes-base.webhook",
"typeVersion": 1,
"position": [250, 300],
"webhookId": "simple123"
},
{
"parameters": {
"fromEmail": "[email protected]",
"toEmail": "={{$json[\"email\"]}}",
"subject": "Merhaba {{$json[\"name\"]}}!",
"text": "Mesajınız alındı: {{$json[\"message\"]}}"
},
"id": "2",
"name": "Send Email",
"type": "n8n-nodes-base.emailSend",
"typeVersion": 1,
"position": [550, 300],
"credentials": {
"smtp": "YOUR_SMTP_CREDENTIALS"
}
}
],
"connections": {
"Webhook": {
"main": [
[
{
"node": "Send Email",
"type": "main",
"index": 0
}
]
]
}
},
"active": false,
"settings": {},
"id": "workflow-webhook-email"
}
⚙️ Nasıl Çalışır?
- n8n → Import Workflow → JSON’u yapıştır.
- SMTP (Mail) bilgilerini gir (örn. Gmail, Outlook veya kendi mail sunucun).
- Workflow’u aktif et.
- Artık
POST http://localhost:5678/webhook/send-email
adresine şu şekilde JSON gönderirsen:
{
"name": "Ahmet",
"email": "[email protected]",
"message": "Bilgilerim eklendi"
}
➡️ “[email protected]” adresine otomatik e-posta gider. 🎉
Süper 🙌 Şimdi sana AI destekli bir n8n workflow JSON hazırlayayım:
👉 Senaryo:
Webhook ile gelen bir metin → OpenAI GPT-4 kullanılarak özetlenir → sonuç kullanıcıya e-posta olarak gönderilir.
📄 Örnek Workflow JSON (Webhook → OpenAI → Email)
{
"name": "Webhook -> OpenAI -> Email",
"nodes": [
{
"parameters": {
"httpMethod": "POST",
"path": "ai-summary",
"options": {}
},
"id": "1",
"name": "Webhook",
"type": "n8n-nodes-base.webhook",
"typeVersion": 1,
"position": [250, 300],
"webhookId": "ai123"
},
{
"parameters": {
"model": "gpt-4o-mini",
"messages": [
{
"role": "system",
"content": "Sen kısa ve net özetler yapan bir asistansın."
},
{
"role": "user",
"content": "Metni özetle: {{$json[\"message\"]}}"
}
]
},
"id": "2",
"name": "OpenAI",
"type": "n8n-nodes-base.openAi",
"typeVersion": 1,
"position": [550, 300],
"credentials": {
"openAiApi": "YOUR_OPENAI_API_KEY"
}
},
{
"parameters": {
"fromEmail": "[email protected]",
"toEmail": "={{$json[\"email\"]}}",
"subject": "Metin Özeti",
"text": "Merhaba {{$json[\"name\"]}},\n\nMesajınızın özeti: {{$node[\"OpenAI\"].json[\"choices\"][0][\"message\"][\"content\"]}}"
},
"id": "3",
"name": "Send Email",
"type": "n8n-nodes-base.emailSend",
"typeVersion": 1,
"position": [850, 300],
"credentials": {
"smtp": "YOUR_SMTP_CREDENTIALS"
}
}
],
"connections": {
"Webhook": {
"main": [
[
{
"node": "OpenAI",
"type": "main",
"index": 0
}
]
]
},
"OpenAI": {
"main": [
[
{
"node": "Send Email",
"type": "main",
"index": 0
}
]
]
}
},
"active": false,
"settings": {},
"id": "workflow-ai-summary"
}
⚙️ Nasıl Çalışır?
- Workflow’u n8n’e import et.
- OpenAI API Key ve SMTP (mail) bilgilerini gir.
- Workflow’u aktif et.
- Şimdi
POST http://localhost:5678/webhook/ai-summary
adresine şu şekilde JSON gönder:
{
"name": "Mehmet",
"email": "[email protected]",
"message": "n8n, farklı uygulamalar arasında otomasyon kurmayı sağlayan açık kaynak bir platformdur. Zapier'e benzer ama kendi sunucunda çalıştırabilirsin."
}
➡️ Mehmet’e otomatik olarak OpenAI tarafından üretilmiş kısa bir özet mail gelir. 🎉
Harika 🎉 Şimdi sana AI + Google Sheets bir workflow JSON hazırlayayım:
👉 Senaryo:
Webhook → OpenAI GPT-4 ile özet → Google Sheets’e kaydet → kullanıcıya e-posta gönder.
📄 Workflow JSON (Webhook → OpenAI → Google Sheets → Email)
{
"name": "Webhook -> OpenAI -> Google Sheets -> Email",
"nodes": [
{
"parameters": {
"httpMethod": "POST",
"path": "ai-sheet",
"options": {}
},
"id": "1",
"name": "Webhook",
"type": "n8n-nodes-base.webhook",
"typeVersion": 1,
"position": [250, 300],
"webhookId": "aiSheet123"
},
{
"parameters": {
"model": "gpt-4o-mini",
"messages": [
{
"role": "system",
"content": "Sen kısa ve net özetler yapan bir asistansın."
},
{
"role": "user",
"content": "Metni özetle: {{$json[\"message\"]}}"
}
]
},
"id": "2",
"name": "OpenAI",
"type": "n8n-nodes-base.openAi",
"typeVersion": 1,
"position": [550, 300],
"credentials": {
"openAiApi": "YOUR_OPENAI_API_KEY"
}
},
{
"parameters": {
"operation": "append",
"sheetId": "YOUR_GOOGLE_SHEET_ID",
"range": "Sheet1!A:D",
"options": {},
"valueInputMode": "RAW",
"data": "={{ [$json[\"name\"], $json[\"email\"], $json[\"message\"], $node[\"OpenAI\"].json[\"choices\"][0][\"message\"][\"content\"]] }}"
},
"id": "3",
"name": "Google Sheets",
"type": "n8n-nodes-base.googleSheets",
"typeVersion": 2,
"position": [850, 250],
"credentials": {
"googleApi": "YOUR_GOOGLE_CREDENTIALS"
}
},
{
"parameters": {
"fromEmail": "[email protected]",
"toEmail": "={{$json[\"email\"]}}",
"subject": "Metin Özeti ve Kaydı",
"text": "Merhaba {{$json[\"name\"]}},\n\nMesajınızın özeti: {{$node[\"OpenAI\"].json[\"choices\"][0][\"message\"][\"content\"]}}\n\nBu kayıt Google Sheets’e eklendi ✅"
},
"id": "4",
"name": "Send Email",
"type": "n8n-nodes-base.emailSend",
"typeVersion": 1,
"position": [850, 400],
"credentials": {
"smtp": "YOUR_SMTP_CREDENTIALS"
}
}
],
"connections": {
"Webhook": {
"main": [
[
{
"node": "OpenAI",
"type": "main",
"index": 0
}
]
]
},
"OpenAI": {
"main": [
[
{
"node": "Google Sheets",
"type": "main",
"index": 0
},
{
"node": "Send Email",
"type": "main",
"index": 0
}
]
]
}
},
"active": false,
"settings": {},
"id": "workflow-ai-sheet"
}
⚙️ Nasıl Çalışır?
- Workflow’u n8n’e import et.
- OpenAI API Key, Google Sheets API ve SMTP bilgilerini ekle.
- Workflow’u aktif et.
POST http://localhost:5678/webhook/ai-sheet
adresine şu şekilde JSON gönder:
{
"name": "Ayşe",
"email": "[email protected]",
"message": "n8n, farklı uygulamaları birbirine bağlamaya yarayan açık kaynaklı bir otomasyon aracıdır."
}
➡️ Sonuç:
- OpenAI özet çıkarır,
- Google Sheet’e (Name, Email, Orijinal Mesaj, Özet) şeklinde satır eklenir,
- Ayşe’ye özeti içeren e-posta gider. 🎉
Bir yanıt yazın
Yorum yapabilmek için oturum açmalısınız.