@startuml
skinparam backgroundColor white
skinparam defaultFontColor black
skinparam ArrowColor black
skinparam shadowing false
skinparam rectangle {
  BorderColor black
  FontColor black
}

title After: Namespaced Auth Docs + Enforced Binding/Route Parity

rectangle "docs/auth/" as authDocs #E8F0FE {
  rectangle "README.md\n(createClient().auth)" as authRoot #F6F9FE
  rectangle "session/" as authSession #F6F9FE
  rectangle "user/" as authUser #F6F9FE
  rectangle "organization/\n  invitation/\n  member/" as authOrg #F6F9FE
  rectangle "sign-in/" as authSignIn #F6F9FE
  rectangle "api-key/" as authApiKey #F6F9FE
  rectangle "admin/\n  role/\n  user/session/\n  email/failure/\n  email/template/" as authAdmin #F6F9FE
  rectangle "callback/" as authCallback #F6F9FE
  rectangle "passkey/" as authPasskey #F6F9FE
  rectangle "two-factor/" as authTwoFactor #F6F9FE
}

rectangle "sdk-api-bindings.md\n(authoritative map)" as sdkRaw #FFEFD5
rectangle "Compatibility test:\n`test_sdk_binding_routes_are_implemented_and_documented`" as compatTest #FFF4CC
rectangle "OpenAPI (openapi.yaml + athena-auth.yaml)" as openapi #E6F7EA
rectangle "Server route stack\n(core + plugins)" as serverRoutes #E6F7EA

note right of authAdmin #EAF3FF
Normalized admin template naming:
auth.admin.email.template.*
end note

authDocs --> sdkRaw : references
sdkRaw --> compatTest : parsed routes
compatTest --> openapi : validate present
compatTest --> serverRoutes : validate implemented

@enduml
