To create statistics, certain HTTP requests (more precisely, the response bodies) should be recorded in the background while the Chrome browser is being used. Basically, it's about evaluating all requests/responses that can also be seen in the network tab of the browser's developer tools (especially XHR requests).
The aim is to filter out certain of these requests based on the URL and to analyze the responses. Certain information should then be sent to an external server for data storage.
Unfortunately, I fail at step 1: What is the best way to read the responses? For example, I tried https://axios-http.com/ but unfortunately didn't make it. I've also tried replacing jQuery's XHR function, but that also results in errors or not all requests being logged. Attempt number 3 would have been a proxy like Charles, but I have no idea how to then analyze/filter the requests and, in particular, export them automatically and send them to a server. There may be a Chrome plugin for this, or it's possible with Selenium, but I have little idea about it.
If you control the clients, the most reliable way is to create a small Chrome extension yourself and use the chrome.webRequest API. You'll find examples on how to build Chrome extensions here.