Versions in this module Expand all Collapse all v4 v4.0.0 May 16, 2024 Changes in this version + type Caller interface + Call func(ctx context.Context, method string, res any, args ...any) error + func RawRequestCaller(req RawRequester) Caller + type Client struct + func NewClient(caller Caller, net *chaincfg.Params) *Client + func (c *Client) AccountAddressIndex(ctx context.Context, account string, branch uint32) (int, error) + func (c *Client) AccountSyncAddressIndex(ctx context.Context, account string, branch uint32, index int) error + func (c *Client) AccountUnlocked(ctx context.Context, account string) (*types.AccountUnlockedResult, error) + func (c *Client) AddMultisigAddress(ctx context.Context, requiredSigs int, addresses []stdaddr.Address, ...) (stdaddr.Address, error) + func (c *Client) AddTicket(ctx context.Context, ticket *dcrutil.Tx) error + func (c *Client) CreateMultisig(ctx context.Context, requiredSigs int, addresses []stdaddr.Address) (*types.CreateMultiSigResult, error) + func (c *Client) CreateNewAccount(ctx context.Context, account string) error + func (c *Client) DumpPrivKey(ctx context.Context, address stdaddr.Address) (*dcrutil.WIF, error) + func (c *Client) FundRawTransaction(ctx context.Context, rawhex string, fundAccount string, ...) (*types.FundRawTransactionResult, error) + func (c *Client) GetAccount(ctx context.Context, address stdaddr.Address) (string, error) + func (c *Client) GetAccountAddress(ctx context.Context, account string) (stdaddr.Address, error) + func (c *Client) GetAddressesByAccount(ctx context.Context, account string) ([]stdaddr.Address, error) + func (c *Client) GetBalance(ctx context.Context, account string) (*types.GetBalanceResult, error) + func (c *Client) GetBalanceMinConf(ctx context.Context, account string, minConfirms int) (*types.GetBalanceResult, error) + func (c *Client) GetInfo(ctx context.Context) (*types.InfoWalletResult, error) + func (c *Client) GetMasterPubkey(ctx context.Context, account string) (*hdkeychain.ExtendedKey, error) + func (c *Client) GetNewAddress(ctx context.Context, account string) (stdaddr.Address, error) + func (c *Client) GetNewAddressGapPolicy(ctx context.Context, account string, gapPolicy GapPolicy) (stdaddr.Address, error) + func (c *Client) GetRawChangeAddress(ctx context.Context, account string, net stdaddr.AddressParams) (stdaddr.Address, error) + func (c *Client) GetReceivedByAccount(ctx context.Context, account string) (dcrutil.Amount, error) + func (c *Client) GetReceivedByAccountMinConf(ctx context.Context, account string, minConfirms int) (dcrutil.Amount, error) + func (c *Client) GetReceivedByAddress(ctx context.Context, address stdaddr.Address) (dcrutil.Amount, error) + func (c *Client) GetReceivedByAddressMinConf(ctx context.Context, address stdaddr.Address, minConfirms int) (dcrutil.Amount, error) + func (c *Client) GetStakeInfo(ctx context.Context) (*types.GetStakeInfoResult, error) + func (c *Client) GetTickets(ctx context.Context, includeImmature bool) ([]*chainhash.Hash, error) + func (c *Client) GetTransaction(ctx context.Context, txHash *chainhash.Hash) (*types.GetTransactionResult, error) + func (c *Client) GetUnconfirmedBalance(ctx context.Context, account string) (dcrutil.Amount, error) + func (c *Client) GetVoteChoices(ctx context.Context) (*types.GetVoteChoicesResult, error) + func (c *Client) ImportPrivKey(ctx context.Context, privKeyWIF *dcrutil.WIF) error + func (c *Client) ImportPrivKeyLabel(ctx context.Context, privKeyWIF *dcrutil.WIF, label string) error + func (c *Client) ImportPrivKeyRescan(ctx context.Context, privKeyWIF *dcrutil.WIF, label string, rescan bool) error + func (c *Client) ImportPrivKeyRescanFrom(ctx context.Context, privKeyWIF *dcrutil.WIF, label string, rescan bool, ...) error + func (c *Client) ImportScript(ctx context.Context, script []byte) error + func (c *Client) ImportScriptRescan(ctx context.Context, script []byte, rescan bool) error + func (c *Client) ImportScriptRescanFrom(ctx context.Context, script []byte, rescan bool, scanFrom int) error + func (c *Client) ListAccounts(ctx context.Context) (map[string]dcrutil.Amount, error) + func (c *Client) ListAccountsMinConf(ctx context.Context, minConfirms int) (map[string]dcrutil.Amount, error) + func (c *Client) ListAddressTransactions(ctx context.Context, addresses []stdaddr.Address, account string) ([]types.ListTransactionsResult, error) + func (c *Client) ListLockUnspent(ctx context.Context) ([]*wire.OutPoint, error) + func (c *Client) ListReceivedByAccount(ctx context.Context) ([]types.ListReceivedByAccountResult, error) + func (c *Client) ListReceivedByAccountIncludeEmpty(ctx context.Context, minConfirms int, includeEmpty bool) ([]types.ListReceivedByAccountResult, error) + func (c *Client) ListReceivedByAccountMinConf(ctx context.Context, minConfirms int) ([]types.ListReceivedByAccountResult, error) + func (c *Client) ListReceivedByAddress(ctx context.Context) ([]types.ListReceivedByAddressResult, error) + func (c *Client) ListReceivedByAddressIncludeEmpty(ctx context.Context, minConfirms int, includeEmpty bool) ([]types.ListReceivedByAddressResult, error) + func (c *Client) ListReceivedByAddressMinConf(ctx context.Context, minConfirms int) ([]types.ListReceivedByAddressResult, error) + func (c *Client) ListSinceBlock(ctx context.Context, blockHash *chainhash.Hash) (*types.ListSinceBlockResult, error) + func (c *Client) ListSinceBlockMinConf(ctx context.Context, blockHash *chainhash.Hash, minConfirms int) (*types.ListSinceBlockResult, error) + func (c *Client) ListTransactions(ctx context.Context, account string) ([]types.ListTransactionsResult, error) + func (c *Client) ListTransactionsCount(ctx context.Context, account string, count int) ([]types.ListTransactionsResult, error) + func (c *Client) ListTransactionsCountFrom(ctx context.Context, account string, count, from int) ([]types.ListTransactionsResult, error) + func (c *Client) ListUnspent(ctx context.Context) ([]types.ListUnspentResult, error) + func (c *Client) ListUnspentMin(ctx context.Context, minConf int) ([]types.ListUnspentResult, error) + func (c *Client) ListUnspentMinMax(ctx context.Context, minConf, maxConf int) ([]types.ListUnspentResult, error) + func (c *Client) ListUnspentMinMaxAddresses(ctx context.Context, minConf, maxConf int, addrs []stdaddr.Address) ([]types.ListUnspentResult, error) + func (c *Client) LockAccount(ctx context.Context, account string) error + func (c *Client) LockUnspent(ctx context.Context, unlock bool, ops []*wire.OutPoint) error + func (c *Client) PurchaseTicket(ctx context.Context, fromAccount string, spendLimit dcrutil.Amount, ...) ([]*chainhash.Hash, error) + func (c *Client) RenameAccount(ctx context.Context, oldAccount, newAccount string) error + func (c *Client) RevokeTickets(ctx context.Context) error + func (c *Client) SendFrom(ctx context.Context, fromAccount string, toAddress stdaddr.Address, ...) (*chainhash.Hash, error) + func (c *Client) SendFromMinConf(ctx context.Context, fromAccount string, toAddress stdaddr.Address, ...) (*chainhash.Hash, error) + func (c *Client) SendMany(ctx context.Context, fromAccount string, ...) (*chainhash.Hash, error) + func (c *Client) SendManyMinConf(ctx context.Context, fromAccount string, ...) (*chainhash.Hash, error) + func (c *Client) SendToAddress(ctx context.Context, address stdaddr.Address, amount dcrutil.Amount) (*chainhash.Hash, error) + func (c *Client) SetTxFee(ctx context.Context, fee dcrutil.Amount) error + func (c *Client) SetVoteChoice(ctx context.Context, agendaID, choiceID string) error + func (c *Client) SignMessage(ctx context.Context, address stdaddr.Address, message string) (string, error) + func (c *Client) SignRawSSGenTx(ctx context.Context, tx *wire.MsgTx) (*wire.MsgTx, bool, error) + func (c *Client) SignRawTransaction(ctx context.Context, tx *wire.MsgTx) (*wire.MsgTx, bool, error) + func (c *Client) SignRawTransaction2(ctx context.Context, tx *wire.MsgTx, inputs []types.RawTxInput) (*wire.MsgTx, bool, error) + func (c *Client) SignRawTransaction3(ctx context.Context, tx *wire.MsgTx, inputs []types.RawTxInput, ...) (*wire.MsgTx, bool, error) + func (c *Client) SignRawTransaction4(ctx context.Context, tx *wire.MsgTx, inputs []types.RawTxInput, ...) (*wire.MsgTx, bool, error) + func (c *Client) TicketsForAddress(ctx context.Context, addr stdaddr.Address) (*dcrdtypes.TicketsForAddressResult, error) + func (c *Client) UnlockAccount(ctx context.Context, account, passphrase string) error + func (c *Client) ValidateAddress(ctx context.Context, address stdaddr.Address) (*types.ValidateAddressWalletResult, error) + func (c *Client) VerifyMessage(ctx context.Context, address stdaddr.Address, signature, message string) (bool, error) + func (c *Client) WalletInfo(ctx context.Context) (*types.WalletInfoResult, error) + func (c *Client) WalletLock(ctx context.Context) error + func (c *Client) WalletPassphrase(ctx context.Context, passphrase string, timeoutSecs int64) error + func (c *Client) WalletPassphraseChange(ctx context.Context, old, new string) error + type GapPolicy string + const GapPolicyError + const GapPolicyIgnore + const GapPolicyWrap + type RawRequester interface + RawRequest func(ctx context.Context, method string, params []json.RawMessage) (json.RawMessage, error) + type SigHashType string + const SigHashAll + const SigHashAllAnyoneCanPay + const SigHashNone + const SigHashNoneAnyoneCanPay + const SigHashSingle + const SigHashSingleAnyoneCanPay + func (s SigHashType) String() string + type SignatureErrors []types.SignRawTransactionError + func (e SignatureErrors) Error() string Other modules containing this package decred.org/dcrwallet decred.org/dcrwallet/v2 decred.org/dcrwallet/v3