Base Path: /api/auth
- Purpose: User login
- Controller:
loginUser - Access Control: Not enforced in this router
- Validation:
- Body:
userLoginSchema
- Body:
- Purpose: Driver login
- Controller:
loginDriver - Access Control: Not enforced in this router
- Validation:
- Body:
driverLoginSchema
- Body:
- Purpose: Create a new user account
- Controller:
registerUser - Access Control: Not enforced in this router
- Validation:
- Body:
userRegistrationSchema
- Body:
- Purpose: Create a new driver account
- Controller:
registerDriver - Access Control: Not enforced in this router
- Validation:
- Body:
driverRegistrationSchema
- Body:
- Purpose: Get user profile by ID
- Controller:
getUserProfile - Access Control: Not enforced in this router; recommended to require authentication
- Validation:
- Params:
userIdParamSchema
- Params:
- Purpose: Authentication statistics
- Controller:
getAuthStats - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Query:
authStatsQuerySchema
- Query:
- Purpose: Bulk update status of users/drivers
- Controller:
bulkUpdateStatus - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Body:
bulkStatusUpdateSchema
- Body:
- Purpose: Perform auth maintenance operation
- Controller:
performMaintenance - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Body:
maintenanceOperationSchema
- Body:
Base Path: /api/drivers
- Purpose: Register a new driver
- Controller:
registerDriver - Access Control: Not enforced in this router
- Validation:
- Body:
driverRegistrationSchema
- Body:
- Purpose: Get driver profile
- Controller:
getDriverProfile - Access Control: Not enforced in this router
- Validation:
- Params:
driverIdParamSchema
- Params:
- Purpose: Update driver profile
- Controller:
updateDriverProfile - Access Control: Not enforced in this router
- Validation:
- Params:
driverIdParamSchema - Body:
driverUpdateSchema
- Params:
- Purpose: Get driver earnings
- Controller:
getDriverEarnings - Access Control: Not enforced in this router
- Validation:
- Params:
driverIdParamSchema - Query:
driverEarningsQuerySchema
- Params:
- Purpose: Get driver bid history
- Controller:
getDriverBids - Access Control: Not enforced in this router
- Validation:
- Params:
driverIdParamSchema - Query:
driverBidHistoryQuerySchema
- Params:
- Purpose: Get driver ride history
- Controller:
getDriverRideHistory - Access Control: Not enforced in this router
- Validation:
- Params:
driverIdParamSchema - Query:
driverRideHistoryQuerySchema
- Params:
- Purpose: Update driver location
- Controller:
updateDriverLocation - Access Control: Not enforced in this router
- Validation:
- Params:
driverIdParamSchema - Body:
driverLocationUpdateSchema
- Params:
- Purpose: Get driver statistics
- Controller:
getDriverStats - Access Control: Not enforced in this router
- Validation:
- Params:
driverIdParamSchema - Query:
analyticsQuerySchema
- Params:
- Purpose: Get driver vehicles
- Controller:
getDriverVehicles - Access Control: Not enforced in this router
- Validation:
- Params:
driverIdParamSchema
- Params:
- Purpose: Assign vehicles to driver
- Controller:
assignVehiclesToDriver - Access Control: Not enforced in this router
- Validation:
- Params:
driverIdParamSchema - Body:
driverVehicleAssignmentSchema
- Params:
- Purpose: Remove vehicles from driver
- Controller:
removeVehiclesFromDriver - Access Control: Not enforced in this router
- Validation:
- Params:
driverIdParamSchema - Body:
driverVehicleAssignmentSchema
- Params:
- Purpose: Update driver vehicle info (use vehicle endpoints instead)
- Controller:
updateDriverProfile - Access Control: Not enforced in this router
- Validation:
- Params:
driverIdParamSchema - Body:
driverUpdateSchema
- Params:
- Purpose: List available drivers
- Controller:
getAvailableDrivers - Access Control: Not enforced in this router
- Validation:
- Query:
driverQuerySchema
- Query:
- Purpose: Find nearby drivers
- Controller:
getNearbyDrivers - Access Control: Not enforced in this router
- Validation:
- Query:
nearbyDriversQuerySchema
- Query:
- Purpose: Bulk update driver status
- Controller:
bulkUpdateDriverStatus - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Body:
bulkUpdateDriverStatusSchema
- Body:
- Purpose: Driver performance analytics
- Controller:
getDriverAnalytics - Access Control: Not enforced in this router
- Validation:
- Params:
driverIdParamSchema - Query:
driverAnalyticsQuerySchema
- Params:
- Purpose: List connected drivers (debug/admin)
- Controller: Inline handler (uses
getConnectedDrivers()) - Access Control: Not enforced in this router; intended admin/debug
- Validation: None
Base Path: /api/ride-requests
- Purpose: Get available ride requests for drivers
- Controller:
getAvailableRideRequests - Access Control: Not enforced in this router
- Validation:
- Query:
availableRideRequestsQuerySchema
- Query:
- Purpose: Get a specific ride request
- Controller:
getRideRequest - Access Control: Not enforced in this router
- Validation:
- Params:
requestIdParamSchema
- Params:
- Purpose: Get all ride requests for a user
- Controller:
getUserRideRequests - Access Control: Not enforced in this router
- Validation:
- Params:
userIdParamSchema - Query:
getRideRequestsQuerySchema
- Params:
- Purpose: Get bids for a ride request
- Controller:
getRideRequestBids - Access Control: Not enforced in this router
- Validation:
- Params:
requestIdParamSchema - Query:
getBidsQuerySchema
- Params:
- Purpose: Ride request analytics
- Controller:
getRideRequestAnalytics - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Query:
rideRequestAnalyticsQuerySchema
- Query:
- Purpose: Bulk cancel ride requests
- Controller:
bulkCancelRequests - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Body:
bulkCancelRequestsSchema
- Body:
- Purpose: Optimize ride matching
- Controller:
optimizeMatching - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Body:
optimizeMatchingSchema
- Body:
Base Path: /api/users
- Purpose: Register a new user
- Controller:
registerUser - Access Control: Not enforced in this router
- Validation:
- Body:
userRegistrationSchema
- Body:
- Purpose: Get user profile
- Controller:
getUserProfile - Access Control: Not enforced in this router
- Validation:
- Params:
userIdParamSchema
- Params:
- Purpose: Update user profile
- Controller:
updateUserProfile - Access Control: Not enforced in this router
- Validation:
- Params:
userIdParamSchema - Body:
userUpdateSchema
- Params:
- Purpose: Get user ride history
- Controller:
getUserRideHistory - Access Control: Not enforced in this router
- Validation:
- Params:
userIdParamSchema - Query:
userRideHistoryQuerySchema
- Params:
- Purpose: Get user statistics
- Controller:
getUserStats - Access Control: Not enforced in this router
- Validation:
- Params:
userIdParamSchema - Query:
analyticsQuerySchema
- Params:
Base Path: /api/vehicles
- Purpose: Search vehicles for a ride
- Controller:
searchVehiclesForRide - Access Control: Not enforced in this router
- Validation:
- Query:
vehicleSearchForRideSchema
- Query:
- Purpose: Get vehicles filtered by type
- Controller:
getVehiclesByType - Access Control: Not enforced in this router
- Validation:
- Query:
vehicleByTypeQuerySchema
- Query:
- Purpose: Get vehicle statistics
- Controller:
getVehicleStatistics - Access Control: Not enforced in this router
- Validation:
- Query:
vehicleStatisticsQuerySchema
- Query:
- Purpose: Vehicle analytics
- Controller:
getVehicleAnalytics - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Query:
vehicleAnalyticsSchema
- Query:
- Purpose: Get vehicle maintenance recommendations
- Controller:
getMaintenanceRecommendations - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Query:
maintenanceRecommendationsQuerySchema
- Query:
- Purpose: Bulk update vehicle statuses
- Controller:
bulkUpdateVehicleStatus - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Body:
bulkVehicleStatusUpdateSchema
- Body:
- Purpose: Optimize vehicle allocation
- Controller:
optimizeVehicleAllocation - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Body:
vehicleAllocationOptimizationSchema
- Body:
- Purpose: List all vehicles
- Controller:
getVehicles - Access Control: Not enforced in this router
- Validation:
- Query:
vehicleQuerySchema
- Query:
- Purpose: Create a new vehicle
- Controller:
createVehicle - Access Control: Not enforced in this router
- Validation:
- Body:
vehicleCreationSchema
- Body:
- Purpose: Get a specific vehicle
- Controller:
getVehicle - Access Control: Not enforced in this router
- Validation:
- Params:
vehicleIdSchema
- Params:
- Purpose: Update a vehicle
- Controller:
updateVehicle - Access Control: Not enforced in this router
- Validation:
- Params:
vehicleIdSchema - Body:
vehicleUpdateSchema
- Params:
- Purpose: Update vehicle status
- Controller:
updateVehicleStatus - Access Control: Not enforced in this router
- Validation:
- Params:
vehicleIdSchema - Body:
vehicleStatusUpdateSchema
- Params:
- Purpose: Delete a vehicle
- Controller:
deleteVehicle - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Params:
vehicleIdSchema
- Params:
- Purpose: Update user location
- Controller:
updateUserLocation - Access Control: Not enforced in this router
- Validation:
- Params:
userIdParamSchema - Body:
userLocationUpdateSchema
- Params:
- Purpose: Update user preferences
- Controller:
updateUserPreferences - Access Control: Not enforced in this router
- Validation:
- Params:
userIdParamSchema - Body:
userPreferencesUpdateSchema
- Params:
- Purpose: Get personalized vehicle recommendations
- Controller:
getPersonalizedRecommendations - Access Control: Not enforced in this router
- Validation:
- Params:
userIdParamSchema - Query:
userRecommendationsQuerySchema
- Params:
- Purpose: Get user's favorite drivers and vehicles
- Controller:
getUserFavorites - Access Control: Not enforced in this router
- Validation:
- Params:
userIdParamSchema
- Params:
- Purpose: User analytics
- Controller:
getUserAnalytics - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Query:
userAnalyticsQuerySchema
- Query:
- Purpose: Bulk update user preferences
- Controller:
bulkUpdatePreferences - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Body:
bulkUpdatePreferencesSchema
- Body:
Base Path: /api/admin
- Purpose: Ride request statistics
- Controller: Inline (uses
DataPersistenceService.getRideRequestStats) - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Query:
adminStatsQuerySchema
- Query:
- Purpose: Driver bid history
- Controller: Inline (uses
DataPersistenceService.getDriverBidHistory) - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Params:
driverIdParamSchema - Query:
adminPaginationSchema
- Params:
- Purpose: User ride history
- Controller: Inline (uses
DataPersistenceService.getUserRideHistory) - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Params:
userIdParamSchema - Query:
adminPaginationSchema
- Params:
- Purpose: Pending bids
- Controller: Inline (uses
DataPersistenceService.getPendingBids) - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Query:
adminPendingBidsQuerySchema
- Query:
- Purpose: Cleanup old ride requests
- Controller: Inline (uses
DataPersistenceService.cleanupOldRequests) - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Backup ride request data
- Controller: Inline (uses
DataPersistenceService.backupRideRequestData) - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Persistence health check
- Controller: Inline (uses
DataPersistenceService.getRideRequestStats,DataPersistenceService.recoverActiveRideRequests) - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Authentication analytics
- Controller:
getAuthStats - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Driver analytics
- Controller:
getDriverAnalytics - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Ride request analytics
- Controller:
getRideRequestAnalytics - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: User analytics
- Controller:
getUserAnalytics - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Vehicle analytics
- Controller:
getVehicleAnalytics - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Socket connection analytics
- Controller:
getConnectionAnalytics - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Bulk update authentication status
- Controller:
bulkUpdateStatus - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Bulk update driver status
- Controller:
bulkUpdateDriverStatus - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Bulk update user preferences
- Controller:
bulkUpdatePreferences - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Optimize ride matching
- Controller:
optimizeMatching - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Optimize vehicle allocation
- Controller:
optimizeVehicleAllocation - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Optimize socket performance
- Controller:
optimizeSocketPerformance - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Auth maintenance
- Controller:
performMaintenance - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Vehicle maintenance recommendations
- Controller:
getMaintenanceRecommendations - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: Broadcast announcement
- Controller:
broadcastAnnouncement - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
- Purpose: User behavior insights
- Controller:
getUserBehaviorInsights - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation: None
Base Path: /api/socket
- Purpose: Socket analytics
- Controller:
getConnectionAnalytics - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Query:
socketAnalyticsQuerySchema
- Query:
- Purpose: Connected drivers
- Controller: Inline (uses
getConnectedDrivers) - Access Control: Not enforced in this router; intended admin/debug
- Validation: None
- Purpose: Connected users
- Controller: Inline (uses
getConnectedUsers) - Access Control: Not enforced in this router; intended admin/debug
- Validation: None
- Purpose: Connection statistics
- Controller: Inline (uses
getConnectionStats) - Access Control: Not enforced in this router; intended admin/debug
- Validation: None
- Purpose: Broadcast to clients
- Controller:
broadcastAnnouncement - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Body:
broadcastMessageSchema
- Body:
- Purpose: Manage socket rooms
- Controller:
manageSocketRooms - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Body:
socketRoomSchema
- Body:
- Purpose: Optimize socket performance
- Controller:
optimizeSocketPerformance - Access Control: Not enforced in this router; intended admin-only (add middleware)
- Validation:
- Body:
socketOptimizationSchema
- Body: