Dai Card on Connext v2.0

What’s new and how to upgrade your legacy Card

Three weeks ago, we announced that v2.0 of Connext is live and usable on the Ethereum mainnet. Today, we’re upgrading all existing Dai Cards to use v2.0 under the hood.

Quick Review: What’s the Dai Card?

The Dai Card is a a simple in-browser wallet (inspired by the Burner wallet and Spank Card) that we built to showcase the power of channels back in March.

When we went live with the Card, we had no way of predicting just how intensely popular cheap, fast, and stable Ethereum payments could be. Within the first week, the Dai Card was tried by hundreds of unique users and developers in the space, who made close to a thousand payments in Dai.

More importantly, the app sparked widespread interest in building similar instant payment experiences using Connext. For instance, Ujo, dTok, Mosendo, the Connext Burner Wallet plugin, and Metamask Mobile all borrowed from or directly utilized the Dai Card code or UX in the months after initial launch.

What’s new with v2.0?

The user interface for the Dai Card running on v2 looks pretty similar to how it has in the past. Behind the scenes, however, things are much more robust and trust-minimized.

Depositing and Withdrawing

We’re still working on making deposits/withdraws faster, but they should generally be more reliable now. This means no more broken channels as a result of our infrastructure failing to detect the mined transaction or because the chain was just congested.

Also, you can now both deposit and withdraw Dai directly! 🎉

Other changes we made in the last two weeks:

Sending and Receiving Transfers

When we put the original Dai Card live, we didn’t support sending transfers to offline recipients. It turned out that this was much more important than we realized, and we hacked together a custodial mechanism for the hub to hold balances until a user came back online.

By moving the Dai Card onto v2.0, all transfers (even the ones to offline recipients) are fully noncustodial through the new ASYNC_TRANSFER conditional payment type. Because this payment type is now used by default everywhere, transfers should also have more simple and predictable UI prompts.

One new gotcha is that addressing in v2.0 is based off xpubs and not normal Ethereum addresses (available under the request screen). This is a part of the security of the new protocol, and stops users from accidentally sending in-channel funds to random onchain Eth addresses. But it’s also a UX tradeoff. We’re working on finding ways to make this more intuitive in the future.

State Storage and Backups

We mentioned this in our v2.0 mainnet post, but a big difference in this update is that users are now responsible for storing their own state. In a browser environment, like the Dai Card, this introduces a risk of losing funds if you clear your browser storage or lose your device (even if you back up your key).

To mitigate this, we’ve added support for state backups and recovery! As a precautionary failsafe, our hub will always back up your state and let you recover your state in a trusted way. We also added support for more trust-minimized state backup/recovery, even in cases where you just need to move your mnemonic to a new device, using Pisa Watchtowers (currently only on Rinkeby).

Extensibility

The change that we’re most excited about is significantly more extensibility of the codebase. Reacting to user feedback in the legacy Dai Card took weeks because even relatively simple changes to payment behavior required deep changes to the hub and client infrastructure.

Now, entirely new transfer types and features can be added in days or even hours (the above ASYNC_TRANSFER type is a great example of this). Expect to see some of the most requested core channel features to be added pretty quickly such as gas-less deposits via metatxs, transaction history, cancellable link payments, etc.

Our Revised Goals

In addition to demonstrating the power of channels on Ethereum today, our vision for the Card is to:

Have a prod-ready app built on Connext which can be used as a forkable reference implementation for developers. Act as a “default interface” for users who need to interact with their channel in the event that no other interface is readily available. Be a testing and data collection environment for our internal team to quickly experiment with new features in front of live users.

And, of course, be a simple, freely available, Venmo-like interface for users who want to transact instantly, securely, and cheaply in Dai.

How do I migrate to the new Card?

If you already have balance in a v1 Dai Card, and you browse to https://daicard.io, you’ll automatically be greeted with this notification:

Migrating is simple: just wait for it to finish by itself. Doing so will withdraw your remaining balance from your v1 Dai Card and deposit it into the new version that runs on v2.0.

How do I build on, fork, or learn more about the new Card?

Code for the new card is freely available in our indra monorepo. It’s a resource for the community, so if you see something broken either let us know in Discord, create an issue, or submit a PR.

Also, STEAL OUR CODE!