API calls are one of the most commonly overlooked costs in public cloud. An API call will gather data from a cloud-based database, produce the price of a stock or instantly provision hundreds of machine instances. To decide which public cloud-based API is right for an IT organization, compare not only features, but API prices as well.
When you break down how providers charge for APIs calls in cloud it reveals how those costs differ among the top cloud providers. Enterprises should develop strategies to reduce -- or more accurately estimate and better manage -- those costs.
AWS Lambda vs. Azure Functions
API prices for calls are sometimes deceptive. For example, since most of the Lambda API service focuses on writing a few lines of code for the AWS Lambda function, most wrongfully assume that this is where most of the cost exists. But let's say there were 2 million AWS Lambda function invocations, including one per external API request. The first 1 million AWS Lambda function calls are free, but the rest are charged at $0.20 per million, at AWS' current rates.
Microsoft Azure Functions is similar and charges by the total number of requested executions per month. This includes instances in which a binding triggers an execution. The first 1 million executions are free each month and then cost $0.20 per million thereafter. But API prices get a bit more complex. Microsoft also bills functions based on observed resource consumption, which is measured in gigabytes per second (GBps). To calculate this cost, multiply the average memory size in gigabytes by the time it takes to run the function. The first 400,000 GBps are free for each month, after that it costs $0.000016 per GBps.
APIs are systemic to public cloud providers, and many provide 1 million free invocations per month. But if you use 5 million invocations each month, you could end up with a sizable bill. Public cloud providers' API prices are typically reasonable, such as AWS Lambda and Azure Functions. However, if a third-party and pricey software system, such as an enterprise resource planning API, is on the public cloud provider, the costs pass to the enterprise using it.
Track API prices and usage
Some enterprises -- that don't estimate API pricing -- wait for their bill and try to understand what happened. An enterprise that uses the wait-and-see approach could end up with cloud bills that are upwards of $100,000 per month, when they expected a tenth of that cost. Cost governance tools monitor API costs and prevent billing shock. These tools can monitor usage for chargebacks and set limits on API costs based on policies.
Moreover, these tools can ensure enterprises make the most of their API usage with planning and analytics technology. Tools can make recommendations for better cost efficiency, such as a time to buy API calls ahead of demand to capitalize on significantly reduced prices or to use APIs during off-peak hours when the cloud provider offers a discount.
As serverless cloud deployments become more common, API prices will matter to enterprise IT budgets.
Manage APIs in a multicloud environment
Reduce API security risks with change reporting
Add portability to your apps with APIs