Skip to content

Architecture

MikroPlan is a browser app, optional Node API, and SQLite-backed shared workspace.

  • The app archive contains the static browser UI and runtime config loader.
  • The API archive contains the Node server, config example, OpenAPI document, and persistence layer.
  • Local-only deployments can use only the app archive.
  • Shared workspace deployments use both archives.

The browser app is written in TypeScript and compiled with esbuild. It can use either:

  • IndexedDbPlanRepository for local-only mode
  • HttpPlanRepository for API mode

The UI treats the workspace as immutable state. Board changes produce a new normalized workspace and save it through the active storage mode.

The API is a small Node HTTP server. It serves static files, workspace endpoints, magic-link auth endpoints, Server-Sent Events, health checks, and an OpenAPI document.

Server configuration is loaded through MikroConf from defaults, mikroplan.config.json, environment overrides, and CLI arguments.

Workspace saves use a revision number. The API rejects stale writes when the caller provides an old revision.

When auth is enabled, workspace and event routes require a valid MikroAuth session. The browser app uses the HttpOnly auth cookie; bearer tokens remain an API fallback. Magic-link requests are restricted by configured allowed emails and domains.

Local mode stores the workspace in IndexedDB.

API mode stores the workspace snapshot, current revision, MikroAuth magic links, and MikroAuth sessions in SQLite.

The app and API are distributed as separate release archives:

  • https://releases.mikrosuite.com/mikroplan_app_latest.zip
  • https://releases.mikrosuite.com/mikroplan_api_latest.zip

The API server can serve the extracted app directory directly with --static-root.