
Dynamic OAuth Scopes in Next.js
Solved an authentication issue in KueCloud Genius onboarding by adjusting Discord OAuth scopes based on user role. Utilized NextAuth.js to make Discord provider's scope dynamic, ensuring invited users don't need 'bot applications.commands' scope, simplifying login.