Service Layer
148 components in the service layer layer
Service Layer components contain business logic, orchestrate operations, and provide core application functionality.
Core authentication service that handles email and password credential validation, JWT access token issuance, rotating refresh token managem...
Server-side handler for the BankID OIDC flow via a certified Norwegian broker (Criipto or Signicat). Exposes initiate and callback endpoints...
Implements the Vipps Login API (OpenID Connect) provider on the Authentication Module backend. Exposes /auth/vipps/initiate and /auth/vipps/...
Orchestrates the full biometric unlock flow: checks device capability, retrieves the stored refresh token from SecureTokenStore, calls POST ...
Platform-native secure storage adapter that persists and retrieves the refresh token using Flutter Secure Storage, which delegates to iOS Ke...
Mobile-side utility that decodes the role claim from the access token at session start and passes it to the Module Registry. Role changes ta...
Backend middleware that reads the role claim array from the validated JWT access token on every protected request and rejects calls from rol...
Orchestrates all read and write operations for user profile data between the remote REST API and the local Drift cache. Applies optimistic m...
Manages the stream of OrganizationMembership objects fetched at login and cached in Drift. Orchestrates the full context-switch flow: POST /...
Flutter infrastructure service using the app_links package that listens for incoming deep links matching the share profile URL pattern. When...
Backend service that generates JWT-signed snapshot URLs for shareable peer mentor profile cards via POST /api/v1/profiles/{userId}/share-lin...
Orchestrates the full FIDO2 WebAuthn registration and assertion ceremonies by coordinating the WebAuthn Bridge (platform channel) with the A...
Flutter platform channel that abstracts native WebAuthn authenticator APIs on iOS (ASAuthorizationController) and Android (CredentialManager...
Core business logic service for activity registration. Handles activity CRUD operations, fetches and caches the activity type catalogue, inj...
Service responsible for uploading activity attachment files to the backend via multipart POST. In offline mode it serialises binary blobs in...
Riverpod Notifier that owns the complete wizard session state including current step index, per-step validated data, and the assembled draft...
Handles all interaction with the device calendar via the Flutter device_calendar plugin, abstracting iOS EventKit and Android CalendarProvid...
Utility service responsible for requesting, caching, and re-checking microphone permission on iOS and Android. Surfaces a structured Permiss...
Flutter service that wraps the speech_to_text plugin, abstracting iOS SFSpeechRecognizer and Android SpeechRecognizer behind a single async ...
Backend-authoritative service that validates coordinator role claims, retrieves the coordinator's managed peer mentor list, and persists act...
Backend API handler that accepts a batch registration payload of shared activity fields plus an array of peer mentor user IDs. Validates cro...
Handles all business logic for event creation including input validation, offline-first local persistence via Drift, and mutation enqueuing ...
Generic BLoC-driven multi-step wizard controller managing step state, validation gating, and the single commit action that finalizes the flo...
Backend service handling participant registration and deregistration for events. Enforces same-organization validation to prevent cross-tena...
Expense Service
Expense Step Controller
Client-side Dart service that compresses captured or selected images to a maximum of 1 MB before upload using flutter_image_compress. Reduce...
Mobile service that enqueues compressed receipt image bytes into the Drift mutation outbox when the device is offline, then schedules upload...
Backend REST service exposing a multipart/form-data endpoint for receipt image upload. Validates file type (JPEG/PNG only) and enforces size...
Backend REST service that exposes the active expense type configuration for the authenticated user's organization, including mutual exclusiv...
Declaration Service
Riverpod provider exposing a reactive combined state of the full contact list and the current search query, with the filtered view derived r...
Riverpod provider that subscribes to a reactive Drift query for a single contact record and its related data, emitting updated state to the ...
Domain service orchestrating the optimistic mutation pattern for contact edits. Immediately writes the updated contact to local Drift storag...
Handles all business logic and CRUD operations for caregiver and next-of-kin records. Provides a reactive Riverpod provider stream so the co...
Riverpod provider encapsulating all business logic for the notes list. Queries the local Drift DAO with user-scoped filtering, exposes react...
Service responsible for picking files or photos from the device using platform file/camera pickers, storing a local file path in note_attach...
Riverpod StateNotifier that listens to note body changes in the editor and persists drafts to the local Drift database using a debounce time...
Riverpod AsyncNotifierProvider that queries the local Drift database to aggregate the current user's activity data into typed statistics mod...
Riverpod FutureProvider-based service fetching and caching coordinator team report data from the REST API. Handles paginated peer mentor pay...
Core backend service that orchestrates Bufdir report generation by querying PostgreSQL for activity records within the specified period and ...
Specialized backend service handling the complex data aggregation logic required for Bufdir report content. Joins activity, contact, and coo...
Admin-portal-only service that enables Global Admins to trigger exports across multiple organizations in a single operation. Queues individu...
Core backend service that receives a validated Bufdir report payload and transforms it into the requested file format (PDF, CSV, or XML). Ha...
Flutter-side service that receives the export binary from the backend, writes it to the device downloads directory using Flutter file system...
Implements the connector interface pattern for pushing approved expense batches to external accounting systems. Each supported target (Xledg...
Manages the registry of available accounting connector modules and their per-organization configuration. Resolves which connector type is ac...
Asynchronous background service that queues approved expense claims and dispatches them to the Accounting API Connector in batches. Implemen...
Manages the full lifecycle of encrypted assignment dispatch: coordinators create and send assignments, delivery and read receipts are tracke...
Scheduled server-side job that identifies assignments exceeding the configurable age threshold (default 10 days) with no read record and tri...
Implements asymmetric end-to-end encryption using the peer mentor's public/private keypair, with the private key stored exclusively in the d...
Admin-facing service for reading and writing organization-specific threshold rule sets stored as JSON in the module_configurations table und...
Backend service responsible for evaluating threshold rules against confirmed-read assignment counts, detecting milestone crossings, and enqu...
Flutter-side service managing the complete lifecycle of FCM and APNs device tokens. Registers tokens on login, subscribes to onTokenRefresh ...
Flutter-side handler for incoming FCM messages across all app lifecycle states - foreground, background, and terminated. Uses flutter_local_...
Backend Next.js service that dispatches push notifications to user devices via the FCM HTTP v1 API. Constructs typed action payloads for Flu...
Prevents duplicate message sends caused by upstream retry logic by generating idempotency keys per outbound event and checking the dispatch ...
Renders versioned server-side HTML email templates by injecting dynamic payload data and per-organization terminology overrides, producing b...
Orchestrates all outbound email and SMS messages, routing transactional notification events to the correct channel based on user preferences...
Handles outbound SMS dispatch via a Norwegian-compliant provider by normalizing recipient phone numbers to E.164 format, delegating to the S...
Manages opt-out requests for marketing-adjacent emails in compliance with Norwegian Markedsføringsloven, maintaining a per-user suppression ...
Scenario Dispatch Router
Scenario Rules Service
Manages reading and writing user notification preferences against both the local Drift cache and the backend REST API. Queries mandatory not...
Handles Flutter deep link routing for both cold-start and warm-start app launch scenarios so the referrer token embedded in invite URLs surv...
Generates short, signed invite URLs with an embedded referrer token and configurable expiry window by calling the backend REST API. Caches t...
Backend service exposing a paginated REST endpoint that aggregates referral data from the referrals table. Executes a single JOIN query (ref...
Riverpod AsyncNotifier on the mobile client that manages fetching and caching of recruitment analytics data. Calls the recruitment analytics...
Business logic layer for course browsing and enrollment lifecycle. Handles paginated course fetching, enrollment writes, role-based access e...
Backend service exposing the admin portal endpoints for manual certificate lifecycle management. Org Admins can issue, revoke, or extend cer...
Server-side scheduled job that queries certificates approaching expiry within the configurable warning window and enqueues push notification...
Handles all client-side certificate operations including fetching the current user's certificate, caching for offline access, and coordinati...
Business logic layer for career workshop lifecycle management. Handles participant roster operations, enforces Coordinator-and-above role re...
Server-side aggregation service that computes a peer mentor's annual impact metrics for a trailing 12-month window. Queries activities, even...
Backend rule engine that evaluates badge trigger conditions as a post-save hook whenever an activity, course enrollment, or contact record i...
Service responsible for reading, writing, and caching the organization-level calculation model parameters (hourly value rates, professional-...
Flutter-side service that persists the most recently received ImpactResult to the local Drift database so the Advantage Calculator Screen ca...
Backend service that receives an activity-summary payload for a user and returns a structured impact object containing computed metric value...
Handles fetching, versioning, and offline caching of talking card content from the backend. Manages cache invalidation when new card sets ar...
A service that collects and surfaces accessibility compliance status across screens, providing structured output for the CI audit step and d...
Manages the registry of field-level sensitivity annotations and per-screen warning behaviour configuration. Annotations are stored as metada...
Core i18n service that registers Northern Sami ARB files with Flutter's flutter_localizations and intl package. Manages locale registration,...
Riverpod-based service that parses the bootstrap API response to extract the tenant's enabled module set, exposes reactive streams of active...
Handles all reads and writes for user preferences, persisting to the backend REST API for cross-device consistency and caching the latest sn...
Backend service exposing REST endpoints for managing and serving the org-configurable external link catalogue. Returns links filtered by the...
Flutter-side service responsible for fetching the link catalogue from the backend, persisting results to the local Drift cache with a config...
POSTs support requests to the backend endpoint, attaching device metadata (platform, OS version, app version, user role) automatically. Hand...
Fetches the privacy policy document from a versioned backend endpoint and caches it in the local Drift database with a configurable TTL for ...
Fetches versioned static content (accessibility statement, privacy policy) from a backend endpoint and caches it in Drift for offline availa...
Fetches structured FAQ content (id, category, question, answer) from the backend public endpoint and caches it offline using Drift with a TT...
Resolves conflicts when the same record was mutated both offline and on the server. Applies entity-scoped strategies: server-wins for activi...
Manages the lifecycle of client-generated temporary UUIDs (v4) used for offline-created entities. Once the server confirms entity creation i...
Applies writes immediately to the local Drift store so the UI remains responsive without waiting for server confirmation. Registers a rollba...
Wraps the connectivity_plus package to expose a reactive stream of network state changes. Subscribes to the stream and triggers an immediate...
Implements truncated exponential backoff with jitter (delay = min(base * 2^attempt + jitter, max_delay), base=30s, max_delay=3600s, jitter ±...
Core orchestrator that drains the mutation outbox in FIFO order by dispatching queued mutations through ApiHttpClient and committing results...
Backend service that executes scoped aggregation queries against PostgreSQL to compute KPI values for the authenticated user's organization....
Server-side service that listens for writes to key tables (activities, expense_claims, assignments, user_roles) and inserts normalized event...
Service responsible for generating time-limited signed JWT invite tokens (48-hour expiry), persisting them to the database, and dispatching ...
Core backend service implementing all user lifecycle operations for the admin portal REST API. Enforces org-scoped authorization so org admi...
Role Assignment Service
Server-side service that executes bulk operations against the users table inside database transactions. Accepts either an explicit list of u...
Backend REST endpoint handler managing activity status transitions from pending to approved or returned. Enforces tenant scoping and role gu...
Service layer responsible for fetching, paginating, and filtering the list of pending activity registrations scoped strictly to the requesti...
REST service that handles manual and automated flag lifecycle operations on activity records. Exposes PATCH endpoints for flagging and unfla...
Server-side service that executes duplicate detection logic both synchronously on activity creation and asynchronously during the nightly ba...
Read-side backend service exposing a paginated, filterable REST endpoint that returns expense claims scoped to the authenticated approver's ...
Backend service handling all approval and rejection mutations for expense claims. Wraps each decision in a database transaction that atomica...
Backend service that persists auto-approval rule configuration per tenant and evaluates expense claims synchronously at submission time. App...
Streaming export service that writes filtered expense records directly to the HTTP response without buffering the full result set in memory....
Backend service that computes and serves aggregate expense metrics by combining nightly-materialized snapshots with a real-time current-day ...
Backend service implementing the /api/v1/reports/team endpoint. Aggregates activity data from the activities and organization_memberships ta...
Utility service that constructs parameterized PostgreSQL aggregate queries for the team reports endpoint. Accepts filter parameters and tena...
Server-side service that orchestrates the full Bufdir export pipeline. Receives the export job request, queries activities, peer mentor part...
Frontend polling service used by the Export Progress Modal to track an in-flight export job. Calls the status endpoint on an interval, appli...
Backend service that receives a query descriptor from the client, validates every dimension and metric against a server-side whitelist, enfo...
Shared service that serializes report result data into CSV or Excel format and streams the file to the client. Accepts the same paginated JS...
Backend service handling all mutations to an organization's configuration via a dedicated settings API endpoint. Enforces org-admin role aut...
Flutter-side singleton service that resolves display labels for the authenticated user's organization by reading from the local Drift cache ...
Backend service managing CRUD operations for organization-scoped label overrides stored in the organization_labels table. Merges overrides w...
Backend service managing the enabled module set per organization tenant. Persists toggle changes, resolves inter-module dependencies, assemb...
Enforces level-scoped access control for all hierarchy management operations. Ensures that admins can only create, update, or delete organiz...
Backend service responsible for all CRUD operations on the organizational hierarchy. Uses recursive CTEs in PostgreSQL to traverse the tree ...
Core backend service that manages the lifecycle of user-to-organization memberships. Enforces the single-primary-membership constraint via a...
Generates and validates time-limited invitation tokens used to onboard peer mentors and coordinators into a specific organizational unit. To...
Service responsible for encrypting, storing, and retrieving per-organization connection credentials (OAuth 2.0 client secrets or API keys) f...
Backend connector service that ingests events and data from HLF's Dynamics-based external portal via secure webhook or polling endpoint. Rea...
Stateless service that translates between the external portal's data schema and Meander's internal user and organization model. Applies the ...
Pluggable adapter layer that routes approved expense claim payloads to the correct external accounting system using per-organization configu...
Internal event subscriber that listens for expense claim approval domain events emitted by the expense approval service. On each event it ch...
Evaluates security event streams against configurable per-tenant thresholds to identify patterns such as N failed logins within T minutes or...
Core backend service querying audit_logs, sessions, and refresh_tokens tables to compute aggregated security metrics with per-tenant scoping...
Backend service that handles all read queries against the audit_logs table. Supports pagination, multi-field filtering, and date range queri...
Core append-only backend utility that writes immutable audit log entries. Called by all authentication flows and every write operation acros...
Backend service that implements soft-deletion of refresh tokens by setting a revoked_at timestamp, cascading invalidation to all child token...
Lightweight client-side analytics integration using Plausible or Vercel Analytics to track page views, CTA interactions, and conversion funn...
Utility that loads and parses MDX files or headless CMS content for all sales website pages. Provides typed content interfaces so page compo...
Pure client-side calculation module implementing conservative, documented ROI formulas covering time savings, reporting accuracy improvement...
Holds the editable content configuration object defining all cost line items, labels, assumptions, and default organization profile values. ...
Pure function utility that takes a base cost configuration and an organization size value and returns scaled manual-cost estimates. Applies ...
Server-side Next.js API route handler that receives booking form submissions, applies server-side Zod validation, persists the lead record t...
Shared Zod schema definitions and validation logic for the booking form, providing a single source of truth for field rules used on both the...
Server-side middleware that enforces per-IP and per-email submission rate limits and validates the honeypot field on incoming booking reques...
Generates and validates short-lived signed tokens embedded in the redirect URL from the booking form to the confirmation page. Prevents raw ...
Sends a branded transactional confirmation email to the prospect immediately after a successful demo booking. Uses an HTML email template ve...
Provides versioned privacy policy content from MDX files or a headless CMS, enabling legal document updates without code deployments. Return...
Backend service that manages Terms of Service versioning, serves the current version to the frontend, and records explicit acceptance events...
Server-side utility that generates or serves a pre-rendered PDF of the current DPA document. Ensures the downloaded file matches the on-scre...
Other Component Types
User Interface components handle presentation logic, user interactions, and visual elements of the application.
Data Layer components manage data persistence, storage operations, and data access patterns throughout the application.
Infrastructure components provide foundational utilities, system integrations, and supporting functionality for the application.