Documentation
¶
Index ¶
- type Balances
- type BroadcastTx
- type ContractQueryParams
- type ContractQueryParamsIndex
- type ContractQueryParamsQuery
- type ContractTx
- type EngineBlock
- type EngineNft
- type EngineStatus
- type FungibleBalance
- type FungibleTokenTransfer
- type History
- type HiveEngineFungibleToken
- type HiveEngineRpcNode
- func (h HiveEngineRpcNode) GetAccountOrders(token, account string, limit, offset int) (*PersonalOrders, error)
- func (h HiveEngineRpcNode) GetAllFungibleTokens() ([]HiveEngineFungibleToken, error)
- func (h HiveEngineRpcNode) GetAllWitnesses() ([]Witness, error)
- func (h HiveEngineRpcNode) GetBalances(token, account string, limit, offset int) (*Balances, error)
- func (h HiveEngineRpcNode) GetBlockRange(startBlock int, endBlock int) ([][]byte, error)
- func (h HiveEngineRpcNode) GetBlockRangeFast(startBlock int, endBlock int) ([][]byte, error)
- func (h HiveEngineRpcNode) GetBook(bookType, token string, limit, offset int) (*OrderBook, error)
- func (h HiveEngineRpcNode) GetHistory(token string, limit, offset int) (*History, error)
- func (h HiveEngineRpcNode) GetLatestBlockInfo() (*EngineBlock, error)
- func (h HiveEngineRpcNode) GetMetrics(token string, limit, offset int) (*Metrics, error)
- func (h HiveEngineRpcNode) GetStatus() (*EngineStatus, error)
- func (h HiveEngineRpcNode) GetSymbolAllNft(nftSymbol string) ([]EngineNft, error)
- func (h HiveEngineRpcNode) GetSymbolAllNftFast(nftSymbol string) ([][]byte, error)
- func (h HiveEngineRpcNode) GetSymbolAllNftMarket(nftSymbol string, chunkSize int) ([]NftMarketOffer, error)
- func (h HiveEngineRpcNode) QueryContract(qParams ContractQueryParams) ([]byte, error)
- func (h HiveEngineRpcNode) QueryContractBatch(qParams []ContractQueryParams) ([][]byte, error)
- func (h HiveEngineRpcNode) QueryContractByAcc(qParams ContractQueryParams) ([]byte, error)
- func (h HiveEngineRpcNode) QueryContractByAccBatch(qParams []ContractQueryParams) ([][]byte, error)
- type Metrics
- type NftMarketOffer
- type NftTransferPayload
- type NftsForNftTransfer
- type Order
- type OrderBook
- type PersonalOrders
- type QueryIDRange
- type QueryIntRange
- type Record
- type Witness
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Balances ¶
type Balances struct {
Account string `json:"account"`
Symbol string `json:"symbol"`
Balance string `json:"balance"`
Stake string `json:"stake"`
PendingUnstake string `json:"pendingUnstake"`
DelegationsIn string `json:"delegationsIn"`
DelegationsOut string `json:"delegationsOut"`
PendingUndelegations string `json:"pendingUndelegations"`
// contains filtered or unexported fields
}
type BroadcastTx ¶
type BroadcastTx struct {
}
type ContractQueryParams ¶
type ContractQueryParams struct {
Contract string `json:"contract"`
Table string `json:"table"`
Query interface{} `json:"query"`
Limit int `json:"limit"`
Offset int `json:"offset"`
Index []ContractQueryParamsIndex `json:"indexes"`
}
type ContractTx ¶
type ContractTx struct {
ContractName string `json:"contractName"`
ContractAction string `json:"contractAction"`
ContractPayload interface{} `json:"contractPayload"`
}
func CreateFungibleTokenTransfer ¶
func CreateFungibleTokenTransfer(symbol string, to string, quantity string, memo string) ContractTx
func CreateNftTransfer ¶
func CreateNftTransfer(symbol string, nftIds []int, to string, memo string) []ContractTx
type EngineBlock ¶
type EngineBlock struct {
BlockNumber int `json:"blockNumber"`
RefHiveBlockNumber int `json:"refHiveBlockNumber"`
Timestamp string `json:"timestamp"`
Transactions json.RawMessage `json:"transactions"`
VirtualTransactions json.RawMessage `json:"virtualTransactions,omitempty"`
Hash string `json:"hash"`
DatabaseHash string `json:"databasehash"`
MerkleRoot string `json:"merkleRoot"`
Round int `json:"round"`
RoundHash string `json:"roundHash"`
Witness string `json:"witness"`
SigningKey string `json:"signingKey"`
RoundSignature string `json:"roundSignature"`
}
type EngineNft ¶
type EngineNft struct {
Id int `json:"_id"`
Account string `json:"account"`
OwnedBy string `json:"ownedBy"`
LockedTokens json.RawMessage `json:"lockedTokens"`
Properties json.RawMessage `json:"properties"`
PreviousAccount string `json:"previousAccount"`
PreviousOwnedBy string `json:"previousOwnedBy"`
}
type EngineStatus ¶
type EngineStatus struct {
LastBlockNumber int `json:"lastBlockNumber"`
LastBlockRefHiveBlockNumber int `json:"lastBlockRefHiveBlockNumber"`
LastParsedHiveBlockNumber int `json:"lastParsedHiveBlockNumber"`
LastVerifiedBlockNumber int `json:"lastVerifiedBlockNumber"`
SSCnodeVersion string `json:"SSCnodeVersion"`
ChainId string `json:"chainId"`
Domain string `json:"domain"`
Lightnode bool `json:"lightnode"`
LastHash string `json:"lastHash"`
}
type FungibleBalance ¶
type FungibleBalance struct {
Id int `json:"_id"`
Account string `json:"account"`
Symbol string `json:"symbol"`
Balance string `json:"balance"`
Stake string `json:"stake"`
PendingUnstake string `json:"pendingUnstake"`
DelegationsIn string `json:"delegationsIn"`
DelegationsOut string `json:"delegationsOut"`
PendingUndelegations string `json:"pendingUndelegations"`
}
type FungibleTokenTransfer ¶
type HiveEngineFungibleToken ¶
type HiveEngineFungibleToken struct {
FungibleId int `json:"_id"`
Issuer string `json:"issuer"`
Symbol string `json:"symbol"`
Name string `json:"name"`
MetaData json.RawMessage `json:"metadata"`
DelegationEnabled bool `json:"delegationEnabled"`
Precision int `json:"precision"`
StakingEnabled bool `json:"stakingEnabled"`
UndelegationCooldown int `json:"undelegationCooldown"`
UnstakingCooldown int `json:"unstakingCooldown"`
}
type HiveEngineRpcNode ¶
type HiveEngineRpcNode struct {
Endpoints engineApiEndpoints
RpcNode rpcServer
}
func NewHiveEngineRpc ¶
func NewHiveEngineRpc(addr string) *HiveEngineRpcNode
func (HiveEngineRpcNode) GetAccountOrders ¶
func (h HiveEngineRpcNode) GetAccountOrders(token, account string, limit, offset int) (*PersonalOrders, error)
func (HiveEngineRpcNode) GetAllFungibleTokens ¶
func (h HiveEngineRpcNode) GetAllFungibleTokens() ([]HiveEngineFungibleToken, error)
func (HiveEngineRpcNode) GetAllWitnesses ¶
func (h HiveEngineRpcNode) GetAllWitnesses() ([]Witness, error)
func (HiveEngineRpcNode) GetBalances ¶
func (h HiveEngineRpcNode) GetBalances(token, account string, limit, offset int) (*Balances, error)
func (HiveEngineRpcNode) GetBlockRange ¶
func (h HiveEngineRpcNode) GetBlockRange(startBlock int, endBlock int) ([][]byte, error)
func (HiveEngineRpcNode) GetBlockRangeFast ¶
func (h HiveEngineRpcNode) GetBlockRangeFast(startBlock int, endBlock int) ([][]byte, error)
func (HiveEngineRpcNode) GetBook ¶
func (h HiveEngineRpcNode) GetBook(bookType, token string, limit, offset int) (*OrderBook, error)
func (HiveEngineRpcNode) GetHistory ¶
func (h HiveEngineRpcNode) GetHistory(token string, limit, offset int) (*History, error)
func (HiveEngineRpcNode) GetLatestBlockInfo ¶
func (h HiveEngineRpcNode) GetLatestBlockInfo() (*EngineBlock, error)
func (HiveEngineRpcNode) GetMetrics ¶
func (h HiveEngineRpcNode) GetMetrics(token string, limit, offset int) (*Metrics, error)
func (HiveEngineRpcNode) GetStatus ¶
func (h HiveEngineRpcNode) GetStatus() (*EngineStatus, error)
func (HiveEngineRpcNode) GetSymbolAllNft ¶
func (h HiveEngineRpcNode) GetSymbolAllNft(nftSymbol string) ([]EngineNft, error)
func (HiveEngineRpcNode) GetSymbolAllNftFast ¶
func (h HiveEngineRpcNode) GetSymbolAllNftFast(nftSymbol string) ([][]byte, error)
func (HiveEngineRpcNode) GetSymbolAllNftMarket ¶
func (h HiveEngineRpcNode) GetSymbolAllNftMarket(nftSymbol string, chunkSize int) ([]NftMarketOffer, error)
func (HiveEngineRpcNode) QueryContract ¶
func (h HiveEngineRpcNode) QueryContract(qParams ContractQueryParams) ([]byte, error)
func (HiveEngineRpcNode) QueryContractBatch ¶
func (h HiveEngineRpcNode) QueryContractBatch(qParams []ContractQueryParams) ([][]byte, error)
func (HiveEngineRpcNode) QueryContractByAcc ¶
func (h HiveEngineRpcNode) QueryContractByAcc(qParams ContractQueryParams) ([]byte, error)
func (HiveEngineRpcNode) QueryContractByAccBatch ¶
func (h HiveEngineRpcNode) QueryContractByAccBatch(qParams []ContractQueryParams) ([][]byte, error)
type Metrics ¶
type Metrics struct {
Symbol string `json:"symbol"`
Volume float64 `json:",string"`
VolumeExpiration int `json:"volumeExpiration"`
LastPrice float64 `json:",string"`
LowestAsk float64 `json:",string"`
HighestBid float64 `json:",string"`
LastDayPrice float64 `json:",string"`
LastDayPriceExpiration int `json:"lastDayPruceExpiration"`
PriceChangeHive float64 `json:",string"`
PriceChangePercent string `json:"priceChangePercent"`
// contains filtered or unexported fields
}
type NftMarketOffer ¶
type NftMarketOffer struct {
Id int `json:"_id"`
Account string `json:"account"`
OwnedBy string `json:"ownedBy"`
NftId string `json:"nftId"`
Grouping json.RawMessage `json:"grouping"`
Timestamp int `json:"timestamp"`
Price string `json:"price"`
PriceDec json.RawMessage `json:"priceDec"`
PriceSymbol string `json:"priceSymbol"`
Fee int `json:"fee"`
}
type NftTransferPayload ¶
type NftTransferPayload struct {
Nfts []NftsForNftTransfer `json:"nfts"`
To string `json:"to"`
Memo string `json:"memo,omitempty"`
}
type NftsForNftTransfer ¶
type Order ¶
type Order struct {
TxId string `json:"txId"`
Timestamp int `json:"timestamp"`
Account string `json:"account"`
Symbol string `json:"symbol"`
Quantity float64 `json:",string"`
Price float64 `json:",string"`
PriceDec interface{} `json:"priceDec"`
TokensLocked float64 `json:",string, omitempty"`
Expiration int `json:"expiration"`
// contains filtered or unexported fields
}
type PersonalOrders ¶
type QueryIDRange ¶
type QueryIDRange struct {
Id QueryIntRange `json:"_id"`
}
type QueryIntRange ¶
type Record ¶
type Record struct {
Type string `json:"type"`
Buyer string `json:"buyer"`
Seller string `json:"seller"`
Symbol string `json:"symbol"`
Quantity float64 `json:",string"`
Price float64 `json:",string"`
Timestamp int `json:"timestamp"`
Volume float64 `json:",string"`
BuyTxId string `json:"buyTxId"`
SellTxId string `json:"sellTxId"`
// contains filtered or unexported fields
}
type Witness ¶
type Witness struct {
Id int `json:"_id"`
Account string `json:"account"`
ApprovalWeight json.RawMessage `json:"approvalWeight"`
SigningKey string `json:"signingKey"`
Ip string `json:"ip"`
IpVersion int `json:"ipVersion"`
RPCPort int `json:"RPCPort"`
P2PPort int `json:"P2PPort"`
Enabled bool `json:"enabled"`
MissedRounds int `json:"missedRounds"`
MissedRoundsInARow int `json:"missedRoundsInARow"`
VerifiedRounds int `json:"verifiedRounds"`
LastRoundVerified int `json:"lastRoundVerified"`
LastBlockVerified int `json:"lastBlockVerified"`
}
Click to show internal directories.
Click to hide internal directories.