Documentation ¶
Overview ¶
nolint
nolint
nolint
Index ¶
- func BroadcastTxRequest(cliCtx context.CLIContext) http.HandlerFunc
- func EncodeTxRequestHandlerFn(cliCtx context.CLIContext) http.HandlerFunc
- func GetBroadcastCommand(cdc *amino.Codec) *cobra.Command
- func GetEncodeCommand(codec *amino.Codec) *cobra.Command
- func QueryCommitTxRequestHandlerFn(cliCtx context.CLIContext) http.HandlerFunc
- func QuerySideTxRequestHandlerFn(cliCtx context.CLIContext) http.HandlerFunc
- func QueryTxCmd(cdc *codec.Codec) *cobra.Command
- func QueryTxRequestHandlerFn(cliCtx context.CLIContext) http.HandlerFunc
- func QueryTxsByEventsCmd(cdc *codec.Codec) *cobra.Command
- func QueryTxsRequestHandlerFn(cliCtx context.CLIContext) http.HandlerFunc
- func RegisterRoutes(cliCtx context.CLIContext, r *mux.Router)
- type BroadcastReq
- type EncodeReq
- type EncodeResp
- type StdTx
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BroadcastTxRequest ¶
func BroadcastTxRequest(cliCtx context.CLIContext) http.HandlerFunc
BroadcastTxRequest implements a tx broadcasting handler that is responsible for broadcasting a valid and signed tx to a full node. The tx can be broadcasted via a sync|async|block mechanism.
func EncodeTxRequestHandlerFn ¶
func EncodeTxRequestHandlerFn(cliCtx context.CLIContext) http.HandlerFunc
swagger:route POST /txs/encode txs txsEncode It Encode the transaction responses: EncodeTxRequestHandlerFn returns the encode tx REST handler. In particular, it takes a json-formatted transaction, encodes it to the Amino wire protocol, and responds with base64-encoded bytes.
func GetBroadcastCommand ¶
GetBroadcastCommand returns the tx broadcast command.
func GetEncodeCommand ¶
GetEncodeCommand returns the encode command to take a JSONified transaction and turn it into Amino-serialized bytes
func QueryCommitTxRequestHandlerFn ¶
func QueryCommitTxRequestHandlerFn(cliCtx context.CLIContext) http.HandlerFunc
swagger:route GET /txs/{hash}/commit-proof txs txsHashCommitProof It returns the commit-proof for the transaction. QueryCommitTxRequestHandlerFn implements a REST handler that queries vote, sigs and tx bytes committed block.
func QuerySideTxRequestHandlerFn ¶ added in v0.1.7
func QuerySideTxRequestHandlerFn(cliCtx context.CLIContext) http.HandlerFunc
swagger:route GET /txs/{hash}/side-tx txs txsSideTx It returns the side-tx bytes QuerySideTxRequestHandlerFn implements a REST handler that queries sigs, side-tx bytes committed block
func QueryTxCmd ¶
QueryTxCmd implements the default command for a tx query.
func QueryTxRequestHandlerFn ¶
func QueryTxRequestHandlerFn(cliCtx context.CLIContext) http.HandlerFunc
swagger:route GET /txs/{hash} txs txsByHash It returns the transaction by hash. QueryTxRequestHandlerFn implements a REST handler that queries a transaction by hash in a committed block.
func QueryTxsByEventsCmd ¶
QueryTxsByEventsCmd returns a command to search through tagged transactions.
func QueryTxsRequestHandlerFn ¶
func QueryTxsRequestHandlerFn(cliCtx context.CLIContext) http.HandlerFunc
swagger:route GET /txs txs txsGET It returns the list of transaction based on page,limit and events specified. QueryTxsRequestHandlerFn implements a REST handler that searches for transactions. Genesis transactions are returned if the height parameter is set to zero, otherwise the transactions are searched for by events.
func RegisterRoutes ¶
func RegisterRoutes(cliCtx context.CLIContext, r *mux.Router)
RegisterRoutes registers REST routes
Types ¶
type BroadcastReq ¶
BroadcastReq defines a tx broadcasting request.
type EncodeResp ¶
type EncodeResp struct {
Tx string `json:"tx"`
}
EncodeResp defines a tx encoding response.