top of page
Search

Part 3: How to Build a 4-Hour Onboarding System (Node.js + TypeScript Implementation)

  • Writer: Mark Kendall
    Mark Kendall
  • 21 hours ago
  • 3 min read





🚀

LearnTeachMaster.org | Intent-Driven Engineering




Part 3: How to Build a 4-Hour Onboarding System (Node.js + TypeScript Implementation)






Intro



In Part 1, we defined onboarding clearly:


Onboarding is complete when a new employee can log in, connect, and operate on Day 1.


In Part 2, we broke that down into what must happen:


  • Identity

  • Communication

  • Access

  • Manager connection



Now we move into the part most organizations never reach:


How do you actually build this system?


Not conceptually.

Not architecturally.


Practically.





What Is Step 3 in Intent-Driven Engineering?



Step 3 is implementation of execution capability.


Not integration yet.

Not optimization.


Just this:


Can your system execute onboarding intent reliably, in parallel, without human intervention?





🧠

The Core Shift



Most companies try to automate onboarding inside tools.


We do the opposite.


We build an execution layer outside the tools.


That execution layer becomes your Shared Services Platform.





🏗️

Implementation Architecture (Node.js + TypeScript)






🧱

Step 1: Create the Orchestration Gateway



This is your entry point.


Everything flows through here — including ServiceNow.



Responsibilities:



  • Accept onboarding intent

  • Trigger execution

  • Coordinate services

  • Return status






💻 Example (Node.js + TypeScript)


import express from "express";

import axios from "axios";


const app = express();

app.use(express.json());


app.post("/onboard", async (req, res) => {

  const { employeeId, manager } = req.body;


  await Promise.all([

    axios.post("http://teams-service/setup", { employeeId }),

      employeeId,

      manager,

    }),

  ]);


  res.json({ status: "ONBOARDING_STARTED" });

});


app.listen(3000);





🧩

Step 2: Build Thin Microservices



Each capability becomes a focused service.





🔹 Identity Service



  • Creates user in Active Directory




🔹 Email Service



  • Provisions mailbox




🔹 Collaboration Service






🔹 Access Service



  • Configures VPN + MFA




🔹 Notification Service



  • Connects employee to manager






💻 Example (Identity Service)


import express from "express";


const app = express();

app.use(express.json());


app.post("/create-user", async (req, res) => {

  const { employeeId } = req.body;


  console.log(`Creating user for ${employeeId}`);


  // Simulated provisioning

  await new Promise((r) => setTimeout(r, 500));


  res.json({ status: "USER_CREATED" });

});


app.listen(3001);





Step 3: Execute Everything in Parallel



This is where you win.


Traditional systems:


  • Sequential execution ❌



Intent-driven systems:


  • Parallel execution ✅



Identity, email, Teams, VPN — all happen at the same time.


This is how you achieve 4-hour onboarding.





🔁

Step 4: Add Event Feedback (Basic Level)



Each service should emit completion events.


Example:


  • IdentityCreated

  • EmailReady

  • AccessGranted



These events:


  • Update status

  • Enable retries

  • Provide visibility



👉 Full integration comes in Part 4





🧠

Step 5: Track State (Not Tasks)



Do not track tickets.


Track state transitions:


  • INITIATED

  • IDENTITY_READY

  • COMMUNICATION_READY

  • ACCESS_READY

  • COMPLETE



This gives you:


  • Deterministic completion

  • Real-time progress

  • Measurable success






🔐

Step 6: Build for Reliability (Day 1)



Even in your first version:


  • APIs must be idempotent

  • Retries must be safe

  • Failures must not restart everything






💻 Example (Idempotency Pattern)


const processed = new Set();


app.post("/create-user", async (req, res) => {

  const { employeeId } = req.body;


  if (processed.has(employeeId)) {

    return res.json({ status: "ALREADY_CREATED" });

  }


  processed.add(employeeId);


  res.json({ status: "USER_CREATED" });

});





🧭

What You Do NOT Do (Important)



  • ❌ No heavy scripting in ServiceNow

  • ❌ No manual ticket routing

  • ❌ No sequential workflows

  • ❌ No tightly coupled systems






📦

What You Hand to Your Tech Team



At the end of Step 3, your team should have:


  • Orchestration gateway (Node.js + TypeScript)

  • Core microservices (identity, email, access, etc.)

  • Parallel execution model

  • Basic event emission

  • State tracking



👉 Not perfect.

👉 But fully functional.





Why This Matters



This is the moment onboarding stops being:


  • A process

  • A checklist

  • A bottleneck



And becomes:


A system that executes intent predictably and repeatedly





Key Takeaways



  • Build an execution layer outside of ServiceNow

  • Use Node.js + TypeScript for scalable, event-driven systems

  • Create thin, focused microservices

  • Execute onboarding tasks in parallel

  • Track state, not tickets

  • Step 3 is about execution capability—not integration yet






🔥

What’s Next (Part 4)



In Part 4, we complete the system:


How everything connects — integration, event backbone, retries, and enterprise hardening


This is where:


  • Systems become decoupled

  • Failures become recoverable

  • Onboarding becomes truly autonomous






 
 
 

Recent Posts

See All

Comments

Rated 0 out of 5 stars.
No ratings yet

Add a rating
Post: Blog2_Post

Subscribe Form

Thanks for submitting!

©2020 by LearnTeachMaster DevOps. Proudly created with Wix.com

bottom of page