📡 You're offline — showing cached content
New version available!
Quick Access
Tutorials API Design gRPC

gRPC

5 min read
gRPC uses binary Protocol Buffers for high-performance typed RPC — ideal for internal service communication.

gRPC

Binary Protocol Buffers for RPC — 10x faster than JSON REST, ideal for internal microservice communication.

# user.proto
syntax = "proto3";
service UserService {
  rpc GetUser   (GetUserRequest)  returns (User);
  rpc ListUsers (ListRequest)     returns (stream User);
}
message User { int32 id=1; string name=2; string email=3; }

# Generate stubs
# protoc --python_out=. --grpc_python_out=. user.proto

# When to use gRPC:
# - Internal microservice communication
# - High-throughput low-latency
# - Streaming data
# - Strongly typed contracts