Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Index

Constructors

constructor

  • new Zec(bitgo: BitGo, network?: any): Zec

Properties

Optional altScriptHash

altScriptHash: undefined | number

Optional supportAltScriptDestination

supportAltScriptDestination: undefined | false | true

Accessors

defaultSigHashType

  • get defaultSigHashType(): number

network

type

  • get type(): string

Static coinTokenPatternSeparator

  • get coinTokenPatternSeparator(): string

Static validAddressTypes

  • get validAddressTypes(): UnspentType[]

Methods

allowsAccountConsolidations

  • allowsAccountConsolidations(): boolean

baseUnitsToBigUnits

  • baseUnitsToBigUnits(baseUnits: string | number): string

bigUnitsToBaseUnits

  • bigUnitsToBaseUnits(bigUnits: string | number): string

calculateFeeAmount

  • calculateFeeAmount(params: object, callback?: NodeCallback<number>): Bluebird<number>

calculateRecoveryAddress

  • calculateRecoveryAddress(scriptHashScript: Buffer): any

calculateSignatureHash

  • calculateSignatureHash(transaction: any, inputIndex: number, pubScript: Buffer, amount: number, hashType: number): Buffer

createMultiSigAddress

  • createMultiSigAddress(addressType: string, signatureThreshold: number, keys: Buffer[]): MultiSigAddress

deriveKeyWithSeed

  • deriveKeyWithSeed(__namedParameters: object): object

enterprises

explainTransaction

feeEstimate

formatForOfflineVault

generateAddress

generateKeyPair

  • generateKeyPair(seed: Buffer): object

getAddressInfoFromExplorer

  • getAddressInfoFromExplorer(addressBase58: string): Bluebird<object>

getBaseFactor

  • getBaseFactor(): number

getChain

  • getChain(): string

getCoinLibrary

  • getCoinLibrary(): any

getExtraPrebuildParams

getFamily

  • getFamily(): string

getFullName

  • getFullName(): string

getLatestBlockHeight

getRecoveryFeePerBytes

  • getRecoveryFeePerBytes(): Bluebird<number>

getRecoveryFeeRecommendationApiBaseUrl

  • getRecoveryFeeRecommendationApiBaseUrl(): Bluebird<string>

getRecoveryMarketPrice

  • getRecoveryMarketPrice(): Bluebird<string>

getUnspentInfoFromExplorer

  • getUnspentInfoFromExplorer(addressBase58: string): Bluebird<object[]>

initiateRecovery

isBitGoTaintedUnspent

  • isBitGoTaintedUnspent(unspent: Unspent): boolean

isValidAddress

  • isValidAddress(address: string, forceAltScriptSupport?: boolean): boolean

isValidMofNSetup

  • isValidMofNSetup(__namedParameters: object): boolean

isValidPub

  • isValidPub(pub: string): boolean

keyIdsForSigning

  • keyIdsForSigning(): number[]

keychains

markets

newWalletObject

  • newWalletObject(walletParams: any): Wallet

parseSignatureScript

parseTransaction

pendingApprovals

postProcessPrebuild

preCreateBitGo

prepareTransactionBuilder

presignTransaction

recover

  • Builds a funds recovery transaction without BitGo

    Parameters

    • params: RecoverParams
      • userKey: [encrypted] xprv, or xpub
      • backupKey: [encrypted] xprv, or xpub if the xprv is held by a KRS provider
      • walletPassphrase: necessary if one of the xprvs is encrypted
      • bitgoKey: xpub
      • krsProvider: necessary if backup key is held by KRS
      • recoveryDestination: target address to send recovered funds to
      • scan: the amount of consecutive addresses without unspents to scan through before stopping
      • ignoreAddressTypes: (optional) array of AddressTypes to ignore, these are strings defined in Codes.UnspentTypeTcomb
         for example: ['p2shP2wsh', 'p2wsh'] will prevent code from checking for wrapped-segwit and native-segwit chains on the public block explorers
    • Optional callback: NodeCallback<any>

    Returns Bluebird<any>

recoverFromWrongChain

recoveryBlockchainExplorerUrl

  • recoveryBlockchainExplorerUrl(url: string): string

signMessage

  • signMessage(key: object, message: string | Buffer, callback?: NodeCallback<Buffer>): Bluebird<Buffer>

signRecoveryTransaction

  • signRecoveryTransaction(txb: any, unspents: Output[], addresses: any, cosign: boolean): any
  • Apply signatures to a funds recovery transaction using user + backup key

    Parameters

    • txb: any

      a transaction builder object (with inputs and outputs)

    • unspents: Output[]

      the unspents to use in the transaction

    • addresses: any

      the address and redeem script info for the unspents

    • cosign: boolean

      whether to cosign this transaction with the user's backup key (false if KRS recovery)

    Returns any

    the transaction builder originally passed in as the first argument

signTransaction

supplementGenerateWallet

supportsBlockTarget

  • supportsBlockTarget(): boolean

supportsP2shP2wsh

  • supportsP2shP2wsh(): boolean

supportsP2wsh

  • supportsP2wsh(): boolean

transactionDataAllowed

  • transactionDataAllowed(): boolean

url

  • url(suffix: string): string

valuelessTransferAllowed

  • valuelessTransferAllowed(): boolean

verifyAddress

verifyRecoveryTransaction

verifySignature

  • verifySignature(transaction: any, inputIndex: number, amount: number, verificationSettings?: object): boolean

verifyTransaction

wallets

webhooks

Static createInstance

Static inferAddressType

  • inferAddressType(addressDetails: object): string | null

Generated using TypeDoc