proto

package
v0.0.0-...-4392a84 Latest Latest
Warning

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

Go to latest
Published: Aug 17, 2019 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BackupCheckRequest

type BackupCheckRequest struct {
}

BackupCheckRequest --

type BackupCheckResponse

type BackupCheckResponse struct {
}

BackupCheckResponse --

type BackupRestoreRequest

type BackupRestoreRequest struct {
	VCode     string `json:"vcode"`
	Signature string `json:"signature"`
}

BackupRestoreRequest --

type BackupRestoreResponse

type BackupRestoreResponse struct {
	Time            int64  `json:"time"`
	EncryptedPrvKey string `json:"encrypted_prvkey"`
}

BackupStoreResponse --

type BackupStoreRequest

type BackupStoreRequest struct {
	Email            string `json:"email"`
	VCode            string `json:"vcode"`
	DeviceID         string `json:"deviceid"`
	Signature        string `json:"signature"`
	CloudService     string `json:"cloud_service"`
	EncryptedPrvKey  string `json:"encrypted_prvkey"`
	EncryptionPubKey string `json:"encryption_pubkey"`
}

BackupStoreRequest --

type BackupStoreResponse

type BackupStoreResponse struct {
}

BackupStoreResponse --

type BackupVCodeRequest

type BackupVCodeRequest struct {
}

BackupVCodeRequest --

type BackupVCodeResponse

type BackupVCodeResponse struct {
	VCode string `json:"vcode"`
}

BackupVCodeResponse --

type BackupVerifyRequest

type BackupVerifyRequest struct {
	EncryptionPubKeyHash string `json:"encryption_pubkey_hash"`
}

BackupVerifyRequest --

type BackupVerifyResponse

type BackupVerifyResponse struct {
	VerifyPassed    bool  `json:"verify_passed"`
	VerifyTimestamp int64 `json:"verify_timestamp"`
}

BackupVerifyResponse --

type EcdsaR2Request

type EcdsaR2Request struct {
	Pos  uint32            `json:"pos"`
	Hash []byte            `json:"hash"`
	R1   *secp256k1.Scalar `json:"R1"`
}

EcdsaR2Request --

type EcdsaR2Response

type EcdsaR2Response struct {
	R2     *secp256k1.Scalar `json:"R2"`
	ShareR *secp256k1.Scalar `json:"shareR"`
}

EcdsaR2Response --

type EcdsaS2Request

type EcdsaS2Request struct {
	Pos     uint32            `json:"pos"`
	Hash    []byte            `json:"hash"`
	EncPK1  *big.Int          `json:"encpk1"`
	EncPub1 *paillier.PubKey  `json:"encpub1"`
	R1      *secp256k1.Scalar `json:"R1"`
	ShareR  *secp256k1.Scalar `json:"shareR"`
}

EcdsaS2Request --

type EcdsaS2Response

type EcdsaS2Response struct {
	S2 *big.Int `json:"S2"`
}

EcdsaS2Response --

type Request

type Request struct {
	// contains filtered or unexported fields
}

Request --

func NewRequest

func NewRequest() *Request

NewRequest -- creates new request.

func (*Request) Get

func (r *Request) Get(url string) (*Response, error)

Get -- get request.

func (*Request) Post

func (r *Request) Post(url string, body interface{}) (*Response, error)

Post -- post request with body.

func (*Request) SetHeaders

func (r *Request) SetHeaders(k string, v string) *Request

SetHeaders -- used to set the headers pair.

func (*Request) SetTimeout

func (r *Request) SetTimeout(t int) *Request

SetTimeout -- used to set the timeout.

type Response

type Response struct {
	// contains filtered or unexported fields
}

Response --

func (*Response) Body

func (r *Response) Body() string

Body -- used to return body bytes.

func (*Response) Cost

func (r *Response) Cost() string

Cost --

func (*Response) Json

func (r *Response) Json(v interface{}) error

Json -- used to return unmarshal value from body.

func (*Response) StatusCode

func (r *Response) StatusCode() int

StatusCode --

type ServerInfoResponse

type ServerInfoResponse struct {
	ChainNet    string `json:"chainnet"`
	ServerTime  int64  `json:"server_time"`
	EnableVCode bool   `json:"enable_vcode"`
}

ServerInfoResponse --

type TokenRequest

type TokenRequest struct {
	UID      string `json:"uid"`
	VCode    string `json:"vcode"`
	DeviceID string `json:"deviceid"`
}

TokenRequest --

type TokenResponse

type TokenResponse struct {
	Token string `json:"token"`
}

TokenResponse --

type TxPushRequest

type TxPushRequest struct {
	TxHex string `json:"txhex"`
}

TxPushRequest --

type TxPushResponse

type TxPushResponse struct {
	TxID string `json:"txid"`
}

TxPushResponse --

type VCodeRequest

type VCodeRequest struct {
	UID string `json:"uid"`
}

VCodeRequest --

type WalletAddressesRequest

type WalletAddressesRequest struct {
	Offset int `json:"offset"`
	Limit  int `json:"limit"`
}

WalletAddressesRequest --

type WalletAddressesResponse

type WalletAddressesResponse struct {
	Address string `json:"address"`
	Pos     uint32 `json:"pos"`
}

WalletAddressesResponse --

type WalletBalanceRequest

type WalletBalanceRequest struct {
}

WalletBalanceRequest --

type WalletBalanceResponse

type WalletBalanceResponse struct {
	CoinValue uint64 `json:"coin_value"`
}

WalletBalanceResponse --

type WalletCheckRequest

type WalletCheckRequest struct {
}

WalletCheckRequest --

type WalletCheckResponse

type WalletCheckResponse struct {
	WalletExists       bool   `json:"wallet_exists"`
	BackupExists       bool   `json:"backup_exists"`
	ForceRecover       bool   `json:"force_rocover"`
	BackupTimestamp    int64  `json:"backup_timestamp"`
	BackupCloudService string `json:"backup_cloudservice"`
}

WalletCheckResponse --

type WalletCreateRequest

type WalletCreateRequest struct {
	Signature    string `json:"signature"`
	MasterPubKey string `json:"masterpubkey"`
}

WalletCreateRequest --

type WalletCreateResponse

type WalletCreateResponse struct {
}

WalletCreateResponse --

type WalletNewAddressRequest

type WalletNewAddressRequest struct {
	DeviceID string `json:"deviceid"`
	Type     string `json:"type"`
}

WalletNewAddressRequest --

type WalletNewAddressResponse

type WalletNewAddressResponse struct {
	Pos     uint32 `json:"pos"`
	Address string `json:"address"`
}

WalletNewAddressResponse --

type WalletPortfolioRequest

type WalletPortfolioRequest struct {
	Code string `json:"code"`
}

WalletPortfolioRequest --

type WalletPortfolioResponse

type WalletPortfolioResponse struct {
	CoinSymbol   string  `json:"coin_symbol"`
	FiatSymbol   string  `json:"fiat_symbol"`
	CurrentPrice float64 `json:"current_price"`
}

WalletPortfolioResponse --

type WalletSendFeesRequest

type WalletSendFeesRequest struct {
	Priority  string `json:"priority"`
	SendValue uint64 `json:"send_value"`
}

WalletSendFeesRequest --

type WalletSendFeesResponse

type WalletSendFeesResponse struct {
	Fees          uint64 `json:"fees"`
	TotalValue    uint64 `json:"total_value"`
	SendableValue uint64 `json:"sendable_value"`
}

WalletSendFeesResponse --

type WalletTxsRequest

type WalletTxsRequest struct {
	Offset  int    `json:"offset"`
	Limit   int    `json:"limit"`
	OrderBy string `json:"orderby"`
}

WalletTxsRequest --

type WalletTxsResponse

type WalletTxsResponse struct {
	Txid        string `json:"txid"`
	Fee         int64  `json:"fee"`
	Data        string `json:"data"`
	Link        string `json:"link"`
	Value       int64  `json:"value"`
	Confirmed   bool   `json:"confirmed"`
	BlockTime   int64  `json:"block_time"`
	BlockHeight int64  `json:"block_height"`
}

WalletTxsResponse --

type WalletUnspentRequest

type WalletUnspentRequest struct {
	Amount uint64 `json:"amount"`
}

WalletUnspentRequest --

type WalletUnspentResponse

type WalletUnspentResponse struct {
	Pos          uint32 `json:"pos"`
	Txid         string `json:"txid"`
	Vout         uint32 `json:"vout"`
	Value        uint64 `json:"value"`
	Address      string `json:"address"`
	Confirmed    bool   `json:"confirmed"`
	SvrPubKey    string `json:"svrpubkey"`
	Scriptpubkey string `json:"scriptpubkey"`
}

WalletUnspentResponse --

Jump to

Keyboard shortcuts

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