This documentation will allow you to go through Spring Cloud Contract Workshops by completing a series of tasks that will teach you the basic and more advanced concept behind Consumer Driven Contracts and Spring Cloud Contract as such.


The repository mostly consists of pairs of producer and consumer applications that show different use cases of Spring Cloud Contract. The initial state of the repository is such that all the examples are working and the tests are passing. In order for you to prepare the repository so it has only the basic pieces of code set up execute this Gradle command

$ git clone
$ cd spring-cloud-contract-samples
$ ./gradlew prepareForWorkshops

This command will remove most of the code / contracts / project setup so that you can start with the workshops.

Whenever your lost - don’t worry. It’s enough to check what’s there in the master branch where all of the examples are ready and working.
You’ll also need to have Maven installed. Check out the website on how to download and install Maven

Generating the documentation

To generate the whole documentation it’s enough to call the Gradle task:

$ git clone
$ cd spring-cloud-contract-samples
$ ./gradlew generateDocumentation


Adib Saikali’s introduction to Consumer Driven Contracts



Introduction to Spring Cloud Contract