from flask_restx import Namespace, Resource 

health_namespace = Namespace('health', description='Face Detection and Tracking ML operations')
 
@health_namespace.route('/check')
class HealthCheck(Resource):
    def get(self, ):
        try:
            return { 
                'success': True, 
                'message': "healthy" 
            }, 200
        except Exception as e:
            print(f"Error retrieving face detection results: {e}")
            return {'message': 'An error occurred while retrieving face detection results.'}, 500