Introducing Socket Firewall: Free, Proactive Protection for Your Software Supply Chain.Learn More
Socket
Book a DemoInstallSign in
Socket

@cerbos/grpc

Package Overview
Dependencies
Maintainers
3
Versions
35
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@cerbos/grpc

Client library for interacting with the Cerbos policy decision point service over gRPC from server-side Node.js applications

latest
Source
npmnpm
Version
0.23.1
Version published
Weekly downloads
12K
11.94%
Maintainers
3
Weekly downloads
 
Created
Source

@cerbos/grpc

npm

Client library for interacting with the Cerbos policy decision point service over gRPC from server-side Node.js applications.

Prerequisites

  • Cerbos 0.16+
  • Node.js 20+

Installation

$ npm install @cerbos/grpc

Example usage

import { GRPC } from "@cerbos/grpc";

const cerbos = new GRPC("localhost:3593", { tls: false });

await cerbos.isAllowed({
  principal: {
    id: "user@example.com",
    roles: ["USER"],
    attr: { tier: "PREMIUM" },
  },
  resource: {
    kind: "document",
    id: "1",
    attr: { owner: "user@example.com" },
  },
  action: "view",
}); // => true

For more details, see the GRPC class documentation.

Further reading

Get help

Keywords

Cerbos

FAQs

Package last updated on 15 Sep 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts