rpc_interface

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2019 License: LGPL-3.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildContractExtraData

func BuildContractExtraData(op string, contractAdr common.Address, params string) []byte

Types

type BlockResp

type BlockResp struct {
	Header model.Header `json:"header"`
	Body   model.Body   `json:"body"`
}

swagger:response BlockResp

type CurBalanceResp

type CurBalanceResp struct {
	Balance *hexutil.Big `json:"balance"`
}

swagger:response CurBalanceResp

type CurStakeResp

type CurStakeResp struct {
	Stake *hexutil.Big `json:"balance"`
}

TODO please confirm with chuang, may use CurrBalanceResp swagger:response CurStakeResp

type DipperinDebugApi

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

func MakeDipperinDebugApi

func MakeDipperinDebugApi(service debugAPI) *DipperinDebugApi

func (*DipperinDebugApi) Metrics

func (api *DipperinDebugApi) Metrics(raw bool) (map[string]interface{}, error)

func (*DipperinDebugApi) PrintGos

func (api *DipperinDebugApi) PrintGos()

type DipperinMercuryApi

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

func MakeDipperinMercuryApi

func MakeDipperinMercuryApi(service *service.MercuryFullChainService) *DipperinMercuryApi

func (*DipperinMercuryApi) AddAccount

func (api *DipperinMercuryApi) AddAccount(derivationPath string, walletIdentifier accounts.WalletIdentifier) (accounts.Account, error)

wallet add account swagger:operation POST /url/AddAccount WalletOperation Wallet --- summary: wallet add account description: add account parameters:

  • name: walletIdentifier in: body description: wallet identifier type: accounts.WalletIdentifier required: true
  • name: derivationPath in: body description: the derived path type: string required: true

produces: - application/json responses:

"200":
     description: return the added account and the operation result

func (*DipperinMercuryApi) CheckBootNode

func (api *DipperinMercuryApi) CheckBootNode() ([]string, error)

func (*DipperinMercuryApi) CloseWallet

func (api *DipperinMercuryApi) CloseWallet(walletIdentifier accounts.WalletIdentifier) error

close wallet swagger:operation POST /url/CloseWallet WalletOperation Wallet --- summary: close wallet description: close wallet parameters:

  • name: walletIdentifier in: body description: wallet identifier type: accounts.WalletIdentifier required: true

produces: - application/json responses:

"200":
     description: return operation result

func (*DipperinMercuryApi) CreateERC20

func (api *DipperinMercuryApi) CreateERC20(from common.Address, tokenName, tokenSymbol string, amount *big.Int, decimal int, fee *big.Int) (ERC20Resp, error)

func (*DipperinMercuryApi) CurrentBalance

func (api *DipperinMercuryApi) CurrentBalance(address common.Address) (resp *CurBalanceResp, err error)

get the current account balance swagger:operation POST /url/CurrentBalance account information CurBalanceResp --- summary: get all UTXO balances of current user description: get all UTXO balances of current user parameters:

  • name: addresses in: body description: address type: []common.Address required: true

produces: - application/json responses:

"200":
     "$ref": "#/responses/CurBalanceResp"

func (*DipperinMercuryApi) CurrentBlock

func (api *DipperinMercuryApi) CurrentBlock() (*BlockResp, error)

swagger:operation GET /url/CurrentBlock block information block --- summary: get the current block description: get the current block produces: - application/json responses:

"200":
     "$ref": "#/responses/BlockResp"

func (*DipperinMercuryApi) CurrentReputation

func (api *DipperinMercuryApi) CurrentReputation(address common.Address) (uint64, error)

func (*DipperinMercuryApi) CurrentStake

func (api *DipperinMercuryApi) CurrentStake(address common.Address) (resp *CurStakeResp, err error)

get address stake swagger:operation POST /url/CurrentStake stakeInfo stakeInfo --- summary: get address stake description: get address stake produces: - application/json responses:

"200":
     description: return address stake and the operation result

func (*DipperinMercuryApi) ERC20Allowance

func (api *DipperinMercuryApi) ERC20Allowance(contractAddr, owner, spender common.Address) (interface{}, error)

func (*DipperinMercuryApi) ERC20Approve

func (api *DipperinMercuryApi) ERC20Approve(contractAdr, from, to common.Address, amount, txFee *big.Int) (common.Hash, error)

func (*DipperinMercuryApi) ERC20Balance

func (api *DipperinMercuryApi) ERC20Balance(contractAddr, owner common.Address) (interface{}, error)

func (*DipperinMercuryApi) ERC20TotalSupply

func (api *DipperinMercuryApi) ERC20TotalSupply(contractAddr common.Address) (interface{}, error)

func (*DipperinMercuryApi) ERC20Transfer

func (api *DipperinMercuryApi) ERC20Transfer(contractAddr, from, to common.Address, amount, txFee *big.Int) (common.Hash, error)

func (*DipperinMercuryApi) ERC20TransferFrom

func (api *DipperinMercuryApi) ERC20TransferFrom(contractAdr, owner, from, to common.Address, amount, txFee *big.Int) (common.Hash, error)

func (*DipperinMercuryApi) EstablishWallet

func (api *DipperinMercuryApi) EstablishWallet(password, passPhrase string, walletIdentifier accounts.WalletIdentifier) (mnemonic string, err error)

establish wallet swagger:operation POST /url/EstablishWallet WalletOperation Wallet --- summary: establish wallet description: establish wallet parameters:

  • name: walletIdentifier in: body description: wallet identifier type: accounts.WalletIdentifier required: true
  • name: password in: body description: wallet password type: string required: true
  • name: passPhrase in: body description: wallet mnemonic passPhrase type: string required: true

produces: - application/json responses:

"200":
     description: return mnemonic and the operation result

func (*DipperinMercuryApi) GetAddressNonceFromWallet

func (api *DipperinMercuryApi) GetAddressNonceFromWallet(address common.Address) (nonce uint64, err error)

get address nonce from wallet

func (*DipperinMercuryApi) GetBlockBody

func (api *DipperinMercuryApi) GetBlockBody(hash common.Hash) *model.Body

consult block body by block hash swagger:operation POST /url/GetBlockBody block information block --- summary: consult block body by block hash description: consult block body by block hash parameters:

  • name: hash in: body description: block hash type: common.Hash required: true

produces: - application/json responses:

"200":
     "$ref": "#/responses/Body"

func (*DipperinMercuryApi) GetBlockByHash

func (api *DipperinMercuryApi) GetBlockByHash(hash common.Hash) (*BlockResp, error)

swagger:operation POST /url/GetBlockByHash block information block --- summary: get the block by block hash description: get the block by block hash parameters:

  • name: hash in: body description: block hash type: common.Hash required: true

produces: - application/json responses:

"200":
     "$ref": "#/responses/BlockResp"

func (*DipperinMercuryApi) GetBlockByNumber

func (api *DipperinMercuryApi) GetBlockByNumber(number uint64) (*BlockResp, error)

swagger:operation POST /url/GetBlockByNumber block information block --- summary: get the block by height description: get the block by height parameters:

  • name: number in: body description: block height type: integer required: true

produces: - application/json responses:

"200":
     "$ref": "#/responses/BlockResp"

func (*DipperinMercuryApi) GetBlockDiffVerifierInfo

func (api *DipperinMercuryApi) GetBlockDiffVerifierInfo(blockNumber uint64) (map[economy_model.VerifierType][]common.Address, error)

func (*DipperinMercuryApi) GetBlockNumber

func (api *DipperinMercuryApi) GetBlockNumber(hash common.Hash) *uint64

swagger:operation POST /url/GetBlockNumber block information block --- summary: get the height of the block by block hash description: get block height by block hash parameters:

  • name: hash in: body description: block hash type: common.Hash required: true

produces: - application/json responses:

"200":
     description: block height

func (*DipperinMercuryApi) GetBlockYear

func (api *DipperinMercuryApi) GetBlockYear(blockNumber uint64) (uint64, error)

func (*DipperinMercuryApi) GetChainConfig

func (api *DipperinMercuryApi) GetChainConfig() (conf chain_config.ChainConfig, err error)

func (*DipperinMercuryApi) GetContract

func (api *DipperinMercuryApi) GetContract(contractAddr common.Address) (interface{}, error)

func (*DipperinMercuryApi) GetContractInfo

func (api *DipperinMercuryApi) GetContractInfo(eData *contract.ExtraDataForContract) (interface{}, error)

func (*DipperinMercuryApi) GetCurVerifiers

func (api *DipperinMercuryApi) GetCurVerifiers() []common.Address

get current verifiers swagger:operation POST /url/GetCurVerifiers verifierInfo verifierInfo --- summary: get current verifiers description: get current verifiers produces: - application/json responses:

"200":
     description: return verifier address list and the operation result

func (*DipperinMercuryApi) GetCurrentConnectPeers

func (api *DipperinMercuryApi) GetCurrentConnectPeers() ([]PeerInfoResp, error)

get current practical verifiers

func (*DipperinMercuryApi) GetDeveloperInfo

func (api *DipperinMercuryApi) GetDeveloperInfo() map[string]*hexutil.Big

func (*DipperinMercuryApi) GetDeveloperLockDIP

func (api *DipperinMercuryApi) GetDeveloperLockDIP(address common.Address, blockNumber uint64) (*hexutil.Big, error)

func (*DipperinMercuryApi) GetEarlyTokenLockDIP

func (api *DipperinMercuryApi) GetEarlyTokenLockDIP(address common.Address, blockNumber uint64) (*hexutil.Big, error)

func (*DipperinMercuryApi) GetFoundationInfo

func (api *DipperinMercuryApi) GetFoundationInfo(usage economy_model.FoundationDIPUsage) map[string]*hexutil.Big

func (*DipperinMercuryApi) GetGenesis

func (api *DipperinMercuryApi) GetGenesis() (*BlockResp, error)

get genesis block swagger:operation GET /url/GetGenesis block information block --- summary: get genesis block description: get genesis block produces: - application/json responses:

"200":
     "$ref": "#/responses/BlockResp"

func (*DipperinMercuryApi) GetInvestorInfo

func (api *DipperinMercuryApi) GetInvestorInfo() map[string]*hexutil.Big

func (*DipperinMercuryApi) GetInvestorLockDIP

func (api *DipperinMercuryApi) GetInvestorLockDIP(address common.Address, blockNumber uint64) (*hexutil.Big, error)

func (*DipperinMercuryApi) GetMaintenanceLockDIP

func (api *DipperinMercuryApi) GetMaintenanceLockDIP(address common.Address, blockNumber uint64) (*hexutil.Big, error)

func (*DipperinMercuryApi) GetMineMasterDIPReward

func (api *DipperinMercuryApi) GetMineMasterDIPReward(blockNumber uint64) (*hexutil.Big, error)

func (*DipperinMercuryApi) GetMineMasterEDIPReward

func (api *DipperinMercuryApi) GetMineMasterEDIPReward(blockNumber uint64, tokenDecimals int) (*hexutil.Big, error)

func (*DipperinMercuryApi) GetNextVerifiers

func (api *DipperinMercuryApi) GetNextVerifiers() []common.Address

get next verifiers swagger:operation POST /url/GetNextVerifiers verifierInfo verifierInfo --- summary: get next verifiers description: get next verifiers produces: - application/json responses:

"200":
     description: return verifier address list and the operation result

func (*DipperinMercuryApi) GetOneBlockTotalDIPReward

func (api *DipperinMercuryApi) GetOneBlockTotalDIPReward(blockNumber uint64) (*hexutil.Big, error)

func (*DipperinMercuryApi) GetReMainRewardLockDIP

func (api *DipperinMercuryApi) GetReMainRewardLockDIP(address common.Address, blockNumber uint64) (*hexutil.Big, error)

func (*DipperinMercuryApi) GetSlot

func (api *DipperinMercuryApi) GetSlot(block model.AbstractBlock) *uint64

func (*DipperinMercuryApi) GetSyncStatus

func (api *DipperinMercuryApi) GetSyncStatus() bool

verify whether the chain is in sync

func (*DipperinMercuryApi) GetTransactionNonce

func (api *DipperinMercuryApi) GetTransactionNonce(addr common.Address) (nonce uint64, err error)

get the nonce needed for the transaction: swagger:operation POST /url/Transaction transaction information Transaction --- summary: get the nonce needed for the transaction description: get the nonce needed for the transaction parameters:

  • name: addr in: body description: address type: common.Address required: true

produces: - application/json responses:

"200":
     description: return nonce and the result

func (*DipperinMercuryApi) GetVerifierDIPReward

func (api *DipperinMercuryApi) GetVerifierDIPReward(blockNumber uint64) (map[economy_model.VerifierType]*hexutil.Big, error)

func (*DipperinMercuryApi) GetVerifierEDIPReward

func (api *DipperinMercuryApi) GetVerifierEDIPReward(blockNumber uint64, tokenDecimals int) (map[economy_model.VerifierType]*hexutil.Big, error)

func (*DipperinMercuryApi) GetVerifiersBySlot

func (api *DipperinMercuryApi) GetVerifiersBySlot(slotNum uint64) ([]common.Address, error)

get verifiers info by round swagger:operation POST /url/GetVerifiersBySlot verifierInfo verifierInfo --- summary: get verifiers info by round description: get verifiers info by round parameters:

  • name: slotNum in: body description: the round (slotNum = blockNumber/slotSize) type: uint64 required: true

produces: - application/json responses:

"200":
     description: return verifier address list and the operation result

func (*DipperinMercuryApi) ListWallet

func (api *DipperinMercuryApi) ListWallet() ([]accounts.WalletIdentifier, error)

list wallet swagger:operation POST /url/ListWallet WalletOperation Wallet --- summary: list wallet description: list wallet produces: - application/json responses:

"200":
     description: return wallet identifier list and the operation result

func (*DipperinMercuryApi) ListWalletAccount

func (api *DipperinMercuryApi) ListWalletAccount(walletIdentifier accounts.WalletIdentifier) ([]accounts.Account, error)

list wallet account swagger:operation POST /url/ListWalletAccount WalletOperation Wallet --- summary: list wallet account description: list wallet account parameters:

  • name: walletIdentifier in: body description: wallet identifier type: accounts.WalletIdentifier required: true

produces: - application/json responses:

"200":
     description: return account list and the operation result

func (*DipperinMercuryApi) NewBlock

func (api *DipperinMercuryApi) NewBlock(ctx context.Context) (*rpc.Subscription, error)

func (*DipperinMercuryApi) NewSendTransactions

func (api *DipperinMercuryApi) NewSendTransactions(txs []model.Transaction) (int, error)

new send multiple-txs

func (*DipperinMercuryApi) NewTransaction

func (api *DipperinMercuryApi) NewTransaction(transactionRlpB []byte) (TxHash common.Hash, err error)

create a new transaction Tx: swagger:operation POST /url/Transaction transaction information NewTransactionReq --- summary: create a new transaction Tx description: create a new transaction Tx parameters:

  • name: tra in: body description: address type: model.Transaction required: true

produces: - application/json responses:

"200":
     description:return TxHash and the operation result

func (*DipperinMercuryApi) OpenWallet

func (api *DipperinMercuryApi) OpenWallet(password string, walletIdentifier accounts.WalletIdentifier) error

open wallet swagger:operation POST /url/OpenWallet WalletOperation Wallet --- summary: open wallet description: open wallet parameters:

  • name: walletIdentifier in: body description: wallet identifier type: accounts.WalletIdentifier required: true
  • name: password in: body description: wallet password type: string required: true

produces: - application/json responses:

"200":
     description: return operation result

func (*DipperinMercuryApi) RemoteHeight

func (api *DipperinMercuryApi) RemoteHeight() uint64

get remote node height

func (*DipperinMercuryApi) RestoreWallet

func (api *DipperinMercuryApi) RestoreWallet(password, mnemonic, passPhrase string, walletIdentifier accounts.WalletIdentifier) error

restore wallet swagger:operation POST /url/RestoreWallet WalletOperation Wallet --- summary: restore wallet description: restore wallet parameters:

  • name: walletIdentifier in: body description: wallet identifier type: accounts.WalletIdentifier required: true
  • name: password in: body description: wallet password type: string required: true
  • name: passPhrase in: body description: wallet mnemonic passPhrase type: string required: true
  • name: mnemonic in: body description: wallet mnemonic type: string required: true

produces: - application/json responses:

"200":
     description: return operation result

func (*DipperinMercuryApi) SendCancelTransaction

func (api *DipperinMercuryApi) SendCancelTransaction(from common.Address, fee *big.Int, nonce *uint64) (common.Hash, error)

send cancel transaction swagger:operation POST /url/SendCancelTransaction transactionOperation transaction --- summary: send cancel transaction description: send cancel transaction parameters:

  • name: from in: body description: the address that send register transaction type: common.Address required: true
  • name: fee in: body description: the transaction fee type: *big.Int required: true

produces: - application/json responses:

"200":
     description: return operation result

func (*DipperinMercuryApi) SendEvidenceTransaction

func (api *DipperinMercuryApi) SendEvidenceTransaction(from, target common.Address, fee *big.Int, voteA *model.VoteMsg, voteB *model.VoteMsg, nonce *uint64) (common.Hash, error)

send evidence transaction swagger:operation POST /url/SendEvidenceTransaction transactionOperation transaction --- summary: send evidence transaction description: send evidence transaction parameters:

  • name: from in: body description: the address that send register transaction type: common.Address required: true
  • name: target in: body description: the report target type: common.Address required: true
  • name: fee in: body description: the transaction fee type: *big.Int required: true
  • name: voteA in: body description: the report evidence voteA type: *model.Verification required: true
  • name: voteB in: body description: the report evidence voteB type: *model.Verification required: true

produces: - application/json responses:

"200":
     description: return operation result

func (*DipperinMercuryApi) SendRegisterTransaction

func (api *DipperinMercuryApi) SendRegisterTransaction(from common.Address, stake, fee *big.Int, nonce *uint64) (common.Hash, error)

send register transaction swagger:operation POST /url/SendRegisterTransaction transactionOperation transaction --- summary: send register transaction description: send register transaction parameters:

  • name: from in: body description: the address that send register transaction type: common.Address required: true
  • name: stake in: body description: the register pledge type: *big.Int required: true
  • name: fee in: body description: the transaction fee type: *big.Int required: true

produces: - application/json responses:

"200":
     description: return operation result

func (*DipperinMercuryApi) SendTransaction

func (api *DipperinMercuryApi) SendTransaction(from, to common.Address, value, transactionFee *big.Int, data []byte, nonce *uint64) (common.Hash, error)

send transaction swagger:operation POST /url/SendTransaction transactionOperation transaction --- summary: send transaction description: send transaction parameters:

  • name: from in: body description: the address that send coin type: common.Address required: true
  • name: to in: body description: the address that receive coin type: common.Address required: true
  • name: transactionFee in: body description: the transaction fee type: *big.Int required: true
  • name: data in: body description: the transaction extra data type: []byte required: true

produces: - application/json responses:

"200":
     description: return operation result

func (*DipperinMercuryApi) SendTransactions

func (api *DipperinMercuryApi) SendTransactions(from common.Address, rpcTxs []model.RpcTransaction) (int, error)

send multiple-txs

func (*DipperinMercuryApi) SendUnStakeTransaction

func (api *DipperinMercuryApi) SendUnStakeTransaction(from common.Address, fee *big.Int, nonce *uint64) (common.Hash, error)

send unstake transaction swagger:operation POST /url/SendCancelTransaction transactionOperation transaction --- summary: send cancel transaction description: send cancel transaction parameters:

  • name: from in: body description: the address that send register transaction type: common.Address required: true
  • name: fee in: body description: the transaction fee type: *big.Int required: true

produces: - application/json responses:

"200":
     description: return operation result

func (*DipperinMercuryApi) SetBftSigner

func (api *DipperinMercuryApi) SetBftSigner(address common.Address) error

set pbft account address swagger:operation POST /url/ListWalletAccount PbftAddressOperation pbftAddress --- summary: set pbft account address description: set pbft account address parameters:

  • name: walletIdentifier in: body description: wallet identifier type: accounts.WalletIdentifier required: true

produces: - application/json responses:

"200":
     description: return account list and the operation result

func (*DipperinMercuryApi) SetMineCoinBase

func (api *DipperinMercuryApi) SetMineCoinBase(addr common.Address) error

set mining address: swagger:operation POST /url/SetMineCoinBase mineOperation SetMineCoinBase --- summary: set mine CoinBase address description: set mine CoinBase address parameters:

  • name: addr in: body description: address type: common.Address required: true

produces: - application/json responses:

"200":
     description: return the operation result

func (*DipperinMercuryApi) StartMine

func (api *DipperinMercuryApi) StartMine() error

start mine: swagger:operation POST /url/StartMine mineOperation StartMine --- summary: start mine description: start mine produces: - application/json responses:

"200":
     description: return the operation result

func (*DipperinMercuryApi) StopDipperin

func (api *DipperinMercuryApi) StopDipperin()

func (*DipperinMercuryApi) StopMine

func (api *DipperinMercuryApi) StopMine() error

stop mine: swagger:operation POST /url/StopMine mineOperation StopMine --- summary: stop mine description: stop mine produces: - application/json responses:

"200":
     description: return the operation result

func (*DipperinMercuryApi) SubscribeBlock

func (api *DipperinMercuryApi) SubscribeBlock(ctx context.Context) (*rpc.Subscription, error)

func (*DipperinMercuryApi) Transaction

func (api *DipperinMercuryApi) Transaction(hash common.Hash) (resp *TransactionResp, err error)

fetch transaction data from TxID swagger:operation POST /url/Transaction transaction information TransactionReq --- summary: fetch transaction data, the height and block ID from TxID description: fetch transaction data, the height and block ID from TxID parameters:

  • name: hash in: body description: transaction hash type: common.Hash required: true

produces: - application/json responses:

"200":
     "$ref": "#/responses/TransactionResp"

func (*DipperinMercuryApi) VerifierStatus

func (api *DipperinMercuryApi) VerifierStatus(address common.Address) (resp *VerifierStatus, err error)

verifier status swagger:operation POST /url/VerifierStatus verifierInfo verifierInfo --- summary: verifier status description: verifier status produces: - application/json responses:

"200":
     description: return verifier status and the operation result

type DipperinP2PApi

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

func MakeDipperinP2PApi

func MakeDipperinP2PApi(service P2PAPI) *DipperinP2PApi

func (*DipperinP2PApi) AddPeer

func (api *DipperinP2PApi) AddPeer(url string) error

func (*DipperinP2PApi) AddTrustedPeer

func (api *DipperinP2PApi) AddTrustedPeer(url string) error

func (*DipperinP2PApi) CsPmInfo

func (api *DipperinP2PApi) CsPmInfo() (*p2p.CsPmPeerInfo, error)

func (*DipperinP2PApi) Peers

func (api *DipperinP2PApi) Peers() ([]*p2p.PeerInfo, error)

func (*DipperinP2PApi) RemovePeer

func (api *DipperinP2PApi) RemovePeer(url string) error

func (*DipperinP2PApi) RemoveTrustedPeer

func (api *DipperinP2PApi) RemoveTrustedPeer(url string) error

type ERC20Resp

type ERC20Resp struct {
	TxId common.Hash    `json:"txid"`
	CtId common.Address `json:"ctid"`
}

type ElectionResp

type ElectionResp struct {
	TxId            common.Hash
	SendBlockNumber uint64
}

Election resp

type ElectionStatus

type ElectionStatus int
const (
	WaitPackaged ElectionStatus = iota
	Packaged
	Invalid
)

type GetElectionStatus

type GetElectionStatus struct {
	ElectionStatus
	VerifierRound uint64
}

get election status resp

type NewTransactionResp

type NewTransactionResp struct {
	TxHash common.Hash `json:"tx_hash"`
}

swagger:response NewTransactionResp

type P2PAPI

type P2PAPI interface {
	AddPeer(url string) error
	RemovePeer(url string) error
	AddTrustedPeer(url string) error
	RemoveTrustedPeer(url string) error
	Peers() ([]*p2p.PeerInfo, error)
	CsPmInfo() (*p2p.CsPmPeerInfo, error)
}

type PeerInfoResp

type PeerInfoResp struct {
	NodeId  string
	Address common.Address
}

current practical verifiers resp

type SendTxReq

type SendTxReq struct {
	Tx *model.Transaction `json:"tx"`
}

type Service

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

func MakeRpcService

func MakeRpcService(conf nodeConf, apis []rpc.API, allowHosts []string) *Service

func (*Service) AddApis

func (service *Service) AddApis(apis []rpc.API)

add extra api

func (*Service) Start

func (service *Service) Start() error

func (*Service) Stop

func (service *Service) Stop()

type TransactionResp

type TransactionResp struct {
	Transaction *model.Transaction `json:"transaction"`
	BlockHash   common.Hash        `json:"blockHash"`
	BlockNumber uint64             `json:"blockNumber"`
	TxIndex     uint64             `json:"transactionIndex"`
}

swagger:response TransactionResp

type VerifierStatus

type VerifierStatus struct {
	Status            string
	Stake             *hexutil.Big
	Balance           *hexutil.Big
	Reputation        uint64
	IsCurrentVerifier bool
}

Jump to

Keyboard shortcuts

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