Documentation ¶
Index ¶
Constants ¶
View Source
const HandleRequestRecursionLimit = 3
View Source
const InfuraURL = "https://%s.infura.io/v3/%s"
Config
View Source
const InfuraWsURL = "wss://%s.infura.io/ws/v3/%s"
Config
View Source
const PocketURL = "https://%s.gateway.pokt.network/v1/%s"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HttpProxyServer ¶ added in v1.0.0
type HttpProxyServer struct { Port string ProviderUrl string Verbose bool ProviderType string // contains filtered or unexported fields }
Proxy server
func NewHttpProxyServer ¶ added in v1.0.0
func NewHttpProxyServer(port string, providerUrl string, network string, projectId string, providerType string, verbose bool) *HttpProxyServer
Create new proxy server
func (*HttpProxyServer) ServeHTTP ¶ added in v1.0.0
func (p *HttpProxyServer) ServeHTTP(w http.ResponseWriter, r *http.Request)
Handle request / serve response
func (*HttpProxyServer) Start ¶ added in v1.0.0
func (p *HttpProxyServer) Start() error
Start proxy server
type InfuraRateLimitError ¶ added in v1.0.0
type InfuraRateLimitError struct { Error struct { Code int `json:"code"` Message string `json:"message"` Data struct { Rate struct { BackoffSeconds float64 `json:"backoff_seconds"` } `json:"rate"` } `json:"data"` } `json:"error"` }
Infura rate limit error
type WsProxyServer ¶ added in v1.0.0
Proxy server
func NewWsProxyServer ¶ added in v1.0.0
func NewWsProxyServer(port string, providerUrl string, network string, projectId string, verbose bool) *WsProxyServer
Create new proxy server
func (*WsProxyServer) ServeHTTP ¶ added in v1.0.0
func (p *WsProxyServer) ServeHTTP(w http.ResponseWriter, r *http.Request)
Handle request / serve response
func (*WsProxyServer) Start ¶ added in v1.0.0
func (p *WsProxyServer) Start() error
Start proxy server
Click to show internal directories.
Click to hide internal directories.