From a295017d8e14636c9a0f0492c57022778ee67864 Mon Sep 17 00:00:00 2001 From: sigurdgroneng Date: Wed, 13 Dec 2023 12:05:14 +0100 Subject: [PATCH] Fix payload names --- src/api/nyDialogWs.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/api/nyDialogWs.ts b/src/api/nyDialogWs.ts index c0b294fe..c460c1e3 100644 --- a/src/api/nyDialogWs.ts +++ b/src/api/nyDialogWs.ts @@ -3,7 +3,7 @@ const ticketUrl = `/please/ws-auth-ticket`; const socketUrl = `ws://${PLEASE_URL}/ws`; enum EventTypes { - NY_MELDING = 'NY_MELDING' + NY_MELDING = 'NY_DIALOGMELDING_FRA_BRUKER_TIL_NAV' } enum ReadyState { @@ -25,7 +25,7 @@ let socket: WebSocket | undefined = undefined; export const listenForNyDialogEvents = (callback: () => void, fnr?: string) => { // Start with only internal if (!fnr) return; - const body = { fnr }; + const body = { subscriptionKey: fnr }; if (socket === undefined || ![ReadyState.OPEN, ReadyState.CONNECTING].includes(socket.readyState)) { socket = new WebSocket(socketUrl); } else {