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

@codespar/hermes

v0.4.0

Published

Hermes Agent adapter for CodeSpar — convert session tools to Hermes MCP/plugin tool format

Readme

@codespar/hermes

Hermes Agent (Nous Research) adapter for CodeSpar — convert session tools to Hermes's MCP/plugin tool format.

Hermes agents ship with a Privy-secured embedded wallet and credit billing but no commerce rail. This adapter gives them LATAM commerce (pay / charge / invoice / ship / notify) routed through a CodeSpar session for billing and audit.

Install

npm install @codespar/hermes @codespar/sdk

Usage

import { CodeSpar } from "@codespar/sdk";
import { getTools } from "@codespar/hermes";

const cs = new CodeSpar({ apiKey: process.env.CODESPAR_API_KEY! });
const session = await cs.create("user_123", { preset: "brazilian" });
const tools = await getTools(session);

// Register the tools with your Hermes plugin / MCP bridge.
for (const tool of tools) {
  plugin.registerTool(tool);
}

Tool shape

Each HermesTool mirrors the MCP tool spec — the format Hermes uses to ingest external tools via plugins and MCP servers:

| Field | Type | Description | |-------|------|-------------| | name | string | Tool name (e.g. codespar_pay) | | description | string | Human/agent-readable description | | inputSchema | Record<string, unknown> | JSON Schema for the tool's arguments | | call | (input) => Promise<string> | Async invoke; routes through session.execute and returns the serialized result |

We chose the MCP-aligned shape (name / description / inputSchema + async call returning a string) over a Hermes-proprietary plugin shape because Hermes ingests external tools primarily through MCP servers, so this is the most portable contract.

API

| Function | Description | |----------|-------------| | getTools | Convert all session tools to Hermes format | | toHermesTool | Convert a single tool | | handleToolCall | Execute a tool call via the session |

Connect via MCP server (no npm install)

Because Hermes natively connects MCP servers, you can also expose CodeSpar's commerce tools to a Hermes agent without installing this package — point Hermes at the session's MCP endpoint:

import { CodeSpar } from "@codespar/sdk";
import { getMcpConfig } from "@codespar/mcp";

const cs = new CodeSpar({ apiKey: process.env.CODESPAR_API_KEY! });
const session = await cs.create("user_123", { preset: "brazilian" });

const { url, headers } = getMcpConfig(session);
// Add this URL + headers as an MCP server in your Hermes config.

Add the resulting url (with auth headers) as an MCP server in Hermes (~/.hermes/ config / MCP servers section). Use this adapter package when you want in-process tool objects; use the MCP-server path when you want the paste-URL, zero-dependency integration.

Need more?

Need governance, budget limits, and audit trails for agent payments? CodeSpar Enterprise adds policy engine, payment routing, and compliance templates on top of these MCP servers.

License

MIT — codespar.dev