Skip to main content

Hub

This section covers both the Hub backend (io-oidis-hub) and the Hub frontend (io-oidis-hub-gui). The backend provides the authentication system, data layer, agent tunneling, webhooks, email engine, and GraphQL API. The frontend provides the admin dashboard, user portal, and SSO interface.

Hub Backend (io-oidis-hub)​

PagePurpose
Backend OverviewLoader, initialization lifecycle, extension points
HTTP Server & ResolversSecurity filtering, 16 HTTP resolvers
Database Models17 MongoDB models, converters, DB upgrades
GraphQL APIDynamic schema generation, auth-aware execution
Email SystemTemplate-based async email queue
WebhooksAdapter-based processing, hub-to-hub sync
External ConnectorsSlack, MS Teams, certificates, file transfer
Logging & MonitoringAudit logs, crash reporting, state tracking
Hub UtilitiesEnvironmentHelper, Threads, Puppeteer, notifications
Configuration ReferenceFull IProject config reference
Legal DocumentsResolver, JSONP defaults, print/PDF dialog for terms/privacy/conditions/cookies

io-oidis-hub-gui​

Frontend application for the Oidis synchronization hub. Provides the admin dashboard, user portal, SSO authentication, and system monitoring interface.

Package Purpose​

io-oidis-hub-gui is the web frontend that runs on top of the hub backend (io-oidis-hub). It provides:

  • Admin Dashboard — Role-based dashboard with dynamic tools menu for user, organization, and system management
  • User Portal — Main page with profile editing, feedback, and FAQ
  • SSO Authentication — Sign-in, sign-up, password reset, OAuth, 2FA challenge and registration
  • User & Organization Management — CRUD operations for users, groups, organizations, and permissions
  • System Monitoring — Agent status, event loop visualization, system logs, server state notifications
  • Configuration Registry — Browse and manage configuration files and app settings
  • Webhooks & Notifications — Webhook management and push notification system
  • Reports & Logging — Usage reports, system logs, and audit trails
  • Print Pipeline — Print-optimized views via Puppeteer integration

Dependency Position​

io-oidis-commons ← io-oidis-services ← io-oidis-gui ← io-oidis-usercontrols ← io-oidis-hub-gui
io-oidis-services ←──────────────────────────────────────────↑

Hub GUI depends on services and usercontrols (which transitively includes gui and commons). It is the topmost GUI layer — solution GUI projects (e.g. io-oidis-{solution}-gui) extend it.

Source Structure​

source/typescript/Io/Oidis/Hub/Gui/
├── Bindings/ — UI interaction handlers (Header, SSO, OAuth, ServerState, FileUpload, etc.)
├── Connectors/ — API connectors to hub backend services (AuthManager, Registry, Reports, etc.)
├── Controllers/
│ ├── Pages/ — Page controllers with @Resolver route decorators
│ └── Panels/ — Panel controllers for dashboard tools and user panels
├── DAO/ — Data validators (Email, Phone, Password, Range, Regex, Enum)
├── Dialogs/ — Modal dialogs (BackdoorLogin, Notifications, ReleaseNotes, Scanner)
├── Enums/ — MenuItemScope, PushNotificationType, StatusIndicator
├── HttpProcessor/ — Error and NotAuthorized resolvers
├── Interfaces/ — IProject configuration with auth providers and header strip
├── LogProcessor/ — InMemory and Forwarding log adapters
├── Models/ — Data models (User, Group, Organization, Agent, AppSettings, etc.)
├── Pages/ — Page views (MainPage, DashboardPage, SSOPage, InitPage, AdminInitPage)
├── Panels/ — Panel views for dashboard and main page sections
├── Primitives/ — Base classes (BasePageLayout, MenuPageLayout, StickyHeaderLayout, etc.)
├── RuntimeTests/ — Browser-based runtime test utilities
├── Structures/ — UserContext — authentication and authorization state
├── UserControls/ — Custom UI components (tables, menu items, breadcrumbs, skeleton loader)
├── Utils/ — BarCodeEngine, CanvasHelper, Convert
├── Viewers/ — View rendering logic
├── ViewersArgs/ — Viewer argument definitions
├── Loader.ts — Singleton entry point
└── ForceCompile.ts — Decorator registration trigger

Entry Point​

The Loader class extends io-oidis-services Loader. It initializes log adapters (InMemoryAdapter, ForwardingAdapter), the UserContext, and the HttpResolver with / as the base path.

import { Loader } from "@io-oidis-hub-gui/Io/Oidis/Hub/Gui/Loader.js";

Loader.Load(appConfig);
const loader : Loader = Loader.getInstance();
const context : UserContext = loader.getContext();
await context.Load();

Key Loader API:

MethodReturnsPurpose
getInstance()LoaderSingleton accessor
getAppConfiguration()IProjectProject configuration with auth providers and header strip
getContext()UserContextAuthentication and authorization state
ApplicationLog()ILoggerTrace[]In-memory application logs
setLogsContext($value)voidSet user ID context for log forwarding and Sentry

Configuration​

Application configuration extends the commons IProject interface with:

  • authProviders — OAuth provider settings (e.g. Google sign-in)
  • target.headerStrip — Environment-specific header banner (prod, dev, eap, localhost) with title and message

See Application Settings for the full configuration reference.

Exported API​

Primitives​

ClassLocationPurpose
LoaderLoader.tsSingleton entry point — initializes subsystems
BasePageLayoutPrimitives/BasePageLayout.tsAbstract page with tabs, dialogs, toasts, skeleton loader
BasePageLayoutControllerPrimitives/BasePageLayoutController.tsAccess validation, tab lifecycle, push notifications
StickyHeaderLayoutPrimitives/StickyHeaderLayout.tsUser-facing page layout with sticky header and footer
StickyHeaderLayoutControllerPrimitives/StickyHeaderLayoutController.tsController for main page layout
MenuPageLayoutPrimitives/MenuPageLayout.tsAdmin dashboard layout with sidebar menu
MenuPageLayoutControllerPrimitives/MenuPageLayoutController.tsMenu binding, dynamic tab registration by role
BasePanelControllerPrimitives/BasePanelController.tsBase controller for individual panels
BaseSubpanelControllerPrimitives/BaseSubpanelController.tsBase controller for nested subpanels
PrintPagePrimitives/PrintPage.tsPrint-optimized page layout

Pages​

ClassLocationPurpose
MainPagePages/MainPage.tsUser-facing hub page (profile, feedback, FAQ)
DashboardPagePages/DashboardPage.tsAdmin dashboard with tool tabs
SSOPagePages/SSOPage.tsAuthentication page (sign-in, sign-up, 2FA)
InitPagePages/InitPage.tsSystem initialization / loading page
AdminInitPagePages/AdminInitPage.tsFirst-time admin account setup

Structures​

ClassLocationPurpose
UserContextStructures/UserContext.tsAuth state: IsAuthenticated, IsAdmin, IsSysAdmin, Need2FACheck

Models​

ClassPurpose
UserUser profile with groups, tokens, 2FA, audit log
GroupRole group (Admin, SysAdmin, custom)
OrganizationOrganization profile with ownership
AgentSync agent status and configuration
AppSettingsGlobal application settings
AuthCodeOAuth authorization codes
AuthTokenSession and API tokens
SSOTokensExternal SSO provider tokens
ConfigFileRegistry configuration files
LogEntrySystem log records
NotificationEntryPush notification records
SendmailEmail/sendmail configuration
PrintPrint job metadata
FileEntryFile metadata for uploads
WhatsNewDaoRelease notes data
PackageInfoVersion and package info
SelfupdatePackageSelf-update package metadata
UserAuditLogLogin history and activity tracking

Sub-pages​

PagePurpose
Pages and RoutingPage hierarchy, @Resolver routes, tab system, layouts
Dashboard and Tools MenuAdmin dashboard, menu scopes, built-in panels
SSO and AuthenticationSSO flow, 2FA, OAuth, role-based access
Connectors and APIAPI connectors to hub backend services
Extending Hub GUIAdding panels, models, and menu items in solution projects

See also: Architecture Overview | GUI Panels and Controllers | Connectors Reference | Separate GUI Repository