Can't wrap my head around the login flow

System Information
  • Strapi Version: 3.6.8
  • Operating System: Windows 10
  • Database: PostgreSQL 13
  • Node Version: v14.16.1
  • Yarn Version: 1.22.15

Hey there! I’m trying to customise the login flow with auth providers but I can’t wrap my head around it. Which files should I edit to handle an auth request before it gets redirected to the third party provider?