Implementation of Authentication with Next js and Next Auth as frontend and multiple backend frameworks. It implements the best way to block access to certain page, and redirect the user. It also block access to certain api endpoints if the user is not authenticated.