Skip to content

Trading Tokens

Tokens can be traded using Skuchain's marketplace. The marketplace is a centralized platform where organizations can list and trade their cryptographically secured assets with authorized entities.

Listing on the marketplace allows an asset to be presented for trade. By creating a listing, the asset becomes visible to potential buyers who can then engage in making offers, negotiating terms, and ultimately completing the transaction, which leads to the transfer of ownership.

The listing serves as the starting point for bringing the asset onto the marketplace, providing parties with access to the necessary information regarding the asset intended for sale.

The marketplace leverages Skuset smart contract to listing and trade assets, while the centralized marketplace server hosts off-chain data with enforced privacy measures.

Listing on the Marketplace Server

  • Listing Preparation: The listing process on the marketplace server involves drafting listing parameters such as the listing amount, asset guarantee, along with verification details of the associated asset.

  • Private Data Maintenance: Asset proofs and related private data, including the documents with Content Identifier (CID) proofs, are securely stored on the marketplace server.

  • Access Restriction: Access to this data is restricted to authorized parties who are whitelisted to view the listing and its associated proofs. Once the asset is sold or the listing is canceled, the files are removed from the marketplace server.

Create Listing

To create a listing on the marketplace, follow these steps:

  1. Go to the Marketplace:

    • The listing party (e.g., Sam) accesses the marketplace and provides the required listing information.
  2. Set Listing Info and Create Listing:

    • Sam creates a listing for the tokens they wish to sell (e.g., 100 T1 tokens).
    • The following actions are performed automatically by the marketplace system:

Steps Automatically Executed Under Create Listing:

  • Approve Skuset (S1):
    • Approval is given to Skuset S1 containing 100 T1 tokens for the marketplace exchange.
  • Exchange Deposit:
    • Automatically deposits the 100 T1 tokens into the Skuset S1.
  • Set Exchange Info:
    • Exchange information is configured to specify the following:
      • Exchange Ratio: 50 (meaning Sam will receive 50 T2 tokens for each T1 token sold).
      • From Token Type: T2 (the settlement token).
      • To Token Type: T1 (the token Sam is selling).
  • Change Skuset Ownership:
    • The ownership of the Skuset S1 is transferred to the marketplace admin.
    • The marketplace admin will now manage the listing.

Listing Visibility:

  • Whitelisting:
    • Based on whitelisting rules, traders like Tom can view the listing.
  • Listing Verification:
    • Interested traders, such as Tom, can verify the listing details, including attached information or documents.

Non-Interactive Token Exchange:

Once the listing is created and approved, the exchange of tokens is automated without further interaction between the listing party and the trader. This process occurs as follows:

  1. Trader Access and Purchase:

    • The trader (e.g., Tom) views the listing and, if interested, gathers the required settlement tokens (e.g., 250 T2 tokens).
  2. Execute Exchange Withdraw:

    • Tom initiates the token exchange by calling the exchangeWithdraw function on Skuset S1:
      • Params: from: T2, to: T1, value: 250
      • This triggers the withdrawal of 5 T1 tokens from Skuset S1 in exchange for the 250 T2 tokens provided by Tom.
  3. Ownership and Token Transfer:

    • Upon successful exchange, 5 T1 tokens are transferred to Tom’s account.
    • Simultaneously, the listing party (Sam) receives 250 T2 tokens in their account as settlement for the trade.
  4. Listing Completion:

    • The listing is updated to reflect the exchange, and the remaining T1 tokens (if any) remain in the Skuset S1, available for future exchanges based on the listing parameters.

With this non-interactive mechanism, the token exchange is seamlessly processed without the need for direct communication or negotiation between the listing party and the trader.

The entire exchange is governed by the Skuset smart contract, ensuring secure and automated asset transfers.