Constructors

  • Parameters

    • crossbarUrl: string
    • Optional verbose: boolean

    Returns CrossbarClient

Properties

crossbarUrl: string
verbose: boolean

Methods

  • GET /fetch/:feedHash Fetch data from the crossbar using the provided feedHash

    Parameters

    • feedHash: string

      The hash of the feed to fetch data for

    Returns Promise<any>

    • The data fetched from the crossbar
  • GET /updates/solana/:network/:feedpubkeys Fetch updates for Solana network feeds from the crossbar

    Parameters

    • network: string

      The Solana network to fetch updates for

    • feedpubkeys: string[]

      The public keys of the feeds to fetch updates for

    • Optional numSignatures: number

      The number of signatures to fetch (optional)

    Returns Promise<{
        lookupTables: string[];
        pullIx: TransactionInstruction;
        responses: {
            errors: string;
            oracle: string;
            result: number;
        }[];
        success: boolean;
    }[]>

    • The updates for the specified feeds
  • GET /simulate/:feedHashes Simulate fetching feed results from the crossbar using feed hashes

    Parameters

    • feedHashes: string[]

      The hashes of the feeds to simulate

    Returns Promise<{
        feedHash: string;
        results: number[];
    }[]>

    • The simulated feed results
  • GET /simulate/solana/:network/:feedpubkeys Simulate fetching Solana feed results from the crossbar

    Parameters

    • network: string

      The Solana network to simulate

    • feedpubkeys: string[]

      The public keys of the feeds to simulate

    Returns Promise<{
        feed: string;
        feedHash: string;
        results: number[];
    }[]>

    • The simulated feed results
  • POST /store Store oracle jobs on the crossbar, associated with a queue address

    Parameters

    • queueAddress: string

      The address of the queue

    • jobs: IOracleJob[]

      The oracle jobs to store

    Returns Promise<{
        cid: string;
        feedHash: string;
        queueHex: string;
    }>

    • The stored data information

Generated using TypeDoc