New:Socket for Asana Is Now Available.Learn more
Sign In

@trigguard/protocol

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@trigguard/protocol

Shared TypeScript types and JSON contract snapshots for TrigGuard authorization decisions and records.

Source
npmnpm
Version
0.1.2
Version published
Weekly downloads
211
4120%
Maintainers
1
Weekly downloads
 
Created
Source

TrigGuard Protocol

npm version

Canonical protocol definitions for TrigGuard governance decisions: vocabulary (PERMIT, DENY, SILENCE), enforcement semantics, and the DecisionRecord shape used across products and tooling.

Package name: @trigguard/protocol — types and contract snapshots; runtime evaluation and policy engines live in other packages and services. Integrations conform to this contract.

Install

npm install @trigguard/protocol

Published on the public registry under the @trigguard scope. For release process, see docs/release/PROTOCOL_RELEASE.md in the monorepo.

Develop inside the repo (no registry), use a path or workspace:

"@trigguard/protocol": "file:../packages/protocol"

or install from a Git URL / workspace as documented in the main TrigGuard repository.

Decision model

DecisionMeaning (high level)
PERMITAuthorization to proceed under policy (subject to enforcement and deployment rules).
DENYAction must not proceed as requested.
SILENCENo authorization was issued; without authorization, execution cannot proceed (see SILENCE_DEFINITION export).

Policy-only layers may restrict emitted decisions to PERMIT / DENY; full protocol surfaces also use SILENCE where applicable.

Example import (TypeScript)

import {
  type Decision,
  type DecisionRecord,
  DECISION,
  DECISIONS,
  SILENCE_DEFINITION,
} from "@trigguard/protocol";

const d: Decision = "PERMIT";
const record: DecisionRecord = {
  decision: DECISION.PERMIT,
  enforcement: "EXECUTED",
  reason_code: "NO_POLICY_VIOLATION",
  timestamp: new Date().toISOString(),
};

There is no evaluate() in this package — evaluation lives in TrigGuard services and kernels. This package supplies types and canonical constants so callers and SDKs share one contract.

Subpath exports (JSON)

The package exposes stable paths for the JSON schema and decision contract snapshot:

const schema = require("@trigguard/protocol/schema");
const contract = require("@trigguard/protocol/contract");

Build (maintainers / CI)

From packages/protocol:

npm install
npm run build

build runs sync-contract (when the full monorepo is present), tsc, and asset copy into dist/. Published tarballs are built via prepack / prepare before npm publish.

Repository

Canonical source: github.com/TrigGuard-AI/TrigGuardpackages/protocol/.

For installation paths and release tagging, see:

  • docs/developers/INSTALL_PROTOCOL.md
  • docs/release/PROTOCOL_RELEASE.md

Legacy note (snapshot)

src/contracts/decision_contract.json is kept in sync with core/contracts/decision_contract.json via npm run sync-contract in the monorepo. Do not edit kernel contracts from this README — follow governance and protocol integrity processes in the main repo.

Keywords

trigguard

FAQs

Package last updated on 20 Mar 2026

Related posts