lbrynet

package
v0.6.2 Latest Latest
Warning

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

Go to latest
Published: Jun 25, 2019 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Client = ljsonrpc.NewClient(config.Settings.GetString("Lbrynet"))

Client is a LBRY SDK jsonrpc client instance

Functions

func CreateAccount added in v0.6.1

func CreateAccount(UID int) (*ljsonrpc.AccountCreateResponse, error)

CreateAccount creates a new account with the SDK. Will return an error if account with this UID already exists.

func GetAccount added in v0.6.1

func GetAccount(UID int) (*ljsonrpc.Account, error)

GetAccount finds account in account_list by UID

func MakeAccountName added in v0.6.1

func MakeAccountName(UID int) string

MakeAccountName formats the UID for use with SDK. UID can be an email or an empty string, in which case a random identifier will be generated.

func RemoveAccount added in v0.6.1

func RemoveAccount(UID int) (*ljsonrpc.AccountRemoveResponse, error)

RemoveAccount removes an account from the SDK by uid

func Resolve added in v0.6.2

func Resolve(url string) (*ljsonrpc.Claim, error)

Resolve calls resolve method on the daemon and handles *frequent* SDK response format changes with grace instead of panicking.

Types

type AccountConflict added in v0.6.1

type AccountConflict struct {
	UID int
}

func (AccountConflict) Error added in v0.6.1

func (e AccountConflict) Error() string

type AccountNotFound added in v0.6.1

type AccountNotFound struct {
	UID int
}

func (AccountNotFound) Error added in v0.6.1

func (e AccountNotFound) Error() string

Jump to

Keyboard shortcuts

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