The need for standardization when expressing API functionality through either REST or XML endpoints in a platform-, transport-, and programming-language-agnostic way emerged as the OpenAPI Specification in 2015, with major organizations such as Apple, IBM, and Google contributing, lead by a company known as SmartBear. The formal website for this specification is https://www.openapis.org/. The specification states that APIs should be described via a file that contains either YAML (Yet Another Markup Language) or JSON that humans and tools can use to streamline the discovery and consumption of APIs.
At first, this standard was known as the Swagger Specification, though it was later renamed the OpenAPI Specification, or OAS. However, many still refer to the standard as Swagger. The Swagger website (https://swagger.io/) now focuses on tooling around the OpenAPI Specification, which includes ways to author an API specification and generate client- and server-side stubs to help developers consume the resulting API more easily. There is even support for generating Apex client stubs to call APIs described via OpenAPI specifications.
Salesforce has started to adopt this standard through its MuleSoft platform and also through Lightning Platform features such as Lightning External Services, which we will discuss in Chapter 14, Integrating with External Services, in more detail, along with a sample Swagger file.