The quotes in your query param seem to be causing the error at the server. Try something like this
apiURL := "http://localhost:8080/api/history/resources/count"
req, err := http.NewRequest("GET", apiURL, nil)
if err != nil {
log.Fatal(err)
}
apiParams := req.URL.Query()
apiParams.Add("startedAfter", "2021-03-06T15:27:13.894415787+0200")
req.URL.RawQuery = apiParams.Encode()
res, err := http.DefaultClient.Do(req)
try that and revert.
solved Getting 400 after a get response, although the url is well formatted [closed]