liveBook · Manning

Backend-for-frontend pattern

As explained in Secure APIs

The backends-for-frontends pattern provides client-specific backend interfaces tailored to the needs of different frontend applications.

The backend-for-frontend pattern exposes client-specific backend interfaces instead of making each frontend understand every underlying service. An API gateway can implement this pattern by encapsulating backend complexity and presenting interfaces tailored to client needs. section 9.1

Without an intermediary, clients must discover and call multiple API endpoints themselves. That increases client responsibility and spreads authentication, authorization, inventory, monitoring, and hardening across separate entry points. section 9.1

E-commerce API boundary

An e-commerce backend may contain APIs deployed across serverless platforms, Kubernetes clusters, and dedicated servers. A gateway can expose a client-oriented interface while hiding those deployment details and underlying API locations. section 9.1

How Secure APIs covers it

How deep it goes
Explains the pattern’s purpose and gateway role, but stops short of implementation code or detailed interface design.
Examples
Uses an e-commerce system spanning serverless, Kubernetes, dedicated servers, REST, GraphQL, gRPC, and asynchronous APIs.
What it assumes
Assumes familiarity with multiple backend APIs and introduces the need for an intermediary in microservices architecture.
What you can do after
Apply it through an API gateway to hide backend complexity and expose client-tailored interfaces.
How it connects
Connects API gateways with microservices architecture, API discovery, protocol translation, authentication, authorization, and monitoring.

Also explained in

Compare how 4 books explain backend-for-frontend pattern →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Secure APIs. The section links point to the parts of the book it draws on.