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

@alfe.ai/gateway

v0.0.5

Published

Alfe local gateway daemon — persistent control plane for agent integrations

Readme

@alfe.ai/gateway

Local gateway daemon for Alfe — the always-on control plane for agent integrations.

Overview

The gateway daemon is a standalone Node.js process that:

  • Maintains a persistent WebSocket connection to Alfe cloud (@alfe/gateway-service on Fly.io)
  • Exposes a Unix socket at ~/.alfe/gateway.sock for local plugin IPC
  • Translates between the cloud protocol and local IPC protocol
  • Survives OpenClaw restarts — it's the always-on bridge between cloud and agent
  • Queues commands when plugins are offline (5min TTL)

Architecture

Alfe Cloud ←—— control WS ——→ @alfe.ai/gateway  (daemon, always running)
                                     ↕  IPC (~/.alfe/gateway.sock)
                              @alfe.ai/openclaw    (OpenClaw plugin, Phase 2)
                                     ↕
                                OpenClaw process

Prerequisites

  1. Run alfe login to configure your API key in ~/.alfe/config.toml
  2. Node.js 22+
  3. pnpm

Usage

Via alfe CLI (recommended)

# Start daemon (foreground)
alfe gateway start

# Check status
alfe gateway status

# Stop daemon
alfe gateway stop

# Install as system service (auto-start on boot)
alfe gateway install

# Remove system service
alfe gateway uninstall

# View logs
alfe gateway logs

# Full health check
alfe doctor

Via standalone binary

# Start daemon
alfe-gateway daemon

# Status
alfe-gateway status

# Stop
alfe-gateway stop

IPC Protocol

Plugins connect to ~/.alfe/gateway.sock and speak newline-delimited JSON:

Request (plugin → daemon)

{ "type": "req", "id": "uuid", "method": "register", "params": { "name": "my-plugin", "version": "1.0.0", "protocolVersion": 1, "capabilities": ["integrations"] } }

Response (daemon → plugin)

{ "id": "uuid", "ok": true, "payload": { "status": "registered", "daemonVersion": "0.1.0", "protocolVersion": 1 } }

Event (daemon → plugin)

{ "type": "event", "event": "cloud.status", "payload": { "connected": true } }

Phase 1 Methods

| Direction | Method | Description | |-----------|--------|-------------| | Daemon→Plugin | integration.install | Install an integration | | Daemon→Plugin | integration.remove | Remove an integration | | Daemon→Plugin | integration.configure | Update integration config | | Daemon→Plugin | integration.health | Check integration health | | Daemon→Plugin | integration.activate | Activate an installed integration | | Daemon→Plugin | integration.deactivate | Deactivate a running integration | | Daemon→Plugin | integration.list | List installed integrations | | Plugin→Daemon | register | Register plugin with daemon | | Plugin→Daemon | status | Get daemon health status | | Plugin→Daemon | integration.list | List known integrations | | Plugin→Daemon | integration.report | Report integration status |

File Locations

| File | Path | |------|------| | Config | ~/.alfe/config.toml | | Socket | ~/.alfe/gateway.sock | | PID file | ~/.alfe/gateway.pid | | Logs | ~/.alfe/logs/gateway.log | | launchd plist | ~/Library/LaunchAgents/ai.alfe.gateway.plist | | systemd unit | ~/.config/systemd/user/alfe-gateway.service |

Security

  • Socket file is chmod 0600 (owner-only access)
  • PID file prevents multiple daemon instances
  • Secrets pass through in-memory only — never persisted to disk
  • Auth via user's api_key from ~/.alfe/config.toml

Development

# From monorepo root
pnpm install
pnpm --filter @alfe.ai/gateway build
pnpm --filter @alfe.ai/gateway test

# Dev mode (auto-restart on changes)
pnpm --filter @alfe.ai/gateway dev

Cloud Protocol

The daemon speaks the following message types with the cloud gateway service:

| Direction | Message | Description | |-----------|---------|-------------| | Outbound | SERVICE_REGISTER | Register daemon with cloud | | Inbound | SERVICE_ACK | Cloud acknowledges registration | | Inbound | COMMAND | Cloud sends a command to execute | | Outbound | COMMAND_ACK | Daemon reports command result | | Inbound | DESIRED_STATE | Cloud pushes desired integration state | | Outbound | RECONCILIATION_REPORT | Daemon reports reconciliation results | | Inbound | PING | Cloud heartbeat | | Outbound | PONG | Daemon heartbeat response |

See src/protocol.ts for full type definitions.

Completed

  • @alfe.ai/openclaw plugin connecting via IPC (packages/openclaw/)
  • Integration manifest spec (packages/integration-manifest/)
  • Integration registry — now DynamoDB-backed via services/integrations/
  • Reconciliation engine (src/reconciliation.ts) — converges local state to cloud desired state

Roadmap

  • Dashboard integration management (backend wired, UI in progress)
  • Voice migration to integration model (packages/openclaw-voice/ exists, not yet full integration)