#Whitelists with getStaticProps and getServerSideProps
1 messages · Page 1 of 1 (latest)
A few questions to help me answer you: 1. Where are you building and running your code? 2. Could u go more in detail of what you’re trying to achieve and how the whitelist fits into all of this?
Sure!! So I've deployed my project with AWS Amplify and what I currently have is a page with getStaticProps that does a fetch to the Google Maps API to get a estimated location of the user. Everything works fine till I deploy it, then when I check the deployment it doesn't render any of the data it should fetch. I believe this is due to the API key, I have 2 keys for my project. Key 1 is for development so I can test the maps API. Key 2 is restricted to only work on the domain I use for my deployment.
What error are you getting
Sorry I didn't see this, I managed to solve the issue, it was a configuration issue with the map service, and as a fallback I have an unrestricted api key.
Now i'm just trying to figure out a painless way to setup a geoip service or use something like fast-geoip in my static and ssr props