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

flexpay-monorepo

v0.1.0

Published

FlexPay is a hackathon MVP SDK for Solana merchants who want to accept payment in any supported token while receiving quoted USDC settlement through Jupiter. It packages the Jupiter quote and swap flow into two entry points:

Readme

FlexPay

FlexPay is a hackathon MVP SDK for Solana merchants who want to accept payment in any supported token while receiving quoted USDC settlement through Jupiter. It packages the Jupiter quote and swap flow into two entry points:

  • @flexpay/core: headless payment orchestration
  • @flexpay/react: drop-in checkout widget

The demo app in apps/demo-store shows the intended judging story: connect a wallet, pay with any funded token, and settle the merchant in USDC.

Why It Fits Jupiter Track

  • It expands Jupiter into commerce, not trading.
  • It uses Jupiter routing as the core infrastructure layer.
  • It gives developers a fast integration path with a widget and a headless client.
  • It demonstrates a developer-friendly checkout flow on top of Jupiter Swap API V2.

Bounty Fit Status

Current repo status against the prompt:

  • Shipped — multi-API composition: Swap V2 (/order + /execute) powers checkout; Tokens v2 supplies wallet metadata and uses isVerified + organicScore to keep spam tokens out of the picker; Price v3 samples the payment mint at quote time and again right before signing, hard-blocking the flow if drift exceeds 150 bps.
  • Shipped — production-shaped SDK: headless @flexpay/core, @flexpay/react widget, @flexpay/server proxy, and a Next.js demo app with stage-aware error UX, RPC 403 hardening, and a live DX telemetry panel on the landing page.
  • Shipped — judge-ready narrative: /story page with before/after code diffs for every DX friction we hit, plus a /docs submission guide that maps the repo to the judging rubric.
  • In flight: Trigger API fallback when volatility blocks a market fill (planned), Recurring + organic-score DCA carts, Lend-backed checkout rails, and AI-stack benchmarking captured in DX-REPORT.md.

DX-REPORT.md is treated as a required deliverable, not optional polish — read it alongside the demo at apps/demo-store and the narrative at /story.

Monorepo Layout

Local Setup

  1. Install dependencies:
pnpm install
  1. Copy the environment template and set your merchant wallet plus preferred Jupiter endpoints:
cp .env.example .env.local
  1. Start the demo app:
pnpm dev
  1. Open the demo storefront and connect a funded mainnet Solana wallet.

5-Minute Integration

import { FlexPayWidget } from "@flexpay/react";

export function Checkout() {
  return (
    <FlexPayWidget
      merchantWallet="YOUR_USDC_DESTINATION"
      amount={29.99}
      rpcEndpoint="https://api.mainnet-beta.solana.com"
      jupiterApiKey={process.env.NEXT_PUBLIC_JUPITER_API_KEY}
      onSuccess={(payment) => console.log(payment.signature)}
    />
  );
}

This is the fastest setup. If you want to keep your key server-side, omit jupiterApiKey and pass quoteApiUrl, swapApiUrl, and tokensApiUrl for your own backend routes.

Architecture

flowchart LR
  A["Customer Wallet"] --> B["FlexPayWidget"]
  B --> C["FlexPay Proxy Routes"]
  C --> D["Jupiter Quote API"]
  C --> E["Jupiter Swap API"]
  B --> F["Solana RPC"]
  E --> G["Unsigned Versioned Transaction"]
  G --> A
  A --> H["Signed Transaction"]
  H --> F
  F --> I["Merchant USDC Account"]

Testing

pnpm test
pnpm typecheck

The repo includes unit tests for @flexpay/core, render tests for @flexpay/react, and route tests for @flexpay/server.

Notes

  • This MVP follows the legacy Jupiter exact-output flow described in the project brief so the merchant can target a fixed USDC amount.
  • The SDK now targets Jupiter Swap API V2 for direct mode and is designed around a mainnet payment flow.
  • Jupiter Tokens API V2 requires an API key. Set FLEXPAY_JUPITER_API_KEY in .env.local so the widget can resolve wallet token metadata.
  • Direct client-side mode is also supported with NEXT_PUBLIC_JUPITER_API_KEY, but that exposes a browser-usable key to the client.
  • Jupiter is effectively a mainnet integration. Devnet SOL and devnet SPL faucet tokens are useful for wallet testing, but not for a real Jupiter payment route.
  • The /dashboard page is presentation-only in this MVP. Persisted merchant reporting should be wired through webhook storage or on-chain indexing next.