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 →
{
"name": "Create GitHub Repository",
"nodes": [
{
"parameters": {
"httpMethod": "POST",
"path": "create-github-repo",
"responseMode": "onReceived",
"options": {}
},
"id": "webhook-create-repo",
"name": "Webhook: Create GitHub Repo",
"type": "n8n-nodes-base.webhook",
"typeVersion": 2.1,
"position": [
250,
300
]
},
{
"parameters": {
"language": "javaScript",
"mode": "runOnceForAllItems",
"jsCode": "// Parse webhook payload and generate repository name\nconst payload = $input.all()[0].json;\n\nconst businessName = payload.businessName || '';\nconst packageTier = payload.packageTier || 'starter';\n\n// Generate repository name using slug pattern\nconst slug = businessName\n .toLowerCase()\n .replace(/[^a-z0-9]+/g, '-')\n .replace(/(^-|-$)/g, '');\n\nconst repoName = `${slug}-${packageTier.toLowerCase()}`;\nconst githubOwner = 'senpapi69';\n\nreturn [{\n json: {\n businessName,\n packageTier,\n repoName,\n githubOwner,\n repoFullName: `${githubOwner}/${repoName}`,\n repoUrl: `https://github.com/${githubOwner}/${repoName}`,\n timestamp: payload.timestamp || new Date().toISOString()\n }\n}];"
},
"id": "parse-payload",
"name": "Parse Payload & Generate Repo Name",
"type": "n8n-nodes-base.code",
"typeVersion": 2,
"position": [
450,
300
]
},
{
"parameters": {
"url": "=https://api.github.com/repos/{{ $json.githubOwner }}/{{ $json.repoName }}",
"method": "GET",
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "Accept",
"value": "application/vnd.github.v3+json"
}
]
},
"options": {
"response": {
"response": {
"responseFormat": "json"
}
}
}
},
"id": "check-repo-exists",
"name": "Check if Repo Exists",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.3,
"position": [
650,
200
],
"continueOnFail": true
},
{
"parameters": {
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "check-repo-status",
"leftValue": "={{ $node['Check if Repo Exists'].json.id }}",
"rightValue": "",
"operator": {
"type": "number",
"operation": "exists"
}
}
]
}
},
"id": "if-repo-exists",
"name": "Repo Already Exists?",
"type": "n8n-nodes-base.if",
"typeVersion": 2.3,
"position": [
850,
200
]
},
{
"parameters": {
"language": "javaScript",
"mode": "runOnceForAllItems",
"jsCode": "// Append timestamp to handle naming conflicts\nconst data = $node['Parse Payload & Generate Repo Name'].json;\nconst timestamp = Date.now();\nconst newRepoName = `${data.repoName}-${timestamp}`;\n\nreturn [{\n json: {\n ...data,\n repoName: newRepoName,\n repoFullName: `${data.githubOwner}/${newRepoName}`,\n repoUrl: `https://github.com/${data.githubOwner}/${newRepoName}`,\n timestampConflict: timestamp\n }\n}];"
},
"id": "handle-conflict",
"name": "Handle Naming Conflict",
"type": "n8n-nodes-base.code",
"typeVersion": 2,
"position": [
1050,
200
]
},
{
"parameters": {
"url": "https://api.github.com/user/repos",
"method": "POST",
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "Accept",
"value": "application/vnd.github.v3+json"
}
]
},
"sendBody": true,
"contentType": "json",
"jsonBody": "={\n \"name\": \"{{ $json.repoName }}\",\n \"description\": \"Website for {{ $json.businessName }} ({{ $json.packageTier }} package)\",\n \"private\": false,\n \"auto_init\": true,\n \"gitignore_template\": \"Node\",\n \"license_template\": \"mit\"\n}",
"options": {
"response": {
"response": {
"responseFormat": "json"
}
}
}
},
"id": "create-repo",
"name": "Create GitHub Repository",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.3,
"position": [
1250,
300
]
},
{
"parameters": {
"url": "=https://api.github.com/repos/{{ $json.githubOwner }}/{{ $json.repoName }}/hooks",
"method": "POST",
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "Accept",
"value": "application/vnd.github.v3+json"
}
]
},
"sendBody": true,
"contentType": "json",
"jsonBody": "={\n \"name\": \"n8n-webhook\",\n \"active\": true,\n \"events\": [\"push\"],\n \"config\": {\n \"url\": \"https://n8n.hudsond.me/webhook/github-render-deploy\",\n \"content_type\": \"json\",\n \"insecure_ssl\": \"0\"\n }\n}",
"options": {
"response": {
"response": {
"responseFormat": "json"
}
}
}
},
"id": "create-webhook",
"name": "Configure GitHub Webhook",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.3,
"position": [
1450,
300
]
},
{
"parameters": {
"language": "javaScript",
"mode": "runOnceForAllItems",
"jsCode": "// Format success response\nconst repoData = $node['Create GitHub Repository'].json;\nconst webhookData = $node['Configure GitHub Webhook'].json;\nconst payload = $node['Parse Payload & Generate Repo Name'].json;\n\nreturn [{\n json: {\n success: true,\n message: `GitHub repository created: ${repoData.full_name}`,\n githubRepo: repoData.html_url,\n repoName: repoData.name,\n webhookUrl: 'https://n8n.hudsond.me/webhook/github-render-deploy',\n businessName: payload.businessName,\n packageTier: payload.packageTier,\n timestamp: new Date().toISOString()\n }\n}];"
},
"id": "format-response",
"name": "Format Success Response",
"type": "n8n-nodes-base.code",
"typeVersion": 2,
"position": [
1650,
300
]
}
],
"connections": {
"Webhook: Create GitHub Repo": {
"main": [
[
{
"node": "Parse Payload & Generate Repo Name",
"type": "main",
"index": 0
}
]
]
},
"Parse Payload & Generate Repo Name": {
"main": [
[
{
"node": "Check if Repo Exists",
"type": "main",
"index": 0
}
]
]
},
"Check if Repo Exists": {
"main": [
[
{
"node": "Repo Already Exists?",
"type": "main",
"index": 0
}
]
]
},
"Repo Already Exists?": {
"main": [
[
{
"node": "Handle Naming Conflict",
"type": "main",
"index": 0
}
],
[
{
"node": "Create GitHub Repository",
"type": "main",
"index": 0
}
]
]
},
"Handle Naming Conflict": {
"main": [
[
{
"node": "Create GitHub Repository",
"type": "main",
"index": 0
}
]
]
},
"Create GitHub Repository": {
"main": [
[
{
"node": "Configure GitHub Webhook",
"type": "main",
"index": 0
}
]
]
},
"Configure GitHub Webhook": {
"main": [
[
{
"node": "Format Success Response",
"type": "main",
"index": 0
}
]
]
}
},
"settings": {
"executionOrder": "v1"
},
"staticData": null,
"tags": [],
"triggerCount": 1
}
For the full experience including quality scoring and batch install features for each workflow upgrade to Pro
About this workflow
Create GitHub Repository. Uses httpRequest. Webhook trigger; 8 nodes.
Source: https://github.com/senpapi69/ghost-hunter-dashboard/blob/43f2684bac0d4a6099808626151cef06cc806904/n8n-workflows/create-github-repo.json — original creator credit. Request a take-down →
Related workflows
Workflows that share integrations, category, or trigger type with this one. All free to copy and import.
This n8n template provides enterprise-level version control for your workflows using GitHub integration. Stop losing hours to broken workflows and manual exports – get proper commit history, visual di
This flow creates dummy files for every item added in your *Arrs (Radarr/Sonarr) with the tag .
This workflow acts as a central API gateway for all technical indicator agents in the Binance Spot Market Quant AI system. It listens for incoming webhook requests and dynamically routes them to the c
Sign PDF documents with legally-compliant digital signatures using X.509 certificates. Supports multiple PAdES signature levels (B, T, LT, LTA) with optional visible stamps.
📡 This workflow serves as the central Alpha Vantage API fetcher for Tesla trading indicators, delivering cleaned 20-point JSON outputs for three timeframes: , , and . It is required by the following a