ERC875, a new standard for non fungible tokens and cheap atomic swaps

Originally published at: https://alphawallet.com/erc875-a-new-standard-for-non-fungible-tokens-and-cheap-atomic-swaps/

With the recent rise of cryptokitties, the crypto world has been taking by storm, adorable blockchain pets that are immutably stored on chain has created massive enthusiasm that is even enticing the layman to join in and get their hands on a rare breed.

But this new enthusiasm surfaced a downside, the ethereum network was pushed to its limits with congestion and high fees. It seems the blockchain world is not yet ready for adorable pets on-chain.

ERC721 a standard which was recently drafted by Dieter Shirley is the first non fungible token standard on ethereum and is implemented by the cryptokitty team as each kitty must be unique from one another.

While ERC721 has shown itself to be effective as a non fungible token standard, it has come with some drawbacks, namely that it is expensive to transfer (has to be done one by one) and it lacks a cohesive strategy for efficiently trading each kitty.

These features strain the ethereum network, when the only way to transfer tokens is one by one, rather than in lots and you can’t sell a kitty cheaply, this causes congestion and means the user has to pay a lot of gas.

Likewise, if the only way to trade your tokens (or furry kittens) is via a decentralised market place in a smart contract, you are gonna incur massive gas costs to make an offer and order, change order details and settle the trade.

But what if there was a way to transfer non fungible tokens in lots and trade in a decentralised safe manner without all the massive costs?

ERC875 is just that, a new draft standard which allows transferring non fungible tokens in lots and contains methods to settle orders in a cheap yet equally safe and decentralised way.

Key new features:

Transfer by lot:

In ERC875, tokens are stored in arrays and can be transferred in multiples by specifying each token index. This can result in massive gas savings and a lower transaction burden on the network as you can move many tokens in one transaction.

Cheap and safe trading:

The traditional way of doing a decentralised marketplace involves placing an order via a transaction and waiting for someone to accept your bid by making another transaction with ether attached. If individually sold (as is the case in cryptokitties), you have to make a seperate transaction for each token order. To top it all off, you also need to make a transaction with gas to update your prices or alter any detail of your order such as changing which tokens you want to sell or cancelling an existing order etc. While you have the choice of selling via an exchange, this comes with counterparty risk and the short history of crypto is riddled with exchanges collapsing or being unreliable.

In ERC875 you can make an order by cryptographically signing a message containing the price, an expiry date for the deal and the signature itself. This process is done off chain and is only broadcasted at the time of settlement. This means you can update your order without ever paying gas. When a buyer is interested, all she has to do is receive the order and broadcast the transaction with the order details and the appropriate amount of ether to fulfil the deal.

This even means that a seller could buy a token using cash or card, hold no ether whatsoever and then sell it to get back ether.

This is a brief overview of the new draft standard, if you would like to delve deeper or even make a suggestion, you can see the issue raised here in the ethereum github page: https://github.com/ethereum/EIPs/issues/875

Twitter: Alpha_wallet

Draft implementation in java with a sample solidity contract: https://github.com/alpha-wallet/ERC875-Example

What do you think of the potential of this new standard? Leave your comments below