Patterns on Designing API Endpoint Operations

Patterns on Designing API Endpoint Operations

Abstract

Domain-driven design (DDD) is often applied when implementing microservices or communicating through APIs in distributed systems. APIs expose a published language that provides a view on entire domain models or subsets of such models. Hence, tactical DDD patterns such as Aggregate, Service, and Entity may not only structure API implementations, but also guide API specification work. In our previous work, we described endpoint-level patterns for this context. In this paper, we present three complementary patterns, namely Aggregated Domain Operation on API Endpoint, Event-Based API Endpoint Operation, and CRUD-Based API Operation. These patterns aim to derive API operations from the operations of Domain Services and Entities as well as Domain Events. We also discuss variants of these patterns, such as their combination with the patterns Command Query Responsibility Segregation (CQRS) and Publish/Subscribe. Our pattern mining work is based on a data set from an empirical study of 32 grey literature sources investigating practitioner views on deriving API designs from DDD models.

Grafik Top
Authors
  • Singjai, Apitchaka
  • Zdun, Uwe
  • Zimmermann, Olaf
  • Stocker, Mirko
  • Pautasso, Cesare
Grafik Top
Projects
Grafik Top
Shortfacts
Category
Paper in Conference Proceedings or in Workshop Proceedings (Paper)
Event Title
28th Conference on Pattern Languages of Programs (PLoP)
Divisions
Software Architecture
Subjects
Systemarchitektur Sonstiges
Software Engineering
Theoretische Informatik
Systemarchitektur Allgemeines
Event Location
Virtual Conference
Event Type
Conference
Event Dates
October 5-7
Date
5 October 2021
Export
Grafik Top