﻿# HTTP-to-gRPC status mapping: fallback only when grpc-status is missing

Apply gRPC's intermediary HTTP fallback in the documented direction, preserve received status, and distinguish a synthesized category from an application verdict.

Author: Retrivium editorial team
Updated: 2026-11-04
Canonical URL: https://retrivium.ai/journal/guide-grpc-http-fallback-missing-status/
Language: en

## The fallback addresses an incomplete protocol response

The gRPC mapping document describes intermediary responses that do not include grpc-status. It provides a client-side way to classify that incomplete response instead of assuming that an ordinary HTTP status is already a complete RPC outcome.

This is a precise precondition. A consumer should first determine whether the expected status was supplied. The fallback is not a general replacement for reading gRPC metadata, and a familiar HTTP code is not sufficient reason to discard a remote status already present in the response.

## Received status takes precedence over the table

The mapping document explicitly requires use of grpc-status when available. A gateway or wrapper that always maps the HTTP status can overwrite the server's actual verdict with a synthesized category.

A proposed adapter retains both the observed HTTP information and the status source. It distinguishes a received RPC status from a fallback interpretation. That distinction lets a diagnostic explain whether the application returned a result category or an intermediary prevented the expected protocol outcome from arriving.

## A successful HTTP response without status is still incomplete

The table explains that an HTTP success response missing the required RPC status is not enough to synthesize an RPC success. A consumer must not fill the missing field with a successful outcome merely because the connection and body were readable.

For a client wrapper, this is an interface-integrity question. A proxy can remove or fail to forward expected metadata while leaving apparently normal transport information. The absence of a status is itself evidence about the broken contract, not permission to guess the most optimistic application result.

## The mapping is intentionally asymmetric

The document says the mappings are neither symmetric nor one-to-one and prohibits servers from using the table to choose their outgoing HTTP status. Reversing it can make several distinct situations indistinguishable or assign an unrelated meaning to an application error.

A protocol-translating server needs its own explicit response contract. A client-side recovery convention does not define how that server should encode every remote status into another API. Keep these two directions separate in configuration and review examples.

## A synthesized category does not prove execution history

The protocol and status guides distinguish transport/runtime failures from application-generated results. A fallback category describes what the client can infer from an incomplete response; it does not establish whether model work ran, whether an effect committed or whether repeating the operation is safe.

A proposed review includes received status, missing status, an intermediary error and HTTP success with incomplete protocol metadata. It verifies the fallback's precondition and direction, preserving uncertainty about execution rather than turning a classification table into an unsupported exactly-once or retry guarantee.

## Primary references

[HTTP-to-gRPC fallback mapping](https://raw.githubusercontent.com/grpc/grpc/master/doc/http-grpc-status-mapping.md).

[gRPC response protocol](https://raw.githubusercontent.com/grpc/grpc/master/doc/PROTOCOL-HTTP2.md).

[gRPC status sources](https://grpc.io/docs/guides/status-codes/).

Related explanations: [Failure context](/journal/provider-request-id-trace-context/); [Protocol termination](/journal/provider-sse-terminal-eof-contract/).
