# iahunter/php7-telecom-management architecture

> Architecture diagram of the GitHub repository iahunter/php7-telecom-management, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-01-02). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/iahunter/php7-telecom-management
- Repository: https://github.com/iahunter/php7-telecom-management

## Overview

##### Main Components

a. Frontend Layer:
- Angular.js 1.5 UI Application
- Bootstrap 3 Components
- Multiple UI Modules (Admin, OnCall, Phone Management)
- Authentication/Authorization UI

b. Backend Layer:
- Laravel 5.3 Framework
- RESTful API Controllers
- Authentication Services (JWT, TLS, LDAP)
- Authorization (Bouncer Permissions)
- Event/Listener System

c. Integration Services:
- Cisco Call Manager (CUCM) Integration
- Sonus 5k Voice Platform
- 911Enable Integration
- Unity Connection Integration
- Microsoft Teams Integration
- LDAP Integration
- IDM Integration

d. Database Layer:
- MySQL 5.7 Database
- Migration Management
- Audit Logging
- Activity Logging

**[Client Layer]**
- ↑↓
**[API Gateway/Load Balancer (HAProxy)]**
- ↑↓
**[Application Layer]**
- ↑↓
**[Service Layer]**
- ↑↓
**[Database Layer]**

##### Key Relationships to Highlight

a. Client-Server Communication:
- REST API endpoints
- JWT authentication flow
- WebSocket connections (if applicable)

b. Service Integration Flows:
- Phone provisioning workflow
- Number management process
- Call monitoring and reporting
- User management and permissions

##### Specific Implementation Details

**[Frontend (Angular.js)]**
- Admin Portal
- OnCall Module
- Phone Management
- Reports Interface

**[API Layer (Laravel)]**
- Route Management
- Controller Logic
- Middleware
- Event System

**[Service Integration Layer]**
- Cisco CUCM Connector
- Sonus Integration
- Teams Integration
- LDAP/Authentication

**[Database Layer]**
- User Management
- Phone Numbers
- Configuration
- Audit Logs

##### Additional Elements

Supporting infrastructure:
- Supervisor workers
- Cron jobs
- Cache system
- Queue management
- Backup system

##### Monitoring and Logging

Flow of:
- Activity logging
- Audit trails
- System monitoring
- Error handling

Remember to include:
- Security boundaries
- Data flow directions
- System dependencies
- Scaling points
- Backup paths
- Monitoring points

This will provide a comprehensive view of the system while keeping it understandable for technical stakeholders.

## Diagram (Mermaid)

```mermaid
graph TB
    subgraph Client
        UI_Admin["Admin Portal"]:::frontend
        UI_OnCall["OnCall Module"]:::frontend
        UI_Phone["Phone Management"]:::frontend
        UI_Auth["Authentication UI"]:::frontend
    end

    subgraph API_Gateway
        HAProxy["Load Balancer (HAProxy)"]:::gateway
    end

    subgraph Backend
        API["Laravel API Controllers"]:::backend
        Auth["Authentication Services"]:::auth
        Events["Event System"]:::backend
        Listeners["Event Listeners"]:::backend
        Permissions["Bouncer Permissions"]:::auth
    end

    subgraph Integration_Services
        CUCM["Cisco Call Manager"]:::integration
        Sonus["Sonus 5k Platform"]:::integration
        Enable911["911Enable"]:::integration
        Unity["Unity Connection"]:::integration
        Teams["Microsoft Teams"]:::integration
        LDAP["LDAP Service"]:::integration
        IDM["IDM Service"]:::integration
    end

    subgraph Database
        MySQL["MySQL Database"]:::database
        Migrations["Database Migrations"]:::database
        Models["Data Models"]:::database
        ActivityLog["Activity Logging"]:::monitoring
        AuditLog["Audit Logging"]:::monitoring
    end

    subgraph Monitoring
        Monitor["Monitoring Services"]:::monitoring
    end

    %% Relationships
    UI_Admin & UI_OnCall & UI_Phone & UI_Auth --> HAProxy
    HAProxy --> API
    API --> Auth
    API --> Events
    Events --> Listeners
    Auth --> Permissions
    API --> Integration_Services
    Integration_Services --> MySQL
    API --> MySQL
    Monitor --> ActivityLog
    Monitor --> AuditLog

    %% Click Events
    click UI_Admin "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/public/admin/"
    click UI_OnCall "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/public/oncall/"
    click UI_Phone "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/public/ui/"
    click API "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/app/Http/Controllers/"
    click Auth "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/app/Http/Controllers/Auth/"
    click Events "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/app/Events/"
    click Listeners "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/app/Listeners/"
    click CUCM "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/app/Console/Commands/CallManager/"
    click Sonus "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/app/Console/Commands/Sonus/"
    click Enable911 "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/app/Console/Commands/West911Enable/"
    click Unity "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/app/Console/Commands/UnityConnection/"
    click Teams "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/app/Console/Commands/Microsoft/"
    click LDAP "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/app/Console/Commands/Ldap/"
    click IDM "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/app/Console/Commands/IDM/"
    click Migrations "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/database/migrations/"
    click ActivityLog "https://github.com/iahunter/PHP7-Telecom-Management/blob/master/database/migrations/2017_03_24_005009_create_activity_log_table.php"
    click Monitor "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/app/Console/Commands/Monitoring/"
    click Permissions "https://github.com/iahunter/PHP7-Telecom-Management/tree/master/app/Console/Commands/BouncerPermissions/"

    %% Styles
    classDef frontend fill:#3498db,stroke:#2980b9,color:white
    classDef backend fill:#2ecc71,stroke:#27ae60,color:white
    classDef auth fill:#e67e22,stroke:#d35400,color:white
    classDef integration fill:#f1c40f,stroke:#f39c12,color:black
    classDef database fill:#9b59b6,stroke:#8e44ad,color:white
    classDef monitoring fill:#e74c3c,stroke:#c0392b,color:white
    classDef gateway fill:#95a5a6,stroke:#7f8c8d,color:white
```
