pub fn status_to_response_with_details(
status: &Status,
details: Option<&StatusDetails>,
) -> ResponseExpand description
Convert a tonic::Status into an axum HTTP response with a JSON error body.
The body is {"error", "message", "code"}, plus a details array when
details is given (see error_body). The HTTP status follows the code the
body reports, so a malformed upstream status answers 500.