Bruno API Client | Blog & News

Simplify gRPC Testing: What is gRPC & How Bruno Makes It Easy

Written by Ganesh Patil | Sep 16, 2025

When building microservices or modern distributed applications, APIs are the backbone of communication between services. Traditionally, REST APIs have dominated the web, but in recent years, gRPC (Google Remote Procedure Call) has gained significant traction, especially in systems where speed, scalability, and bi-directional communication are critical.

What is gRPC?

gRPC is a high-performance, open-source RPC framework developed by Google. It’s designed for efficient communication between services, especially in microservices-based architectures.

One of the core components of gRPC is Protocol Buffers (Protobuf) — a language-neutral, platform-neutral way of serializing structured data. You can think of Protobuf as a rulebook that defines the contract between the client and server.

What about REST APIs?

REST APIs have been around for decades and are the default choice for web applications. They are:

  • Easy to implement

  • Widely supported

  • Secure and familiar

However, REST is tied to HTTP/1.1, where each new request requires a new connection. In high-throughput systems, this can introduce unnecessary overhead and reduce efficiency.

Why gRPC?

Unlike REST, gRPC is built on HTTP/2, which brings several key benefits:

  • Persistent connection → A single connection can handle multiple requests and responses.

  • Streaming support → Clients and servers can send multiple messages over the same connection.

  • Smaller payloads → Protobuf is more compact than JSON, leading to faster serialization and deserialization.

  • Bi-directional communication → Perfect for real-time apps like chat, collaboration tools, or streaming services.

📌 Example: In a chat application, gRPC allows a client to send messages continuously and receive responses instantly over the same session — no need to re-establish a connection for every message.

REST vs gRPC: Choosing the Right API for Modern Applications

REST Example (Express.js)

Here’s how you might expose a simple Hello World endpoint using a REST API with Express.js:

const express = require('express');
const app = express();
const port = 3000;

app.get('/hello/:name', (req, res) => {
  const name = req.params.name;
  res.json({ message: `Hello, ${name}!` });
});

app.listen(port, () => {
  console.log(`REST API server running at http://localhost:${port}`);
});

To test, open a browser or run:

http://localhost:3000/hello/usebruno

Response:

{ "message": "Hello, usebruno!" }

gRPC Example (Node.js + Protobuf)

With gRPC, you define the service in a .proto file and generate code from it.

1. Define the service (hello.proto):

syntax = "proto3";

service HelloService {
  rpc SayHello (HelloRequest) returns (HelloReply);
}

message HelloRequest {
  string name = 1;
}

message HelloReply {
  string message = 1;
}

2. Implement the server (server.js):

const grpc = require('@grpc/grpc-js');
const protoLoader = require('@grpc/proto-loader');
const packageDef = protoLoader.loadSync('hello.proto');
const grpcObj = grpc.loadPackageDefinition(packageDef);

const server = new grpc.Server();
server.addService(grpcObj.HelloService.service, {
  SayHello: (call, callback) => {
    const name = call.request.name;
    callback(null, { message: `Hello, ${name}!` });
  }
});
server.bindAsync(
  '0.0.0.0:50051',
  grpc.ServerCredentials.createInsecure(),
  () => {
    console.log("gRPC server running at http://localhost:50051");
    server.start();
  }
);

3. Call the service (client.js):

const grpc = require('@grpc/grpc-js');
const protoLoader = require('@grpc/proto-loader');

const packageDef = protoLoader.loadSync('hello.proto');
const grpcObj = grpc.loadPackageDefinition(packageDef);

const client = new grpcObj.HelloService(
  'localhost:50051',
  grpc.credentials.createInsecure()
);

client.SayHello({ name: "usebruno" }, (err, response) => {
  if (err) console.error(err);
  else console.log(response.message);
});

To test, run the server and client:

node server.js
node client.js

Response:

Hello, usebruno!

Say Hello to gRPC in Bruno (Beta)

We at Bruno recently released support for gRPC in beta mode. You can test, debug and perform streaming operations for gRPC, including unary, server, client and bidirectional streaming. 

You can add a .proto file at the collection and individual request level to reflect server methods automatically in Bruno. 

Features

  • Proto Support: Add .proto file at collection and request level
  • Support for Streams: Test and debug (unary, server, client, bidirectional) streams directly in Bruno
  • Auto Method Discovery: Method discovery based on server reflection and proto files
  • Memory Cache: Refresh feature to track latest changes in memory from server updates 

gRPC Interface 

The Bruno gRPC interface provides a familiar, intuitive experience for working with gRPC services.

  • Per-request proto file support:  Attach a .proto file at the request level to define the service and message structures.

  • Method auto-suggestion: When composing a request, Bruno automatically suggests available methods in the response section based on the attached proto file.

  • Pre-built message autofill: Use the Auto Fill button to quickly populate fields with pre-built message templates when sending a request.

Note: The gRPC feature is currently in beta. You can learn more about it in the official Bruno documentation.

Enable gRPC Support - Beta

To start using the gRPC feature in Bruno:

  1. Open Preferences in Bruno.

  2. Go to the Beta section.

  3. Enable the gRPC Support option.

Once enabled, you can create, test, and debug gRPC requests directly within Bruno, just like you would with REST requests.

Create gRPC Request

Once you enable the gRPC support from Preferences > Beta, you create a gRPC request with the following steps:

  1. Create a fresh collection, or you can choose an existing collection as well.
  2. Click on Context Menu at Collection and select New Request
  3. Select gRPC and enter request name and URL

Your gRPC endpoint is visible in Bruno now to send, debug and test requests.

Adding Proto Files

You can add proto files in the gRPC interface at two levels:

Request Level

You can add the proto file individually at the request level for method discovery.

  1. Open your gRPC request in Bruno
  2. In the gRPC interface, locate the Using Reflection section
  3. Click on the Browse for proto file button or toggle the proto file option
  4. Click the file browser to select .proto files from your local system

Collection Level

Adding proto files at the collection level reduces the redundant steps at once and uses multiple. 

  1. Go to collection-level settings
  2. Navigate to the gRPC tab
  3. Click the Browse for proto files to select .proto files from your local system

 

gRPC Streams

gRPC streaming allows you to send and receive multiple messages over a single connection, making it ideal for:

  • Unary streaming (simple request-response, CRUD operations, authentication)
  • Client streaming (batch processing, data collection)
  • Server streaming (real-time notifications, live data feeds, progress updates)
  • Bidirectional streaming (chat applications, collaborative editing, gaming)

Feel free to read more about streaming with examples from Bruno's official documentation.

Try the Demo Yourself

We’ve published the full working collection on GitHub. You can either clone this or simply click the Fetch in Bruno button below!

 

 

Conclusion

REST APIs remain a great choice for public APIs, simple web apps, and when human readability and wide adoption matter most. gRPC shines in microservices, real-time apps, and high-performance systems, where speed, efficiency, and streaming are critical.

Bruno’s gRPC support lets you test, debug, and validate your gRPC APIs without requiring login or credentials. Download Bruno, start exploring gRPC, and share your feedback!