AutomationFlowsData & Sheets › Create Module

Create Module

Create Module. Uses postgres. Webhook trigger; 4 nodes.

Webhook trigger★★☆☆☆ complexity4 nodesPostgres
Data & Sheets Trigger: Webhook Nodes: 4 Complexity: ★★☆☆☆ Added:

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 →

Download .json
{
  "name": "Create Module",
  "nodes": [
    {
      "parameters": {
        "httpMethod": "POST",
        "path": "create-module",
        "responseMode": "responseNode",
        "options": {}
      },
      "id": "e283c0f4-0014-4c05-8fa0-a99cf7341891",
      "name": "Webhook",
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 2,
      "position": [
        -464,
        48
      ]
    },
    {
      "parameters": {
        "schema": {
          "__rl": true,
          "value": "public",
          "mode": "list",
          "cachedResultName": "public"
        },
        "table": {
          "__rl": true,
          "value": "modules",
          "mode": "list",
          "cachedResultName": "modules"
        },
        "columns": {
          "mappingMode": "defineBelow",
          "value": {
            "title": "={{ $json.body.title }}",
            "description": "={{ $json.body.description }}",
            "teacher_id": "={{ $json.body.teacherId }}",
            "teacher_name": "={{ $json.body.teacherName }}"
          },
          "matchingColumns": [],
          "schema": [
            {
              "id": "title",
              "displayName": "title",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true
            },
            {
              "id": "description",
              "displayName": "description",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true
            },
            {
              "id": "teacher_id",
              "displayName": "teacher_id",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true
            },
            {
              "id": "teacher_name",
              "displayName": "teacher_name",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true
            }
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {}
      },
      "id": "104f0121-ad7f-44c5-91dd-c658cea5efe0",
      "name": "Insert Module",
      "type": "n8n-nodes-base.postgres",
      "typeVersion": 2.5,
      "position": [
        -240,
        48
      ],
      "credentials": {
        "postgres": {
          "name": "<your credential>"
        }
      },
      "onError": "continueErrorOutput"
    },
    {
      "parameters": {
        "respondWith": "json",
        "responseBody": "={\n  \"success\": true,\n  \"message\": \"Module created successfully\",\n  \"moduleId\": \"{{ $json.id }}\",\n  \"title\": \"{{ $json.title }}\"\n}",
        "options": {}
      },
      "id": "518c916f-4c78-4e2b-8d95-14300a1331b6",
      "name": "Success Response",
      "type": "n8n-nodes-base.respondToWebhook",
      "typeVersion": 1.1,
      "position": [
        0,
        0
      ]
    },
    {
      "parameters": {
        "respondWith": "json",
        "responseBody": "={\n  \"success\": false,\n  \"message\": \"Failed to create module. Please try again.\",\n  \"error\": \"{{ $json.error?.message || 'Database error' }}\"\n}",
        "options": {
          "responseCode": 500
        }
      },
      "id": "6acbf703-e1b9-4024-8d58-1e4768e8d8d6",
      "name": "Error Response",
      "type": "n8n-nodes-base.respondToWebhook",
      "typeVersion": 1.1,
      "position": [
        0,
        160
      ]
    }
  ],
  "connections": {
    "Webhook": {
      "main": [
        [
          {
            "node": "Insert Module",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Insert Module": {
      "main": [
        [
          {
            "node": "Success Response",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Error Response",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "active": true,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "fd2d803b-9518-40dd-a918-dd78aa54b439",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "id": "NGwkWC7qMuALhGvP",
  "tags": [
    {
      "updatedAt": "2025-12-22T11:04:00.847Z",
      "createdAt": "2025-12-22T11:04:00.847Z",
      "id": "aMug7NNgyX2UPh15",
      "name": "school-platform"
    }
  ]
}

Credentials you'll need

Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.

Pro

For the full experience including quality scoring and batch install features for each workflow upgrade to Pro

About this workflow

Create Module. Uses postgres. Webhook trigger; 4 nodes.

Source: https://github.com/CodingNeeds/todoList/blob/7062de7f683b7758b36970ac80eb8784710495bc/n8n/CreateModuleWorking.json — original creator credit. Request a take-down →

More Data & Sheets workflows → · Browse all categories →

Related workflows

Workflows that share integrations, category, or trigger type with this one. All free to copy and import.

Data & Sheets

This n8n template demonstrates how to create a comprehensive voice-powered restaurant assistant that handles table reservations, food orders, and restaurant information requests through natural langua

Postgres
Data & Sheets

Create - KB. Uses postgres, crypto. Webhook trigger; 10 nodes.

Postgres, Crypto
Data & Sheets

Acts as a virtual receptionist for the restaurant, handling incoming calls via VAPI without human intervention. It collects user details (name, booking time, number of people) for table bookings, chec

Postgres
Data & Sheets

Get - KB. Uses postgres. Webhook trigger; 9 nodes.

Postgres
Data & Sheets

Text-to-SQL: Check Status. Uses postgres. Webhook trigger; 5 nodes.

Postgres