barsa 38bb40b88b Add Service and Component Structure for Internet and SIM Offerings
- Introduced new controllers for internet eligibility and service health checks to enhance backend functionality.
- Created service modules for internet, SIM, and VPN offerings, improving organization and maintainability.
- Developed various components for internet and SIM configuration, including forms and plan cards, to streamline user interactions.
- Implemented hooks for managing service configurations and eligibility checks, enhancing frontend data handling.
- Updated utility functions for pricing and catalog operations to support new service structures and improve performance.
2025-12-25 13:20:45 +09:00

22 lines
657 B
TypeScript

/**
* Realtime Events - Shared Contracts
*
* Shared SSE payload shapes for portal + BFF.
*/
export interface RealtimeEventEnvelope<TEvent extends string = string, TData = unknown> {
event: TEvent;
data: TData;
}
export interface ServicesEligibilityChangedPayload {
accountId: string;
eligibility: string | null;
timestamp: string;
}
export type AccountStreamEvent =
| RealtimeEventEnvelope<"account.stream.ready", { topic: string; timestamp: string }>
| RealtimeEventEnvelope<"account.stream.heartbeat", { topic: string; timestamp: string }>
| RealtimeEventEnvelope<"services.eligibility.changed", ServicesEligibilityChangedPayload>;