# indian-meet/google_meet architecture

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

- Interactive diagram: https://gitdiagram.com/indian-meet/google_meet
- Repository: https://github.com/indian-meet/google_meet

## Overview

This is a microservices video-calling app. A browser uses the API Gateway for account, profile, room, and chat-history REST operations, while connecting directly to Signaling over WebSocket for live room coordination and WebRTC signaling. Signaling consults the Room Service and coordinates media through the SFU; chat messages are published through Redis for persistence by Chat Service. The README documents these service boundaries and integrations; unsampled service internals are represented only at supported directory paths.

Main entry points: [`services/api-gateway/src/routes/proxyRoutes.ts`](https://github.com/indian-meet/google_meet/blob/master/services/api-gateway/src/routes/proxyRoutes.ts) (HTTP API Gateway), [`services/signaling-service/src/socket/index.ts`](https://github.com/indian-meet/google_meet/blob/master/services/signaling-service/src/socket/index.ts) (WebSocket signaling), [`services/auth-service/src/controllers/loginController.ts`](https://github.com/indian-meet/google_meet/blob/master/services/auth-service/src/controllers/loginController.ts) (Accounts and tokens), [`services/chat-service/src/controllers/getMessagesController.ts`](https://github.com/indian-meet/google_meet/blob/master/services/chat-service/src/controllers/getMessagesController.ts) (Chat history API)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_edge["Client edge"]
  node_gateway["HTTP API Gateway<br/>[proxyRoutes.ts]"]
  node_turn["STUN/TURN"]
end

subgraph group_identity["Identity and profiles"]
  node_auth["Accounts and tokens<br/>[loginController.ts]"]
  node_authdb[("Auth PostgreSQL<br/>[db.ts]")]
  node_users["User profiles"]
  node_userdb[("User PostgreSQL<br/>[db.ts]")]
end

subgraph group_collaboration["Rooms and chat"]
  node_rooms["Room lifecycle"]
  node_roomdb[("Room PostgreSQL<br/>[db.ts]")]
  node_chat["Chat history API"]
  node_chatdb[("Chat MongoDB<br/>[ChatMessage.ts]")]
end

subgraph group_realtime["Live media"]
  node_signaling["WebSocket signaling<br/>[index.ts]"]
  node_redis[("Redis presence and events<br/>[redis.ts]")]
  node_sfu["WebRTC media SFU"]
  node_media["Media room state<br/>[peerManager.ts]"]
end

node_browser(("Browser client"))

node_browser -->|"sends REST"| node_gateway
node_gateway -->|"proxies auth"| node_auth
node_gateway -->|"proxies profiles"| node_users
node_gateway -->|"proxies rooms"| node_rooms
node_gateway -->|"proxies history"| node_chat
node_auth -->|"reads and writes"| node_authdb
node_auth -->|"issues credentials"| node_turn
node_browser -->|"uses ICE"| node_turn
node_users -->|"reads and writes"| node_userdb
node_rooms -->|"reads and writes"| node_roomdb
node_browser -->|"connects WebSocket"| node_signaling
node_signaling -->|"fetches room"| node_rooms
node_signaling -->|"tracks presence"| node_redis
node_signaling -.->|"coordinates media"| node_sfu
node_sfu -->|"manages peers"| node_media
node_signaling -->|"publishes chat events"| node_redis
node_chat -->|"subscribes events"| node_redis
node_chat -->|"reads history"| node_chatdb

click node_gateway "https://github.com/indian-meet/google_meet/blob/master/services/api-gateway/src/routes/proxyRoutes.ts"
click node_auth "https://github.com/indian-meet/google_meet/blob/master/services/auth-service/src/controllers/loginController.ts"
click node_authdb "https://github.com/indian-meet/google_meet/blob/master/services/auth-service/src/config/db.ts"
click node_users "https://github.com/indian-meet/google_meet/blob/master/services/user-service/src/controllers/updateProfileController.ts"
click node_userdb "https://github.com/indian-meet/google_meet/blob/master/services/user-service/src/config/db.ts"
click node_rooms "https://github.com/indian-meet/google_meet/blob/master/services/room-service/src/controllers/endRoomController.ts"
click node_roomdb "https://github.com/indian-meet/google_meet/blob/master/services/room-service/src/config/db.ts"
click node_signaling "https://github.com/indian-meet/google_meet/blob/master/services/signaling-service/src/socket/index.ts"
click node_redis "https://github.com/indian-meet/google_meet/blob/master/services/signaling-service/src/config/redis.ts"
click node_chat "https://github.com/indian-meet/google_meet/blob/master/services/chat-service/src/controllers/getMessagesController.ts"
click node_chatdb "https://github.com/indian-meet/google_meet/blob/master/services/chat-service/src/models/ChatMessage.ts"
click node_sfu "https://github.com/indian-meet/google_meet/blob/master/services/sfu-service/src/controllers/transportController.ts"
click node_media "https://github.com/indian-meet/google_meet/blob/master/services/sfu-service/src/mediasoup/peerManager.ts"

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_gateway,node_turn,node_browser toneBlue
class node_auth,node_authdb,node_users,node_userdb toneAmber
class node_rooms,node_roomdb,node_chat,node_chatdb toneMint
class node_signaling,node_redis,node_sfu,node_media toneRose
```

## Components

### Client edge

- [HTTP API Gateway](https://github.com/indian-meet/google_meet/blob/master/services/api-gateway/src/routes/proxyRoutes.ts): `services/api-gateway/src/routes/proxyRoutes.ts`
- **STUN/TURN**

### Identity and profiles

- [Accounts and tokens](https://github.com/indian-meet/google_meet/blob/master/services/auth-service/src/controllers/loginController.ts): `services/auth-service/src/controllers/loginController.ts`
- [Auth PostgreSQL](https://github.com/indian-meet/google_meet/blob/master/services/auth-service/src/config/db.ts): `services/auth-service/src/config/db.ts`
- [User profiles](https://github.com/indian-meet/google_meet/blob/master/services/user-service/src/controllers/updateProfileController.ts): `services/user-service/src/controllers/updateProfileController.ts`
- [User PostgreSQL](https://github.com/indian-meet/google_meet/blob/master/services/user-service/src/config/db.ts): `services/user-service/src/config/db.ts`

### Rooms and chat

- [Room lifecycle](https://github.com/indian-meet/google_meet/blob/master/services/room-service/src/controllers/endRoomController.ts): `services/room-service/src/controllers/endRoomController.ts`
- [Room PostgreSQL](https://github.com/indian-meet/google_meet/blob/master/services/room-service/src/config/db.ts): `services/room-service/src/config/db.ts`
- [Chat history API](https://github.com/indian-meet/google_meet/blob/master/services/chat-service/src/controllers/getMessagesController.ts): `services/chat-service/src/controllers/getMessagesController.ts`
- [Chat MongoDB](https://github.com/indian-meet/google_meet/blob/master/services/chat-service/src/models/ChatMessage.ts): `services/chat-service/src/models/ChatMessage.ts`

### Live media

- [WebSocket signaling](https://github.com/indian-meet/google_meet/blob/master/services/signaling-service/src/socket/index.ts): `services/signaling-service/src/socket/index.ts`
- [Redis presence and events](https://github.com/indian-meet/google_meet/blob/master/services/signaling-service/src/config/redis.ts): `services/signaling-service/src/config/redis.ts`
- [WebRTC media SFU](https://github.com/indian-meet/google_meet/blob/master/services/sfu-service/src/controllers/transportController.ts): `services/sfu-service/src/controllers/transportController.ts`
- [Media room state](https://github.com/indian-meet/google_meet/blob/master/services/sfu-service/src/mediasoup/peerManager.ts): `services/sfu-service/src/mediasoup/peerManager.ts`

### Other components

- **Browser client**

## Connections

- Browser client → HTTP API Gateway: sends REST
- HTTP API Gateway → Accounts and tokens: proxies auth (evidence: `services/api-gateway/src/routes/proxyRoutes.ts`)
- HTTP API Gateway → User profiles: proxies profiles (evidence: `services/api-gateway/src/routes/proxyRoutes.ts`)
- HTTP API Gateway → Room lifecycle: proxies rooms (evidence: `services/api-gateway/src/routes/proxyRoutes.ts`)
- HTTP API Gateway → Chat history API: proxies history (evidence: `services/api-gateway/src/routes/proxyRoutes.ts`)
- Accounts and tokens → Auth PostgreSQL: reads and writes (evidence: `services/auth-service/src/controllers/loginController.ts`)
- Accounts and tokens → STUN/TURN: issues credentials
- Browser client → STUN/TURN: uses ICE
- User profiles → User PostgreSQL: reads and writes (evidence: `services/user-service/src/controllers/updateProfileController.ts`)
- Room lifecycle → Room PostgreSQL: reads and writes (evidence: `services/room-service/src/controllers/endRoomController.ts`)
- Browser client → WebSocket signaling: connects WebSocket
- WebSocket signaling → Room lifecycle: fetches room
- WebSocket signaling → Redis presence and events: tracks presence
- WebSocket signaling → WebRTC media SFU: coordinates media
- WebRTC media SFU → Media room state: manages peers (evidence: `services/sfu-service/src/controllers/transportController.ts`)
- WebSocket signaling → Redis presence and events: publishes chat events
- Chat history API → Redis presence and events: subscribes events
- Chat history API → Chat MongoDB: reads history (evidence: `services/chat-service/src/controllers/getMessagesController.ts`)
