DlcDevKit & Beyond

DlcDevKit & Beyond

My final report for my first OpenSats grant with dlcdevkit has a focus on the user space for ddk consumers.

There has been excitement over nostr being a transport protocol for oracles as well as DLC communication. I wanted to showcase how ddk can work with nostr out of the box.

I made significant improvement to the nostr transport in #76 as well created a nostr oracle client with #84. I am excited to showcase how smooth the experience performing DLC contracts over nostr with ddk with very little boilerplate code. Below is a video walking through the experience of using ddk with nostr with the ddk-node that is downloadable from crates.io.

Walkthrough of ddk-node with nostr

User Applications

Most Bitcoin applications are typically interfaced through node solutions such as Umbrel and Start9. I wanted to focus on bringing an app to those marketplaces to drive interest in the products and get active users.

I am excited to announce the open sourcing of Ernest Money. An application stack for using dlcdevkit. Ernest has 3 components that users can use with the goal having them shipped to node-in-a-box market places.

Son of Liberty (SoL) - A Full-Stack Solution for dlcdevkit

SoL frontend

Son of Liberty (SoL)—named with a little revolutionary spirit for fun—is a full-stack application that brings dlcdevkit to life for Bitcoin users, especially those running node-in-a-box solutions like Umbrel or Start9. SoL is the culmination of dlcdevkit’s core features, wrapping contract creation, management, and storage into a practical, user-ready application. It’s designed to abstract away the complexities of Discreet Log Contracts (DLCs) that dlcdevkit handles under the hood, such as contract execution and message handling, while giving users a clear, detailed view of what’s happening. Whether it’s a solo Bitcoin user or a startup, SoL provides a complete solution that can be packaged as a binary and distributed through repositories, making it easy to deploy and scale as needed.

One of SoL’s key strengths is its support for multiple users with customizable policies. Admins can set spending limits, approve counterparties, and control which contracts users can view, ensuring flexibility and security for different use cases. SoL also tracks market data like hashrate and Bitcoin core metrics, displaying them in a clean dashboard alongside price trends, so users can make informed decisions. On top of that, SoL integrates with Nostr to let users view a market of DLC offers, opening up new opportunities for peer-to-peer contract creation. For node-in-a-box users, this is a big step forward—back in the day, solutions like SuredBits were clunky, forcing users to manually pass long hex-encoded strings asynchronously. SoL streamlines the entire process, making DLCs intuitive and accessible.

What makes SoL truly valuable is how it bridges the gap between dlcdevkit’s backend power and real-world usability. It displays contracts, manages an order book, generates reports, and even provides an API for developers to build on top. Users get a rich, transparent view of their wallet balances, contract states, and market activity, all while the heavy lifting of DLC management is handled seamlessly. Since SoL is open-sourced, anyone can expand its features further—whether that’s adding new market data feeds or building custom user policies. This application showcases the full potential of dlcdevkit, proving it’s ready for real-world adoption thanks to OpenSats’ support.

Ernest Oracle - Enabling Bitcoin Chain Data for DLC Contracts

Ernest Oracle is a critical addition to the dlcdevkit stack, built over the past 6 months on top of my existing Kormir project under the OpenSats grant. It serves as an oracle that announces and attests to Bitcoin chain data like hashrates, difficulty adjustments, fee rates, and UTXO size—information that was previously unavailable for creating decentralized markets with DLCs, especially for mining pools. Before Ernest Oracle, there wasn’t a solution that provided this specific data, leaving a gap for developers and users looking to build contracts tied to Bitcoin’s network metrics. Now, with Ernest Oracle, dlcdevkit users can access this data to create more sophisticated and relevant DLC contracts, opening up new possibilities for innovation.

A standout feature of Ernest Oracle is its integration with Nostr, following NIP-88 for event attestation. This allows for broader reach: users don’t need to know a specific API URL to access the oracle’s data; they can simply use the oracle’s public key and listen for announcement and attestation events on Nostr. This makes it easier for clients to integrate with Ernest Oracle, reducing setup complexity and enabling more users to participate in DLC markets. For example, mining pools working on decentralized markets can now use Ernest Oracle’s attested chain data to create contracts that reflect real-time network conditions, such as betting on hashrate changes or difficulty adjustments—use cases that weren’t possible before.

Ernest Oracle ties directly into Son of Liberty’s (SoL) market dashboard, enhancing its functionality for dlcdevkit users. The dashboard in SoL displays the chain data provided by Ernest Oracle, giving users clear insights into Bitcoin’s network metrics. From there, they can create contract announcements and offers based on this data, such as setting up a DLC tied to fee rate fluctuations. For the OpenSats board, Ernest Oracle is exciting because it greatly expands the types of contracts users can create, enabling cooler, Bitcoin-specific use cases that strengthen the DLC ecosystem. This oracle not only fills a critical gap but also demonstrates how OpenSats’ support is driving innovation in decentralized markets.

City Tavern - Proxied DLC Communication

City Tavern is a proxy server designed to streamline DLC communication for dlcdevkit users, tackling a common pain point in user-facing applications: the need for a public-facing IP to handle Lightning transport. With City Tavern, users connect to the proxy server, craft their DLC messages for a specific recipient, and the server forwards the message if the recipient is connected—all without exposing their IP. This makes DLC communication far more accessible, especially for non-technical users who might struggle with networking setup. On top of that, City Tavern allows users to send DLC offers to the server, which broadcasts them to all connected peers, creating a shared market or order book for DLCs that users can tap into.

What sets City Tavern apart is its focus on reliability and ease of use. By using encrypted communication, it avoids the latency and connection issues often seen with alternatives like the Tor network, ensuring messages are delivered quickly and securely. This is a big win for companies looking to ship applications like Son of Liberty (SoL) to a broader audience. With City Tavern handling the networking, businesses can deploy SoL without worrying about the complexities of setting up and maintaining DLC communication for their users. It’s a practical solution that removes a major barrier, letting users focus on creating and managing contracts rather than dealing with networking headaches.

City Tavern represents a key step toward scaling the DLC ecosystem. By simplifying communication and providing a reliable way to share offers, it opens the door for a much larger user base to engage with DLCs—whether they’re individual Bitcoin users or startups building on dlcdevkit. Its design as an open-source component means anyone can run their own City Tavern instance, further growing the network of DLC participants. This proxy server not only enhances the usability of dlcdevkit but also lays the groundwork for wider adoption, showing how OpenSats’ investment is helping build a more accessible and robust DLC infrastructure.

Pull Request: SQLx Support for DLC Storage

As part of the ongoing development of dlcdevkit, I’ve submitted a pull request to add SQLx support, making it simple for users to store DLC data in databases like PostgreSQL and SQLite. This feature enhances flexibility and scalability, allowing developers to choose their preferred database backend for managing contracts and related data. It’s a direct response to requests from companies interested in dlcdevkit, addressing a key need for integrating the toolkit into enterprise-level workflows. This addition showcases how dlcdevkit continues to evolve to meet real-world demands, further validating OpenSats’ investment in this project.

Closing Remarks

With the open-sourcing of the Ernest stack, the release of a demo video showcasing ddk-node integrated with Nostr, and the addition of SQLx support for DLC storage, this project has reached a major milestone thanks to the OpenSats board’s support. I’ve poured an incredible amount of work into dlcdevkit and its components—Son of Liberty, City Tavern, and Ernest Oracle—building a robust, accessible toolkit that empowers Bitcoin users and developers alike. I’m thrilled to be applying for another grant to continue this journey, eager to push the boundaries of decentralized markets and DLC innovation even further. Thank you, OpenSats, for this opportunity to grow and contribute to the Bitcoin ecosystem—I’m proud of what we’ve achieved together.