$  curl https://ip4.dev/location/ type IP,then press `Enter`

{
ip: "8.8.8.8",
continent_code: "NA",country: "United States",
country_code: "US",country_code3: "USA",
latitude: 37.751,longitude: -97.822,
timezone: "America/Chicago",offset: -21600,
asn: 15169,organization: "GOOGLE"
}
      

curl https://ip4.dev/location?callback=jsonCb11836

 jsonCb11836 ({
ip: "8.8.8.8",
continent_code: "NA",country: "United States",
country_code: "US",country_code3: "USA",
latitude: 37.751,longitude: -97.822,
timezone: "America/Chicago",offset: -21600,
asn: 15169,organization: "GOOGLE"
})
      

curl https://ip4.dev/myip

8.8.8.8
      

curl "https://ip4.dev/myip?format=json"

{"code":200,"data":"8.8.8.8" }
      

curl https://ip4.dev/myip?callback=jsonCb11836

jsonCb11836("8.8.8.8");