# taherfetoui/itinera architecture

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

- Interactive diagram: https://gitdiagram.com/taherfetoui/itinera
- Repository: https://github.com/taherfetoui/itinera

## Overview

This repository contains a Node/Express backend for a transport or fleet-management product, with API families for buses, drivers, planning, assignments, clients, and related records. The evidenced workflow is a client request entering the server, being dispatched to a mounted API router, then handled by that router’s database-operation module. The Flutter platform folders contain native launch and plugin-registration scaffolding, but the application’s Dart source is absent from the supplied tree, so its user-facing workflow cannot be mapped. Database internals and most domain operations were not sampled.

Main entry points: [`Backend/index.js`](https://github.com/taherfetoui/itinera/blob/master/Backend/index.js) (Express server), [`Backend/apiCL.js`](https://github.com/taherfetoui/itinera/blob/master/Backend/apiCL.js) (Client API), [`Backend/apiA.js`](https://github.com/taherfetoui/itinera/blob/master/Backend/apiA.js) (Assignment API), [`Backend/apiB.js`](https://github.com/taherfetoui/itinera/blob/master/Backend/apiB.js) (Bus API)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_server["Server ingress"]
  node_server["Express server<br/>[index.js]"]
end

subgraph group_apis["API routes"]
  node_api_a["Assignment API<br/>[apiA.js]"]
  node_api_b["Bus API<br/>[apiB.js]"]
  node_api_c["Driver API<br/>[apiC.js]"]
  node_api_cl["Client API<br/>[apiCL.js]"]
  node_api_l["Record API<br/>[apiL.js]"]
  node_api_p["Planning API<br/>[apiP.js]"]
  node_api_pb["Paper API<br/>[apiPB.js]"]
  node_api_r["Manager API<br/>[apiR.js]"]
  node_api_rp["Fleet manager API<br/>[apiRP.js]"]
  node_api_s["Service API<br/>[apiS.js]"]
end

subgraph group_data["Data operations"]
  node_db_a["Assignment operations<br/>[dboperationsA.js]"]
  node_db_b["Bus operations<br/>[dboperationsB.js]"]
  node_db_c["Driver operations<br/>[dboperationsC.js]"]
  node_db_cl["Client operations<br/>[dboperationsCL.js]"]
  node_db_l["Record operations<br/>[dboperationsL.js]"]
  node_db_p["Planning operations<br/>[dboperationsP.js]"]
  node_db_pb["Paper operations<br/>[dboperationsPB.js]"]
  node_db_r["Manager operations<br/>[dboperationsR.js]"]
  node_db_rp["Fleet manager operations<br/>[dboperationsRP.js]"]
  node_db_s["Service operations<br/>[dboperationsS.js]"]
end

node_user(("API client"))

node_user -->|"sends requests"| node_server
node_server -->|"mounts route"| node_api_a
node_server -->|"mounts route"| node_api_b
node_server -->|"mounts route"| node_api_c
node_server -->|"mounts route"| node_api_cl
node_server -->|"mounts route"| node_api_l
node_server -->|"mounts route"| node_api_p
node_server -->|"mounts route"| node_api_pb
node_server -->|"mounts route"| node_api_r
node_server -->|"mounts route"| node_api_rp
node_server -->|"mounts route"| node_api_s
node_api_a -->|"uses operations"| node_db_a
node_api_b -->|"uses operations"| node_db_b
node_api_c -->|"uses operations"| node_db_c
node_api_cl -->|"uses operations"| node_db_cl
node_api_cl -->|"uses operations"| node_db_b
node_api_l -->|"uses operations"| node_db_l
node_api_p -->|"uses operations"| node_db_p
node_api_pb -->|"uses operations"| node_db_pb
node_api_r -->|"uses operations"| node_db_r
node_api_rp -->|"uses operations"| node_db_rp
node_api_s -.->|"uses operations"| node_db_s

click node_server "https://github.com/taherfetoui/itinera/blob/master/Backend/index.js"
click node_api_a "https://github.com/taherfetoui/itinera/blob/master/Backend/apiA.js"
click node_api_b "https://github.com/taherfetoui/itinera/blob/master/Backend/apiB.js"
click node_api_c "https://github.com/taherfetoui/itinera/blob/master/Backend/apiC.js"
click node_api_cl "https://github.com/taherfetoui/itinera/blob/master/Backend/apiCL.js"
click node_api_l "https://github.com/taherfetoui/itinera/blob/master/Backend/apiL.js"
click node_api_p "https://github.com/taherfetoui/itinera/blob/master/Backend/apiP.js"
click node_api_pb "https://github.com/taherfetoui/itinera/blob/master/Backend/apiPB.js"
click node_api_r "https://github.com/taherfetoui/itinera/blob/master/Backend/apiR.js"
click node_api_rp "https://github.com/taherfetoui/itinera/blob/master/Backend/apiRP.js"
click node_api_s "https://github.com/taherfetoui/itinera/blob/master/Backend/apiS.js"
click node_db_a "https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsA.js"
click node_db_b "https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsB.js"
click node_db_c "https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsC.js"
click node_db_cl "https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsCL.js"
click node_db_l "https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsL.js"
click node_db_p "https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsP.js"
click node_db_pb "https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsPB.js"
click node_db_r "https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsR.js"
click node_db_rp "https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsRP.js"
click node_db_s "https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsS.js"

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_server,node_user toneBlue
class node_api_a,node_api_b,node_api_c,node_api_cl,node_api_l,node_api_p,node_api_pb,node_api_r,node_api_rp,node_api_s toneAmber
class node_db_a,node_db_b,node_db_c,node_db_cl,node_db_l,node_db_p,node_db_pb,node_db_r,node_db_rp,node_db_s toneMint
```

## Components

### Server ingress

- [Express server](https://github.com/taherfetoui/itinera/blob/master/Backend/index.js): `Backend/index.js`

### API routes

- [Assignment API](https://github.com/taherfetoui/itinera/blob/master/Backend/apiA.js): `Backend/apiA.js`
- [Bus API](https://github.com/taherfetoui/itinera/blob/master/Backend/apiB.js): `Backend/apiB.js`
- [Driver API](https://github.com/taherfetoui/itinera/blob/master/Backend/apiC.js): `Backend/apiC.js`
- [Client API](https://github.com/taherfetoui/itinera/blob/master/Backend/apiCL.js): `Backend/apiCL.js`
- [Record API](https://github.com/taherfetoui/itinera/blob/master/Backend/apiL.js): `Backend/apiL.js`
- [Planning API](https://github.com/taherfetoui/itinera/blob/master/Backend/apiP.js): `Backend/apiP.js`
- [Paper API](https://github.com/taherfetoui/itinera/blob/master/Backend/apiPB.js): `Backend/apiPB.js`
- [Manager API](https://github.com/taherfetoui/itinera/blob/master/Backend/apiR.js): `Backend/apiR.js`
- [Fleet manager API](https://github.com/taherfetoui/itinera/blob/master/Backend/apiRP.js): `Backend/apiRP.js`
- [Service API](https://github.com/taherfetoui/itinera/blob/master/Backend/apiS.js): `Backend/apiS.js`

### Data operations

- [Assignment operations](https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsA.js): `Backend/dboperationsA.js`
- [Bus operations](https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsB.js): `Backend/dboperationsB.js`
- [Driver operations](https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsC.js): `Backend/dboperationsC.js`
- [Client operations](https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsCL.js): `Backend/dboperationsCL.js`
- [Record operations](https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsL.js): `Backend/dboperationsL.js`
- [Planning operations](https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsP.js): `Backend/dboperationsP.js`
- [Paper operations](https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsPB.js): `Backend/dboperationsPB.js`
- [Manager operations](https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsR.js): `Backend/dboperationsR.js`
- [Fleet manager operations](https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsRP.js): `Backend/dboperationsRP.js`
- [Service operations](https://github.com/taherfetoui/itinera/blob/master/Backend/dboperationsS.js): `Backend/dboperationsS.js`

### Other components

- **API client**

## Connections

- API client → Express server: sends requests
- Express server → Assignment API: mounts route (evidence: `Backend/index.js`)
- Express server → Bus API: mounts route (evidence: `Backend/index.js`)
- Express server → Driver API: mounts route (evidence: `Backend/index.js`)
- Express server → Client API: mounts route (evidence: `Backend/index.js`)
- Express server → Record API: mounts route (evidence: `Backend/index.js`)
- Express server → Planning API: mounts route (evidence: `Backend/index.js`)
- Express server → Paper API: mounts route (evidence: `Backend/index.js`)
- Express server → Manager API: mounts route (evidence: `Backend/index.js`)
- Express server → Fleet manager API: mounts route (evidence: `Backend/index.js`)
- Express server → Service API: mounts route (evidence: `Backend/index.js`)
- Assignment API → Assignment operations: uses operations (evidence: `Backend/apiA.js`)
- Bus API → Bus operations: uses operations (evidence: `Backend/apiB.js`)
- Driver API → Driver operations: uses operations (evidence: `Backend/apiC.js`)
- Client API → Client operations: uses operations (evidence: `Backend/apiCL.js`)
- Client API → Bus operations: uses operations (evidence: `Backend/apiCL.js`)
- Record API → Record operations: uses operations (evidence: `Backend/apiL.js`)
- Planning API → Planning operations: uses operations (evidence: `Backend/apiP.js`)
- Paper API → Paper operations: uses operations (evidence: `Backend/apiPB.js`)
- Manager API → Manager operations: uses operations (evidence: `Backend/apiR.js`)
- Fleet manager API → Fleet manager operations: uses operations (evidence: `Backend/apiRP.js`)
- Service API → Service operations: uses operations
