Closed stoically closed 1 year ago
The problem with 500 errors is that they tend to get interpreted by things like Cloudflare to mean "this server is down", which wouldn't be correct.
How about an endpoint which still returns 200, but has an easier-to-parse body?
I see. Yeah, maybe /api/federation-ok
just returning true
or false
?
yup. Or OK
or some error code, maybe. I'd be happy to accept a pull request :)
I'd like to use the federation tester backend as monitoring in terms of whether federation generally works or not. I could parse the returned JSON and look at the
FederationOK
value. However, some tools currently don't support that, such as uptime-kuma (a regex feature could help as well, if it lands). In this case an API endpoint that revealsFederationOK
as HTTP Status would be useful.Maybe
GET /api/federation-ok
which responds with HTTP 200 if the federation is ok, and HTTP 500 if the federation is not ok, potentially with the error array as JSON, for easier debugging?