Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IP to Earth #33

Open
nerg4l opened this issue Sep 29, 2019 · 4 comments
Open

IP to Earth #33

nerg4l opened this issue Sep 29, 2019 · 4 comments

Comments

@nerg4l
Copy link

nerg4l commented Sep 29, 2019

Add support for IP to Earth Heroku add-on.

Heroku is getting more and more popular because of the cheap price and simple deployment. It would be beneficial to support one of their add-on.

@yak0d3
Copy link
Member

yak0d3 commented Mar 5, 2020

Would you please elaborate a bit more? How could IP to Earth benefit this package?

@nerg4l
Copy link
Author

nerg4l commented Mar 6, 2020

We could add a driver to stevebauman's location package.

The short description of this add-on for Heroku states the following:

Find the Country and City of origin for an IP Address

This could be a useful feature for developers who already integrated their services to Heroku.

@yak0d3
Copy link
Member

yak0d3 commented Mar 29, 2020

Do you mean supporting geo-constraints with not only countries but also cities and regions? (e.g. ->allowFrom('Virginia Beach, VA, US'))

@nerg4l
Copy link
Author

nerg4l commented Mar 30, 2020

Under the hood this package is using stevebauman/location which has 5 drivers (IpApi, IpApiPro, IpInfo, GeoPlugin, MaxMind). The proposal is to add an other driver which is using a Heroku add-on called IP to Earth.

When using this add-on you send a request to https://iptoearth.expeditedaddons.com/?api_key={{API_KEY}}&ip={{IP}} and receive a response. The respond contains country_code which can be used for the filter.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants