Building OpenAPI-enabled APIs with Heroku
The Insights API is the core of the solution described in this chapter. It aggregates data from Heroku Postgres and the Salesforce org into one API response, providing data to the browser through web API calls made from the Insights LWC code, as described in the earlier sections. It is also intended to be a public-facing API. In this section, we will look at how this API is implemented and how it is documented. Providing a well-documented API is an essential part of any application, which is why Chapter 11, Providing Integration and Extensibility, is dedicated to the subject.
Having a consistent and shared way to describe APIs and the data they require and expose enables them to be more easily discovered and consumed, not only from multiple programming languages but also declarative tools. The OpenAPI (https://www.openapis.org) industry specification is used in this chapter as a well-recognized standard and one that Salesforce has also...