feat(auth): add configurable scope enforcement with scope_mode option - #625
Style Review Completed
The pull request has 7 style issues.
Duration: 783ms
PR URL: #625
Review Log: View detailed log
Review Comments: The AI has posted 7 inline comments with suggestions
Summary of changes:
Updated documentation to use gerunds for conceptual headings and replaced 'MCP Server' with 'Apollo Server' to ensure consistent product naming. Refined grammar by removing articles before 'Apollo Server', limiting bold text to UI elements, and removing parentheticals from headings. Improved stylistic consistency by maintaining active voice, using imperative verbs, and ensuring descriptions remain concise, unpunctuated fragments.
Annotations
Check notice on line 61 in docs/source/auth.mdx
apollo-librarian / AI Style Review
docs/source/auth.mdx#L61
Use gerunds for headings in conceptual overview pages.
```suggestion
## Configuring scope enforcement
```
Check warning on line 63 in docs/source/auth.mdx
apollo-librarian / AI Style Review
docs/source/auth.mdx#L63
Use Apollo Server instead of MCP Server to maintain consistent product naming.
```suggestion
Use the `scope_mode` option to control how Apollo Server validates scopes from OAuth tokens.
```
Check notice on line 67 in docs/source/auth.mdx
apollo-librarian / AI Style Review
docs/source/auth.mdx#L67
The word 'all' is used correctly here, but ensure the surrounding documentation uses imperative verbs and active voice. This line is acceptable as a table entry fragment.
```suggestion
| `require_all` | Token must have all configured scopes (default) |
```
Check warning on line 68 in docs/source/auth.mdx
apollo-librarian / AI Style Review
docs/source/auth.mdx#L68
Do not use bold for general emphasis. Use bold only for interactive UI elements or specific user roles.
```suggestion
| `require_any` | Token must have at least one of the configured scopes |
```
Check notice on line 71 in docs/source/auth.mdx
apollo-librarian / AI Style Review
docs/source/auth.mdx#L71
Remove parentheticals from headings. Use the subtitle or body text to indicate default status.
```suggestion
### Require all scopes
```
Check warning on line 119 in docs/source/auth.mdx
apollo-librarian / AI Style Review
docs/source/auth.mdx#L119
Do not use 'the' before Apollo Server. Use 'Apollo Server' as a proper product name without an article.
```suggestion
Use `scope_mode: disabled` only when downstream services, such as subgraphs, handle authorization. Without scope enforcement, any valid token grants full access to Apollo Server.
```
Check notice on line 284 in docs/source/config-file.mdx
apollo-librarian / AI Style Review
docs/source/config-file.mdx#L284
The description uses 'or' which is unopinionated. Prescribe the recommended mode if applicable, or ensure the description remains a simple fragment without ending punctuation.
```suggestion
| `scope_mode` | `string` | `require_all` | Scope enforcement mode: `disabled`, `require_all`, or `require_any` |
```