# malla-aayushman/seetiesreppies architecture

> Architecture diagram of the GitHub repository malla-aayushman/seetiesreppies, 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/malla-aayushman/seetiesreppies
- Repository: https://github.com/malla-aayushman/seetiesreppies

## Overview

SetReps is a workout-tracking web app: users record exercises and dated sets, then review training history, progress, and insights. Account registration and login establish a PHP session; the API exposes session, profile, account, and full-store synchronization operations backed by MySQL. The sampled JavaScript shows exercise logging, session editing, and dashboard/progress/insights rendering. Client-to-store synchronization details are not visible in the excerpts, so that connection is not asserted here.

Main entry points: [`app.js`](https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js) (Workout logic), [`db.php`](https://github.com/malla-aayushman/seetiesreppies/blob/main/db.php) (Database access), [`auth.php`](https://github.com/malla-aayushman/seetiesreppies/blob/main/auth.php) (Session helpers), [`auth.js`](https://github.com/malla-aayushman/seetiesreppies/blob/main/auth.js) (Auth submit handler)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_workout["Workout tracking"]
  node_app_page["Workout app<br/>[SetReps.html]"]
  node_app_logic["Workout logic<br/>[app.js]"]
  node_exercise_catalog["Exercise catalog<br/>[app.js]"]
  node_session_logging["Session logging<br/>[app.js]"]
  node_session_history["Session history<br/>[app.js]"]
end

subgraph group_analysis["Training analysis"]
  node_dashboard["Dashboard<br/>[app.js]"]
  node_progress["Progress views<br/>[app.js]"]
  node_insights["Training insights<br/>[app.js]"]
end

subgraph group_identity["Identity and profile"]
  node_login_page["Login page<br/>[login.php]"]
  node_register_page["Registration page<br/>[register.php]"]
  node_auth_client["Auth submit handler<br/>[auth.js]"]
  node_login_api["Login endpoint<br/>[login.php]"]
  node_register_api["Registration endpoint<br/>[register.php]"]
  node_session_api["Session endpoint<br/>[session.php]"]
  node_logout_api["Logout endpoint<br/>[logout.php]"]
  node_account_api["Account updates<br/>[account.php]"]
  node_profile_api["Profile endpoint<br/>[profile.php]"]
  node_auth_helpers["Session helpers<br/>[auth.php]"]
end

subgraph group_persistence["Persistence"]
  node_data_api["Store sync API<br/>[data.php]"]
  node_db_access["Database access<br/>[db.php]"]
  node_mysql[("MySQL store<br/>[setreps.sql]")]
end

node_user(("User"))

node_user -->|"opens"| node_login_page
node_user -->|"opens"| node_register_page
node_user -->|"uses"| node_app_page
node_login_page -->|"loads"| node_auth_client
node_register_page -->|"loads"| node_auth_client
node_auth_client -->|"submits login"| node_login_api
node_auth_client -->|"submits registration"| node_register_api
node_app_page -->|"checks session"| node_session_api
node_app_logic -->|"uses"| node_exercise_catalog
node_app_logic -->|"records sets"| node_session_logging
node_app_logic -->|"renders history"| node_session_history
node_app_logic -->|"renders"| node_dashboard
node_app_logic -->|"renders"| node_progress
node_app_logic -->|"renders"| node_insights
node_login_api -->|"uses"| node_auth_helpers
node_login_api -->|"queries"| node_db_access
node_register_api -->|"uses"| node_auth_helpers
node_register_api -->|"queries and writes"| node_db_access
node_session_api -->|"checks session"| node_auth_helpers
node_session_api -->|"loads user"| node_db_access
node_logout_api -->|"ends session"| node_auth_helpers
node_account_api -->|"requires login"| node_auth_helpers
node_account_api -->|"updates account"| node_db_access
node_profile_api -->|"requires login"| node_auth_helpers
node_profile_api -->|"reads and updates"| node_db_access
node_data_api -->|"requires login"| node_auth_helpers
node_data_api -->|"loads and syncs"| node_db_access
node_db_access -->|"reads and writes"| node_mysql

click node_app_page "https://github.com/malla-aayushman/seetiesreppies/blob/main/SetReps.html"
click node_app_logic "https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js"
click node_exercise_catalog "https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js"
click node_session_logging "https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js"
click node_session_history "https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js"
click node_dashboard "https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js"
click node_progress "https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js"
click node_insights "https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js"
click node_login_page "https://github.com/malla-aayushman/seetiesreppies/blob/main/login.php"
click node_register_page "https://github.com/malla-aayushman/seetiesreppies/blob/main/register.php"
click node_auth_client "https://github.com/malla-aayushman/seetiesreppies/blob/main/auth.js"
click node_login_api "https://github.com/malla-aayushman/seetiesreppies/blob/main/api/login.php"
click node_register_api "https://github.com/malla-aayushman/seetiesreppies/blob/main/api/register.php"
click node_session_api "https://github.com/malla-aayushman/seetiesreppies/blob/main/api/session.php"
click node_logout_api "https://github.com/malla-aayushman/seetiesreppies/blob/main/api/logout.php"
click node_account_api "https://github.com/malla-aayushman/seetiesreppies/blob/main/api/account.php"
click node_profile_api "https://github.com/malla-aayushman/seetiesreppies/blob/main/api/profile.php"
click node_auth_helpers "https://github.com/malla-aayushman/seetiesreppies/blob/main/auth.php"
click node_data_api "https://github.com/malla-aayushman/seetiesreppies/blob/main/api/data.php"
click node_db_access "https://github.com/malla-aayushman/seetiesreppies/blob/main/db.php"
click node_mysql "https://github.com/malla-aayushman/seetiesreppies/blob/main/setreps.sql"

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_app_page,node_app_logic,node_exercise_catalog,node_session_logging,node_session_history,node_user toneBlue
class node_dashboard,node_progress,node_insights toneAmber
class node_login_page,node_register_page,node_auth_client,node_login_api,node_register_api,node_session_api,node_logout_api,node_account_api,node_profile_api,node_auth_helpers toneMint
class node_data_api,node_db_access,node_mysql toneRose
```

## Components

### Workout tracking

- [Workout app](https://github.com/malla-aayushman/seetiesreppies/blob/main/SetReps.html): `SetReps.html`
- [Workout logic](https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js): `app.js`
- [Exercise catalog](https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js): `app.js`
- [Session logging](https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js): `app.js`
- [Session history](https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js): `app.js`

### Training analysis

- [Dashboard](https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js): `app.js`
- [Progress views](https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js): `app.js`
- [Training insights](https://github.com/malla-aayushman/seetiesreppies/blob/main/app.js): `app.js`

### Identity and profile

- [Login page](https://github.com/malla-aayushman/seetiesreppies/blob/main/login.php): `login.php`
- [Registration page](https://github.com/malla-aayushman/seetiesreppies/blob/main/register.php): `register.php`
- [Auth submit handler](https://github.com/malla-aayushman/seetiesreppies/blob/main/auth.js): `auth.js`
- [Login endpoint](https://github.com/malla-aayushman/seetiesreppies/blob/main/api/login.php): `api/login.php`
- [Registration endpoint](https://github.com/malla-aayushman/seetiesreppies/blob/main/api/register.php): `api/register.php`
- [Session endpoint](https://github.com/malla-aayushman/seetiesreppies/blob/main/api/session.php): `api/session.php`
- [Logout endpoint](https://github.com/malla-aayushman/seetiesreppies/blob/main/api/logout.php): `api/logout.php`
- [Account updates](https://github.com/malla-aayushman/seetiesreppies/blob/main/api/account.php): `api/account.php`
- [Profile endpoint](https://github.com/malla-aayushman/seetiesreppies/blob/main/api/profile.php): `api/profile.php`
- [Session helpers](https://github.com/malla-aayushman/seetiesreppies/blob/main/auth.php): `auth.php`

### Persistence

- [Store sync API](https://github.com/malla-aayushman/seetiesreppies/blob/main/api/data.php): `api/data.php`
- [Database access](https://github.com/malla-aayushman/seetiesreppies/blob/main/db.php): `db.php`
- [MySQL store](https://github.com/malla-aayushman/seetiesreppies/blob/main/setreps.sql): `setreps.sql`

### Other components

- **User**

## Connections

- User → Login page: opens
- User → Registration page: opens
- User → Workout app: uses
- Login page → Auth submit handler: loads
- Registration page → Auth submit handler: loads
- Auth submit handler → Login endpoint: submits login
- Auth submit handler → Registration endpoint: submits registration
- Workout app → Session endpoint: checks session
- Workout logic → Exercise catalog: uses
- Workout logic → Session logging: records sets
- Workout logic → Session history: renders history
- Workout logic → Dashboard: renders
- Workout logic → Progress views: renders
- Workout logic → Training insights: renders
- Login endpoint → Session helpers: uses
- Login endpoint → Database access: queries
- Registration endpoint → Session helpers: uses
- Registration endpoint → Database access: queries and writes
- Session endpoint → Session helpers: checks session
- Session endpoint → Database access: loads user
- Logout endpoint → Session helpers: ends session
- Account updates → Session helpers: requires login
- Account updates → Database access: updates account
- Profile endpoint → Session helpers: requires login
- Profile endpoint → Database access: reads and updates
- Store sync API → Session helpers: requires login
- Store sync API → Database access: loads and syncs
- Database access → MySQL store: reads and writes
