📄️ What Is a Web Client?
Let’s check the Hexagonal Architecture diagram once more and focus on the Secondary Adapter (External API) (blue box lower right outside the hexagon):
📄️ Define Your Clients in a Contract
Back in Contract-Driven Development, we used an OpenAPI Specification to define the expected behavior of our Spring Boot application when providing endpoints to whoever decides to use our app.
📄️ Generate a Feign Client API from the Contract
1. Import GenerateTask (start of build.gradle)
📄️ Understanding the Generated Feign Client API
The generated Feign client code provides a solid starting point. However, in more complex scenarios you’ll often need additional customization. In particular, pay attention to the following areas:
📄️ Configure the Generated Feign Client API
So far we've used the OpenAPI Generator Gradle Plugin to generate the representation of the external API we want to integrate.