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

multi-dex-peg-kit

v0.3.0

Published

Bounded multi-DEX peg / market-maker kit for Polygon, Base, Arbitrum, Optimism, and BSC (dry-run first).

Downloads

32

Readme

multi-dex-peg-kit

Bounded multi-DEX peg bot for Polygon, Base, Arbitrum, Optimism, and BSC — dry-run first, pluggable adapters, YAML config, CLI.

Soft-peg or rebalance a USDC/base pool toward an HTTP target price (raw / EMA / TWAP) with circuit breakers, reserve floors, and optional multi-leg fills.

Features

  • Adapters: Uniswap V3, Uni V2 (QuickSwap / Pancake V2), Pancake V3 (BSC), Aerodrome (Base), multi-hop V3
  • Chains: Polygon, Base, Arbitrum, Optimism, BSC
  • CLI: peg status | peg dry-run | peg run | peg simulate --amount <USDC>
  • Risk: max daily notional, drawdown bps, max absolute USDC loss, min reserves
  • Alerts: generic webhook + Telegram + Discord
  • Metrics: JSONL + optional Prometheus
  • Live CI smoke against public Polygon RPC
  • Default dryRun: true

Demo (peg status)

peg status demo

Text capture: docs/demo-status.txt · regenerate GIF: npm run gif

Quick start

git clone https://github.com/nad33mahm3d/multi-dex-peg-kit.git
cd multi-dex-peg-kit
npm install
cp config.example.yaml config.yaml
cp .env.example .env
# edit config.yaml + .env
npm run peg -- status
npm run peg -- simulate --amount 100
npm run peg -- dry-run

npx (after publish)

npm run build
# npm publish  # maintainer
npx multi-dex-peg-kit help

Architecture

peg CLI → YAML+env → smoother (raw|ema|twap) → loop
   → circuit breaker / reserve floors
   → adapter registry → strategy all|best → multi-leg → execute
   → JSONL + Prometheus + webhook/Telegram/Discord

Config highlights

See config.example.yaml.

| Area | Keys | |------|------| | Target | indexApi.mode: raw | ema | twap | | Circuit | maxDailyNotionalUsdc, maxDrawdownBps, maxLossUsdc | | Floors | minReserveUsdc, minReserveBase | | Alerts | webhookUrl, telegramBotToken+telegramChatId, discordWebhookUrl | | Chain | polygon | base | arbitrum | optimism | bsc |

USDC / stables

  • Polygon: native + USDC.e
  • Base / Optimism / Arbitrum: native USDC
  • BSC: USDC (0x8AC76a51…) — Pancake pools

Adapters

| Name | Typical chain | |------|----------------| | uniswap_v3 | Polygon, Base, Arbitrum, Optimism; Pancake V3 on BSC | | univ2 | QuickSwap (Polygon), Pancake V2 (BSC) | | aerodrome | Base | | multihop_v3 | hop via WETH/WMATIC/WBNB |

Plugin guide: docs/adapters.md · stub: examples/stub-adapter.ts

Deploy & CI

Non-goals

  • MEV / private transactions
  • Cross-DEX arb as a product
  • Financial advice

License

MIT — LICENSE. Security: SECURITY.md.