# 60302700/automated-booking-python-udst architecture

> Architecture diagram of the GitHub repository 60302700/automated-booking-python-udst, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-03). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/60302700/automated-booking-python-udst
- Repository: https://github.com/60302700/automated-booking-python-udst

## Overview

This repository is a command-line gym and sports-facility booking tool for UDST, with a helper that generates recurring booking schedules. The main workflow logs in, discovers bookable facilities and rental limits, prepares a reservation, and submits it; the code also fetches guest details and supports sport categories. The excerpts show these responsibilities within gym.py but omit portions of its orchestration, so only clearly evidenced calls and HTTP interactions are connected. No README documentation was provided.

Main entry points: [`gym.py`](https://github.com/60302700/automated-booking-python-udst/blob/main/gym.py) (Booking CLI), [`schedule-make.py`](https://github.com/60302700/automated-booking-python-udst/blob/main/schedule-make.py) (Schedule generator), [`sport_types.py`](https://github.com/60302700/automated-booking-python-udst/blob/main/sport_types.py) (Sport categories)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_booking["Booking runtime"]
  node_gym_cli["Booking CLI<br/>[gym.py]"]
  node_login["Session login<br/>[gym.py]"]
  node_facility_search["Facility discovery<br/>[gym.py]"]
  node_guest_details["Guest details<br/>[gym.py]"]
  node_reservation["Reservation submission<br/>[gym.py]"]
end

subgraph group_scheduling["Schedule generation"]
  node_schedule_generator["Schedule generator<br/>[schedule-make.py]"]
  node_schedule_file["Generated schedule<br/>[schedule-make.py]"]
end

subgraph group_domain["Booking domain"]
  node_sport_types["Sport categories<br/>[sport_types.py]"]
end

node_user(("Booking user"))
node_udst["UDST sports portal"]
node_planyo["Planyo services"]

node_user -->|"provides booking options"| node_gym_cli
node_gym_cli -->|"authenticates"| node_login
node_login -->|"fetches token and logs in"| node_udst
node_gym_cli -->|"gets facilities"| node_facility_search
node_facility_search -->|"queries resources"| node_udst
node_facility_search -->|"fetches rental limits"| node_planyo
node_gym_cli -->|"loads guest list"| node_guest_details
node_guest_details -->|"fetches guest records"| node_udst
node_gym_cli -.->|"submits booking"| node_reservation
node_reservation -->|"posts reservation"| node_udst
node_gym_cli -->|"checks sport category"| node_sport_types
node_user -->|"enters schedule"| node_schedule_generator
node_schedule_generator -->|"writes YAML"| node_schedule_file
node_schedule_file -->|"configures booking run"| node_gym_cli

click node_gym_cli "https://github.com/60302700/automated-booking-python-udst/blob/main/gym.py"
click node_login "https://github.com/60302700/automated-booking-python-udst/blob/main/gym.py"
click node_facility_search "https://github.com/60302700/automated-booking-python-udst/blob/main/gym.py"
click node_guest_details "https://github.com/60302700/automated-booking-python-udst/blob/main/gym.py"
click node_reservation "https://github.com/60302700/automated-booking-python-udst/blob/main/gym.py"
click node_schedule_generator "https://github.com/60302700/automated-booking-python-udst/blob/main/schedule-make.py"
click node_schedule_file "https://github.com/60302700/automated-booking-python-udst/blob/main/schedule-make.py"
click node_sport_types "https://github.com/60302700/automated-booking-python-udst/blob/main/sport_types.py"

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_gym_cli,node_login,node_facility_search,node_guest_details,node_reservation,node_user toneBlue
class node_schedule_generator,node_schedule_file toneAmber
class node_sport_types toneMint
class node_udst,node_planyo toneIndigo
```

## Components

### Booking runtime

- [Booking CLI](https://github.com/60302700/automated-booking-python-udst/blob/main/gym.py): `gym.py`
- [Session login](https://github.com/60302700/automated-booking-python-udst/blob/main/gym.py): `gym.py`
- [Facility discovery](https://github.com/60302700/automated-booking-python-udst/blob/main/gym.py): `gym.py`
- [Guest details](https://github.com/60302700/automated-booking-python-udst/blob/main/gym.py): `gym.py`
- [Reservation submission](https://github.com/60302700/automated-booking-python-udst/blob/main/gym.py): `gym.py`

### Schedule generation

- [Schedule generator](https://github.com/60302700/automated-booking-python-udst/blob/main/schedule-make.py): `schedule-make.py`
- [Generated schedule](https://github.com/60302700/automated-booking-python-udst/blob/main/schedule-make.py): `schedule-make.py`

### Booking domain

- [Sport categories](https://github.com/60302700/automated-booking-python-udst/blob/main/sport_types.py): `sport_types.py`

### Other components

- **Booking user**
- **UDST sports portal**
- **Planyo services**

## Connections

- Booking user → Booking CLI: provides booking options (evidence: `gym.py`)
- Booking CLI → Session login: authenticates (evidence: `gym.py`)
- Session login → UDST sports portal: fetches token and logs in (evidence: `gym.py`)
- Booking CLI → Facility discovery: gets facilities (evidence: `gym.py`)
- Facility discovery → UDST sports portal: queries resources (evidence: `gym.py`)
- Facility discovery → Planyo services: fetches rental limits (evidence: `gym.py`)
- Booking CLI → Guest details: loads guest list (evidence: `gym.py`)
- Guest details → UDST sports portal: fetches guest records (evidence: `gym.py`)
- Booking CLI → Reservation submission: submits booking (evidence: `gym.py`)
- Reservation submission → UDST sports portal: posts reservation (evidence: `gym.py`)
- Booking CLI → Sport categories: checks sport category (evidence: `gym.py`)
- Booking user → Schedule generator: enters schedule (evidence: `schedule-make.py`)
- Schedule generator → Generated schedule: writes YAML (evidence: `schedule-make.py`)
- Generated schedule → Booking CLI: configures booking run (evidence: `schedule-make.py`)
