Smart Contract Templates: foundations, design landscape and researc...