AutomationFlowsGeneral › User Registration Webhook to MongoDB

User Registration Webhook to MongoDB

Original n8n title: Register

Register. Uses respondToWebhook, mongoDb. Webhook trigger; 7 nodes.

Webhook trigger★★★★☆ complexity7 nodesMongoDB
General Trigger: Webhook Nodes: 7 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": "Register",
  "nodes": [
    {
      "parameters": {
        "httpMethod": "POST",
        "path": "register",
        "responseMode": "responseNode",
        "options": {
          "allowedOrigins": "*"
        }
      },
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 2,
      "position": [
        -280,
        0
      ],
      "id": "9b49e9ea-5937-4206-91c3-b6e549719eda",
      "name": "Webhook"
    },
    {
      "parameters": {
        "options": {}
      },
      "type": "n8n-nodes-base.respondToWebhook",
      "typeVersion": 1.3,
      "position": [
        1220,
        0
      ],
      "id": "60bbeb19-9d28-4d9d-bb93-533d7845e0e3",
      "name": "Respond to Webhook"
    },
    {
      "parameters": {
        "collection": "users",
        "options": {},
        "query": "={\n  \"email\": \"{{ $('Webhook').first().json.body.email }}\"\n}"
      },
      "type": "n8n-nodes-base.mongoDb",
      "typeVersion": 1.2,
      "position": [
        0,
        0
      ],
      "id": "ae709a52-cf13-40c6-9177-521913a4794b",
      "name": "MongoDB",
      "alwaysOutputData": true,
      "credentials": {
        "mongoDb": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "conditions": {
          "options": {
            "caseSensitive": true,
            "leftValue": "",
            "typeValidation": "strict",
            "version": 2
          },
          "conditions": [
            {
              "id": "c9800ea8-9c3a-41e3-ac6c-a0ce3db1e96a",
              "leftValue": "={{ '_id' in $input.first().json }}",
              "rightValue": 0,
              "operator": {
                "type": "boolean",
                "operation": "false",
                "singleValue": true
              }
            }
          ],
          "combinator": "and"
        },
        "options": {}
      },
      "type": "n8n-nodes-base.if",
      "typeVersion": 2.2,
      "position": [
        220,
        0
      ],
      "id": "1e5e6923-9556-42c1-8f8f-7867382777da",
      "name": "If"
    },
    {
      "parameters": {
        "respondWith": "json",
        "responseBody": "{\n  \"error\": \"Usu\u00e1rio j\u00e1 existe\"\n}",
        "options": {}
      },
      "type": "n8n-nodes-base.respondToWebhook",
      "typeVersion": 1.3,
      "position": [
        880,
        100
      ],
      "id": "bf3f6608-b2cd-44e9-8641-aa49d5af448e",
      "name": "Respond to Webhook1"
    },
    {
      "parameters": {
        "operation": "insert",
        "collection": "users",
        "fields": "email,password",
        "options": {}
      },
      "type": "n8n-nodes-base.mongoDb",
      "typeVersion": 1.2,
      "position": [
        900,
        -80
      ],
      "id": "85f90a7f-7c87-4802-8a53-1b0f8e181a55",
      "name": "MongoDB1",
      "credentials": {
        "mongoDb": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "assignments": {
          "assignments": [
            {
              "id": "8a2acbee-2abd-4e6f-aebc-be27a4aaa350",
              "name": "email",
              "value": "={{ $('Webhook').first().json.body.email }}",
              "type": "string"
            },
            {
              "id": "dd66a30b-8a0a-4be7-9bf8-b6a66bc47c4b",
              "name": "password",
              "value": "={{ $('Webhook').first().json.body.password }}",
              "type": "string"
            }
          ]
        },
        "options": {}
      },
      "type": "n8n-nodes-base.set",
      "typeVersion": 3.4,
      "position": [
        600,
        -100
      ],
      "id": "47045ade-782e-477d-a045-7d1ec7df08de",
      "name": "Edit Fields"
    }
  ],
  "connections": {
    "Webhook": {
      "main": [
        [
          {
            "node": "MongoDB",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "MongoDB": {
      "main": [
        [
          {
            "node": "If",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "If": {
      "main": [
        [
          {
            "node": "Edit Fields",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Respond to Webhook1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "MongoDB1": {
      "main": [
        [
          {
            "node": "Respond to Webhook",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Edit Fields": {
      "main": [
        [
          {
            "node": "MongoDB1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "active": true,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "a991e403-7044-455c-8d28-72c7ee10b6d4",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "id": "VaJhBjwOr8wyLkc7",
  "tags": []
}

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

Register. Uses respondToWebhook, mongoDb. Webhook trigger; 7 nodes.

Source: https://github.com/albreis/manycure/blob/dd0ca71f23c3995b45f0572c4a7a9498a431ff47/workflows/Register.json — original creator credit. Request a take-down →

More General workflows → · Browse all categories →

Related workflows

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

General

Bookings. Uses jwt, mongoDb. Webhook trigger; 5 nodes.

Jwt, MongoDB
General

A production-ready authentication workflow implementing secure user registration, login, token verification, and refresh token mechanisms. Perfect for adding authentication to any application without

Crypto, Data Table, Execute Workflow Trigger
General

Portfolio Orchestrator. Uses httpRequest. Webhook trigger; 59 nodes.

HTTP Request
General

This n8n template demonstrates how a simple Multi-Layer Perceptron (MLP) neural network can predict housing prices. The prediction is based on four key features, processed through a three-layer model.

General

github code Try yourself

Google Calendar