Get the CorDapp Template

When writing a new CorDapp, it is helpful to start from one of the following standard templates:

The CorDapp templates provide the boilerplate for developing a new CorDapp. CorDapps can be written in either Java or Kotlin. Sample code is provided in both languages throughout this tutorial.

Download the template

  1. Open a terminal window in the directory where you want to download the CorDapp template, and run the following command:

    git clone
    git clone
  2. Once you have cloned the repository you wish to use, navigate to the correct subdirectory:

    cd cordapp-template-kotlin
    cd cordapp-template-java
  3. Once you have successfully cloned the CorDapp template, open the cordapp-template-kotlin or cordapp-template-java in IntelliJ IDEA.

    If you are unsure of how to open a CorDapp in IntelliJ, see the documentation on Running a sample CorDapp.

Template structure

For this tutorial, you will only be modifying the following files:

// 1. The state

// 2. The flow
// 1. The state

// 2. The flow

Progress so far

You now have a template that you can build upon to define your IOU CorDapp. Let’s start by defining the IOUState.