Chapter 3. API First

 

This chapter covers

  • Code consistency
  • Feature equality
  • Increased velocity
  • External/open versus internal
  • Examples of API First development

When you’re setting up an API, the vision for the entire platform is quite important, from determining the business value through structure and design decisions. I’m going to step back for a moment from the practical description of APIs in order to talk about an overarching model that is generally superior to the old model of creating APIs in parallel with the main product.

Previous models for product lines with multiple different interfaces, such as mobile or integration, were created so that each of the integration points available for the different client use cases were built independently. This generally led to unfortunate consequences—APIs that were creating code already written for the main product, APIs that were perennially behind in features and functions, and a great deal of technical debt because each change to the system needed to be pulled into each type of client.

API First does what it says. Instead of product first, the API First model describes a model where the back end interfaces only with the API, and all products—the main front-end website, mobile integrations, and other integrations—interface with the API itself.

3.1. Why choose API First?

3.2. Code consistency

3.3. Functional equality

3.4. Increased productivity

3.5. Internal/external access

3.6. Case studies

3.7. Summary