The easiest thing is to to call an External API which responds back with an IP Address of the caller.
Now i looked around but couldnt find any that is quite clean and useful.
So i made one for this :) It is a simple API to which you can make a GET request from your Javascript Action and the response is in JSON format. One example is below.
{"client_ip_addresss":"111.111.111.111"}
// BEGIN USER CODE
const response = await fetch("https://polite-kashata-ea7b05.netlify.app/api/address");
const jsonData = await response.json();
return jsonData.client_ip_addresss;
// END USER CODE
Put a button somewhere which can call a Nanoflow which has an Action of type Javascript Action Call
Let me know how it went
Hi Corina,
If you want the client's IP address you can get this using a request handler. There is a module on the App Store called IP Validation. Which checks an IP address on login
https://appstore.home.mendix.com/link/app/1752/
And if this doesn’t help you might wanna have a look at this question also,
https://forum.mendix.com/link/space/other/questions/5846
Hope it helps!!