I have a chrome extension and there is a websocket that i get message with below code.
chrome.tabs.query({ currentWindow: true, active: true }, function (tabs) {
let activeTab = tabs[0];
chrome.debugger.attach({ tabId: activeTab.id }, "1.1", function () {
chrome.debugger.sendCommand({ tabId: activeTab.id }, "Network.enable");
chrome.debugger.onEvent.addListener((debuggerId, message, params) => {
if (message === "Network.webSocketFrameReceived") {
handleWebsocketMessage(params.response.payloadData);
}
})
})
})
}
Is there any method which can help me to send websocket message in debugger mode ? I searched in Chrome DevTools Protocol and i found Network.WebSocketFrame but i don't know how can use it.