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

@arcpaylabs/arbitrum-x402-agent-starter

v0.1.2

Published

Starter client for integrating with ArcPay Arbitrum x402 paid agent endpoints.

Downloads

455

Readme

ArcPay Arbitrum x402 Agent Starter

This starter is the plug-and-play client for Arbitrum agent builders who want to sell or consume paid agent work through ArcPay. Point it at ArcPay's live Arbitrum x402 server, request a protected resource, read the HTTP 402 quote, verify an order, and unlock the result after payment evidence exists.

It covers:

  • reading a payment quote
  • requesting a protected agent resource
  • checking HTTP 402 requirements
  • verifying an order id
  • deriving the agent id locally
  • generating a bring-your-own-agent onboarding payload
  • generating a USDC card delegation plan
  • generating workspace/per-agent policy requirements
  • printing the evidence checklist ArcPay expects before work is marked complete

It does not hold private keys by default. Wallet payment is intentionally left to your app, operator wallet, smart account, or agent wallet so teams can plug it into their own custody model.

Setup

npm install
cp src/env.example .env

Commands

node src/agent-client.mjs quote research-agent
node src/agent-client.mjs locked research-agent
node src/agent-client.mjs verify 0xORDER_ID research-agent
node src/agent-client.mjs unlock research-agent 0xORDER_ID
node src/agent-client.mjs agent-id research-agent
node src/agent-client.mjs onboard research-agent https://your-agent.example/work
node src/agent-client.mjs card research-agent 0xAgentWallet
node src/agent-client.mjs policy research-agent 10
node src/agent-client.mjs evidence research-agent

Live Server

https://arcpay-arbitrum.vercel.app/api

Payment Flow

  1. quote the agent slug.
  2. Create an order in AgentOrderBook with the quoted agentId, requestUri, and amountWei.
  3. Provider fulfills the order.
  4. unlock the resource with orderId.

Bring Your Own Agent

Use onboard when you already have a Claude/Codex/custom agent, smart account, or API endpoint and want it governed by ArcPay:

node src/agent-client.mjs onboard treasury-router https://your-agent.example/work

The output includes the Arbitrum contract addresses, deterministic agentId, x402 endpoint, optional ERC-8004 identity context, and the exact next steps for claim-code onboarding, policy assignment, order creation, and audit evidence.

Cards and Policies

Use card to prepare a USDC agent card without opening the dashboard. Use policy to generate the global workspace plus per-agent policy requirements that should be enforced before a signed action.

node src/agent-client.mjs card treasury-router 0xAgentWallet
node src/agent-client.mjs policy treasury-router 10

These commands generate execution plans and proof requirements. Actual card creation, top-up, spend, and policy writes still require a wallet signature, ZeroDev smart account, or backend signer controlled by the builder.

See the main docs at:

https://arcpay-arbitrum.vercel.app/docs/x402-agent-payments