npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@reziiix-ai/sdk

v1.0.0

Published

Official SDK for the REZIIIX AI Governance Platform — scan agent actions, enforce policies, and verify compliance receipts.

Readme

@reziiix/sdk

Official SDK for the REZIIIX AI Governance Platform. Scan agent actions, enforce policies, detect PII, and verify compliance receipts — all with a single API call.

Install

npm install @reziiix/sdk

Quick Start

import { ReziiixClient } from '@reziiix/sdk';

const client = new ReziiixClient({
  apiKey: 'rzx_your-api-key-here',
});

// Scan an agent action before it executes
const result = await client.scan({
  agentId: 'my-agent',
  action: 'Send email with customer data',
  context: { userId: 'user-123', isExternal: true },
});

console.log(result.ok);                  // true
console.log(result.results.piiFound);    // number of PII entities detected
console.log(result.results.durationMs);  // evaluation time in ms

Configuration

const client = new ReziiixClient({
  apiKey: 'rzx_...',                  // Required — create at Developer Hub → API Keys
  endpoint: 'https://reziiix.com',    // Optional — defaults to https://reziiix.com
  timeout: 15000,                     // Optional — request timeout in ms (default: 10000)
});

API

client.scan(options)

The primary method. Scans an AI agent action through the full governance pipeline: intent classification → PII detection → policy evaluation → cryptographic receipt.

const result = await client.scan({
  agentId: 'email-agent',              // required
  action: 'Export customer PII to CSV', // required
  context: {                            // optional — extra data for policy evaluation
    userId: 'user-123',
    isExternal: true,
    recipientCount: 5,
  },
  mode: 'sample',                      // optional — 'sample' (default) or 'csv'
  data: 'base64-csv-string...',        // required when mode is 'csv'
});

Returns:

{
  ok: true,
  results: {
    totalRecords: 500,
    piiFound: 45,
    rowsWithPii: 23,
    detectionRate: '4.60%',
    violationsByType: { EMAIL_ADDRESS: 18, PHONE_NUMBER: 12, PERSON: 15 },
    classificationDistribution: { Public: 477, Internal: 23 },
    sampleViolations: [{ row: 12, type: 'EMAIL_ADDRESS', severity: 'WARN', count: 2 }],
    durationMs: 245,
    engines: ['presidio', 'regex']
  }
}

client.policies.list()

List all active governance policies (built-in + custom).

const { data: policies } = await client.policies.list();

for (const policy of policies) {
  console.log(`${policy.id}: ${policy.effect} — ${policy.description}`);
}

client.agents.list()

List all registered AI agents with activity stats.

const { data: agents } = await client.agents.list();

for (const agent of agents) {
  console.log(`${agent.agentName}: ${agent.totalActions} actions, ${agent.blockRate}% blocked`);
}

client.agents.get(agentId)

Get detailed info for a specific agent including recent actions and distributions.

const { data: agent } = await client.agents.get('my-agent');

console.log(agent.recentActions);
console.log(agent.toolDistribution);
console.log(agent.classificationDistribution);

client.receipts.list(filters?)

List cryptographic governance receipts with optional filters.

const { data: receipts } = await client.receipts.list({
  agent: 'my-agent',
  decision: 'FORBID',
  from: '2026-03-01',
  to: '2026-03-13',
  limit: 100,
});

client.receipts.verify(receiptIds)

Batch verify the integrity of governance receipts.

const { results } = await client.receipts.verify([
  'receipt-id-1',
  'receipt-id-2',
]);

for (const r of results) {
  console.log(`${r.receiptId}: verified=${r.verified}`);
}

client.stats()

Get aggregated dashboard metrics.

const { data } = await client.stats();

console.log(`Governance Score: ${data.governanceScore}`);
console.log(`Decisions Today: ${data.decisionsToday}`);
console.log(`Active Agents: ${data.activeAgents}`);
console.log(`Open Anomalies: ${data.openAnomalies}`);

Error Handling

The SDK throws typed errors for different failure modes:

import {
  ReziiixClient,
  ReziiixAuthError,
  ReziiixApiError,
  ReziiixValidationError,
  ReziiixTimeoutError,
} from '@reziiix/sdk';

try {
  await client.scan({ agentId: 'x', action: 'y' });
} catch (err) {
  if (err instanceof ReziiixAuthError) {
    // 401/403 — API key is invalid, expired, or revoked
    console.error('Auth failed:', err.message);
  }
  if (err instanceof ReziiixApiError) {
    // Server returned an error (5xx, 4xx)
    console.error(`API error (${err.status}):`, err.message);
  }
  if (err instanceof ReziiixValidationError) {
    // Client-side validation failed (missing required fields)
    console.error('Validation:', err.message);
  }
  if (err instanceof ReziiixTimeoutError) {
    // Request exceeded the configured timeout
    console.error('Timeout:', err.message);
  }
}

All errors extend ReziiixError which has:

  • message — human-readable description
  • code — machine-readable code (AUTH_ERROR, API_ERROR, VALIDATION_ERROR, TIMEOUT_ERROR)
  • status — HTTP status code (when applicable)

API Key Scopes

| Scope | Permission | |---|---| | scan | Call the scan endpoint | | orchestrate | Full pipeline orchestration | | admin | Key management + policy access |

Create API keys in the Developer Hub at https://reziiix.com/developers (admin role required).

Requirements

  • Node.js 18+ (uses native fetch)
  • TypeScript 5+ (optional — JS works too)

License

MIT — REZIIIX PTE LTD