Skip to content

switchboard-xyz/sb-on-demand-examples

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Switchboard Logo

Switchboard On-Demand Examples

Example repositories for Switchboard's latest on-demand functionality across multiple blockchain ecosystems.

Quick Links

🌐 Examples by Chain

Solana

The Solana examples demonstrate Switchboard On-Demand functionality on the Solana blockchain:

JavaScript/TypeScript Client Code:

  • 📁 Client Examples - Complete JavaScript/TypeScript examples for integrating Switchboard On-Demand
    • Feed operations, streaming, benchmarks, and utilities
    • Ready-to-run examples for oracle quotes, Surge WebSocket streaming, and more

Resources:

Sui

The Sui examples demonstrate Switchboard On-Demand oracle functionality on the Sui blockchain:

  • 🔮 Oracle Feeds - Pull-based price feeds with fresh oracle data
  • Real-time data fetching from external APIs through oracle networks
  • On-demand feed updates with aggregated results from multiple oracles

JavaScript/TypeScript Client Code:

  • 📁 Feed Examples - Complete TypeScript examples for Sui integration
    • Oracle data fetching, feed reading, transaction simulation
    • No private key required for data reading and simulation

Resources:

EVM

The EVM examples showcase Switchboard functionality on EVM-compatible chains:

Supported Networks:

  • Monad, Core, Arbitrum

Resources:

🌍 Chain-Agnostic Resources

The common/ directory contains tools and examples that work across all blockchain platforms:

  • Variable Overrides - Secure credential management for oracle feeds

    • Use variables for API keys/auth tokens only
    • Maintain feed verifiability with hardcoded data sources
    • Works identically on Solana, EVM, and Sui
  • Job Testing - Test and develop custom oracle job definitions

    • Works identically on Solana, EVM, and Sui
    • Validate API integrations before on-chain deployment
  • Streaming - Real-time unsigned price streaming via WebSocket

    • Chain-agnostic price monitoring for UIs and dashboards
    • Ultra-low latency data feeds

These resources let you design and test oracle functionality once, then deploy on any supported blockchain.

🚀 Getting Started

Each directory contains specific examples with their own setup instructions. Choose your blockchain platform above to explore the relevant examples.

For comprehensive documentation and integration guides, visit our official documentation

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Contributors 7