It’s not just technology and underwear that change frequently, software requirements and Terms of Service (TOS) can change quickly too. Even if you don’t do anything, external factors can turn your app into 404 without warning. This can happen for many reasons, including when changes come to the APIs we use. Don’t worry, you are just an API Key away from success in some cases. What API Key? Do I need one? Let’s dive in.
What API Key?
Thankfully, the online documentation is now littered with reminders for API Keys if you are looking. The Map class basemap section has a list titled “Basemaps for use with API keys”. That explains the issue from earlier. Another example, the Getting Started section plays it more direct - it mentions these 3 things to get you started:
- Setup the API
- Get an API key
- Start the tutorial
Not a sneaky switcheroo, another change to technology over time. Although, if you migrated from Google based on the 2018 marketing, I could understand if you are a little pissed. One silver lining is that the 2018 article mentioned 1 million free map transactions per month with a developer subscription. Today, that number has increased to 2 million. You can still be pissed, but take the 2 million map requests.
You can work directly with our location services using open-source mapping libraries like Leaflet, GL JS, OpenLayers, and ArcGIS REST JS. ~Esri ArcGIS Platform (PaaS) blog
This doesn’t mean it will take your beer money - there is still a free tier with a developer API key and… oh wait, it’s the same as Goog… Yes, a free tier for most services and some premium services are also available. And you don’t need an API key for everything (yet). My demo is back and running without a key and it gets the job done - it’s just a demo and will cap out to less than 2 million monthly requests even if I needed a key. Not that I make any beer money from it anyway.
So, you need an API Key for Google, Esri, and many other services. Not a big deal. If you want to avoid API Keys, you do have other options - but remember, API Keys aren’t evil. OpenStreetMap and the popular Leaflet API both have lots of options. And yes, Esri has an extension to Leaflet to integrate with Esri. However, if you want to use premium Esri services (basemaps, routing, etc), you will still require an Esri API Key (I looked it up, it’s in the docs). On the flip side, you can use whatever API you like and still access premium services with the key. Glass half full.
Esri Developer Terms of Service
Since I was digging into things, I also reviewed the current Terms of Service. There are a few items related to developers creating value-added applications (revenue-generating) that might be of interest to a select few.
Value-added applications built with:
What’s the Point?
The point is, web development is always changing, and so are the requirements to access services. Keep an eye on the APIs and services you use and the changes that are happening. Old applications can be impacted without warning, so don’t forget to check the documentation and requirements before you start pulling your application apart. API Keys are just one of many types of changes. Breaking changes can also be introduced with new API versions (ArcGIS 3x to 4x for example). Heck, my Wyze camera stopped its in-camera person detection one day - Why? The company that made that piece of software (Xnor.ai) was acquired by Apple, so Wyze had to change its terms and no more onboard AI software.
In short, RTFM once a year for all the APIs and web services you use just to make sure everything will keep ticking. As well, a big tech company might buy something and screw your recent home camera purchase.
- Esri - Terms of Service e300
- Getting Started with 4x
Cover image: Silas Köhler (Unsplash) April 17, 2021.