gRPC Transcode Configuration
Configuration reference for the gRPC Transcode plugin (`grpc-transcode`): the parameters, each attribute with its type, whether it is required, its default and its accepted values.
Parameters
See plugin common configurations (opens in Apache APISIX docs) for configuration options available to all plugins.
proto_id — string or integer · required · since APISIX 1.2 · API7 Gateway 3.4.0
ID of the APISIX proto (opens in Apache APISIX docs) resource, which contains the protocol buffer definitions.
service — string · required · since APISIX 1.2 · API7 Gateway 3.4.0
Name of the gRPC service.
method — string · required · since APISIX 1.2 · API7 Gateway 3.4.0
Method name of the gRPC service.
deadline — number · optional · default: 0 · since APISIX 1.2 · API7 Gateway 3.4.0
Deadline for the gRPC service in ms. This is the time APISIX will wait for a gRPC call to complete.
pb_option — array[string] · optional · default: ["enum_as_name", "int64_as_number", "auto_default_values", "disable_hooks"] · since APISIX 1.2 · API7 Gateway 3.4.0
Encoder and decoder options. The option can be configured as an array of one or more of the below values:
For enum as result: enum_as_name, enum_as_value
For int64 as result: int64_as_number, int64_as_string, int64_as_hexstring
For default values: auto_default_values, no_default_values, use_default_values, use_default_metatable
For hooks: enable_hooks, disable_hooks
show_status_in_body — boolean · optional · default: false · since APISIX 3.1.0 · API7 Gateway 3.4.0
If true, display the parsed grpc-status-details-bin in the response body.
status_detail_type — string · optional · since APISIX 3.1.0 · API7 Gateway 3.4.0
The message type corresponding to the details part of grpc-status-details-bin. If not specified, the error message will not be decoded.
max_resp_body_size — integer · optional · default: 67108864 · since APISIX 3.18.0 · API7 Gateway 3.9.17
Valid values: greater than or equal to 1
Maximum response body size in bytes buffered for transcoding. A larger response is truncated to this size before transcoding. The chunk that crosses the threshold is buffered before the limit is enforced, so transient memory use can exceed the configured size. Introduced in API7 Enterprise 3.9.17 and 3.10.4, and APISIX 3.18.0.