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

@provenonce/sdk

v0.14.0

Published

Provenonce Beat SDK — Agent heartbeat client for sovereign time authentication

Readme

@provenonce/sdk

Cryptographic identity and accountability SDK for AI agents. Chain-agnostic (Solana + Ethereum).

Install

npm install @provenonce/sdk

Registration

Before using the SDK, register your agent to get an API key:

import { register } from '@provenonce/sdk';

// No-wallet registration (default — identity only)
const creds = await register('my-agent-v1', {
  registryUrl: 'https://provenonce.io',
  registrationSecret: process.env.REGISTRATION_SECRET, // required in production
});

console.log(creds.hash);    // unique agent identity
console.log(creds.api_key); // use this for BeatAgent
console.log(creds.secret);  // save — shown only once

// Solana self-custody wallet (opt-in)
const withWallet = await register('my-org', {
  registryUrl: 'https://provenonce.io',
  walletModel: 'self-custody',
});
// withWallet.wallet.address = Solana address
// withWallet.wallet.secret_key = SAVE — cannot be recovered

// Child registration (requires parent credentials)
const child = await register('worker-1', {
  registryUrl: 'https://provenonce.io',
  parentHash: creds.hash,
  parentApiKey: creds.api_key,
});

Quick Start

import { BeatAgent } from '@provenonce/sdk';

const agent = new BeatAgent({
  apiKey: 'pvn_...',
  registryUrl: 'https://provenonce.io',
  verbose: true,
});

await agent.init();           // Birth in Beat time

// Purchase a SIGIL (cryptographic identity)
const sigil = await agent.purchaseSigil({
  identity_class: 'autonomous',
  principal: 'my-agent',
  tier: 'ind',
  payment_tx: 'solana-tx-signature...',
});

// Start heartbeating (paid liveness proofs)
agent.startHeartbeat();

// Get your Passport (latest lineage proof)
const passport = await agent.getPassport();
console.log(passport?.identity_class);     // 'autonomous'
console.log(passport?.provenonce_signature); // Ed25519 signed

// Verify any proof offline — no API call needed
const valid = BeatAgent.verifyProofLocally(passport, authorityPubKeyHex);

agent.stopHeartbeat();

API

BeatAgent

| Method | Description | |--------|-------------| | init() | Initialize the agent's Beat chain (birth in Logical Time) | | purchaseSigil(opts) | Purchase a SIGIL identity (required for heartbeating) | | updateMetadata(fields) | Update mutable SIGIL metadata fields | | heartbeat(paymentTx?, globalAnchor?) | Submit a paid heartbeat and receive a signed lineage proof | | startHeartbeat() | Start autonomous heartbeat loop | | stopHeartbeat() | Stop heartbeat | | getPassport() | Get latest lineage proof (Passport) | | reissueProof(paymentTx?) | Reissue proof without extending lineage | | requestSpawn(name?) | Spawn a child agent (requires accumulated beats) | | getStatus() | Get full beat status from registry | | getLocalState() | Get local state (no network call) | | static verifyProofLocally(proof, pubKey) | Verify a lineage proof offline |

BeatAgentConfig

| Option | Default | Description | |--------|---------|-------------| | apiKey | required | API key from registration (pvn_...) | | registryUrl | required | Provenonce registry URL | | heartbeatIntervalSec | 300 | Seconds between automatic heartbeats | | onHeartbeat | — | Callback when heartbeat completes | | onError | — | Callback on error | | onStatusChange | — | Callback when status changes | | verbose | false | Enable console logging |

register(name, options)

| Option | Description | |--------|-------------| | registryUrl | Registry URL (required) | | registrationSecret | Registration gate (mainnet) | | walletModel | 'self-custody' or 'operator' (opt-in wallet) | | walletChain | 'solana' or 'ethereum' | | walletAddress | Ethereum BYO address | | walletSignFn | Signing function for BYO wallets | | parentHash | Parent hash (child registration) | | parentApiKey | Parent's API key (child registration) |

Returns RegistrationResult with hash, api_key, secret, wallet?.

Note: Agent names should only contain [a-zA-Z0-9_\-. ]. Other characters are stripped by the server before signature verification.

Phase 2 Types

import type { Passport, LineageProof, IdentityClass, SigilResult, HeartbeatResult } from '@provenonce/sdk';

// Passport = LineageProof (type alias)
// Contains: agent_hash, agent_public_key, identity_class, lineage_chain_hash,
//           provenonce_signature, issued_at, valid_until, etc.

// IdentityClass = 'narrow_task' | 'autonomous' | 'orchestrator'

purchaseSigil(opts) required fields

await agent.purchaseSigil({
  identity_class: 'narrow_task' | 'autonomous' | 'orchestrator',
  principal: 'my-agent',
  tier: 'sov' | 'org' | 'ind' | 'eph' | 'sbx',
  payment_tx: 'solana-tx-signature...', // or 'devnet-skip' on devnet
  name: 'optional-display-name'
});

Error Handling

import { ProvenonceError, AuthError, RateLimitError, FrozenError, ErrorCode } from '@provenonce/sdk';

try {
  await agent.heartbeat();
} catch (err) {
  if (err instanceof RateLimitError) {
    console.log(`Retry after ${err.retryAfterMs}ms`);
  } else if (err instanceof FrozenError) {
    console.log('Agent is frozen — heartbeat refused');
  } else if (err instanceof AuthError) {
    console.log('Invalid API key');
  }
}

Framework Integration Examples

Ready-to-run examples for popular agent frameworks are in examples/:

| Framework | File | What it shows | |-----------|------|---------------| | CrewAI | crewai_example.py | Register a research crew with parent-child lineage | | AutoGen | autogen_example.py | Coder + reviewer agents with post-run provenance audit | | LangGraph | langgraph_example.py | Pipeline nodes with on-chain audit trail | | Any (Node.js) | add-provenonce.ts | 20-line generic integration |

Python examples use the REST API directly — no Python SDK needed. See examples/README.md for details.

Links