README.md: fix UI protocol documentation
[e-mobility-charging-stations-simulator.git] / src / types / WorkerBroadcastChannel.ts
index 2cc18943cfbe11019dec4115acf8ad21138f5dc5..f235200c283b0393e900754b19e93d9e26f377fc 100644 (file)
@@ -16,28 +16,17 @@ export enum BroadcastChannelProcedureName {
   STOP_TRANSACTION = 'stopTransaction',
   START_AUTOMATIC_TRANSACTION_GENERATOR = 'startAutomaticTransactionGenerator',
   STOP_AUTOMATIC_TRANSACTION_GENERATOR = 'stopAutomaticTransactionGenerator',
+  STATUS_NOTIFICATION = 'statusNotification',
 }
 
-interface BaseBroadcastChannelRequestPayload extends Omit<RequestPayload, 'hashId' | 'hashIds'> {
+export interface BroadcastChannelRequestPayload extends RequestPayload {
   connectorId?: number;
-  connectorIds?: number[];
   transactionId?: number;
   idTag?: string;
 }
 
-interface HashIdBroadcastChannelRequestPayload extends BaseBroadcastChannelRequestPayload {
-  hashId: string;
-}
-
-interface HashIdsBroadcastChannelRequestPayload extends BaseBroadcastChannelRequestPayload {
-  hashIds: string[];
-}
-
-export type BroadcastChannelRequestPayload =
-  | HashIdBroadcastChannelRequestPayload
-  | HashIdsBroadcastChannelRequestPayload;
-
-export interface BroadcastChannelResponsePayload extends ResponsePayload {
+export interface BroadcastChannelResponsePayload
+  extends Omit<ResponsePayload, 'hashIdsSucceeded' | 'hashIdsFailed' | 'responsesFailed'> {
   hashId: string;
 }