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

hypnex-registry

v0.3.0

Published

TypeScript SDK for the Hypnex agent registry — proposed MRC 58 implementation for the Morpheus AI network.

Downloads

352

Readme

hypnex-registry (TypeScript)

TypeScript SDK for the Hypnex agent registry — proposed MRC 58 implementation for the Morpheus AI network.

npm install hypnex-registry

Affiliation & monetization

This SDK is published by Hypnex Labs and is monetized via the v2 registry's register() fee. Each registration costs 1 MOR (configurable on-chain by the claim-admin) and is forwarded directly to the Hypnex Labs treasury at 0x22B5C0075372E743042b2d62b3D254425Eb957D8 inside the same registration tx. The SDK auto-approves the MOR allowance for you on first use. Hypnex is not affiliated with the Morpheus AI Foundation.

Status

Two contract versions are deployed on Arbitrum + Base mainnet:

| Version | Arbitrum | Base | Notes | |---|---|---|---| | v2 (default) — paid registry | 0x5563Be0a302885eE3e454be42DC12c177DA3625B | 0x191630a3d190B6f67cC7fB1325aD97D2CeB82697 | 1 MOR fee per register() | | v1 (deprecated) — fee-free reference | 0xCC258a7BBF361fd824e87D4b3C0D394De6Fd454F | 0xd4D014De1e0D6287BeeD39CD6de99E3A73645ca4 | MRC 58 reference impl |

By default new Registry({ chain: "arbitrum" }) connects to v2. Pass version: "v1" to read the legacy registry instead.

| Chain | Address | Verified source | |---|---|---| | Arbitrum One | 0xCC258a7BBF361fd824e87D4b3C0D394De6Fd454F | Arbiscan ↗ | | Base mainnet | 0xd4D014De1e0D6287BeeD39CD6de99E3A73645ca4 | BaseScan ↗ |

Reference Solidity: registry-contracts/contracts/HypnexAgentRegistry.sol Deploy record: registry-contracts/DEPLOYMENT.md Spec: docs/MRC-58-DRAFT.md

Quickstart

Pure helpers (no RPC)

import { agentId, capabilityTag, modelIdFor } from "hypnex-registry";

agentId("hypnex", "summarizer");   // bytes32
capabilityTag("chat");             // bytes32
modelIdFor("glm-5");               // bytes32

These match the Solidity contract's encoding exactly.

Read

import { Registry } from "hypnex-registry";

const r = await Registry.fromFallbacks({
  address: "0xYourTestnetDeployment",
  chain: "base",
});

const total = await r.totalAgents();
const ids = await r.listAgents(0n, 50n);
for (const id of ids) {
  const agent = await r.getAgent(id);
  console.log(`${agent.namespace}/${agent.name}`);
}

Write (signer required)

import { Registry } from "hypnex-registry";

const r = Registry.withPrivateKey(process.env.PRIVATE_KEY as `0x${string}`, {
  address: "0xYourTestnetDeployment",
  chain: "base",
});

const tx = await r.register({
  namespace: "hypnex",
  name: "summarizer",
  metadataURI: "ipfs://Qm...",
  capabilities: ["chat", "summarize"],   // auto-keccak'd
  pricePerCallWei: 100_000_000_000_000n, // 0.0001 MOR
  modelId: "glm-5",                       // auto-keccak'd
});

Discovery by capability

const ids = await r.agentsWithCapability("chat");
const agents = await Promise.all(ids.map((id) => r.getAgent(id)));
const active = agents.filter((a) => a.isActive);

Public API

new Registry({ address?, chain?, rpcUrl?, publicClient?, walletClient? })

// static factories
Registry.fromFallbacks(opts)
Registry.withPrivateKey(pk, opts)
Registry.fromEnv(opts)

// read
.agentIdOf(namespace, name)
.isRegistered(agentId)
.totalAgents()
.listAgents(offset, limit)
.agentsOf(owner)
.agentsWithCapability(capability)
.getAgent(agentId)

// write (require walletClient)
.register({ namespace, name, metadataURI, capabilities, pricePerCallWei?, modelId? })
.updateMetadata({ agentId, metadataURI, pricePerCallWei, modelId })
.setCapabilities(agentId, capabilities)
.deactivate(agentId)
.reactivate(agentId)
.transferOwnership(agentId, newOwner)

// pure helpers
agentId(namespace, name)
capabilityTag(label)
modelIdFor(modelName)

Environment variables

  • HYPNEX_REGISTRY_ADDRESS — registry contract address
  • HYPNEX_REGISTRY_CHAINbase | arbitrum | ethereum | base-sepolia (default: base)
  • HYPNEX_REGISTRY_RPC_URL — override RPC
  • PRIVATE_KEY — for writes only

Tests

npm install
npm test                # off-chain helper tests

License

MIT