diff --git a/wsapi/status.go b/wsapi/status.go index e15d6cd202..563fb5956e 100644 --- a/wsapi/status.go +++ b/wsapi/status.go @@ -67,3 +67,18 @@ func HandleNetworkInfo( r.NetworkID = state.GetNetworkID() return r, nil } + +func HandlePredictiveFER( + state interfaces.IState, + params interface{}, +) ( + interface{}, + *primitives.JSONError, +) { + type ret struct { + PredictiveFER uint64 + } + r := new(ret) + r.PredictiveFER = state.GetPredictiveFER() + return r, nil +} \ No newline at end of file diff --git a/wsapi/wsapiV2.go b/wsapi/wsapiV2.go index fe6d4a688c..813935b684 100644 --- a/wsapi/wsapiV2.go +++ b/wsapi/wsapiV2.go @@ -161,6 +161,9 @@ func HandleV2Request(state interfaces.IState, j *primitives.JSON2Request) (*prim case "network-info": resp, jsonError = HandleNetworkInfo(state, params) break + case "predictive-fer": + resp, jsonError = HandlePredictiveFER(state, params) + break // END STATUS calls