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

pi-agentation

v0.1.0

Published

Pi extension that receives Agentation webhooks and turns them into queued user messages

Readme

pi-agentation

A Pi extension that receives Agentation webhook payloads and turns them into real Pi user messages.

Please note: this is a very early version. Pi did most of the coding.

What it does

  • starts a small local webhook server inside Pi
  • accepts Agentation submit webhook payloads
  • also accepts Agentation MCP-style action payloads with output
  • forwards the formatted prompt into Pi with pi.sendUserMessage(...)
  • uses deliverAs: "followUp" while Pi is busy

Install

From npm

pi install npm:pi-agentation

From git

pi install git:github.com/denniseijpe/pi-agentation

Usage

Start the listener manually inside Pi:

/agentation-start

Or provide a custom port:

/agentation-start 8080

Stop it when you are done:

/agentation-stop

Configuration in your app

Environment variables:

  • PI_AGENTATION_HOST default: 127.0.0.1
  • PI_AGENTATION_PORT default: 4761
  • PI_AGENTATION_PATH default: /agentation
  • PI_AGENTATION_TOKEN optional shared token passed as ?token=...

Example:

PI_AGENTATION_PORT=4761 pi

Or using mise.toml

If you use mise, add this to your project's mise.toml:

[env]
PI_AGENTATION_PORT = "4761"
PI_AGENTATION_TOKEN = "your-secret-token"

This allows you to have seperate ports for different projects.

Agentation setup

Install the agentation package from npm.

Point Agentation at:

http://127.0.0.1:4761/agentation

If you enable a token (recommended):

http://127.0.0.1:4761/agentation?token=your-secret-token

Example React usage (SPA):

import { Agentation } from "agentation";

if (process.env.NODE_ENV === "development") {
	localStorage.setItem(
		"feedback-toolbar-settings",
		JSON.stringify({
			...JSON.parse(localStorage.getItem("feedback-toolbar-settings") ?? "{}"),
			webhooksEnabled: false,
			autoClearAfterCopy: true,
		}),
	);
}

export function App() {
  return (
    <>
      {/* your app */}
      <Agentation webhookUrl="http://127.0.0.1:4761/agentation?token=your-secret-token" />
    </>
  );
}

Example React usage (SSR / Next.js):

import { useEffect } from "react";
import { Agentation } from "agentation";

function useAgentationSettings() {
  useEffect(() => {
    if (typeof window === "undefined") {
      return;
    }
    if (process.env.NODE_ENV === "development")  {
      const raw = localStorage.getItem("feedback-toolbar-settings");
      const saved = raw ? JSON.parse(raw) : {};
      localStorage.setItem(
        "feedback-toolbar-settings",
        JSON.stringify({
          ...saved,
          webhooksEnabled: false,
          autoClearAfterCopy: true,
        }),
      );
    }
  }, []);
}

export function App() {
  useAgentationSettings();

  return (
    <>
      {/* your app */}
      <Agentation webhookUrl="http://127.0.0.1:4761/agentation?token=your-secret-token" />
    </>
  );
}

Behavior

  • If Pi is idle, the Agentation message is sent immediately.
  • If Pi is busy, the message is queued with Pi's follow-up queue.
  • Duplicate webhook submissions are ignored for a short dedupe window.

Commands

| Command | Description | |---------|-------------| | /agentation-start [port] | Start the webhook listener (optional port) | | /agentation-stop | Stop the webhook listener | | /agentation-status | Show current listener status |

Notes

  • The server does not auto-start; run /agentation-start after loading Pi.
  • The server binds to localhost by default.
  • annotation.add and other non-submit toolbar events are ignored on purpose.
  • This extension is focused on getting Agentation prompts into Pi, not on syncing replies back.
  • If you switch or fork sessions, the listener stops with the old session. Re-run /agentation-start in the new session.