Class BaseXChainClientAbstract

Interface for an XChain client.

Implements

Constructors

  • Constructor for the BaseXChainClient class. Initializes the client with the provided chain and parameters.

    Parameters

    • chain: string

      The blockchain chain identifier

    • params: XChainClientParams

      The client parameters, including network, fee bounds, and root derivation paths

    Returns BaseXChainClient

    Throws

    Thrown if an invalid mnemonic phrase is provided

Properties

chain: string
feeBounds: FeeBounds
network: Network
phrase: string = ''
rootDerivationPaths: undefined | RootDerivationPaths

Methods

  • Get the full derivation path based on the wallet index.

    Parameters

    • walletIndex: number

      The HD wallet index

    Returns string

    The full derivation path

  • Set or update the mnemonic phrase.

    Parameters

    • phrase: string

      The new mnemonic phrase

    • walletIndex: number = 0

      (Optional) The HD wallet index

    Returns string

    The address derived from the provided phrase

    Throws

    Thrown if an invalid mnemonic phrase is provided

  • Make a GET request to the Thorchain API.

    Parameters

    • endpoint: string

      The API endpoint

    Returns Promise<unknown>

    The response data

Generated using TypeDoc