Leilani Ledingham
Product

Covalent's Human-Readable Transactions: A New Era of Standardization and Clarity

TLDR;

  • Covalent has decoded, classified and standardized complex transaction data across multiple blockchains and markets, including 80 DEXs, 25 lending protocols, and 40 NFT markets to date.

  • Covalent's ultimate goal is to provide human-readable transaction data, paving the way for the seamless onboarding of new users, empowering developers, and promoting a multi-chain future.

The Evolution of Blockchain Transactions: From Simple Payments to Complex DeFi Systems

The advent of blockchain technology, pioneered with Bitcoin, initially focused on simple peer-to-peer transfers of value, much like digital cash. These transactions were relatively straightforward, with each transaction essentially involving a sender, a receiver, and a specified amount of cryptocurrency being transferred.

However, with the emergence of Ethereum and its smart contract functionality, the landscape of transactions on the blockchain became exponentially more complex. Unlike Bitcoin, which was designed primarily as a currency, Ethereum was conceived as a platform for decentralized applications (dApps). This opened up a myriad of possibilities for more complex transactions governed by programmable contracts.

Here are a few examples:

  1. Smart Contracts & dApps: Ethereum's programmable smart contracts can encode complex logic, enabling the creation of dApps with advanced features. Transactions involving smart contracts can include function calls and event logs, which can be challenging to decipher without a deep understanding of the contract's code.

  2. DeFi (Decentralized Finance): The DeFi movement on Ethereum has introduced a host of innovative financial products, like decentralized exchanges (DEXs), lending platforms and more. Transactions in DeFi protocols are often multifaceted. For example, a user might deposit collateral, borrow against it, swap borrowed assets on a DEX, then stake the swapped tokens in a yield farm – all in a single transaction.

  3. NFTs (Non-Fungible Tokens): NFTs represent unique digital assets on the blockchain, and they have added another layer of complexity to blockchain transactions. NFT transactions can involve minting, buying, selling, bidding, or transferring unique tokens, often with accompanying metadata about the asset.

  4. DAOs (Decentralized Autonomous Organizations): Transactions in DAOs can involve voting on proposals, staking tokens for governance rights, and collectively managing pooled funds, among other things.

Each of these areas has its own sets of transaction types, events, and data structures. This complexity makes extracting meaningful information from blockchain transactions challenging for users, developers, and analysts. The complexity is further exacerbated with the same protocol with subtle changes across blockchains.

Addressing the Scaling Shortfalls of Blockchain Transactions

Why Transaction Data Doesn’t Scale

  1. Blockchain data is highly decentralized and heterogeneous. Blockchains are open and permissionless, meaning anyone can write anything to a blockchain - essentially a form of free speech. While there are token standards like ERC-20, ERC-721 (NFTs), ERC-1155 (multi-token standard), and others, the implementations of these standards by different protocols or platforms can vary, and it's an open platform which is what makes blockchains attractive. This difference in each protocol’s rules and methods for recording transactions and events leads to inconsistency in the data these contracts produce.

  2. The volume of data is enormous. Blockchains have had scalability challenges, leading to all sorts of solutions being presented, including L2s, sharding, etc. These networks process thousands to millions of transactions daily, each with its own metadata. This means the that there is a colossal and rapidly growing volume of data that isn't necessarily standardized.

The Result

Blockchain data is immutable and transparent, yet not easy to interpret.

While the above points are strengths from a security, scalability and trust perspective, they often mean that transactions are encoded in a way that is not user-friendly. As a developer trying to process and make meaning of this data to build into their app or UX, the lack of standardization and clarity makes it a huge challenge.

Covalent’s Focus: Simplifying Transaction Data

Covalent is uniquely positioned to take on this challenge due to its technical expertise, infrastructure, and a singular focus on tackling blockchain data. The Covalent team has developed specialized methods to extract, transform, and load this data into a format that is easy to understand and use. This includes working out the kinks associated with different contract standards, normalizing across various protocols, and creating endpoints that scale.

Covalent goes beyond providing raw blockchain data. We decode and classify complex transaction events, standardize data across different blockchains and contracts, and enrich the data with additional contextual details, like protocol logos and quotes in fiat currency. The end result is a comprehensive and user-friendly blockchain data service.

How We Solve It

To simplify transactions, we have standardized the following complex events across several markets and blockchains:

DEX events

  • add_liquidity

  • pair_created

  • remove_liquidity

  • swap

Each of these events signifies a particular type of activity within a DEX, and by presenting them in a consistent format, we facilitate a clearer, enhanced understanding of the transaction process.

Here, you can see the before (left) and after (right) of adding additional DEX data to the Get a transaction endpoint response:

Lending events

  • borrow

  • deposit

  • flashloan

  • liquidation

  • repay

  • withdraw

These events represent various actions within lending protocols, and by unifying their representation, we bring greater clarity to the user experience.

NFT sales

We've reverse-engineered the array of transaction types that occur in NFT sales across different markets, simplifying the transaction data to an easy-to-understand format. For example:

"Megan sent $500 to Bob, and Bob sent Megan an image of a monkey.”

To give further context on the value of this event mapping, we can focus on Opensea. Opensea has upgraded its protocol multiple times to create additional flexibility for users, from v1 to v2 and now Seaport. NFT sales on each of these exchange versions have their own standards, which make the on-chain transactions look different. They can change the names of the events, for instance, change the order of the data etc.

Here is an example of an NFT sale on v1 versus an example of an NFT sale on Seaport. On the left, someone sold a single NFT on the v1 exchange for 2.68 ETH, and the transaction contains 3 event logs. On the right, someone sold 5 NFTs in a single transaction for 49 ETH, and the transaction contains 11 event logs.

We’ve standardized all these sales so that the API response is formatted the same across any market, taking the complexity out of it.

Today, our Get a transaction endpoint supports 80 DEXs, 25 Lending protocols, and 40 NFT markets.

Illustrating the Potential of Human-Readable Transactions

The convention for most people, when they complete a transaction in Web3, is to view the details on Etherscan or another block explorer to confirm it executed successfully. This is not a particularly user-friendly experience for a few reasons:

  1. Complexity: blockchain explorers present data in a technical format. These websites provide essential details but can be overwhelming for people unfamiliar with blockchain technology and jargon.

  2. Auditability: For compliance reasons, businesses often need to keep detailed records of all transactions. While block explorers provide the raw data, they don't offer the kind of formatting and organization that would make this information readily auditable.

  3. Multi-chain transactions: With the proliferation of various blockchain networks, users may execute transactions on different chains. Block explorers are usually specific to one blockchain, making it difficult for users to track their activities across multiple networks in a unified way.

  4. No Visual Appeal: While this might seem minor, the lack of visual appeal and user experience design in many block explorers can make them uninviting and challenging to use, particularly for newer users who might be more accustomed to well-designed, intuitive interfaces in other web applications.

These are all pain points addressed by Covalent’s human-readable transaction data. Rather than placing a burden upon users to sift through technical information on external websites, dApps integrate receipt or invoice features that mimic the familiar experience of transacting in Web2. This makes it easy for users to do their own record-keeping, understand the context of each transaction, and serve as an onboarding tool in helping newcomers understand what's happening when they make a transaction on-chain.

Here’s an example of a receipt created with Covalent’s enriched NFT transaction response. In this case, the user can see:

  • The NFT they purchased.

  • How much it cost in ETH and their respective fiat currency.

  • The gas fees they paid.

  • The protocol they bought it on.

Similar features could be added to DeFi protocols to help users manage their LP positions, keep track of their cost basis, and understand complex multi-part transactions.

The Power of Simplicity in Web3

The impact of Covalent's work in simplifying blockchain transactions reaches far and wide, creating a powerful ripple effect in the world of Web3. It paves the way for seamless onboarding of the next wave of users, aligning with industry trends such as account abstraction. By providing clarity in transactions, we enable developers to concentrate on what genuinely matters to their users, thereby fostering innovation and boosting productivity. Most importantly, our efforts bolster our conviction in a multi-chain future. By making transactions across different chains appear seamless, we're not just advocating for a multi-chain future—we're helping users believe in and embrace it.

Join the Future of Web3 Development

Embrace the new era of standardization and clarity in blockchain transactions. Join Covalent in paving the way for a more accessible and user-friendly blockchain future. If you haven’t got a free API key yet, get one here!


About Covalent:

Covalent provides the industry-leading Unified API bringing visibility to billions of Web3 data points. Developers and analysts use Covalent to build exciting multi-chain applications like crypto wallets, NFT galleries, and investor dashboard tools utilizing data from 226 + blockchains. Covalent is trusted by a community of 40,000+ developers and powers data for 5,000+ applications, including 0x, Zerion, Rainbow Wallet, Rotki, Bitski, and many others.