Categories
Blockchain Entrepreneurship Finance Financial Services Other Supply Chain Technology

How to leverage distributed ledger technology in corporate platforms

In the modern-day digital landscape, consortia and corporate platforms face numerous challenges. These include managing complexity, enhancing collaboration, and improving transparency. This article focuses on addressing them using distributed ledger technology (DLT). Power relations, coopetition within consortia, data security, and privacy in decentralized architectures will be the topic of examination.

How to leverage distributed ledger technology in corporate platforms and consortia

Table of contents:

  1. Modern-day application of blockchain
  2. How blockchain can address challenges faced by consortia
  3. Interactions in corporate platforms – a four-phase trajectory
  4. Conditions for a Successful distributed ledger technology Project
  5. Things can go wrong with blockchain
  6. Our distributed ledger technology business case: HLB Global
  7. About this article
  8. About Agnieszka Hołownia-Niedzielska

Modern-day application of blockchain

Distributed Ledger Technology has wide uses. Sectors like settlements and supply chain management continue to leverage it. Logistics use blockchain to track production and delivery processes, prevent food fraud, and verify product origin. It also helps verify transportation conditions, validate expiry dates, and confirm eco-certificates.

How blockchain can address challenges faced by consortia

Operating across companies requires considerations around cost division, compromising needs, and managing relationships without a chain of command. Despite many unknowns that characterize building and organizing consortia, the business case that stakeholders want to work on remains the same. They will be looking for similar benefits. That’s why creating a list of benefits and presenting them to internal stakeholders is important. This shift could have significant implications for all workers. It can lead to increased automation, greater independence from a central unit, and higher accountability. With a more process-oriented approach, organizations can expect better-structured processes, but also better data quality. This could lead to less confusion and more organized cross-company systems.

Ecosystems based on DLT, blockchain, or other decentralized architectures are maturing. More companies now look beyond innovation and publicity. Instead, they focus on tangible business cases. Use cases of these consortia are likely to impact workers not directly involved in software development and tech, such as those in accounting and settlements. By automating repetitive tasks, these technologies allow specialists to focus on expert tasks, reducing mistakes and streamlining processes.

The power within blockchain consortia is distributed differently from that of large centralized platform providers. Blockchain implementation operates independently of the organizational or legal framework. However, its decentralized nature means that each participant owns a full copy of the data, rather than a single central unit that has to be monitored or widely trusted.

Interactions in corporate platforms – a four-phase trajectory

The interaction between various companies involved in such platform projects always has specific characteristics, but it could be streamlined into a four-phase course.

The first phase involves innovators, often CIOs driven by personal interest, who identify a persistent problem. It could be resolved by standardizing the process across companies with blockchain technology.

Later, the initiating company experiencing the issue reaches out to interested parties in other business units. This usually happens after many companies have dealt with the same problem for years.

In the third phase of the process, business owners from one or more companies work together. Occasionally, the tech and legal departments also get involved. Usually, the ones in control of the project consult internally with multiple stakeholders. They then work on a solution acceptable to all businesses.

Finally, the proposed solution is built into a Minimum Viable Product (MVP) or Proof of Concept (PoC) version. It’s then beta-tested, feedback is collected, and the solution gains momentum. Some companies might wish to join only as participants, while the majority prefers to join as nodes to own their copy of data.

Conditions for a Successful distributed ledger technology Project

Maintaining relationships within DLT consortia requires some vital work. Mainly, it’s a key to managing tasks well and organizing things, keeping people on different levels informed. Those managing consortia projects need to consider differences between participants and the number of departments and workers engaged. It’s crucial to understand that processes and roles may differ. As a consequence, the people engaged in the project may change. Depending on the consortium’s participants, the structure of the internal process can also vary.  

Also, although blockchain communication is secure, establishing connections between nodes built in different organizations requires careful consideration of IT policies. Some of them may need adjustments. The team may modify the project’s technical side according to needs. In an ideal scenario, all participants have their node, transforming IT solution consumers into “vendors”.

Gathering feedback regularly is also a success factor. Feedback from early adopters – a group of pilot companies – plays a vital role, especially during usability tests. What’s important to note is that this work isn’t done when the first version of the solution is in operation. Collecting lessons learned after the MVP phase is a method to implement agile adjustments successfully. 

Interested in validating your blockchain project idea? Check out our article:
6 Easy Steps to Verify a Blockchain Project

Things can go wrong with blockchain

However, not all blockchain projects succeed. Some fail because they don’t grow big enough, so they don’t get their momentum. Some people treat consortia projects as internal, resulting in a lack of external communication and adaptability. This creates a restrictive ‘our way is the only way’ mentality. Moreover, implementing change always presents a challenge.

Despite some disappointments, distributed ledger technology consortia and structures keep offering benefits. This could be savings, or utility (paying more but gaining a single, independent source of truth). Developers build these structures in an agile manner, adding new participants and features, and planning for the next steps in the decentralization process. The key is to ensure that end-users actively use these projects; they don’t remain just as ideas hidden in a drawer.

Our distributed ledger technology business case: HLB Global

It’s time to analyze a real-world application, a case study of HLB Global. HLB is a global network of independent advisory and accounting firms. They have independent branches across 157 countries with more than 38 000 professionals, combining local expertise and global capabilities.

Espeo Software created a decentralized system to let members interact with each other more easily. HLB wanted to standardize and clarify its referral processes. They wanted everyone to play by the same rules enforced by the system. With the ability to add new referrals in place via the existing SharePoint interface, it’s now easier for everyone to manage their tasks. To track deal statuses, data is gathered from various sources like project orders, invoices, and payments. We had to build trust into the solution.

We used Hyperledger Fabric, a private blockchain network, as the solution. Users within this network operate in a transparent and secure environment. The system tracks and permanently records every action, ensuring it’s tamper-proof. The permissioned nature of HLF allows only authorized participants to gain access, maintaining the integrity and confidentiality of the blockchain network.

The HLF blockchain network now stores the data. It serves as the one source of truth with immutable data history. We also automated status changes that follow the execution of chain code tasks.

About this article

Espeo Software’s Solutions Consultant, Agnieszka Hołownia-Niedzielska, was invited by Prof. Dr. Ulrich Klüh to share her expertise on a Coopetition in Corporate Platforms project. The Darmstadt Business School conducts the research project, with funding from the Hans Böckler Foundation.

About Agnieszka Hołownia-Niedzielska:

Agnieszka Hołownia-Niedzielska is a Senior Solutions Consultant at Espeo Software. She has over a decade of experience in FinTech and RegTech product development and project management. Having been a business owner herself, she brings unique insights into business and technical analysis across various project sizes. She acquired Blockchain for Business Professional certification.

Categories
Blockchain Financial Services Newsroom Supply Chain

Darmstadt Business School Interviews Espeo DLT Expert

Consortia and corporate platforms face numerous challenges, including managing complexity, enhancing collaboration, and improving transparency. Espeo Software is pleased to announce that its Solutions Consultant, Agnieszka Hołownia-Niedzielska, to contribute her expertise in a research project on Coopetition in Corporate Platforms. The Darmstadt Business School, under the leadership of Prof. Dr. Ulrich Klüh, conducts the study and he also handles the interview. The project, funded by the Hans Böckler Foundation, explores the challenges and solutions of consortia and corporate platforms.

Hołownia-Niedzielska’s interview focuses on how Distributed Ledger Technology (DLT) can help address the challenges consortia and corporate platforms face. She analyzes various aspects and implications of decentralized architectures.

“It’s crucial to emphasize that DLT continues to mature and is no longer merely an innovation. Companies are starting to realize the tangible business benefits it provides,” says Hołownia-Niedzielska. 

According to Hołownia-Niedzielska, success in DLT projects starts with problem identification. This is followed by the second phase, where the needs of interested parties are gathered. The third phase involves collaborative work across companies to create solutions. Lastly, a Minimum Viable Product (MVP) or a Proof of Concept (PoC) is developed. An article with the entire interview is now available as a blog post on our website. 

Be the first to read the article – now on our blog:
How to leverage distributed ledger technology in corporate platforms

Espeo Software demonstrates the tangible benefits of DLT through its successful case study with HLB Global, a network of advisory and accounting firms spanning 157 countries. We developed a decentralized system using the Hyperledger Fabric private blockchain network to enhance transparency in HLB’s referral processes. This solution allows all members to interact seamlessly, with built-in trust and accurate tracking for every action, making the network tamper-proof.

We thank Prof. Dr Ulrich Klüh and Darmstadt Business School for recognizing our expertise in the field of DLT. This technology can become essential to how consortia and corporate platforms operate. DLT can lead to streamlined processes and better data quality by offering security and accountability. 

About Agnieszka Hołownia-Niedzielska:

Agnieszka Hołownia-Niedzielska is a Senior Solutions Consultant at Espeo Software. She has over a decade of experience in FinTech and RegTech product development and project management. Having been a business owner herself, she brings unique insights into business and technical analysis across various project sizes. She acquired Blockchain for Business Professional certification.

About Espeo Software:

Espeo Software has been helping companies develop and implement innovative fintech solutions since 2008. By leveraging our expertise in blockchain, online payments, and other related areas, our clients can invent and create cutting-edge solutions and services that help them stay at the forefront of innovation. 

Categories
Blockchain Financial Services Software

How to build and deploy NFT Marketplace – a step-by-step guide

An NFT marketplace is an online platform based on blockchain that allows for selling and buying non-fungible tokens (NFT-s). This article will show you how to build and deploy the NFT marketplace from scratch on Polygon. Matic Polygon enables the building of the same applications, consistent with the same standards as Ethereum standards, with the added benefits of lower gas costs and faster transaction speed, among other things.

In the following chapters, we will show you how to build a full-stack application using technologies such as React.js as a front-end framework, Hardhat as a Solidity development environment, IPFS for File Storage, and Web3-React for Polygon Web Client. We have described them briefly below.

Polygon – Polygon is a decentralized Ethereum scaling platform designated to be used for building scalable, user-friendly dApps with low transaction fees. It is compliant with multiple Ethereum security and token standards. The platform offers ready-to-use tools to scale, secure, or build networks.

Metamask – MetaMask is a mature, popular and reliable software cryptocurrency wallet that interacts with the Ethereum blockchain. It allows users to manage their crypto assets through a browser extension or mobile app, which can then be used to interact with decentralized applications. The wallet enables adding multiple EVM network tokens.

React – JavaScript library for rapid development of reactive frontend applications. Mature solution with a growing list of frameworks to build web apps.

Hardhat – Ethereum development environment for creating, testing, and debugging code in Solidity. Flexible and popular in multiple mature project solutions for developers.

IPFS – It is a protocol and peer-to-peer network for distributed storing and sharing files. One of the main IPFS features is content-addressing to uniquely identify each file in a global namespace that connects all devices in the network.

Marketplace smart contract 

The central part of the application is the marketplace smart contract “NFTMarketplace” with data storage, core functions, and query functions.

Core functions:

function createMarketItem(address nftContract,uint256 tokenId,uint256 price) payable
function deleteMarketItem(uint256 itemId) public
function createMarketSale(address nftContract,uint256 id) public payable

Query functions:

function fetchActiveItems() public view returns (MarketItem[] memory)
function fetchMyPurchasedItems() public view returns (MarketItem[] memory)
function fetchMyCreatedItems() public view returns (MarketItem[] memory) 

A seller can use the smart contract to:

  • approve an NFT to market contract
  • create a market item with a listing fee
  • waiting for a buyer to buy the NFT
  • receive the price value

When a buyer buys an NFT in the marketplace, the market contract processes the purchase process:

  • buyer buys by paying the price value
  • market contract completes the purchase process:
    • transfer the price value to the seller
    • transfer the NFT from seller to buyer
    • transfer the listing fee to the market owner
    • change market item state from Created to Release

NFT marketplace smart contract coding

Let’s elaborate on each step with code samples.

Storing data in IPFS 

But first of all, let’s create our NFT and store its data on IPFS. IPFS is a peer-to-peer hypermedia protocol designed to preserve and grow humanity’s knowledge by making the web upgradeable, resilient, and more open.

To upload our file to IPFS, let’s use two functions for the front-end side.

The first is uploading an image to the store, and the second uploads metadata with a newly created link to this image.

UploadToIPFS function returns url which then we set into NFT ERC721 smart contract.

Minting NFT

We have to create an NFT ERC721 smart contract inheriting OpenZeppelin’s ERC721 implementation. We add such functionality here:

  • auto-increment token id 
  • safeMint(to, tokenId) everyone can mint
  • _setTokenURI(tokenId, uri) to set up IPFS URI for our NFT metadata object

We also add a deploy script scripts/deploy.ts to deploy the smartcontract with name: NFToken and symbol: ERC721

As well as automatically verify the contract script:

As a result, we have just created NFT ERC721 smart contract, deployed it, verified and we can use it to mint multiple NFTs with metadata stored on IPFS.

As blockchain functions, require a time- and resource-consuming mining process of verifying and validating blockchain transactions some time should be gone before we can use our NFT. ERC721 token under the hood emits events we can subscribe for. Let’s subscribe to the Transfer event on our application’s front-end part to get know exactly when/if the transfer or creation of NFT is completed:

And approve this NFT right here to use it by NFTMarketplace smart contract:

NFT marketplace smart contract’s structure

We define a structure for MarketItem:

Every market item can be one of three states:

All items are stored in a mapping:

The market has an owner which is the contract deployer. The listing fee will be going to the market owner when an NFT item is sold in the market.

The first thing to do is to list market items for sale by calling createMarketItem function providing a fixed price for it:

Create MarketItem function also checks whether the price is greater than zero and NFT is approved by the owner of the market. In the end, it emits a creation event to the front-end where we could catch this event for different purposes.

The responsible function for buying is createMarketSale which apart from selling logic checks whether buying price is equal selling price and emits a selling event to the front-end.

An important part of the application is setting up a market owner fee as well as transferring marketplace ownership:

Web3 app setup

Set up web app project using Web3-React & Chakra UI

  • React
  • Next.js
  • Chakra UI
  • Web3-React
  • ethers.js
  • SWR

Crypto wallet configuration

Prepare your MetaMask

Make sure your MetaMask has the RPC URL https://rpc-mumbai.matic.today/ and chain id 80001 for Mumbai Polygon testnet.

In webapp/ folder, run the command from the terminal:

We will use the web3 connecting framework Web3-React to get our job done. The web app stack is:

On the browser, go to page: http://localhost:3000/ where our webpage is running in the local environment and try its functionality.

Summary – Marketplace ready to operate

As a result, we have created a starting point for a customizable alternative to ready-to-use solutions like OpenSea. Notice that we have created not only smartcontract predestined for buying and selling that is crucial for the marketplace. We also made NFTs, so if a collection of NFTs is all you need, use only the smartcontract to mint and get those NFT-s into your wallet.

If there was anything that surprised you as the reader in the process we have described, please feel free to get in touch with us.

This article was written by Blockchain Developer Roman Foltyn. Click HERE for a source code

Categories
Blockchain Financial Services

Bridges between blockchains: connecting the DeFi space

The blockchain space has been fortunate with a creativity burst that resulted in impressive product abundance. Yet, an uneven distribution of liquidity together with a rapid rise of DeFi created an urgent need for interoperability between blockchains.

Bridges are a set of smart contracts that promise to enable information exchange between protocols at lower fees than more traditional means. In the present blog post, we propose a mental framework that could ease the work on such a demanding project for managers, developers, and product managers.

Introduction to the DeFi space

The recent explosion in the blockchain space could be intimidating. At the time of writing the present blog post, there are around 140 blockchains that are the backbone for approximately 19,577 cryptocurrencies. Their overall market capitalization is estimated at 1.27 trillion dollars USD. Within it, NFT collections like Bored Ape Yacht Club or CryptoPunks have an estimated market cap of 1,097,268.38 ETH and 417,239.67 ETH, respectively. This abundance comes with a very particular set of pros and cons.

Namely, on the one hand, this fragmentation is excellent. It gives freedom to the blockchain creators, so they can investigate different design options in search of more effective consensus methods, faster transaction rates, or more versatile smart contracts languages. As a result, users have a plethora of options to choose from, so they can find a protocol that suits them best. This opens a door for fierce competition between blockchains and pushes their evolution even faster. During this process, new stars are born, and their early adopters are handsomely rewarded.

On the other hand, this fragmentation is terrible. Tokens from blockchains are locked within a confined space, resulting in data isolation. In addition, despite having potential, many protocols are struggling to attract liquidity as movement between protocols is costly. Finally, smart contracts from distinct blockchains cannot exchange information, which limits their use cases.

Motivations to building bridges between blockchains

We should add two peculiarities to the mentioned market characteristics that recently started to play an important role. First, most of the market liquidity is divided only among two contenders, i.e., Bitcoin and Ethereum. Secondly, the rapid rise of decentralized finance (DeFi) pushes protocol creators to attract liquidity quickly. Yet, how to get liquidity if it is locked among competitors? Currently, the answer for many clients is to use a bridge.

In essence, the bridge is a set of smart contracts that lock tokens on root blockchains and mint a wrapped equivalent of them on a target one. Such a project is interesting for a developer because of a distinct set of inherent challenges. Namely, because a bridge links blockchains that usually use different programming languages, a developer needs to be fluent in them. Moreover, a developer needs to understand protocols to a great degree, as most of the work will be spent on consolidating their discrepancies.

Let’s be clear. The work will be demanding as even running a test version of the product will be a dev-ops project of its own. Finally, you need to have a substantial budget for the project. As building and auditing, the code is expensive. Nevertheless, this is the current frontier in computer science, and there is a joy in being the explorer of it.

Design phase

As the market research progresses and the management decides to start the project, it is essential, in our opinion, to explore the following topics that will help to shape the product:

User personas

This section covers the most fundamental problem that a bridge must resolve, i.e, a bridge needs to be a response to the client’s needs. These in turn will vary based on numerous factors like:

user experience: how will we explain how our bridge works? If an inexperienced user makes an error will we have a way to recover the funds?

products that the user is using: are we dealing with a sophisticated DeFi trader that is interested in high volume and frequent bridging or crypto enthusiasts that just occasionally is exchanging tokens

tokens that the user is holding in the wallet: if our bridge is linking blockchains with small liquidity it is possible that a user will not have its native currency;

trust level: during exploring the different personas that are going to interact with the product it is worth noting that each of them could have a different trust level, e.g, an advanced user with coding experience would prefer a fully decentralized solution, whereas a user that just explores the space would prefer a system with a way to recover the funds, i.e., less decentralized.

Technology

The crucial decision to be made is to choose the proper level of bridge decentralization. Do we want to have an administrative user? How much power should this user have? Should it have the authority to recover some funds, change the contracts, or freeze assets? If we want to have an administrator with all mentioned features, should we create an administrative panel for its role?
Next, the developer team needs to choose tools to create a solution to the described user needs and decided level of decentralization. During the research, it is worth answering the following questions:

    Is the tool open source and has a permissive license? Is the project active and backed by some organization? How many people are using it? Are developers familiar with the programming language of the tool? Was the tool audited for security? How easy will it be to implement proper tests with it?

Fees

This could be one of the most tricky features to implement. On the one hand, your client wants to use the bridge to lower the costs that are imposed by more traditional exchanges. On the other hand, your product needs to create revenue. Balancing these conflicting requirements requires careful calculations.
A minor issue that the team needs to resolve is in what currency the fees are going to be taken.

Monitoring

Finding quickly if there is a problem with bridge assets could be critical to the project’s success in the long term. Thus, it is important to have in mind a logging/monitoring function for each feature of the bridge.

Discrepancies between blockchains

The effective philosophy of unifying differences between blockchains is the key to the bridge’s success. It needs to resolve issues like:

  • Different number of decimals in tokens
  • Managing distinct data types
  • Separate ways of creating tokens

Scenarios

During the design phase, it is also worth spending some time exploring different scenarios that could happen, mostly including the edge ones, by creating spreadsheet simulations. Your team needs to be able to answer questions like:

  • What is the plan if the bridge is hacked like the Wormhole bridge?
  • How to omit a situation in which the bridge will not be able to back all the users claims, a case that allegedly happened to EVODeFi Bridge?

Implementation

For product managers (PM) the implementation phase could be particularly demanding. Projects using blockchain as its backbone are not easily adhering the mainstream Agile values, e.g.:

    How to make frequent releases and respond to change if smart contracts code is immutable? How to adhere to the principle of working software over documentation if auditors and more advanced users want a detailed code description?

These are just a few problems that a PM will face while working on a project. As a result, similarly to the developers, the bridge will open a new perspective and challenges for PM.
In our opinion, given that smart contracts are currently facing a lot of technological constraints and orchestrating interactions between them on distinct blockchains is time-consuming, the cost of change is substantial. Thus, the design and planning phase is more important than in typical IT projects.

Testing

While creating a financial product, testing is the most crucial part of the development process. There is no room for error, as even a tiny bug could result in significant damages that could hamper the bridge’s reputation. Thus, testing should be an iterative process split into separate phases. We propose the following ones:

    Unit tests of functions inside smart contracts End-to-end tests of the whole bridge process Tests on the chosen test network Code audit by a separate institution Tests on mainnet

Conclusion

DeFi expansion with its need for liquidity together with the smart contract dominance created a significant need among users for bridges that connect previously isolated blockchain. Projects like that are demanding as they force managers, developers, and project managers to quit their comfort zones and quickly adapt to a mostly unknown environment. Yet, in the present post, we presented a mental framework that could help reduce the cognitive burden.

Disclaimer

All data is based on: coinmarketcap.com . Data related to cryptocurrencies is subjected to rapid changes and could change substantially when the reader is checking it.
The present blog post is for informational purposes only and is neither legal nor financial advice/statement. Cryptocurrencies are high-risk investments with the potential to lose all invested capital. Thus, before you invest, consult proper authorities and perform due diligence.