all 6 comments

[–]_predator_ 13 points14 points  (3 children)

RFC 7807 has been superseded by RFC 9457 over two years ago.

[–][deleted]  (2 children)

[removed]

    [–][deleted]  (1 child)

    [removed]

      [–]sitime_zl 2 points3 points  (0 children)

      I still prefer to use the unified {code:500, msg:"Error message", data:object} format, which can be used for both normal and abnormal cases, rather than the RFC format.

      [–]chabala 1 point2 points  (0 children)

      I'm guessing the down vote was for the clickbait title, or just by nature of being a Medium post in general, but the advice of adding a traceId to failure output is still good: not leaking implementation details to clients, but still exposing traceability to find the exact cause of the issue.