nip06 0.2.0 copy "nip06: ^0.2.0" to clipboard
nip06: ^0.2.0 copied to clipboard

This package contains the basic key derivation from mnemonic seed phrase protocol flow for Nostr as described in the NIP-06.

example/nip06_example.dart

import 'package:nip06/nip06.dart';
import 'package:nip01/nip01.dart' as nip01;

void main() {
  final keyPair = nip01.KeyPair.generate();
  print('Private key: ${keyPair.privateKey}');

  final keyPairFromMnemonic = Nip06KeyPair.fromMnemonic(
    'abandon '
    'abandon '
    'abandon '
    'abandon '
    'abandon '
    'abandon '
    'abandon '
    'abandon '
    'abandon '
    'abandon '
    'abandon '
    'about',
  );
  print('Private key: ${keyPairFromMnemonic.privateKey}');
}
1
likes
160
points
12
downloads

Documentation

API reference

Publisher

verified publisherkumuly.dev

Weekly Downloads

This package contains the basic key derivation from mnemonic seed phrase protocol flow for Nostr as described in the NIP-06.

Repository (GitHub)
View/report issues

License

MIT (license)

Dependencies

bip32, bip39, convert, nip01

More

Packages that depend on nip06