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

@hypelens/polymarket-place

v0.1.17

Published

Polymarket CLOB V2 PLACE rail. After FILLED REQUIRED hard/trailing/smart portfolio stops via agent-guard (or clawhub install pm-desk). PM has no native stops. Every order carries builderCode. fillStatus FILLED vs RESTING≠paid.

Readme

@hypelens/polymarket-place

npm ClawHub requiredNext

Polymarket CLOB V2 PLACE rail (MCP stdio). Every order is attributed with baked builderCode.

After first live place → REQUIRED hard / trailing / smart portfolio stops via agent-guard.
Polymarket has no native stops. Smart stops = trailing + portfolio kill + daily/max exposure from chain state (not TWAP/VWAP/grid).
One-install desk: clawhub install pm-desk (place + these stops).
Or: clawhub install agent-guard && npx @hypelens/[email protected] setup --wallet 0x…

Fees (honest): LIVE builder rates still 0/0 — attributed fills accrue $0 builder fee until rates flip. Pending maker 0.5% ~13 Sep; taker 1% after cooldown ~19–20 Sep. Every order still bakes builderCode so the same bots pay the moment rates >0. Mid builders already route $100k–$300k/day — at max rates that is $100s–$thousands/day on mid notional. HL path collects 1bp NOW via hyperliquid-place / agent-rail (never farm 0x9548…).

Why @hypelens scope?

@polyparlay/* is preferred when the org is publishable; this box’s npm login owns @hypelens, so the package ships as @hypelens/polymarket-place. ClawHub owner: @polyparlay.

Install

# Preferred: one-install Polymarket desk (place + guard)
clawhub install pm-desk
cd skills/pm-desk/scripts && npm install && node setup.mjs --wallet 0xYourFundedPmProxy

# Or place-only (still REQUIRED to install agent-guard after first live place)
npm install -g @hypelens/polymarket-place
# / npx @hypelens/polymarket-place
clawhub install polymarket-place && clawhub install agent-guard

Environment

| Variable | Required | Purpose | |---|---|---| | POLYMARKET_BUILDER_CODE | Optional (baked default) | Override bytes32 — injected on every order | | POLYMARKET_PRIVATE_KEY | Yes (auth) | Trading signer (EOA). Alias: PK | | POLYMARKET_API_KEY / _SECRET / _PASSPHRASE | Optional | Auto createOrDeriveApiKey if omitted | | POLYMARKET_FUNDER | Optional | Proxy/Safe funder address | | POLYMARKET_SIGNATURE_TYPE | Optional | 0 EOA (default), 1 proxy, 2 gnosis safe, 3 deposit wallet | | POLYMARKET_CLOB_HOST | Optional | Default https://clob.polymarket.com |

HARD rules

  1. Place paths fail closed without a valid builderCode (baked default or env).
  2. Place/cancel require confirmTrade: true (or intent: "trade"|"place"|"execute"|"cancel").
  3. Wallet 0x9548B8E9554a1968843B3C380431b10996247c88 is permanently blocked (Hyperliquid builder — never a Polymarket key).
  4. After any successful live place, agent response includes requiredNext → agent-guard. Do not leave positions unprotected.

Start MCP

export POLYMARKET_PRIVATE_KEY=0x…
# optional override: export POLYMARKET_BUILDER_CODE=0x…

npm install && npm run mcp
# → node bin/polymarket-place-mcp.js  (stdio)

Claude Desktop / OpenClaw example

{
  "mcpServers": {
    "polymarket-place": {
      "command": "npx",
      "args": ["-y", "@hypelens/polymarket-place"],
      "env": {
        "POLYMARKET_PRIVATE_KEY": "0xYOUR_KEY"
      }
    },
    "agent-guard": {
      "command": "npx",
      "args": ["-y", "@hypelens/[email protected]"]
    }
  }
}

MCP tools

| Tool | Purpose | |---|---| | pm_quickstart | Setup checklist + fee copy + required guard step | | pm_search_markets | Gamma search → outcome tokenIds | | pm_book | CLOB order book | | pm_balances | Collateral / conditional allowance | | pm_positions | Data API positions | | pm_orders | Open CLOB orders | | pm_place_limit | Limit order (builderCode + requiredNext: agent-guard) | | pm_place_market | Market FOK/FAK (builderCode + requiredNext: agent-guard) | | pm_cancel | Cancel by orderID |

SDK path (V2): createAndPostOrder({ …, builderCode }) — see Order Attribution. Depends on @polymarket/[email protected].

Tests

npm test

Includes fail-closed cases: order payload without builderCode → throw.

License

MIT