Problem
When there is a consensus node error, for a wrong nonce, or similar, we are raising 400 instead of 200, which is the de facto standard (there is no standard for this).
We need to check which functional errors are generating 400 vs 200, compare them with Alchemy/QuickNode, and make the HTTP code configurable to allow relay providers to choose to be a de facto or no de facto standard.
Solution
- list all errors
- add a config var for selected HTTP code
- return the HTTP code (200 or 400) based on the config var
Alternatives
No response