@arkade-os/sdk Documentation - v0.4.54
    Preparing search index...

    Class BIP21

    Index

    Constructors

    Methods

    Constructors

    Methods

    • Integer-sats amount encoded in a BIP21 URI (amount= is BTC), or undefined when absent or the URI is unparseable. Shared by the payment rails, which accept either a bare address or a BIP21 URI.

      Parameters

      • uri: string

        BIP21 URI (or bare address) to read the amount from

      Returns number | undefined

      The amount in satoshis, or undefined

    • Create a BIP21 URI from the provided parameters.

      Parameters

      Returns string

      Encoded BIP21 URI

    • Parse a BIP21 URI and return its decoded parameters.

      Parameters

      • uri: string

        BIP21 URI to parse

      Returns BIP21ParseResult

      Parsed BIP21 URI data

      Error if the URI does not start with the bitcoin: scheme