I have some JS code in a webpage that is executed and sends some data gathered when certain events (such as changing pages) are done. I would like to exclude all (or almost all) of the devices in my workplace to execute this function, so as to not gather data that is made in work (99% of it is test data and garbage).
My idea is to use geolocation or IPs in order to exclude this devices (or this location) from executing the JS function, but I don't have a clue how I should do it.
I wouldn't like the webpage to show a popup for asking permission for geolocation, so I prefer to use IP location, but I don't know how that works exactly (once I have the IP, what is next?). I have seen some services but most of them are very limited in the number of requests made by hour/day.
Thank you and best regards.