@did-btc1/method
    Preparing search index...

    Class Btc1Identifier

    Index

    Constructors

    Methods

    Constructors

    Methods

    • Implements 3.2 did:btc1 Identifier Encoding.

      A did:btc1 DID consists of a did:btc1 prefix, followed by an id-bech32 value, which is a Bech32m encoding of:

      • the specification version;
      • the Bitcoin network identifier; and
      • either:
        • a key-value representing a secp256k1 public key; or
        • a hash-value representing the hash of an initiating external DID document.

      Parameters

      • params: {
            genesisBytes: Uint8Array;
            idType: string;
            network: string | number;
            version: number;
        }

        See CreateIdentifierParams for details.

        • genesisBytes: Uint8Array

          Public key or an intermediate document bytes.

        • idType: string

          Identifier type (key or external).

        • network: string | number

          Bitcoin network name.

        • version: number

          Identifier version.

      Returns string

      The new did:btc1 identifier.