@arkade-os/sdk Documentation - v0.5.0-rc.11
    Preparing search index...

    Interface VHTLCV2ContractParams

    Typed parameters for VHTLC.ScriptV2 contracts.

    The eight mandatory fields are VHTLCContractParams verbatim — the two script versions take the same VHTLC.Options, so a divergent shape here would be a difference with no cause. What V1's handler has no field for is the emulator covenant suite, and that is exactly what the swap corridor's lockup carries, so leaving it out would make this handler unable to round-trip the contract it exists to serve.

    interface VHTLCV2ContractParams {
        asset?: { groupIndex: number; txid: Uint8Array };
        nonInteractiveParameters?: {
            emulatorPubkey: Uint8Array;
            legacy?: "preTimelockedRefund";
            receiverPkScript: Uint8Array;
            senderPkScript: Uint8Array;
        };
        preimageHash: Uint8Array;
        receiver: Uint8Array;
        refundLocktime: bigint;
        sender: Uint8Array;
        server: Uint8Array;
        unilateralClaimDelay: RelativeTimelock;
        unilateralRefundDelay: RelativeTimelock;
        unilateralRefundWithoutReceiverDelay: RelativeTimelock;
    }
    Index

    Properties

    asset?: { groupIndex: number; txid: Uint8Array }

    The Arkade asset the covenant leaves bind, if any.

    Type Declaration

    • groupIndex: number

      The asset group index within that genesis transaction.

    • txid: Uint8Array

      The asset's genesis txid, 32 bytes, canonical order — as the serialized Asset ID carries it.

    VHTLC.Options.asset

    nonInteractiveParameters?: {
        emulatorPubkey: Uint8Array;
        legacy?: "preTimelockedRefund";
        receiverPkScript: Uint8Array;
        senderPkScript: Uint8Array;
    }

    The emulator covenant suite, all or nothing — mirrors VHTLC.Options.nonInteractiveParameters exactly, including the legacy selector: a row funded before the timelocked refund leaf shipped round-trips with legacy: "preTimelockedRefund" and re-derives its eight-leaf shape.

    Type Declaration

    • emulatorPubkey: Uint8Array
    • Optionallegacy?: "preTimelockedRefund"

      VHTLC.Options.nonInteractiveParameters.legacy

    • receiverPkScript: Uint8Array
    • senderPkScript: Uint8Array
    preimageHash: Uint8Array
    receiver: Uint8Array
    refundLocktime: bigint
    sender: Uint8Array
    server: Uint8Array
    unilateralClaimDelay: RelativeTimelock
    unilateralRefundDelay: RelativeTimelock
    unilateralRefundWithoutReceiverDelay: RelativeTimelock