export enum ConnectionState {
  DISCONNECTED = 'disconnected',
  CONNECTING = 'connecting',
  CONNECTED = 'connected',
  ERROR = 'error',
}

export interface ConnectionStatus {
  botId: string;
  state: ConnectionState;
  connectedAt?: Date;
  lastHeartbeat?: Date;
  error?: string;
}

export class WsStatusResponseDto {
  botId: string;
  state: ConnectionState;
  connectedAt?: string;
  lastHeartbeat?: string;
  error?: string;
}

export class WsConnectResponseDto {
  success: boolean;
  botId: string;
  status: ConnectionState | string;
  error?: string;
}

export class WsDisconnectResponseDto {
  success: boolean;
  botId: string;
  status: ConnectionState | string;
}

export class AllWsStatusResponseDto {
  connections: WsStatusResponseDto[];
}
