ocean

module
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 15, 2020 License: MIT

README

🌊 ocean

Go package for building Elements/Liquid wallets.

Usage

Install
$ go get github.com/tiero/ocean
Quickstart
import "github.com/tiero/ocean/partial"
// Create an empty PSET
pset := NewPartial()

// Add a segwit input and a unblinded output
pset.AddInput(hash, index , witnessUtxo, nil)
pset.AddOutput(asset, value, script, false) 
// Generate a KeyPair object
privKeyHex := "bfb96a215dfb07d1a193464174b9ea8e91f2a15bba79800dea838add330f6d86"
keyPair, _ := keypair.FromPrivateKey(privKeyHex)
//Sign the input with a private key
pset.SignWithPrivateKey(0, keyPair)

Development

Clone
$ git clone https://github.com/tiero/ocean
Run test
$ go test -race ./...

Directories

Path Synopsis
internal
pkg

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL