Documentation ¶
Index ¶
- Constants
- func StartServer()
- type Action
- type ApiServer
- type Params
- type Route
- type Router
- func (r *Router) Connect(path string, handler http.HandlerFunc)
- func (r *Router) Delete(path string, handler http.HandlerFunc)
- func (r *Router) Get(path string, handler http.HandlerFunc)
- func (r *Router) Head(path string, handler http.HandlerFunc)
- func (r *Router) Options(path string, handler http.HandlerFunc)
- func (r *Router) Post(path string, handler http.HandlerFunc)
- func (r *Router) Put(path string, handler http.HandlerFunc)
- func (r *Router) ServeHTTP(w http.ResponseWriter, req *http.Request)
- func (r *Router) Try(path string, method string) (http.HandlerFunc, Params, error)
Constants ¶
View Source
const ( ApiGetConnectionCount = "/api/v1/node/connectioncount" ApiGetNodeState = "/api/v1/node/state" ApiGetBlockTxsByHeight = "/api/v1/block/transactions/height/:height" ApiGetBlockByHeight = "/api/v1/block/details/height/:height" ApiGetBlockByHash = "/api/v1/block/details/hash/:hash" ApiGetConfirmByHeight = "/api/v1/confirm/details/height/:height" ApiGetConfirmByHash = "/api/v1/confirm/details/hash/:hash" ApiGetBlockHeight = "/api/v1/block/height" ApiGetBlockHash = "/api/v1/block/hash/:height" ApiGetTransaction = "/api/v1/transaction/:hash" ApiGetAsset = "/api/v1/asset/:hash" ApiGetBalanceByAddr = "/api/v1/asset/balances/:addr" ApiGetBalanceByAsset = "/api/v1/asset/balance/:addr/:assetid" ApiGetUTXOByAsset = "/api/v1/asset/utxo/:addr/:assetid" ApiGetUTXOByAddr = "/api/v1/asset/utxos/:addr" ApiSendRawTransaction = "/api/v1/transaction" ApiGetTransactionPool = "/api/v1/transactionpool" ApiRestart = "/api/v1/restart" )
Variables ¶
This section is empty.
Functions ¶
func StartServer ¶
func StartServer()
Types ¶
type ApiServer ¶
type ApiServer interface { Start() Stop() }
func InitRestServer ¶
func InitRestServer() ApiServer
Click to show internal directories.
Click to hide internal directories.