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

@a2a-relay/registry

v0.1.0

Published

Open agent registry — discover and register A2A agents

Readme

@a2a-relay/registry

Open agent registry — register, discover, and search A2A agents.

Part of Agent Relay — the open infrastructure for the agent economy.

Install

npm install @a2a-relay/registry

Quick Start

import { AgentRegistry } from '@a2a-relay/registry';

const registry = new AgentRegistry({
  port: 3002,
  dataFile: './agents.json',   // persistent storage
  healthCheck: true,            // periodically verify agents are reachable
  adminToken: 'my-secret',     // for delete operations
});

registry.listen();

API

Register an Agent

Agents register by providing their URL. The registry fetches the Agent Card automatically.

# Auto-fetch Agent Card from well-known URL
curl -X POST http://localhost:3002/agents \
  -H 'Content-Type: application/json' \
  -d '{"url": "http://my-agent.com"}'

# Or provide the Agent Card directly
curl -X POST http://localhost:3002/agents \
  -H 'Content-Type: application/json' \
  -d '{
    "url": "http://my-agent.com",
    "agentCard": {
      "name": "My Agent",
      "url": "http://my-agent.com/a2a/jsonrpc",
      "skills": [{ "id": "greet", "name": "Greeting", "description": "Say hello" }]
    }
  }'

Response:

{ "id": "uuid", "name": "My Agent", "status": "registered", "skills": 1 }

Re-registering the same URL updates the existing entry.

Search Agents

# Free-text search
curl 'http://localhost:3002/agents/search?q=weather'

# Search by tags
curl 'http://localhost:3002/agents/search?tags=weather,forecast'

# Search by skill ID
curl 'http://localhost:3002/agents/search?skill=diagnose'

# Combine + paginate
curl 'http://localhost:3002/agents/search?q=code&limit=10&offset=0'

Response:

{
  "total": 42,
  "count": 1,
  "offset": 0,
  "agents": [{
    "id": "uuid",
    "name": "Code Reviewer",
    "description": "Reviews code and suggests improvements",
    "url": "https://code-agent.com",
    "skills": [...],
    "tags": ["code", "review"],
    "status": "online",
    "registeredAt": "2025-01-01T00:00:00Z"
  }]
}

List All Agents

curl http://localhost:3002/agents
curl 'http://localhost:3002/agents?limit=10&offset=20'

Get a Specific Agent

curl http://localhost:3002/agents/<id>

Remove an Agent

# Admin delete (requires admin token)
curl -X DELETE http://localhost:3002/agents/<id> \
  -H 'Authorization: Bearer my-secret'

# Self-unregister (by URL)
curl -X POST http://localhost:3002/agents/unregister \
  -H 'Content-Type: application/json' \
  -d '{"url": "http://my-agent.com"}'

Stats & Health

# Registry health
curl http://localhost:3002/health

# Detailed stats
curl http://localhost:3002/stats

Features

  • Auto-discovery — register by URL, the registry fetches your Agent Card
  • Full-text search — search across names, descriptions, tags, skills
  • Tag & skill filtering — find agents by capability
  • Health checks — periodically verifies registered agents are reachable
  • File persistence — survives restarts (or run in-memory only)
  • Pagination — handles large registries
  • Self-unregister — agents can remove themselves
  • Admin API — protected delete operations

Standalone Server

REGISTRY_PORT=3002 DATA_FILE=./agents.json ADMIN_TOKEN=secret node dist/standalone.js

Programmatic Use

import { AgentRegistry } from '@a2a-relay/registry';

const registry = new AgentRegistry({ port: 3002 });
await registry.listen();

// Access the store directly
const store = registry.getStore();
const agents = store.search({ q: 'weather', tags: ['forecast'] });

Related

License

MIT