return jsonResponse on deauthenticate to send cors
add frontend authentication (testing)