You check the OAuth scopes.
They ask for more than they need.
One wrong click, and a compromised token could read, write, and delete in systems you thought were locked down.
OAuth scopes exist to limit access. They define exactly what an app can do. Yet in many teams, scope management is chaotic—spread across spreadsheets, config files, and tribal knowledge. Without strict governance, scopes pile up, drift from best practice, and open attack surfaces no one is watching.
Security as Code changes that.
Treat scopes like any other critical resource in your codebase. Declare them, version them, review them in pull requests. Automate checks to ensure an app only gets the scopes it needs. Integrate this into CI/CD so violations fail the build before they can reach production.