Skip to main content

Melcor

1 Abstract

The Melcor project is an advanced decentralized application (dApp) designed to simplify the process of trading real goods and services for cryptocurrency.

Melcor operates on EVM-compatible blockchain platforms, providing users with a secure, efficient, and convenient way to conduct trade transactions.

To use the application, only a browser with an installed cryptocurrency wallet is required.

Our mission is to make the purchase of goods and services for cryptocurrency as convenient and secure as possible for every user.

2 Introduction

2.1 Context and Issues

In today's world, cryptocurrency holders face numerous challenges when using them to purchase goods and services. Converting cryptocurrency to fiat money is often accompanied by high fees and delays.

Additionally, even when finding a seller willing to accept cryptocurrency, transactions remain risky due to the lack of security and reliability guarantees from partners.

The high volatility of cryptocurrencies and the absence of guarantee mechanisms create significant obstacles to their use in everyday transactions.

2.2 Project Goals and Mission

The goal of the Melcor project is to create a secure and efficient platform for trading real goods and services for cryptocurrency, making this process familiar and accessible to everyone.

Our mission is to provide users with a convenient and secure way to use cryptocurrency in everyday life.

We strive to make the process of buying and selling with cryptocurrency as simple as using fiat money.

3 Technology

3.1 Architecture

The Melcor project is built on a modular architecture, including the following key components:

  • Smart Contracts: These are the foundation of Melcor's functionality and security. They automate the execution of transaction conditions, significantly reducing risks for users. Due to smart contracts, the trading process becomes transparent, reliable, and protected from human error or fraud.
  • The Graph API: Provides quick access to data through event processing, enhancing the platform's speed and efficiency.
  • IPFS: A decentralized system for storing metadata and media files, ensuring reliable and sustainable data storage.
  • P2P Messenger: We use the Waku protocol to ensure secure and confidential communication between platform users.
  • Web Interface: An intuitive interface for user-friendly interaction with the platform, simplifying the usage process and enhancing service accessibility.

3.1.1 Smart Contracts

Melcor utilizes several smart contracts to operate the platform.

The main smart contract is the Melcor core. It contains numerous functions for platform operations, including functions for creating a store/collection/product, content moderation functions, and order placement and control functions.

An Escrow contract is used to control the execution of transactions. It describes functions that allow sellers and buyers to interact safely with each other.

3.1.2 The Graph API

The Graph is a decentralized protocol for indexing and querying data from the blockchain. It allows querying data that is difficult to obtain directly.

The data processing procedure is as follows:

  • Melcor records data to the blockchain via a transaction in the smart contract.
  • The smart contract creates one or more events when processing the transaction.
  • The Graph node constantly scans the blockchain, processing each block in search of data described in the Melcor subgraph.
  • The Graph node parses the events related to the Melcor subgraph recorded in that block and structures them according to the subgraph's data schema using the WASM module. The data is then stored in the Graph Node database tables.
  • Melcor requests data indexed from the blockchain from The Graph node.

3.1.3 InterPlanetary File System

IPFS (InterPlanetary File System) is a protocol and network system designed to create a content-addressable and permanent web.

In Melcor, we use IPFS for storing metadata and images, ensuring high data availability and reliability. It allows us to guarantee the preservation and protection of our platform's data.

3.2 Innovations

Melcor offers the most convenient interaction with the platform. To start trading, you only need a cryptocurrency wallet that supports EVM blockchains.

We also offer multiple protection systems for various types of transactions, including deals involving guarantors and transactions with an initial deposit. A decentralized Waku infrastructure is used for communication between transaction participants.

Additionally, Melcor supports not only our token as a payment method but also other popular tokens.

At its core, Melcor uses decentralized technologies that are immune to censorship and state blockades. Melcor is also designed so that its copies can be launched on any device while maintaining full functionality, requiring only an internet connection.

4 Security

Security is an absolute priority for Melcor.

We implement a wide range of methods and technologies to protect users and their data, including the use of smart contracts, data encryption, and many other advanced security measures.

This ensures that all transactions on the platform are protected from fraud and abuse.

Melcor has two main methods of protecting transaction participants:

4.1 Escrow

Escrow is a mechanism used in Melcor to enhance security and provide buyers with confidence when conducting transactions on the platform. It is a tripartite agreement between the buyer, seller, and guarantor.

In Melcor, this process is implemented based on a special smart contract that ensures the automatic fulfillment of transaction conditions. When the buyer transfers tokens to the contract, they await receipt of their goods. Upon successful receipt, the tokens are transferred to the seller's account. However, if something goes wrong, a third party—the guarantor—intervenes to resolve the issue.

A guarantor is an independent expert who monitors compliance with the terms of the transaction and is ready to intervene in case of problems. They are a trusted figure for both parties and ensure that both sides adhere to the transaction terms. Any user of the platform can become a guarantor.

In case of a dispute, the guarantor makes decisions based on the evidence provided by the parties. This reduces risks for buyers and sellers and increases trust in the platform.

4.1.1 Buyer Places Order

The buyer selects a product and places an order on the Melcor platform, specifying all necessary details and confirming the transaction. This is the first step in the secure escrow system, ensuring that both buyer and seller are protected throughout the transaction. The order status changes to OFFERED.

4.1.2 Seller Accepts or Rejects Order

The seller receives a notification of the new order and accepts or rejects it based on product availability and other factors. This step allows the seller to manage inventory and orders, ensuring timely fulfillment of commitments to buyers.

The seller selects a guarantor and signs the transaction, creating the escrow contract. The order status changes to ACCEPTED. After accepting the order, the seller, buyer, and guarantor gain access to a messenger for communication and discussion of further steps.

4.1.3 Buyer Pays for the Product

The buyer pays for the product using specified tokens, which are deposited into the escrow smart contract. The order status changes to PAID.

4.1.4 Seller Ships the Product

The seller ships the product to the buyer and provides proof of shipment, such as a tracking number. This stage is crucial for ensuring transparency and confidence that the product has indeed been shipped and is on its way to the buyer. The order status changes to SHIPPED.

4.1.5 Buyer Completes the Order

After receiving the product, the buyer confirms its receipt, completes the order, and initiates the transfer of tokens to the seller.

This step completes the order lifecycle, ensuring fair fulfillment of the transaction terms and satisfaction of both parties. The order status changes to COMPLETED. If desired, the buyer can immediately leave a review of the product and rate the seller and guarantor.

4.1.6 Buyer or Seller Opens a Dispute

If any issues arise, the buyer or seller can open a dispute to resolve the issue with the help of the guarantor. This allows for prompt and effective resolution of conflicts, ensuring fairness and protection of the interests of all transaction participants. The order status changes to DISPUTE.

4.1.7 Guarantor Resolves the Dispute

The guarantor reviews the dispute and makes a decision based on the provided evidence, ensuring a fair and impartial resolution of the conflict. This process maintains users' trust in the platform by guaranteeing the protection of their rights and interests. The guarantor receives a percentage of the transaction. The order status changes to COMPLETED.

4.2 Initial Deposit

Instead of choosing a guarantor to resolve disputes, both participants must provide collateral by making a security deposit into the smart contract. This means both parties must deposit digital assets into the smart contract.

This security deposit is automatically fully returned to both parties once they mark the transaction as completed. This assures both parties that their funds will be returned in the event of a successful transaction.

If any dispute or issue arises, both parties must reach a mutual agreement to mark the transaction as completed. Since both parties have their security deposits locked in the escrow smart contract, they are motivated to collaborate and reach a reasonable resolution.

Additionally, this mechanism can be used to manage transaction risks and can be particularly useful in cases where the transaction participants do not know each other personally or have little experience in conducting digital transactions.

If an agreement is not reached, both security deposits will remain locked until a resolution is agreed upon. This provides additional protection for transaction participants and ensures that they are incentivized to resolve any issues that may arise during the transaction process.

4.2.1 Changes in Transaction Mechanism

The transaction process using the initial deposit differs from using escrow in the following aspects:

  • At step 4.1.3, the buyer needs to deposit tokens for the payment of the goods and an additional amount as a security deposit.
  • At step 4.1.4, the seller deposits their security deposit (the buyer's deposit cannot exceed the seller's deposit).
  • At step 4.1.5, the seller and buyer receive their deposits back.
  • Steps 4.1.6 and 4.1.7 are unavailable as dispute resolution is not possible.

4.3 Guarantors

On Melcor, any user can act as a guarantor in transactions between other users. A guarantor is a third party who ensures the safety of the transaction and resolves disputes if they arise.

How to become a guarantor

  1. Any user can register as a guarantor, specifying the percentage of remuneration for participation in the transaction. The maximum percentage of remuneration is 20%.
  2. The fee percentage is only withheld if a dispute arises and is successfully resolved.
  3. Guarantors help to resolve conflicts between the parties to a transaction by acting as an independent party.

5 Payment

Melcor supports payment for services using a variety of approved ERC20 tokens, including partner project tokens. Each token has a payment fee, except for the Melcor platform token (NSD), for which there is no payment fee.

5.1 Payment System Features

  • Users can use both platform tokens and tokens from partner projects to conduct transactions on the platform.
  • For all tokens, except NSD, a commission can be set, which depends on the terms of each partner project.
  • NSD token gives users the privilege of no commission when paying for services on the platform.

6 Communication

To ensure the confidentiality and security of communication between users on our platform, we use the Waku messaging protocol. Waku is a family of robust, censorship-resistant, peer-to-peer communication protocols that provide confidential messaging for Web3 applications.

This allows Melcor to integrate decentralized communication functions without compromising security and privacy.

Melcor creates an Elliptic Curve Integrated Encryption Scheme (ECIES) key pair for your account based on secp256k1. The public key is used to encrypt a special secret password. This password protects your messages and the messages of the guarantor and seller from unauthorized access.

The private key is used to decrypt this secret password and gain access to the messages. Your public key is stored on the blockchain and is publicly accessible, while the private key is additionally encrypted using AES encryption and stored on your device.

7 Referral system

Melcor offers users the opportunity to participate in a referral program. Members of the program can refer new users and receive remuneration for it. Each member has a unique referral link that can be distributed to potential customers.

7.1 How the referral system works

  1. An authorized user receives a referral link.
  2. A new user who authorizes through this link becomes a referral.
  3. The user receives royalties in the form of tokens for the product they sell.

If the user does not have a referrer, the platform acts as a referrer. The tokens collected in this way go into a reserve fund and can be used for various activities or burning.

8 Content Moderation and Filters

8.1 Score

Melcor has a content moderation system based on voting for various entities. Each entity (store, collection, product) has a score, which is initially set to (uint256(0) - 1) / 2.

Every platform user can upvote or downvote any entity. Entities with scores below a certain threshold are not displayed to most users by default, although any user can adjust this threshold for themselves.

8.2 Hiding Inappropriate Content

When creating any entity on the platform, the creator can specify whether the entity is inappropriate. Inappropriate entities are not displayed to users by default. However, any user can disable this filter.

8.3 Country Filtering

Melcor provides filtering by countries of the world. When creating a store, the user can specify which country the store will be available to. Users from other countries will not see the store.

9 Application

9.1 Use Cases

Melcor provides users with the ability to buy and sell a variety of goods and services, such as electronics, clothing, digital goods, and services. All transactions are conducted in accordance with the laws of the specific country and Melcor's terms of use.

For example, a seller can easily list an item for sale, and a buyer can safely and quickly purchase it using cryptocurrency without the need to convert it to fiat.

9.2 Target Users and Market

Target users of Melcor include:

  • Individuals with cryptocurrency who are interested in purchasing goods and services with cryptocurrency.
  • Sellers who wish to offer their goods and services in a market where cryptocurrency is an accepted form of payment.

The Melcor market encompasses a broad range of cryptocurrency users and has the potential to attract anyone interested in a convenient and secure way to trade goods and services using cryptocurrency.