fetch('https://api.ipify.org/?format=json') .then(response => response.json()) // Returns { "ip": "user_ip" }