5. Building Block View

5.1. Landscape

Diagram

5.2. Whitebox

Diagram
Table 5.1 Building blocks
Container Description

Web Application

The web application is the primary interface for users to interact with the prediction market. The application is part of Content+.

Browser Extension

The browser extension brings the prediction market to other web properties. The extension is also part of Content+.

Smart Contracts

The smart contracts represents all contracts deployed to Arbitrum One. They are a combination of contracts deployed from thirdweb and custom contracts.

Application Programming Interface (API)

The API is the interface between the user interfaces and everything else. It is the central hub for business logic, and responsible for coordinating interactions based on user input.

Database

The database stores off-chain data, such as user information and market data.

5.3. Building Blocks Level 2

5.3.1. Web Application

Diagram
Table 5.2 Building blocks
Component Description

Admin

The admin interface is used to create and manage markets. This is only available to DASTAN admin.

Trader

The trader interface is used to make and take orders. This is available to all users of the Content+ platform.

5.3.2. Smart Contracts

Diagram
Table 5.3 Building blocks
Component Description

$POINTS

The ERC-20 token rewarded to users of the Content+ platform. It is used as collateral for the prediction market.

MarketMakerFactory

A factory contract that is used to create new markets / market makers.

MarketMaker

The contract that manages the state of a market. It is responsible for pricing shares that are represented as conditional tokens.

ConditionalTokens

ERC-1155 tokens that represent shares in a market. They are used to trade on the outcome of a market. The conditional tokens contracts holds the collateral token for open positions. Developed by Gnosis.

Table 5.4 Interfaces
Interface Description

thirdweb Engine

thirdweb engine is used by the system to interact with the blockchain. This includes interaction with DASTAN owned contracts as well as third party contracts.

Oracle

The oracle is responsible for resolving markets.