The Lnav service had stopped authorizing half the client calls. The scopes were wrong.
OAuth scopes control exactly what a token can do inside Lnav. Misconfigured scopes break features or open the door to data leakage. Managing them well is not optional. It is the core of keeping your system secure and predictable.
Lnav OAuth scopes management starts with clear mapping between each scope and its allowed API actions. Build a scope inventory. For every endpoint, define the minimum set of scopes needed. Remove anything unused. This prevents privilege creep, where tokens gain more access than intended.
Use environment-specific scope lists. Production scopes should be locked down. Development scopes can be broader but still controlled. Automate scope audits so you get alerts when a role or app’s scopes drift from baseline. Store configurations in source control for transparency and rollback.