From 9e842c6774e40f1990c69bfb7983569f30ab0e46 Mon Sep 17 00:00:00 2001 From: Chandresh Kerkar Date: Sun, 14 Dec 2025 20:30:30 +0530 Subject: [PATCH] Working with latest DB --- public/test.html | 187 ++++++++++++++++++++++++++++++++++- src/middleware/stepUpAuth.js | 22 ++++- src/middleware/validation.js | 61 +++++++++--- src/routes/authRoutes.js | 25 ++++- src/routes/userRoutes.js | 150 +++++++++++++++++++++++++--- src/services/riskScoring.js | 27 +++-- src/services/tokenService.js | 182 ++++------------------------------ 7 files changed, 434 insertions(+), 220 deletions(-) diff --git a/public/test.html b/public/test.html index f7020f9..697b34f 100644 --- a/public/test.html +++ b/public/test.html @@ -41,6 +41,7 @@

3. Complete Profile (name + user_type)

+

⚠️ Requires OTP verification first (Step 2)

Uses the access_token from step 2

@@ -53,21 +54,64 @@ - +

   

4. Get User Details

+

⚠️ Requires OTP verification first (Step 2)

Authenticated GET request to fetch user profile with JWT token

Shows: phone number, name, profile type, location, last login, and all saved locations

- +

   
+
+

5. Add/Update Location

+

⚠️ Requires OTP verification first (Step 2)

+

Save your current location or a custom address

+ + + + + + + + + + + + + + + + + + + + + + + + + +

+  
+