Logo
NeoArc Studio

gRPC API Documentation

Document gRPC APIs with services, methods, all four streaming types, proto message definitions, standard gRPC status codes, Google RPC error detail types, interceptor chains, retry and hedging policies, HTTP transcoding, proto import and export, and a published gRPC API browser with streaming flow diagrams.

The gRPC editor documents gRPC APIs alongside your REST, GraphQL, AsyncAPI, Webhook, and MCP documentation. Define services, methods with all four streaming types, proto message schemas, error responses with google.rpc detail types, interceptor chains, retry and hedging policies, and HTTP transcoding rules in a structured format that publishes as a browsable gRPC API reference on your documentation site.

Core Concepts

gRPC API documentation is organised around three entity types with a shared schema layer for proto messages.

API Definition
The root gRPC API configuration: package name, version, servers with TLS settings, authentication (channel and call credentials), proto file options (java_package, go_package, csharp_namespace), and channel configuration.
Services
Logical groupings of related RPC methods. Each service defines interceptor chains with ordered execution, service-level options, and service-to-service dependencies that appear as edges in the Intent Graph.
Methods
Individual RPC endpoints with streaming type, request and response message references, metadata headers, error responses, retry or hedging policies, timeout, examples, and HTTP transcoding configuration.
Proto Messages
Proto message definitions use the shared schema system with proto extensions: field numbers, cardinality, oneof groups, map fields, well-known types, nested messages, and nested enums.

Four Streaming Types

Every gRPC method specifies its streaming type, which determines the request and response flow pattern.

TypeClient StreamsServer StreamsDescription
UnaryNoNoSingle request, single response. The most common pattern, equivalent to a traditional RPC call.
Server StreamingNoYesSingle request, stream of responses. Used for real-time feeds, large result sets, and push notifications.
Client StreamingYesNoStream of requests, single response. Used for file uploads, sensor data aggregation, and batch processing.
BidirectionalYesYesBoth sides stream independently. Used for chat, collaborative editing, and multiplexed data exchange.

Authentication

gRPC authentication separates channel-level credentials from per-call credentials, matching the gRPC security model.

Channel Credentials
Transport-level security: SSL/TLS, Insecure (development only), Google Default, ALTS (Application Layer Transport Security), and Composite credentials combining channel and call credentials.
Call Credentials
Per-request authentication: token-based credentials with configurable token type and header name, or plugin-based credentials with custom implementation references.

Error Handling

Document error responses with the full google.rpc error model. Each method specifies which standard gRPC status codes it may return, with descriptions and structured error details.

CategoryStatus Codes
SuccessOK
Client ErrorsCANCELLED, INVALID_ARGUMENT, NOT_FOUND, ALREADY_EXISTS, PERMISSION_DENIED, RESOURCE_EXHAUSTED, FAILED_PRECONDITION, ABORTED, OUT_OF_RANGE, UNAUTHENTICATED
Server ErrorsUNKNOWN, DEADLINE_EXCEEDED, UNIMPLEMENTED, INTERNAL, UNAVAILABLE, DATA_LOSS

Advanced Features

Interceptor Chains
Document ordered interceptor pipelines on services with type (unary, streaming, both), phase (client, server, both), execution order, and configuration. Per-method overrides can skip, replace, or reconfigure individual interceptors.
Retry and Hedging Policies
Configure retry policies with max attempts, backoff parameters, and retryable status codes. Or use hedging policies with max attempts, delay, and non-fatal status codes. Each method chooses one mode.
HTTP Transcoding
Map gRPC methods to HTTP endpoints for REST compatibility. Configure HTTP method (GET, POST, PUT, DELETE, PATCH), URL path pattern, body mapping, response body, and additional bindings. Maps to the google.api.http annotation in proto export.
Channel Configuration
Document channel settings: max send and receive message sizes, concurrent streams, keepalive timers, default compression (gzip, deflate, snappy, zstd), load balancing policy (pick_first, round_robin, grpclb, xds), connection timeout, and retry enablement.

Proto Import and Export

Viewer

The published site includes a gRPC API browser panel with dedicated viewers for API info, services, and methods.

Navigation Panel
Browse services and methods in a tree structure. Methods display streaming type badge icons. Search and filter across all gRPC API elements.
Streaming Flow Diagrams
Method viewers render visual streaming flow diagrams showing the request and response flow pattern for each streaming type. Readers see at a glance whether a method is unary, server-streaming, client-streaming, or bidirectional.
Searchable
gRPC API definitions are included in the published site search index. Find services, methods, and messages by name, package, or description.