Documentation
¶
Index ¶
- func AccountListRequestHandlerFn(w http.ResponseWriter, r *http.Request)
- func ExportAccountRequestHandlerFn(cliCtx context.CLIContext, cdc *codec.Codec) http.HandlerFunc
- func GetAccountTxsFn(cliCtx context.CLIContext, cdc *codec.Codec) http.HandlerFunc
- func NewAccountRequestHandlerFn(w http.ResponseWriter, r *http.Request)
- func QueryAccountRequestHandlerFn(storeName string, cdc *codec.Codec, decoder auth.AccountDecoder, ...) http.HandlerFunc
- func QueryBalancesRequestHandlerFn(storeName string, cdc *codec.Codec, decoder auth.AccountDecoder, ...) http.HandlerFunc
- func RegisterRoute(cliCtx context.CLIContext, r *mux.Router, cdc *codec.Codec, storeName string)
- func RegisterRoutes(cliCtx context.CLIContext, r *mux.Router, cdc *codec.Codec)
- type AccountBody
- type AccountTxsReq
- type CreateShiftReq
- type DisplayTx
- type ExportAccountBody
- type NewAccInfo
- type ResultAccountTxs
- type ResultExportAccount
- type SendDataBaseReq
- type SendShiftReq
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AccountListRequestHandlerFn ¶
func AccountListRequestHandlerFn(w http.ResponseWriter, r *http.Request)
func ExportAccountRequestHandlerFn ¶ added in v1.0.1
func ExportAccountRequestHandlerFn(cliCtx context.CLIContext, cdc *codec.Codec) http.HandlerFunc
func GetAccountTxsFn ¶
func GetAccountTxsFn(cliCtx context.CLIContext, cdc *codec.Codec) http.HandlerFunc
GetAccountTxsFn @param Address: address of account @param FromHeight: query tx in the block height range [fromHeight,endHeight]; when FromHeight and endHeight is 0, range is [CHAIN_HEIGHT-800, CHAIN_HEIGHT] @param EndHeight: query tx in the block height range [fromHeight,endHeight] when FromHeight and endHeight is 0, range is [CHAIN_HEIGHT-800, CHAIN_HEIGHT] @param Flag: query flag; 0, address appears both in fromAddress and toAddress; 1, address appears in fromAddress; 2, address appears in toAddress
func NewAccountRequestHandlerFn ¶
func NewAccountRequestHandlerFn(w http.ResponseWriter, r *http.Request)
func QueryAccountRequestHandlerFn ¶
func QueryAccountRequestHandlerFn( storeName string, cdc *codec.Codec, decoder auth.AccountDecoder, cliCtx context.CLIContext, ) http.HandlerFunc
query accountREST Handler
func QueryBalancesRequestHandlerFn ¶
func QueryBalancesRequestHandlerFn( storeName string, cdc *codec.Codec, decoder auth.AccountDecoder, cliCtx context.CLIContext, ) http.HandlerFunc
query accountREST Handler
func RegisterRoute ¶
register REST route
func RegisterRoutes ¶
resgister REST routes
Types ¶
type AccountBody ¶
type AccountBody struct {
Type string `json:"type"`
Value NewAccInfo `json:"value"`
}
type AccountTxsReq ¶
type CreateShiftReq ¶
type CreateShiftReq struct {
//BaseReq rest.BaseReq `json:"base_req"`
BaseReq SendDataBaseReq `json:"base_req"`
To string `json:"to"`
Amount []sdk.BigCoin `json:"amount"`
Encode bool `json:"encode"`
}
create
type ExportAccountBody ¶ added in v1.0.1
type NewAccInfo ¶
type NewAccInfo struct {
Address sdk.AccAddress `json:"address"`
Coins []sdk.BigCoin `json:"coins"`
PubKey crypto.PubKey `json:"public_key"`
AccountNumber uint64 `json:"account_number"`
Sequence uint64 `json:"sequence"`
}
accinfo
type ResultAccountTxs ¶
type ResultExportAccount ¶ added in v1.0.1
type ResultExportAccount struct {
PrivateKey string `json:"private_key"`
}
type SendDataBaseReq ¶
type SendDataBaseReq struct {
From string `json:"from"`
Password string `json:"password"`
Memo string `json:"memo"`
ChainID string `json:"chain_id"`
AccountNumber uint64 `json:"account_number"`
Sequence uint64 `json:"sequence"`
GasPrice string `json:"gas_price"`
GasWanted string `json:"gas_wanted"`
GasAdjustment string `json:"gas_adjustment"`
GenerateOnly bool `json:"generate_only"`
Simulate bool `json:"simulate"`
}
type SendShiftReq ¶
type SendShiftReq struct {
BaseReq SendDataBaseReq `json:"base_req"`
To string `json:"to"`
Amount []sdk.BigCoin `json:"amount"`
Data string `json:"data"`
GasPrice string `json:"gas_price"` // unit: HTDF/gallon
GasWanted string `json:"gas_wanted"` // unit: gallon
}
send
Click to show internal directories.
Click to hide internal directories.