Spaces:
Paused
Paused
Download src/routes/utils.js from Huzaifa1313/Prof_app: direct link, hf CLI and curl.
- Browser
- Download file 696 Bytes
-
https://huggingface.co/spaces/Huzaifa1313/Prof_app/resolve/main/src/routes/utils.js
- Command line
-
hf download hf://spaces/Huzaifa1313/Prof_app/src/routes/utils.js
-
curl -L -o utils.js https://huggingface.co/spaces/Huzaifa1313/Prof_app/resolve/main/src/routes/utils.js
696 Bytes
| const express = require('express'); | |
| const router = express.Router(); | |
| const { verifyToken } = require('../middleware/auth'); | |
| const UtilityController = require('../controllers/utilityController'); | |
| /** | |
| * POST /api/utils/validate-profile | |
| * Validate professional profile completeness. | |
| * Returns: { isComplete, missingFields } | |
| */ | |
| router.post('/validate-profile', verifyToken, UtilityController.validateProfessionalProfile); | |
| /** | |
| * POST /api/utils/reset-test-data | |
| * Reset user data for testing (delete bookings, chats, reset wallet to 5000). | |
| * Dev/test only — disabled in production. | |
| */ | |
| router.post('/reset-test-data', verifyToken, UtilityController.resetTestData); | |
| module.exports = router; | |