Set Up Pretty URLs with Google Maps
Link: https://support.brilliantdirectories.com/support/solutions/articles/12000086439
This article covers the steps to create a second Google Maps API key for use with the Enable All Location Features For "Pretty URL" Search Results Pages Advanced Setting. This new API key will be set up to work with server-side API calls necessary for this functionality in addition to the Javascript API calls used by the normal API Key used elsewhere on the website.
Create the API Key
Log in to the Google Console Credentials page: https://console.cloud.google.com/apis/credentials
Click on "+ Create Credentials":
Click on "API key":
Click "Close":
Click on Actions >> Edit API Key:
Name the API key and select IP addresses:
Now it's time to add the IPs that have permission to use the key.
First, add the IP address for the Admin of the website, Managemydirectory.com:
216.120.255.180
Next, we also need to add the IP address of the website's server. To find this IP address, navigate to Settings >> Domain Manager in the Admin of the site. Scroll down and find the IP displayed here:
NOTE: Websites are hosted on different servers, and the IP address shown in the screenshot may be different than the IP address shown in the Admin of the website. It is important to use the IP address shown in the Admin of the website, even if it is different from the IP address shown above.
Once the Server IP is added, click on "Done":
Click on "Don't Restrict Key":
Finally, click on "Save". This will refresh the page and display the list of API Credentials saved for the account.
Geocoding API
Make sure the Geocode API is enabled in the account:
Enable the API:
Add the API Key to the Website
Copy the API Key from the Google Console here:
Log in to the Admin of the website and navigate to Settings >> Advanced Settings. Locate the Advanced Setting called All Location Features For Pretty URL Search Results Pages API Key
Paste the API Key from the clipboard and click "Save Settings":
Finally, locate the setting Enable All Location Features. With the new API Key added, this setting can be set to "On":
API Usage Cost
Beginning in March 2025, enabling this setting will impact how quickly free Google API credits are used.
Previously, Google provided a flat $200 monthly credit covering all API requests, but now they offer the first 10,000 requests per month free for each API, with charges applied only after surpassing this limit.
If a particular API (like the Geocoding API) experiences heavy use, this new structure means the free allowance will be used up more quickly, causing charges from Google to accumulate sooner.
For more information about Google Maps Monthly Credits Usage and pricing: https://developers.google.com/maps/billing-and-pricing/faq