@startuml title "Application" left to right direction package "AppFlowy Application" { [User] } cloud "Supabase Server" { [RESTful Component] [Realtime Component] [Postgres DB] } database "LocalServer" { [Local Server Component] } cloud "AppFlowy Cloud Server" { [RESTful Component] as [AppFlowy RESTful Component] [Realtime Component] as [AppFlowy Realtime Component] [Postgres DB] as [AppFlowy Postgres DB] } User --> [AppFlowy Application] [AppFlowy Application] --> [Local Server Component] : Connect [AppFlowy Application] --> [RESTful Component] : RESTful API Communication [AppFlowy Application] <..> [Realtime Component] : WebSocket Communication [AppFlowy Application] --> [AppFlowy RESTful Component] : RESTful API Communication [AppFlowy Application] <..> [AppFlowy Realtime Component] : WebSocket Communication @enduml @startuml left to right direction interface AppFlowyServer { + enable_sync(_enable: bool) + user_service(): Arc + folder_service(): Arc + database_service(): Arc + document_service(): Arc + collab_storage(): Option> } class SupabaseServer { + enable_sync(_enable: bool) + user_service(): Arc + folder_service(): Arc + database_service(): Arc + document_service(): Arc + collab_storage(): Option> } class SelfHostServer { + user_service(): Arc + folder_service(): Arc + database_service(): Arc + document_service(): Arc + collab_storage(): Option> } class LocalServer { + user_service(): Arc + folder_service(): Arc + database_service(): Arc + document_service(): Arc + collab_storage(): Option> } SupabaseServer -u-|> AppFlowyServer SelfHostServer -u-|> AppFlowyServer LocalServer -u-|> AppFlowyServer @enduml