Fix authentication response handling
Fix request handling
Add missing function parameter types