REST vs GraphQL vs gRPC 00:00:01 REST and separate resources A phone opens a customer profile together with orders and product details. One engineer counts network trips, another counts database calls, and they get different answers. Both counts matter when choosing the interface. The user and the orders do not depend on each other, so the app asks for both. The user with every field, and orders that only hold product ids. Now the ids are known. Two more requests. Four requests in two waves. Most fields of the user were not needed. An app that waits for each answer before the next request needs four waves. Independent requests can run in parallel, and separately addressable resources can be cached separately. Some later requests still need identifiers returned by an earlier one. 00:00:55 Ask for a shaped result The app writes down the fields and asks once. One POST with the exact fields. The query is checked against the schema and the cost limit. Resolvers fetch the first levels. All product ids of the query are fetched together. JSON in the shape of the query, nothing more. A GraphQL query can describe nested fields in one client request. The resolver still needs authorization, limits and an efficient way to fetch every requested relationship. 00:01:28 Call a typed service A method made for this screen, with binary messages. The generated client turns the call into a few bytes and adds a deadline. The service calls the others over gRPC on connections that are already open. Then the products, in one call. The app receives an object with known types. A gRPC interface makes message types and method signatures explicit. Its transport and tooling may suit calls between controlled services even when a public browser client needs a different interface. 00:02:03 The extra lookup per item Three orders with two items each, resolved naively and in batches. One query each, both ways. Naively, one query per order: three. Naively, one query per item: six. Collect the ids, ask once, hand out the results. Eleven queries become four. Count backend trips, not just public requests. Batch keys or prefetch related objects where suitable and verify that cached results preserve the caller's authorization boundary. 00:02:41 Compare the bytes fairly The same user as JSON and as Protocol Buffers. JSON writes the name, quotes, colon and three digits: 8 bytes. Protobuf writes a tag and one byte: 2. Both must store eight letters. JSON adds the field name and quotes. Sixteen characters in both. Two braces and two commas complete the JSON. 55 against 30 bytes. Message format, compression, reused connections and the actual selected fields all affect the measured payload. A small example cannot establish a universal winner for size or latency. 00:03:25 Different callers can choose differently They have tools for HTTP and JSON, and you cannot update their code. Plain REST endpoints are enough. GraphQL, if the team can run and protect it. gRPC when types, volume or streams matter. The public mobile contract can aggregate fields while internal services exchange compact typed requests. That boundary is valuable only when it saves demonstrable work or reduces coupling for a real caller. Choose the interface by its clients and the boundary they cross. One elegant public request can still hide expensive repeated work behind the server that receives it.