export type AppRouteSource =
  | 'gateway'
  | 'system.devices'
  | 'runtime-registry'
  | 'projection';

export type AppRouteServedBy =
  | 'linked-device'
  | 'current-host'
  | 'platform-local'
  | 'auto-selected'
  | 'unavailable';

export type AppRouteTargetSource =
  | 'explicit'
  | 'namespace'
  | 'auto'
  | 'linked-device'
  | 'current-host'
  | 'linked-device-route'
  | 'linked-device-offline'
  | 'linked-device-app-route-missing'
  | 'linked-device-asset-mount-unreachable'
  | 'linked-device-runtime-control-unavailable'
  | 'current-host-route'
  | 'dashboard-section';

export interface IAppRouteView {
  readonly appName: string;
  readonly url: string;
  readonly routePrefix: string;
  readonly routeKey?: string;
  readonly authorityRoot?: string;
  readonly runtimeTargetRoot?: string;
  readonly runtimeWireRoot?: string;
  readonly deviceId?: string;
  readonly runtimeHostViewId?: string;
  readonly runtimeId?: string;
  readonly packageRef?: string;
  readonly routeSource: AppRouteSource;
  readonly servedBy: AppRouteServedBy;
  readonly targetSource?: AppRouteTargetSource;
  readonly requestedTarget?: string;
  readonly actualTarget?: string;
  readonly assetMount?: string;
  readonly origin?: string;
  readonly runtimeControlHealthStatus?: string;
  readonly runtimeControlHealthReason?: string;
  readonly recoveryReason?: string;
}
