# monii-dev/read365-library-py architecture

> Architecture diagram of the GitHub repository monii-dev/read365-library-py, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-10). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/monii-dev/read365-library-py
- Repository: https://github.com/monii-dev/read365-library-py

## Overview

This is a small, single-file Python tool for searching a school library’s holdings and enriching results with loan status. Its API can be used as a library or through a CLI. The graph keeps those stages distinct; the excerpt does not show the full CLI orchestration or state-request implementation, so those links are omitted or marked unverified.

Main entry points: [`read365-library.py`](https://github.com/monii-dev/read365-library-py/blob/main/read365-library.py) (Book search)

## Diagram (Mermaid)

```mermaid
flowchart TD

node_user(("User"))
node_cli["CLI entry<br/>[read365-library.py]"]
node_session["HTTP session<br/>[read365-library.py]"]
node_search["Book search<br/>[read365-library.py]"]
node_response["Response validation<br/>[read365-library.py]"]
node_book["Book records<br/>[read365-library.py]"]
node_states["Loan status<br/>[read365-library.py]"]
node_read365["Read365 API"]
node_output["Result output<br/>[read365-library.py]"]

node_user -->|"runs"| node_cli
node_session -->|"provides session"| node_search
node_search -->|"posts search"| node_read365
node_search -->|"validates response"| node_response
node_search -->|"creates records"| node_book
node_states -->|"creates sessions"| node_session
node_states -.->|"fetches status"| node_read365
node_user -->|"requests books"| node_search
node_user -->|"requests status"| node_states
node_user -->|"reads results"| node_output

click node_cli "https://github.com/monii-dev/read365-library-py/blob/main/read365-library.py"
click node_session "https://github.com/monii-dev/read365-library-py/blob/main/read365-library.py"
click node_search "https://github.com/monii-dev/read365-library-py/blob/main/read365-library.py"
click node_response "https://github.com/monii-dev/read365-library-py/blob/main/read365-library.py"
click node_book "https://github.com/monii-dev/read365-library-py/blob/main/read365-library.py"
click node_states "https://github.com/monii-dev/read365-library-py/blob/main/read365-library.py"
click node_output "https://github.com/monii-dev/read365-library-py/blob/main/read365-library.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_user toneBlue
class node_cli,node_session,node_search,node_response,node_book,node_states,node_output toneTeal
class node_read365 toneMint
```

## Components

### Other components

- **User**
- [CLI entry](https://github.com/monii-dev/read365-library-py/blob/main/read365-library.py): `read365-library.py`
- [HTTP session](https://github.com/monii-dev/read365-library-py/blob/main/read365-library.py): `read365-library.py`
- [Book search](https://github.com/monii-dev/read365-library-py/blob/main/read365-library.py): `read365-library.py`
- [Response validation](https://github.com/monii-dev/read365-library-py/blob/main/read365-library.py): `read365-library.py`
- [Book records](https://github.com/monii-dev/read365-library-py/blob/main/read365-library.py): `read365-library.py`
- [Loan status](https://github.com/monii-dev/read365-library-py/blob/main/read365-library.py): `read365-library.py`
- **Read365 API**
- [Result output](https://github.com/monii-dev/read365-library-py/blob/main/read365-library.py): `read365-library.py`

## Connections

- User → CLI entry: runs (evidence: `read365-library.py`)
- HTTP session → Book search: provides session (evidence: `README.md`)
- Book search → Read365 API: posts search (evidence: `read365-library.py`)
- Book search → Response validation: validates response (evidence: `read365-library.py`)
- Book search → Book records: creates records (evidence: `read365-library.py`)
- Loan status → HTTP session: creates sessions (evidence: `read365-library.py`)
- Loan status → Read365 API: fetches status
- User → Book search: requests books (evidence: `README.md`)
- User → Loan status: requests status (evidence: `README.md`)
- User → Result output: reads results (evidence: `README.md`)
