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

@terra-protocol/oamp-sdk

v1.0.0

Published

Open Agent Mandate Protocol (OAMP v1.0) — Cryptographic Agent Identity, Multi-Hop Delegation, Section 8.14 Contagion Clause, and MCP/x402/LangChain/CrewAI Middleware SDK

Readme

@terra-protocol/oamp-sdk — Open Agent Mandate Protocol (OAMP v1.0)

The Cryptographic Birth Certificate, Multi-Hop Delegation, and Liability Attribution SDK for Autonomous AI Agents.

Built by TERRA (EyeTea Solutions ApS / TERRA ApS) — The Global Agent Trust, Liability, State Verification, and Physical Reality Layer for Autonomous AI.


Features

  • Zero External Dependencies (< 2ms p99 Sign + Verify, < 0.02ms Cached Verify): Built on native Ed25519 (RFC 8032), W3C did:key (0xed01 Base58BTC) & did:ion, Canonical JSON-LD (RFC 8785), and Jacobian ECDSA secp256k1.
  • Multi-Hop Sub-Agent Delegation: Cryptographic inheritance chains (Primary Agent -> Sub-Agent -> Worker) enforcing cumulative spend decay (authorityDecayFactor), tool scope subsetting, and maximum cascade depth (Rule B).
  • Mandatory 7-Header TERRA Protocol & Section 8.14 ("The Contagion Clause") Suite:
    • X-Terra-Mandate: Ed25519-signed JSON-LD capability & budget mandate
    • X-Terra-Principal: Root legal entity did:key URI
    • X-Terra-Prompt-Hash: Immutable SHA-256 digest of { baseModelId, systemPrompt, activeTools, triggeringContext } (Rule A Hash Drift protection)
    • X-Terra-Liability-Proof: Base64 MGA insurance policy & escrow reservation proof
    • X-TERRA-OAMP-MANDATE-ID: UUIDv4 Mandate Identifier
    • X-TERRA-OAMP-PROOF-HASH: Ed25519 signature binding mandateId:promptHash
    • X-TERRA-OAMP-ESCROW-SIG: ECDSA secp256k1 signature binding mandateId:escrowReservationId:maxPerCallUsd
  • Drop-In Framework Middleware:
    • Model Context Protocol (MCP): wrapMcpToolCall, verifyMcpToolCall
    • HTTP x402 Payment Rail (15 bps MGA Micro-Policy): createX402PaymentHeaders, verifyX402PaymentHeaders
    • LangChain (LCEL): withTerraLcelRunnable
    • CrewAI: executeCrewAiGuardedTask

Quick Start

npm install @terra-protocol/oamp-sdk
import {
  generateEd25519KeyPair,
  generateSecp256k1KeyPair,
  createMandate,
  buildTerraHeaders,
  verifyTerraHeaders,
} from "@terra-protocol/oamp-sdk";

const principal = generateEd25519KeyPair();
const agent = generateEd25519KeyPair();
const escrow = generateSecp256k1KeyPair();

const mandate = createMandate({
  principalDid: principal.didKey,
  agentDid: agent.didKey,
  signerPrivateKeyHex: principal.privateKeyHex,
  jurisdiction: "EU-DK",
  allowedTools: ["stripe.create_payment", "logistics.book_freight"],
  maxPerCallUsd: 25_000,
  dailyCapUsd: 100_000,
});

const headers = buildTerraHeaders({
  mandate,
  agentPrivateKeyHex: agent.privateKeyHex,
  promptContext: {
    baseModelId: "gemini-4-argon-high",
    systemPrompt: "Insured enterprise procurement agent.",
    activeTools: mandate.allowedTools,
    triggeringContext: "Book container #881 for $12,000",
  },
  escrowPrivateKeyPem: escrow.privateKeyPem,
  escrowPublicKeyPem: escrow.publicKeyPem,
});

const verified = verifyTerraHeaders(headers, {
  requestedTool: "logistics.book_freight",
  requestedSpendUsd: 12_000,
});
console.log(verified.valid); // true

License

Apache-2.0 — Copyright (c) 2026 EyeTea Solutions ApS (binavn: TERRA ApS).