Skip to Content
DocumentationRadixOracle Architecture

Radix Oracle Architecture

The Morpher Oracle on Radix is designed as a pull-based oracle system that provides secure, verifiable price data for blockchain applications. This page explains the overall architecture and components of the system.

System Components

Key Components

  1. Off-Chain Data Sources

    • Exchange APIs: Direct connections to cryptocurrency exchanges like Gate.io
    • Market Data Providers: Services that aggregate and normalize market data
    • Price Aggregators: Systems that combine multiple price sources for reliability
  2. Oracle Infrastructure

    • Oracle Backend: The core service that:
      • Collects and validates data from multiple sources
      • Processes subscription requests
      • Signs price data with the Oracle’s private key
      • Verifies NFT ownership and public key validity
    • Oracle Database: Stores historical price data and subscription information
  3. DApp Infrastructure

    • DApp Backend: A service operated by the DApp developer that:
      • Securely stores the DApp’s private key
      • Creates and signs requests to the Oracle Backend
      • Forwards signed price data to the Frontend
    • Private Key Storage: Secure storage for the DApp’s private key
    • Frontend/User: The user interface and wallet connection that:
      • Initiates transactions requiring price data
      • Constructs transaction manifests with signed data
      • Submits transactions to the Radix network
  4. On-Chain Components

    • Oracle Component: The smart contract that:
      • Verifies signatures from the Oracle Backend
      • Validates data authenticity
      • Provides verified price data to other smart contracts
    • Smart Contract: The DApp’s on-chain logic that:
      • Calls the Oracle Component to verify signed data
      • Validates data freshness for its specific use case
      • Uses verified price data for its business logic
      • Applies additional validation rules as needed
    • Subscription NFT: A non-fungible token that:
      • Represents a paid subscription to the Oracle service
      • Stores the subscriber’s public key
      • Controls access to Oracle services

Security Model

The Morpher Oracle employs a multi-layered security approach:

  1. Data Signing: All price data is cryptographically signed by the Oracle, ensuring data integrity and authenticity.

  2. Subscription Verification: Access to Oracle services requires ownership of a subscription NFT, preventing unauthorized usage.

  3. On-Chain Verification: Signatures are verified on-chain before data is used in transactions, preventing manipulation.

  4. Timestamp Validation: Price data includes timestamps that are checked on-chain to ensure data freshness.

  5. Market Status Checks: The system validates that price data is consistent with the current market status (open/closed).

This architecture ensures that price data is:

  • Authentic (signed by the Oracle)
  • Fresh (recent timestamps)
  • Authorized (linked to a valid subscription)
  • Verifiable (signature checked on-chain)

In the next section, we’ll explore the Pull Oracle Flow in detail.