If you're using CDXZipStream and want to leverage Google Maps services—like geocoding, routing or creating maps—you'll need to set up a Google Maps API key. This key is crucial as it allows your application to authenticate with Google's servers to access mapping data. This guide walks you through creating a Google Maps API key and setting it up in CDXZipStream.
Step 1: Setting Up Your Google Cloud Account
Before you can create an API key, you’ll need a Google Cloud Platform (GCP) account. Follow these steps if you haven't already created one:
- Sign up for Google Cloud: Go to the Google Cloud Platform and sign up. A Gmail account and credit card is required for full access to the service. As of the writing, Google is offering a free trial for 90 days with a $300 credit, which can help you test out the Google Maps API before committing to a billing plan. Google will not automatically charge your credit card after the trial period or when $300 is reached. You will need to re-enable the service to continue. After your trial, Google offers monthly billing plans with a $200 credit.
- Create a New Project: In the Google Cloud Console, click on the Select a Project drop-down at the top, then select New Project. Give it a name that reflects the use of Google Maps with CDXZipStream.
Step 2: Enable the Google Maps API
Once you have a project set up, you’ll need to enable the necessary APIs:
- Go to the API Library: In the Google Cloud Console, navigate to API & Services area
- Enable the Required APIs: Click on “Enable APIs and Services”. For CDXZipStream to work correctly you need to enable 4 specific APIs.
All of the following APIs are required. Use the search function to quickly find and enable APIs.
- Geocoding API: For address-to-coordinate conversion.
- Route API: For calculating distances between locations.
- Maps Static API: For embedding Google Maps graphics in Excel
- Directions API: For additional information about route details.
You can also find these in the the “Maps” category section.
- For each API, click on it and select Enable. It may take several minutes for these changes to propagate to all of Google’s servers.
Step 3: Create an API Key
Now that the necessary APIs are enabled, you can create an API key. Go to the Credentials Page: Navigate to API & Services > Credentials.
- Click on "Create Credentials": Then Select API Key from the drop-down menu. Google will generate an API key for you.
- Restrict Your API Key: For security, it’s a good practice to restrict your API key to specific services and IP addresses. Click on the key shown to add restrictions.
- Save Your Key: Copy the API key to a secure location, as you’ll need it for CDXZipStream.
Step 4: Enter the API Key in CDXZipStream
Now that you have your Google Maps API key, you can integrate it with CDXZipStream.
- Open CDXZipStream: Launch Excel and go to the CDXZipStream tab.
- Access Settings: Click on Settings within the CDXZipStream ribbon. Press the "Google API" settings button.
.
- Enter the API Key:
In the dialog that appears, press the "Set Google API key" button. Then paste in your Google Maps API key.
- Test the Key: CDXZipStream will test the key that it is valid and that the correct Google services have been set up. You will receive an error message if the correct APIs have not been enabled. You can also press the "Check Google Api Services" button on the dialog above to see the status of the required API's.
Step 5: Start Using Google Maps API Functions in CDXZipStream
Once you’ve entered your API key, you can start using the Google Maps-based functionalities in CDXZipStream. Here are some of the tasks you can accomplish:
- Geocoding: Convert addresses to latitude and longitude with CDXLocateGoogle.
- Distance Calculations: Calculate distances or directions between locations using CDXRouteGoogle
- Mapping: Embed Maps with the right-click Google menu functions.
Additional Tips
- Monitor Your Usage: Google Maps services are typically billed based on usage. Google Cloud offers detailed usage reporting and budgeting tools to help you keep track of your API usage.
- API Limits: Keep in mind the rate limits and quotas associated with Google Maps APIs. If you exceed these limits, you may experience temporary access issues.