< Blog

Building Marlowe-powered DApps: TypeScript SDK (beta version) and prototypes

Dominika Kusak

Dominika Kusak

Sr. Product Marketing Manager

· 7 min

Marlowe's mission is to simplify the developer experience of building smart contract-powered applications on Cardano. The Marlowe team is excited to introduce the beta release of Marlowe TypeScript SDK (TS-SDK), DApp prototypes, and DApp components. The TS-SDK and the smart contract templates allow developers to easily integrate Marlowe contracts into their application workflows with familiar frameworks in React and TypeScript. The DApp prototypes and components take this one step further by providing examples of how contracts can be embedded within applications.

Help the Marlowe team iterate the beta version by contributing to the GitHub repo.


Why Marlowe TS-SDK?

While Marlowe Runtime already simplified developers' lives by replacing multiple tools with a REST interface, TS-SDK (beta) takes it a step further by lowering entry barriers for developers into Web3, facilitating quick onboarding, and enabling easy blockchain development. This approach simplifies the integration of Web3 components into traditional applications, mitigating EUTXO complexities, standardizing development processes, and facilitating easy incorporation of Marlowe smart contracts on any webpage.

The TS-SDK (beta) contains the following packages:


Getting started

To start working with the TS-SDK (beta), you need:

  • a URL to a running instance of the Marlowe Runtime (Demeter is the simplest way to set this up)
  • a supported wallet extension (e.g. Lace, Nami, or Eternl) installed in your browser.

Here’s a short demo of how to get started with TS-SDK packages. For detailed technical information, dive deeper into TS-SDK GitHub repo.


Prototypes: DApp examples and components

To illustrate the immense potential of TypeScript SDK and educate about the Marlowe features in a real-world setting, we're thrilled to unveil a series of example DApps and DApp components, that developers can explore on the Cardano testnet.

Along the journey of building the TS-SDK, we realized that our ideas for Marlowe-powered DApps and DApp components could not only be sources of inspiration for DApp builders but also could be customized and integrated into community-built DApps and wallets – so we made them open source. They are open source under the Apache 2.0 license, which enables DApp builders to deploy them themselves, learn about potential design patterns, customize, and expand according to their business needs.

These prototypes are just the beginning of what is possible using TypeScript SDK, and we encourage DApp builders to get inspired and create your own, custom DApps.


First prototype DApp component: Marlowe payouts

The payouts DApp component on testnet illustrates the withdrawal process for role tokens within Marlowe smart contracts. It simplifies users' ability to discover, track, and withdraw funds from contracts that utilize role tokens.


Why is this important?

It showcases how DApp builders can simplify payout redemption from any Marlowe contract, serving as a first use of TS-SDK capabilities. While it may resemble a standalone DApp, it is a component that can be integrated in any end-user flow (e.g. in a wallet or an end-user application).

To summarize, here are some possible ways of using this DApp component:

  • Easy tracking and withdrawal of role tokens. Users can efficiently explore and retrieve role tokens tied to Marlowe smart contracts, whether they are ada handles or domains, or custom tokens. The flexibility in usage allows diverse functionalities for these tokens.
  • Integration within DApps. DApp developers can employ the payouts DApp as a standalone application or integrate its functionality within a broader DApp to enhance its capabilities.
  • Wallet integration. This prototype can seamlessly integrate into wallets, enabling users to view and withdraw available role tokens directly from their wallet interfaces.

Besides the payouts component, you can expect more of DApp examples and components to be released soon, so stay tuned!


Your role in shaping the future

We invite you to test these prototypes and share your feedback and ideas. The above use cases are just the start. We aim to regularly provide the community with examples and components that will continue to simplify the Web3 DApp builders' journey. Learn how to simplify the smart contract and DApp development process with TS-SDK now!

Have a specific feature in mind that you'd love to see in action? Your input matters – share your ideas with us, and we'll gladly explore their potential for implementation.

Delve into the GitHub repository and Marlowe documentation for details, and watch the latest demo showcasing the capabilities of the TS-SDK.

Join us in revolutionizing DApp development on Cardano!

Special thanks to Omer Husain, Fernando Sanchez, and Olga Hryniuk, who contributed to this article!

Join the conversation

Get all the latest news and updates by following us on our social channels. Plus, you can share resources and feedback with your peers and the Marlowe team.