CCC Docs
    Preparing search index...

    Class representing a Bitcoin signer that extends SignerBtc

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    name: string

    The name of the signer.

    icon: string

    The icon URL of the signer.

    addressType: "auto" | "p2wpkh" | "p2tr" = "auto"

    The address type.

    Accessors

    • get supportsSingleCallSignAndBroadcast(): boolean

      Whether the wallet supports a single call to sign + broadcast (combined flow). Default false; override in implementations like Xverse/JoyID.

      Returns boolean

    Methods

    • Disconnects to the signer.

      Returns Promise<void>

      A promise that resolves when the signer is disconnected.

    • Gets the Bitcoin account address.

      Returns Promise<string>

      A promise that resolves to the Bitcoin account address.

    • Gets the Bitcoin public key.

      Returns Promise<`0x${string}`>

      A promise that resolves to the Bitcoin public key.

    • Connects to the provider by requesting authentication.

      Returns Promise<void>

      A promise that resolves when the connection is established.

    • Checks if the signer is connected.

      Returns Promise<boolean>

      A promise that resolves to true if connected, false otherwise.

    • Signs a PSBT using JoyID wallet.

      Parameters

      • psbtHex: string

        The hex string of PSBT to sign

      • Optionaloptions: SignPsbtOptions

      Returns Promise<string>

      A promise that resolves to the signed PSBT hex string

    • Signs and broadcasts a PSBT to the Bitcoin network using JoyID wallet.

      This method combines both signing and broadcasting in a single operation.

      Parameters

      • psbtHex: string

        The hex string of PSBT to sign and broadcast

      • Optional_options: SignPsbtOptions

      Returns Promise<string>

      A promise that resolves to the transaction ID

      Use this method directly for sign+broadcast operations to avoid double popups. While calling signPsbt() then pushPsbt() will still work, it triggers two popups and requires double signing.