# koroandshiro/climbbeta architecture

> Architecture diagram of the GitHub repository koroandshiro/climbbeta, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-28). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/koroandshiro/climbbeta
- Repository: https://github.com/koroandshiro/climbbeta

## Overview

ClimbBeta serves climbers through a mobile app and gym owners through a web backoffice, with a Kotlin API supporting account activation, climbing logs, gym discovery/management, and social activity. The principal workflow is account access, logging an indoor, free-gym, or outdoor ascent, then viewing logs and social feed. The README documents additional exploration, profile, media, and admin capabilities. Sampled source confirms selected API/service/repository calls; other feature links are omitted where wiring was not sampled.

Main entry points: [`backend/src/main/kotlin/com/climbbeta/api/http`](https://github.com/koroandshiro/climbbeta/tree/main/backend/src/main/kotlin/com/climbbeta/api/http) (Feature APIs), [`backend/src/main/kotlin/com/climbbeta/api/http/UserController.kt`](https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/http/UserController.kt) (Account API), [`frontend/ClimbBetaMobile/src/services/api.ts`](https://github.com/koroandshiro/climbbeta/blob/main/frontend/ClimbBetaMobile/src/services/api.ts) (Mobile API client), [`backend/src/main/kotlin/com/climbbeta/api/services/AscentService.kt`](https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/services/AscentService.kt) (Logbook and feed)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_clients["Client apps"]
  node_mobile["Climber app<br/>[App.tsx]"]
  node_mobileauth["Mobile auth<br/>[authService.ts]"]
  node_mobileapi["Mobile API client<br/>[api.ts]"]
  node_web["Owner backoffice<br/>[App.tsx]"]
  node_webauth["Web auth<br/>[authService.ts]"]
  node_webapi["Web API client<br/>[api.ts]"]
end

subgraph group_api["API boundary"]
  node_usercontroller["Account API<br/>[UserController.kt]"]
  node_ascentcontroller["Ascent API"]
  node_featurecontrollers["Feature APIs"]
  node_authpipeline["Access pipeline"]
end

subgraph group_domain["Product services"]
  node_userservice["Identity and activation<br/>[UserService.kt]"]
  node_ascentservice["Logbook and feed<br/>[AscentService.kt]"]
  node_outdoorservice["Outdoor routes"]
  node_gymservice["Gym management<br/>[GymService.kt]"]
  node_socialservices["Social interactions"]
  node_gamification["Stats and rankings"]
  node_mediaservice["Media handling<br/>[MediaService.kt]"]
end

subgraph group_storage["Persistence"]
  node_repositories["JDBI repositories"]
end

subgraph group_external["External systems"]
  node_postgres[("PostgreSQL")]
  node_minio[("MinIO storage")]
end

node_climber(("Climber"))
node_gymowner(("Gym owner"))
node_admin(("Admin"))

node_climber -->|"uses"| node_mobile
node_gymowner -->|"uses"| node_web
node_admin -.->|"generates codes"| node_usercontroller
node_mobile -->|"authenticates via"| node_mobileauth
node_mobileauth -->|"requests through"| node_mobileapi
node_web -->|"authenticates via"| node_webauth
node_webauth -->|"requests through"| node_webapi
node_mobileapi -->|"calls API"| node_usercontroller
node_mobileapi -->|"calls API"| node_ascentcontroller
node_mobileapi -->|"calls API"| node_featurecontrollers
node_webapi -->|"calls API"| node_usercontroller
node_webapi -->|"calls API"| node_featurecontrollers
node_usercontroller -->|"calls"| node_userservice
node_ascentcontroller -->|"calls"| node_ascentservice
node_authpipeline -->|"authenticates requests"| node_usercontroller
node_userservice -->|"reads and writes"| node_repositories
node_ascentservice -->|"reads and writes"| node_repositories
node_ascentservice -->|"finds or creates route"| node_outdoorservice
node_ascentservice -->|"records media"| node_mediaservice
node_featurecontrollers -->|"gym operations"| node_gymservice
node_featurecontrollers -->|"social operations"| node_socialservices
node_featurecontrollers -->|"stats and rankings"| node_gamification
node_featurecontrollers -->|"media operations"| node_mediaservice
node_repositories -->|"queries"| node_postgres
node_mediaservice -->|"stores images"| node_minio

click node_mobile "https://github.com/koroandshiro/climbbeta/blob/main/frontend/ClimbBetaMobile/App.tsx"
click node_mobileauth "https://github.com/koroandshiro/climbbeta/blob/main/frontend/ClimbBetaMobile/src/services/authService.ts"
click node_mobileapi "https://github.com/koroandshiro/climbbeta/blob/main/frontend/ClimbBetaMobile/src/services/api.ts"
click node_web "https://github.com/koroandshiro/climbbeta/blob/main/frontend/ClimbBetaWeb/src/App.tsx"
click node_webauth "https://github.com/koroandshiro/climbbeta/blob/main/frontend/ClimbBetaWeb/src/services/authService.ts"
click node_webapi "https://github.com/koroandshiro/climbbeta/blob/main/frontend/ClimbBetaWeb/src/services/api.ts"
click node_usercontroller "https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/http/UserController.kt"
click node_ascentcontroller "https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/http/AscentController.kt"
click node_featurecontrollers "https://github.com/koroandshiro/climbbeta/tree/main/backend/src/main/kotlin/com/climbbeta/api/http"
click node_authpipeline "https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/pipeline/AuthenticationInterceptor.kt"
click node_userservice "https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/services/UserService.kt"
click node_ascentservice "https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/services/AscentService.kt"
click node_outdoorservice "https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/services/OutdoorRouteService.kt"
click node_gymservice "https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/services/GymService.kt"
click node_socialservices "https://github.com/koroandshiro/climbbeta/tree/main/backend/src/main/kotlin/com/climbbeta/api/services"
click node_gamification "https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/services/GamificationService.kt"
click node_mediaservice "https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/services/MediaService.kt"
click node_repositories "https://github.com/koroandshiro/climbbeta/tree/main/backend/src/main/kotlin/com/climbbeta/api/repository_jdbi"

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_mobile,node_mobileauth,node_mobileapi,node_web,node_webauth,node_webapi toneBlue
class node_usercontroller,node_ascentcontroller,node_featurecontrollers,node_authpipeline toneAmber
class node_userservice,node_ascentservice,node_outdoorservice,node_gymservice,node_socialservices,node_gamification,node_mediaservice toneMint
class node_repositories toneRose
class node_postgres,node_minio,node_climber,node_gymowner,node_admin toneIndigo
```

## Components

### Client apps

- [Climber app](https://github.com/koroandshiro/climbbeta/blob/main/frontend/ClimbBetaMobile/App.tsx): `frontend/ClimbBetaMobile/App.tsx`
- [Mobile auth](https://github.com/koroandshiro/climbbeta/blob/main/frontend/ClimbBetaMobile/src/services/authService.ts): `frontend/ClimbBetaMobile/src/services/authService.ts`
- [Mobile API client](https://github.com/koroandshiro/climbbeta/blob/main/frontend/ClimbBetaMobile/src/services/api.ts): `frontend/ClimbBetaMobile/src/services/api.ts`
- [Owner backoffice](https://github.com/koroandshiro/climbbeta/blob/main/frontend/ClimbBetaWeb/src/App.tsx): `frontend/ClimbBetaWeb/src/App.tsx`
- [Web auth](https://github.com/koroandshiro/climbbeta/blob/main/frontend/ClimbBetaWeb/src/services/authService.ts): `frontend/ClimbBetaWeb/src/services/authService.ts`
- [Web API client](https://github.com/koroandshiro/climbbeta/blob/main/frontend/ClimbBetaWeb/src/services/api.ts): `frontend/ClimbBetaWeb/src/services/api.ts`

### API boundary

- [Account API](https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/http/UserController.kt): `backend/src/main/kotlin/com/climbbeta/api/http/UserController.kt`
- [Ascent API](https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/http/AscentController.kt): `backend/src/main/kotlin/com/climbbeta/api/http/AscentController.kt`
- [Feature APIs](https://github.com/koroandshiro/climbbeta/tree/main/backend/src/main/kotlin/com/climbbeta/api/http): `backend/src/main/kotlin/com/climbbeta/api/http`
- [Access pipeline](https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/pipeline/AuthenticationInterceptor.kt): `backend/src/main/kotlin/com/climbbeta/api/pipeline/AuthenticationInterceptor.kt`

### Product services

- [Identity and activation](https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/services/UserService.kt): `backend/src/main/kotlin/com/climbbeta/api/services/UserService.kt`
- [Logbook and feed](https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/services/AscentService.kt): `backend/src/main/kotlin/com/climbbeta/api/services/AscentService.kt`
- [Outdoor routes](https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/services/OutdoorRouteService.kt): `backend/src/main/kotlin/com/climbbeta/api/services/OutdoorRouteService.kt`
- [Gym management](https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/services/GymService.kt): `backend/src/main/kotlin/com/climbbeta/api/services/GymService.kt`
- [Social interactions](https://github.com/koroandshiro/climbbeta/tree/main/backend/src/main/kotlin/com/climbbeta/api/services): `backend/src/main/kotlin/com/climbbeta/api/services`
- [Stats and rankings](https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/services/GamificationService.kt): `backend/src/main/kotlin/com/climbbeta/api/services/GamificationService.kt`
- [Media handling](https://github.com/koroandshiro/climbbeta/blob/main/backend/src/main/kotlin/com/climbbeta/api/services/MediaService.kt): `backend/src/main/kotlin/com/climbbeta/api/services/MediaService.kt`

### Persistence

- [JDBI repositories](https://github.com/koroandshiro/climbbeta/tree/main/backend/src/main/kotlin/com/climbbeta/api/repository_jdbi): `backend/src/main/kotlin/com/climbbeta/api/repository_jdbi`

### External systems

- **PostgreSQL**
- **MinIO storage**

### Other components

- **Climber**
- **Gym owner**
- **Admin**

## Connections

- Climber → Climber app: uses
- Gym owner → Owner backoffice: uses
- Admin → Account API: generates codes
- Climber app → Mobile auth: authenticates via
- Mobile auth → Mobile API client: requests through
- Owner backoffice → Web auth: authenticates via
- Web auth → Web API client: requests through
- Mobile API client → Account API: calls API
- Mobile API client → Ascent API: calls API
- Mobile API client → Feature APIs: calls API
- Web API client → Account API: calls API
- Web API client → Feature APIs: calls API
- Account API → Identity and activation: calls
- Ascent API → Logbook and feed: calls
- Access pipeline → Account API: authenticates requests
- Identity and activation → JDBI repositories: reads and writes
- Logbook and feed → JDBI repositories: reads and writes
- Logbook and feed → Outdoor routes: finds or creates route
- Logbook and feed → Media handling: records media
- Feature APIs → Gym management: gym operations
- Feature APIs → Social interactions: social operations
- Feature APIs → Stats and rankings: stats and rankings
- Feature APIs → Media handling: media operations
- JDBI repositories → PostgreSQL: queries
- Media handling → MinIO storage: stores images
