Run gh auth status and read the scopes line for the active account. Expected output: the account is listed and you can see whether repo appears in its scopes.

Refresh the scopes, adding repo, and complete the browser or device prompt that follows. Expected output: the refresh finishes and reports the account as signed in.

Run gh auth status again. Expected output: repo now appears in the scopes list for the active account.

Retry the failing API call unchanged. Expected output: the call returns repository data instead of a 403 scope error.

If it still fails, check for multiple signed-in accounts and switch to the one that owns access to the repository, then repeat steps 1 to 4. Expected output: the active account matches the repository owner access.