Documentation ¶
Index ¶
- Variables
- func LogSkipper(c echo.Context) bool
- type NewServerOpts
- type Server
- func (srv *Server) GetBlockInfo(c echo.Context) error
- func (srv *Server) GetEventsByAddress(c echo.Context) error
- func (srv *Server) GetSuspendedTransactions(c echo.Context) error
- func (srv *Server) Health(c echo.Context) error
- func (srv *Server) ServeHTTP(w http.ResponseWriter, r *http.Request)
- func (srv *Server) Shutdown(ctx context.Context) error
- func (srv *Server) Start(address string) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNoHTTPFramework = errors.Validation.NewWithKeyAndDetail( "ERR_NO_HTTP_ENGINE", "HTTP framework required", ) ErrNoRewarder = errors.Validation.NewWithKeyAndDetail( "ERR_NO_REWARDER", "Rewarder is required", ) )
Functions ¶
func LogSkipper ¶
Types ¶
type NewServerOpts ¶
type NewServerOpts struct { Echo *echo.Echo EventRepo relayer.EventRepository SuspendedTxRepo relayer.SuspendedTransactionRepository CorsOrigins []string SrcEthClient ethClient DestEthClient ethClient }
func (NewServerOpts) Validate ¶
func (opts NewServerOpts) Validate() error
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
@host relayer.katla.taiko.xyz Server represents an relayer http server instance.
func NewServer ¶
func NewServer(opts NewServerOpts) (*Server, error)
func (*Server) GetBlockInfo ¶
getBlockInfoResponse
returns block info for the chains @Summary Get block info @ID get-block-info @Accept json @Produce json @Success 200 {object} getBlockInfoResponse @Router /blockInfo [get]
func (*Server) GetEventsByAddress ¶
GetEventsByAddress
returns events by address @Summary Get events by address @ID get-events-by-address @Param address query string true "address to query" @Param msgHash query string false "msgHash to query" @Param chainID query string false "chainID to query" @Param eventType query string false "eventType to query" @Param event query string false "event to query" @Accept json @Produce json @Success 200 {object} paginate.Page @Router /events [get]
func (*Server) GetSuspendedTransactions ¶
GetSuspendedTransactions
returns suspended transactions @Summary Get suspended transactions @ID get-suspended-transactions @Accept json @Produce json @Success 200 {object} paginate.Page @Router /suspendedTransactions [get]
func (*Server) ServeHTTP ¶
func (srv *Server) ServeHTTP(w http.ResponseWriter, r *http.Request)
ServeHTTP implements the `http.Handler` interface which serves HTTP requests
Click to show internal directories.
Click to hide internal directories.