# heangchihav/springboot-auth-code-flow architecture

> Architecture diagram of the GitHub repository heangchihav/springboot-auth-code-flow, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-16). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/heangchihav/springboot-auth-code-flow
- Repository: https://github.com/heangchihav/springboot-auth-code-flow

## Overview

This repository appears to be a collection of five Spring Boot OAuth examples: authorization-code flow, PKCE, two client variants, and a protected resource service. The tree identifies controllers, security/configuration classes, and client/service components, but no README or source excerpts were provided. Consequently, the graph shows the application components without asserting calls, OAuth redirects, token exchanges, or resource requests that cannot be verified.

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_auth_code["Authorization Code Sample"]
  node_auth_app["Application"]
  node_auth_security["Security Config"]
  node_auth_home["Home Controller"]
  node_auth_userinfo["User Info Service"]
end

subgraph group_pkce["PKCE Sample"]
  node_pkce_app["Application"]
  node_pkce_security["Security Config"]
  node_pkce_api["API Controller<br/>[ApiController.java]"]
end

subgraph group_client["Proxy Client Sample"]
  node_client_app["Application"]
  node_client_security["Security Config"]
  node_client_web["Web Config<br/>[WebConfig.java]"]
  node_proxy_controller["Proxy Controller"]
  node_resource_service["Resource Service"]
  node_resource_client["Resource Client"]
end

subgraph group_pure_client["Pure Client Sample"]
  node_pure_app["Application"]
  node_pure_oauth["OAuth2 Config<br/>[OAuth2Config.java]"]
  node_pure_runner["Resource Runner"]
  node_pure_resource_client["Resource Client"]
end

subgraph group_resource["Resource API"]
  node_resource_app["Application"]
  node_resource_security["Security Config"]
  node_data_controller["Data Controller"]
end

click node_auth_app "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/auth-code-flow/src/main/java/com/demo/auth_code_flow/AuthCodeFlowApplication.java"
click node_auth_security "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/auth-code-flow/src/main/java/com/demo/auth_code_flow/config/SecurityConfig.java"
click node_auth_home "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/auth-code-flow/src/main/java/com/demo/auth_code_flow/controller/HomeController.java"
click node_auth_userinfo "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/auth-code-flow/src/main/java/com/demo/auth_code_flow/service/UserInfoService.java"
click node_pkce_app "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/pkce/src/main/java/com/demo/pkce/PkceApplication.java"
click node_pkce_security "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/pkce/src/main/java/com/demo/pkce/config/SecurityConfig.java"
click node_pkce_api "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/pkce/src/main/java/com/demo/pkce/controller/ApiController.java"
click node_client_app "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/client/src/main/java/com/demo/client/ClientApplication.java"
click node_client_security "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/client/src/main/java/com/demo/client/config/SecurityConfig.java"
click node_client_web "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/client/src/main/java/com/demo/client/config/WebConfig.java"
click node_proxy_controller "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/client/src/main/java/com/demo/client/controller/ProxyController.java"
click node_resource_service "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/client/src/main/java/com/demo/client/service/ResourceService.java"
click node_resource_client "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/client/src/main/java/com/demo/client/client/ResourceClient.java"
click node_pure_app "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/pure-client/src/main/java/com/demo/pure_client/PureClientApplication.java"
click node_pure_oauth "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/pure-client/src/main/java/com/demo/pure_client/config/OAuth2Config.java"
click node_pure_runner "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/pure-client/src/main/java/com/demo/pure_client/runner/ResourceClientRunner.java"
click node_pure_resource_client "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/pure-client/src/main/java/com/demo/pure_client/client/ResourceClient.java"
click node_resource_app "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/resource/src/main/java/com/demo/resource/ResourceApplication.java"
click node_resource_security "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/resource/src/main/java/com/demo/resource/config/SecurityConfig.java"
click node_data_controller "https://github.com/heangchihav/springboot-auth-code-flow/blob/main/resource/src/main/java/com/demo/resource/controller/DataController.java"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_auth_app,node_auth_security,node_auth_home,node_auth_userinfo toneBlue
class node_pkce_app,node_pkce_security,node_pkce_api toneAmber
class node_client_app,node_client_security,node_client_web,node_proxy_controller,node_resource_service,node_resource_client toneMint
class node_pure_app,node_pure_oauth,node_pure_runner,node_pure_resource_client toneRose
class node_resource_app,node_resource_security,node_data_controller toneIndigo
```

## Components

### Authorization Code Sample

- [Application](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/auth-code-flow/src/main/java/com/demo/auth_code_flow/AuthCodeFlowApplication.java): `auth-code-flow/src/main/java/com/demo/auth_code_flow/AuthCodeFlowApplication.java`
- [Security Config](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/auth-code-flow/src/main/java/com/demo/auth_code_flow/config/SecurityConfig.java): `auth-code-flow/src/main/java/com/demo/auth_code_flow/config/SecurityConfig.java`
- [Home Controller](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/auth-code-flow/src/main/java/com/demo/auth_code_flow/controller/HomeController.java): `auth-code-flow/src/main/java/com/demo/auth_code_flow/controller/HomeController.java`
- [User Info Service](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/auth-code-flow/src/main/java/com/demo/auth_code_flow/service/UserInfoService.java): `auth-code-flow/src/main/java/com/demo/auth_code_flow/service/UserInfoService.java`

### PKCE Sample

- [Application](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/pkce/src/main/java/com/demo/pkce/PkceApplication.java): `pkce/src/main/java/com/demo/pkce/PkceApplication.java`
- [Security Config](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/pkce/src/main/java/com/demo/pkce/config/SecurityConfig.java): `pkce/src/main/java/com/demo/pkce/config/SecurityConfig.java`
- [API Controller](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/pkce/src/main/java/com/demo/pkce/controller/ApiController.java): `pkce/src/main/java/com/demo/pkce/controller/ApiController.java`

### Proxy Client Sample

- [Application](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/client/src/main/java/com/demo/client/ClientApplication.java): `client/src/main/java/com/demo/client/ClientApplication.java`
- [Security Config](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/client/src/main/java/com/demo/client/config/SecurityConfig.java): `client/src/main/java/com/demo/client/config/SecurityConfig.java`
- [Web Config](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/client/src/main/java/com/demo/client/config/WebConfig.java): `client/src/main/java/com/demo/client/config/WebConfig.java`
- [Proxy Controller](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/client/src/main/java/com/demo/client/controller/ProxyController.java): `client/src/main/java/com/demo/client/controller/ProxyController.java`
- [Resource Service](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/client/src/main/java/com/demo/client/service/ResourceService.java): `client/src/main/java/com/demo/client/service/ResourceService.java`
- [Resource Client](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/client/src/main/java/com/demo/client/client/ResourceClient.java): `client/src/main/java/com/demo/client/client/ResourceClient.java`

### Pure Client Sample

- [Application](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/pure-client/src/main/java/com/demo/pure_client/PureClientApplication.java): `pure-client/src/main/java/com/demo/pure_client/PureClientApplication.java`
- [OAuth2 Config](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/pure-client/src/main/java/com/demo/pure_client/config/OAuth2Config.java): `pure-client/src/main/java/com/demo/pure_client/config/OAuth2Config.java`
- [Resource Runner](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/pure-client/src/main/java/com/demo/pure_client/runner/ResourceClientRunner.java): `pure-client/src/main/java/com/demo/pure_client/runner/ResourceClientRunner.java`
- [Resource Client](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/pure-client/src/main/java/com/demo/pure_client/client/ResourceClient.java): `pure-client/src/main/java/com/demo/pure_client/client/ResourceClient.java`

### Resource API

- [Application](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/resource/src/main/java/com/demo/resource/ResourceApplication.java): `resource/src/main/java/com/demo/resource/ResourceApplication.java`
- [Security Config](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/resource/src/main/java/com/demo/resource/config/SecurityConfig.java): `resource/src/main/java/com/demo/resource/config/SecurityConfig.java`
- [Data Controller](https://github.com/heangchihav/springboot-auth-code-flow/blob/main/resource/src/main/java/com/demo/resource/controller/DataController.java): `resource/src/main/java/com/demo/resource/controller/DataController.java`
