Oracle response class that wraps raw gateway responses with convenient methods

Constructors

Accessors

Methods

  • Get detailed latency breakdown for this oracle response

    Note: For heartbeat updates (triggered_on_price_change=false), the oracleProcessing metric is not meaningful since heartbeats are generated by the oracle itself rather than processing external price data.

    Returns {
        endToEnd: string | number;
        exchangeToOracleUpdate: string | number;
        isScheduledPriceHeartbeat: boolean;
        oracleUpdateToClient: string | number;
    }

  • Convert to Solana bundle instruction supporting both signature schemes

    • Ed25519 (default): Returns single TransactionInstruction
    • Secp256k1 (backwards compat): Returns [TransactionInstruction, Buffer] tuple

    Parameters

    • instructionIdx: number = 0

      The instruction index (defaults to 0)

    Returns TransactionInstruction | [TransactionInstruction, Buffer<ArrayBufferLike>]

    Transaction instruction or [instruction, bundleData] tuple depending on signature scheme