@glosfer/bitbox-app-hycon
TypeScript icon, indicating that this package has built-in type declarations

0.0.3 • Public • Published

BitBox API for Hycon

BitBox Hardware Wallet Node JS API for Hycon.

Example

import { hid } = require("@glosfer/bitbox-nodejs")
import { BitBox, IResponseGetXPub } from "@glosfer/bitbox-app-hycon";
import HDKey = require("hdkey")

const getHyconAddress = async () => {
    const hidInfo = hid.getDeviceInfo()
    if (!hidInfo) {
        console.log(`Digital BitBox not plugged in`)
        return
    }
    const bitbox = new BitBox(hidInfo.path)
    const xpub: IResponseGetXPub = await bitbox.getXPub("m/44'/1397'/0'/0/0")
    const hdkey = HDKey.parseExtendedKey(xpub.xpub)
    const result = hdkey.publicKey
    return result;
};
getHyconAddress().then(a => console.log(`Public key: ${a.toString("hex")}`));

Install dependencies

npm install

Build

npm build

Deploy

Checklist before deploying a new release:

  • you have the right in the glosfer org on NPM
  • you have run npm login once (check npm whoami)
  • Go to master branch
    • your master point on glosfer repository (check with git config remote.$(git config branch.master.remote).url and fix it with git branch --set-upstream master origin/master)
    • you are in sync (git pull) and there is no changes in git status
  • Run npm once, there is still no changes in git status

deploy a new release

 npm run clean
 npm install
 npm run lint
 npm run build
 npm publish

then, go to /releases and create a release with change logs.

Issues & Pull Requests

If you have an issue, feel free to add it to the Issues tab. If you'd like to help us out, the Pull Request tab is a great place to start.

If you have found a security bug, please contact us at security@glosfer.com.

Package Sidebar

Install

npm i @glosfer/bitbox-app-hycon

Weekly Downloads

4

Version

0.0.3

License

none

Unpacked Size

22.3 kB

Total Files

10

Last publish

Collaborators

  • joowon
  • arigatodl