# adrianhajdin/zoom-clone architecture

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

- Interactive diagram: https://gitdiagram.com/adrianhajdin/zoom-clone
- Repository: https://github.com/adrianhajdin/zoom-clone

## Overview

##### Project type and purpose
- This is a full-stack, real-time video conferencing “Zoom-clone” built on Next.js (App Router), TypeScript, Tailwind CSS, Clerk (authentication), and getstream (video/real-time API).
- It provides user auth, meeting creation/scheduling, joining via link, in-meeting controls (recording, screen share, reactions), and access to past/recorded meetings.

##### File structure
- Top-level:
- app/ – Next.js App Router pages and layouts (client + server components)
- components/ & components/ui – React UI and shadcn-based primitives
- hooks/, lib/, constants/ – data-fetching hooks, utility functions, constants
- providers/ – StreamClientProvider wrapping the app for getstream SDK
- actions/stream.actions.ts – wrappers for calling getstream REST/SDK methods
- middleware.ts – Next.js edge middleware (likely for auth redirection)
- next.config.mjs, tailwind.config.ts, postcss.config.js – framework configs
- No custom database: meeting state and recordings reside in getstream’s managed back end. Authentication state resides in Clerk.

##### README
- Confirms tech stack and features
- Emphasizes secure real-time interactions via getstream and social/email auth via Clerk

##### Essential elements
- Clear labels: e.g., “Next.js App Router”, “StreamClientProvider”, “useGetCalls Hook”

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% Browser / Client Layer
    subgraph "Browser / Client" 
        direction TB
        SV["Stream Video SDK"]:::client
        CW["Clerk Frontend Widgets"]:::client
        MR["MeetingRoom Component"]:::client
        MS["MeetingSetup Component"]:::client
        MC["MeetingCard Component"]:::client
        CL["CallList Component"]:::client
        EC["EndCallButton Component"]:::client
        UG["useGetCalls Hook"]:::client
        UID["useGetCallById Hook"]:::client
    end

    %% Next.js Server Layer
    subgraph "Next.js Server" 
        direction TB
        APPL["app/layout.tsx"]:::server
        GLOB["app/globals.css"]:::server
        MID["middleware.ts"]:::server
        SCP["StreamClientProvider"]:::server
        STA["actions/stream.actions.ts"]:::server
        SIP["SignIn Page"]:::server
        supP["SignUp Page"]:::server
        HLAY["Home Layout"]:::server
        HPG["Home Page"]:::server
        UPP["Upcoming Meetings Page"]:::server
        PREP["Previous Meetings Page"]:::server
        RCPG["Recordings Page"]:::server
        PRPG["Personal Room Page"]:::server
        MDPG["Meeting Detail Page"]:::server
    end

    %% External Services
    subgraph "External Services"
        direction TB
        ClerkAPI["Clerk Auth API"]:::external
        GSVID["getstream Video API"]:::external
        GSREST["getstream REST API"]:::external
        CDN["CDN / Static Hosting"]:::external
    end

    %% Relationships
    %% Client to Server
    MR -->|renders via| APPL
    MS -->|renders via| HLAY
    MC -->|renders via| HPG
    CL -->|uses| HPG
    EC -->|in| MR
    UG -->|fetched in| HPG
    UID -->|fetched in| MDPG

    CW -->|auth UIs| ClerkAPI
    SV -->|media streams| GSVID
    MR -->|webrtc| SV

    %% Server interactions
    HPG -->|calls| STA
    MDPG -->|GET /calls/:id| STA
    STA -->|REST| GSREST
    MID -->|validates sessions| ClerkAPI
    SCP -->|injects SDK| SV

    %% CDN to Client
    CDN -->|serves bundles| SV

    %% Click Events
    click SCP "https://github.com/adrianhajdin/zoom-clone/blob/main/providers/StreamClientProvider.tsx"
    click STA "https://github.com/adrianhajdin/zoom-clone/blob/main/actions/stream.actions.ts"
    click MID "https://github.com/adrianhajdin/zoom-clone/blob/main/middleware.ts"
    click SIP "https://github.com/adrianhajdin/zoom-clone/blob/main/app/(auth)/sign-in/[[...sigin-in]]/page.tsx"
    click supP "https://github.com/adrianhajdin/zoom-clone/blob/main/app/(auth)/sign-up/[[...sign-up]]/page.tsx"
    click HLAY "https://github.com/adrianhajdin/zoom-clone/blob/main/app/(root)/(home)/layout.tsx"
    click HPG "https://github.com/adrianhajdin/zoom-clone/blob/main/app/(root)/(home)/page.tsx"
    click UPP "https://github.com/adrianhajdin/zoom-clone/blob/main/app/(root)/(home)/upcoming/page.tsx"
    click PREP "https://github.com/adrianhajdin/zoom-clone/blob/main/app/(root)/(home)/previous/page.tsx"
    click RCPG "https://github.com/adrianhajdin/zoom-clone/blob/main/app/(root)/(home)/recordings/page.tsx"
    click PRPG "https://github.com/adrianhajdin/zoom-clone/blob/main/app/(root)/(home)/personal-room/page.tsx"
    click MDPG "https://github.com/adrianhajdin/zoom-clone/blob/main/app/(root)/meeting/[id]/page.tsx"
    click APPL "https://github.com/adrianhajdin/zoom-clone/blob/main/app/layout.tsx"
    click GLOB "https://github.com/adrianhajdin/zoom-clone/blob/main/app/globals.css"

    click MR "https://github.com/adrianhajdin/zoom-clone/blob/main/components/MeetingRoom.tsx"
    click MS "https://github.com/adrianhajdin/zoom-clone/blob/main/components/MeetingSetup.tsx"
    click MC "https://github.com/adrianhajdin/zoom-clone/blob/main/components/MeetingCard.tsx"
    click CL "https://github.com/adrianhajdin/zoom-clone/blob/main/components/CallList.tsx"
    click EC "https://github.com/adrianhajdin/zoom-clone/blob/main/components/EndCallButton.tsx"
    click UG "https://github.com/adrianhajdin/zoom-clone/blob/main/hooks/useGetCalls.ts"
    click UID "https://github.com/adrianhajdin/zoom-clone/blob/main/hooks/useGetCallById.ts"

    click Button "https://github.com/adrianhajdin/zoom-clone/blob/main/components/ui/button.tsx"
    click Card "https://github.com/adrianhajdin/zoom-clone/blob/main/components/ui/card.tsx"
    click Dialog "https://github.com/adrianhajdin/zoom-clone/blob/main/components/ui/dialog.tsx"
    click DropdownMenu "https://github.com/adrianhajdin/zoom-clone/blob/main/components/ui/dropdown-menu.tsx"
    click Input "https://github.com/adrianhajdin/zoom-clone/blob/main/components/ui/input.tsx"
    click Popover "https://github.com/adrianhajdin/zoom-clone/blob/main/components/ui/popover.tsx"
    click Sheet "https://github.com/adrianhajdin/zoom-clone/blob/main/components/ui/sheet.tsx"
    click Textarea "https://github.com/adrianhajdin/zoom-clone/blob/main/components/ui/textarea.tsx"
    click Toast "https://github.com/adrianhajdin/zoom-clone/blob/main/components/ui/toast.ts"
    click Toaster "https://github.com/adrianhajdin/zoom-clone/blob/main/components/ui/toaster.tsx"
    click useToast "https://github.com/adrianhajdin/zoom-clone/blob/main/components/ui/use-toast.ts"

    %% Styles
    classDef client fill:#D0E8FF,stroke:#333,stroke-width:1px
    classDef server fill:#D0FFD6,stroke:#333,stroke-width:1px
    classDef external fill:#FFE3B3,stroke:#333,stroke-width:1px
```
