mirror of
https://github.com/aljazceru/ark.git
synced 2025-12-17 20:24:21 +01:00
* migrate descriptors --> tapscripts * fix covenantless * dynamic boarding exit delay * remove duplicates in tree and bitcointree * agnostic signatures validation * revert GetInfo change * renaming VtxoScript var * Agnostic script server (#6) * Hotfix: Prevent ZMQ-based bitcoin wallet to panic (#383) * Hotfix bct embedded wallet w/ ZMQ * Fixes * Rename vtxo is_oor to is_pending (#385) * Rename vtxo is_oor > is_pending * Clean swaggers * Revert changes to client and sdk * descriptor in oneof * support CHECKSIG_ADD in MultisigClosure * use right witness size in OOR tx fee estimation * Revert changes --------- Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com>
43 lines
1.1 KiB
Go
43 lines
1.1 KiB
Go
package wallet
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/ark-network/ark/pkg/client-sdk/explorer"
|
|
)
|
|
|
|
const (
|
|
SingleKeyWallet = "singlekey"
|
|
)
|
|
|
|
type TapscriptsAddress struct {
|
|
Tapscripts []string
|
|
Address string
|
|
}
|
|
|
|
type WalletService interface {
|
|
GetType() string
|
|
Create(
|
|
ctx context.Context, password, seed string,
|
|
) (walletSeed string, err error)
|
|
Lock(ctx context.Context, password string) (err error)
|
|
Unlock(ctx context.Context, password string) (alreadyUnlocked bool, err error)
|
|
IsLocked() bool
|
|
GetAddresses(
|
|
ctx context.Context,
|
|
) (offchainAddresses, boardingAddresses, redemptionAddresses []TapscriptsAddress, err error)
|
|
NewAddress(
|
|
ctx context.Context, change bool,
|
|
) (offchainAddr, onchainAddr *TapscriptsAddress, err error)
|
|
NewAddresses(
|
|
ctx context.Context, change bool, num int,
|
|
) (offchainAddresses, onchainAddresses []TapscriptsAddress, err error)
|
|
SignTransaction(
|
|
ctx context.Context, explorerSvc explorer.Explorer, tx string,
|
|
) (signedTx string, err error)
|
|
SignMessage(
|
|
ctx context.Context, message []byte,
|
|
) (signature string, err error)
|
|
Dump(ctx context.Context) (seed string, err error)
|
|
}
|