An OAuth2-secured MCP server with a Spring Authorization Server that adds Dynamic Client Registration in front of a federated IdP (Keycloak)
Spring OAuth2 MCP demonstrates solid fundamentals with clear verb-based naming (whoami, list_notes, create_note, purge_notes) and explicit risk classifications. Tool descriptions are present and contextual, explaining scope requirements and use cases. However, input schemas are minimal or absent for most tools, and parameter descriptions lack detail. The server prioritizes security (scope-gating, JWT validation) over comprehensive schema documentation. Output schemas are not documented. Error handling is implicit (scope validation) but not explicitly guided for LLM recovery.
Create a note (recorded under your identity). Requires the note:write scope.
List all notes. Requires the note:read scope.
Delete ALL notes. Admin-only — requires the note:admin scope.
Returns your authenticated identity (subject, username, email) and the scopes your token carries. Any authenticated caller — use it to see what the note tools (list_notes / create_note / purge_notes) will allow.
Input schemas incomplete or missing for 3 of 4 tools. whoami, list_notes, and purge_notes declare empty input objects {} with no parameter descriptions. LLMs cannot infer pagination, filtering, or optional flags.
Output schemas not documented. Clients do not know what fields to expect from list_notes (does it return note IDs, timestamps, author info?) or create_note (does it return the created note object or just an ID?). This forces LLMs to guess and risks parsing errors.
No pagination support declared. list_notes has no limit, offset, or cursor parameters visible. Returning all notes in one call risks context window exhaustion and violates the pattern of capping results at 20-50 items.
Inferred effective spec: 2026-07-28+.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | D | 59 | 2026-07-28+ | v2 |
Error handling is implicit (scope validation via @PreAuthorize) but not explicitly documented. LLMs do not know what error messages to expect or how to recover from 'insufficient scope' failures. No recovery guidance in tool descriptions.
create_note parameter 'text' lacks constraints. No min/max length, no format guidance. LLMs may pass empty strings, extremely long text, or special characters without validation hints.