{
  "name": "New Contact Onboarding Workflow",
  "nodes": [
    {
      "parameters": {
        "httpMethod": "POST",
        "path": "/webhook/contact-created",
        "responseMode": "onReceived",
        "options": {}
      },
      "name": "Contact Created Webhook",
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 1,
      "position": [
        250,
        300
      ]
    },
    {
      "parameters": {
        "conditions": {
          "string": [
            {
              "value1": "={{ $json.jobtitle }}",
              "operation": "contains",
              "value2": "CEO"
            }
          ]
        }
      },
      "name": "Check if VIP",
      "type": "n8n-nodes-base.if",
      "typeVersion": 1,
      "position": [
        450,
        300
      ]
    },
    {
      "parameters": {
        "fromEmail": "sales@company.com",
        "toEmail": "sales-team@company.com",
        "subject": "New VIP Contact: {{ $json.fullname }}",
        "text": "A new VIP contact has been created.\n\nName: {{ $json.fullname }}\nCompany: {{ $json.company }}\nEmail: {{ $json.email }}\n\nPlease prioritize outreach.",
        "options": {
          "attachments": ""
        }
      },
      "name": "Send VIP Notification",
      "type": "n8n-nodes-base.emailSend",
      "typeVersion": 1,
      "position": [
        650,
        200
      ]
    },
    {
      "parameters": {
        "resource": "task",
        "operation": "create",
        "title": "Follow up with VIP: {{ $json.fullname }}",
        "dueDate": "={{ $now.plus({days: 3}).toISO() }}",
        "additionalFields": {
          "description": "Schedule introductory call with new VIP contact {{ $json.fullname }} from {{ $json.company }}"
        }
      },
      "name": "Create Follow-up Task",
      "type": "n8n-nodes-base.todoist",
      "typeVersion": 1,
      "position": [
        850,
        200
      ]
    },
    {
      "parameters": {
        "fromEmail": "welcome@company.com",
        "toEmail": "={{ $json.email }}",
        "subject": "Welcome to Our Platform!",
        "text": "Dear {{ $json.firstname }},\n\nThank you for your interest in our platform. A member of our team will be in touch soon.\n\nBest regards,\nThe Sales Team",
        "options": {}
      },
      "name": "Send Welcome Email",
      "type": "n8n-nodes-base.emailSend",
      "typeVersion": 1,
      "position": [
        650,
        400
      ]
    },
    {
      "parameters": {
        "method": "POST",
        "url": "https://api.company.com/audit",
        "options": {},
        "bodyParameters": {
          "parameters": [
            {
              "name": "event",
              "value": "contact_created"
            },
            {
              "name": "contact_name",
              "value": "={{ $json.fullname }}"
            },
            {
              "name": "timestamp",
              "value": "={{ $now.toISO() }}"
            }
          ]
        }
      },
      "name": "Log to Audit API",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 1,
      "position": [
        1050,
        300
      ]
    }
  ],
  "connections": {
    "Contact Created Webhook": {
      "main": [
        [
          {
            "node": "Check if VIP",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Check if VIP": {
      "main": [
        [
          {
            "node": "Send VIP Notification",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Send Welcome Email",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Send VIP Notification": {
      "main": [
        [
          {
            "node": "Create Follow-up Task",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create Follow-up Task": {
      "main": [
        [
          {
            "node": "Log to Audit API",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Send Welcome Email": {
      "main": [
        [
          {
            "node": "Log to Audit API",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "active": true,
  "settings": {
    "executionOrder": "v1"
  },
  "id": "n8n-workflow-001",
  "tags": [
    {
      "id": "1",
      "name": "CRM"
    },
    {
      "id": "2",
      "name": "Onboarding"
    }
  ]
}