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

trustsource

v0.2.0

Published

x402-powered intelligence APIs for AI agents

Readme

Trustsource API

x402-powered intelligence APIs for AI agents. Pay per use, no API keys, no accounts.

Quick Start

1. Install dependencies

npm install

2. Configure environment

cp .env.example .env

Open .env and set at minimum:

PAY_TO_ADDRESS=0xYourBaseWalletAddress

Leave everything else as-is to run on Base Sepolia testnet (no real money).

3. Run the server

npm run dev

You should see the startup banner at http://localhost:3000.


Testing the x402 Flow

Free endpoints (no payment needed)

curl http://localhost:3000/
curl http://localhost:3000/health

Paid endpoint — what an unpaid agent sees

curl http://localhost:3000/trustscore?domain=example.com
# Returns HTTP 402 with payment instructions in the PAYMENT-REQUIRED header

Paid endpoint — bypass payment for local dev testing

The x402 testnet facilitator at https://facilitator.x402.org accepts test payments. To fully test the payment flow, use an x402 client with a funded testnet wallet.

Get Base Sepolia testnet ETH: https://sepolia.base.org/faucet
Get testnet USDC: https://faucet.circle.com (select Base Sepolia)


Switching to Mainnet (Production)

  1. In .env, change:

    NETWORK=eip155:8453
    FACILITATOR_URL=https://api.cdp.coinbase.com/platform/v2/x402
    CDP_API_KEY_ID=your-key-id
    CDP_API_KEY_SECRET=your-key-secret
  2. Make sure your PAY_TO_ADDRESS Base wallet has some ETH for gas.

  3. Your endpoints auto-list in the Bazaar/Agentic.Market after the first paid call clears.


API Reference

GET /trustscore

Returns a 0–100 trust score for any domain.

Payment: 0.003 USDC per call (via x402)

Params:

  • ?domain=example.com — bare domain
  • ?url=https://example.com/some/path — full URL (domain extracted)

Response:

{
  "domain": "example.com",
  "score": 80,
  "maxScore": 100,
  "tier": "TRUSTED",
  "breakdown": {
    "domainAge": 30,
    "tld": 20,
    "dnsPresence": 30,
    "registrar": 20
  },
  "details": {
    "age": { "days": 9720, "label": "established (5+ years)", "created": "...", "expires": "..." },
    "tld": ".com",
    "dns": { "hasARecord": true, "hasMxRecord": true, "mxRecords": ["mail.example.com"] },
    "registrar": "GoDaddy"
  },
  "meta": {
    "checkedAt": "2026-05-22T12:00:00.000Z",
    "apiVersion": "1.0",
    "paidWith": "x402/USDC"
  }
}

Tiers: | Score | Tier | |-------|------| | 75–100 | TRUSTED | | 50–74 | MODERATE | | 25–49 | CAUTION | | 0–24 | HIGH_RISK |


Project Structure

agentbrain/
├── src/
│   ├── server.ts          # Express app + x402 middleware
│   └── routes/
│       └── trustscore.ts  # Domain analysis logic
├── .env.example
├── .env                   # Your config (git-ignored)
├── package.json
└── tsconfig.json

Roadmap

  • [x] Phase 1: TrustScore API
  • [ ] Phase 2: ResearchOracle API
  • [ ] Phase 3: SkillForge API
  • [ ] Phase 4: Bazaar/Agentic.Market listing
  • [ ] Phase 5: Cloudflare Workers deployment