Pricing Blog

get user ip address

  • ssssadsadasd-1408749312850133112

    ssssadsadasd

    3 months ago

    I want to use [this api](https://ip-api.com/docs/api:json), to get user's ip address (I need the country). for that I need to disable "proxy request" in NC otherwise it gets the cloudflare country. however, if I disable it shows an error.

    how to solve this? thanks
  • andreasmoller-1408797470053629963

    Andreas Møller

    3 months ago

    What is the error?
  • ssssadsadasd-1409087258245468232

    ssssadsadasd

    3 months ago

    @Andreas Møller "Failed to fetch"
  • andreasmoller-1409126937774919752

    Andreas Møller

    3 months ago

    Can you check your browser console and see if there are any Cross Origin Errors?
  • ssssadsadasd-1409142908459814922

    ssssadsadasd

    3 months ago

    @Andreas Møller
    Mixed Content: The page at 'https://appname.toddle.site/home' was loaded over HTTPS, but requested an insecure resource 'http://ip-api.com/json/'. This request has been blocked; the content must be served over HTTPS.
  • ssssadsadasd-1409144556909367400

    ssssadsadasd

    3 months ago

    ah so it means i have to use https for which oyu need a subscription
  • andreasmoller-1409148924953886801

    Andreas Møller

    3 months ago

    Yes
  • Really? They make you subscribe for https?

    That is dodgy
  • ssssadsadasd-1409151725536936096

    ssssadsadasd

    3 months ago

    yeah, when I add https it tells you to get a paid plan.
    found this one which seems to work https://api.country.is/