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

cryptoetf

v1.1.1

Published

Official TypeScript client for the CryptoETF API: daily net flows of US spot crypto ETFs for 16 assets (BTC, ETH, SOL, XRP, HYPE, DOGE, LINK, AVAX, HBAR, LTC, BNB, DOT, SUI, NEAR, TRX, ZEC), fund by fund, plus fund AUM, the CEFI sentiment index and coin p

Readme

CryptoETF — TypeScript SDK for spot crypto ETF flows

npm

The official client for the CryptoETF API: daily net flows of every US-listed spot crypto ETF, fund by fund, plus fund AUM, the CEFI sentiment index and coin prices. Data by cryptoetf.today.

Sixteen assets: BTC, ETH, SOL, XRP, HYPE, DOGE, LINK, AVAX, HBAR, LTC, BNB, DOT, SUI, NEAR, TRX, ZEC. Zero dependencies, fully typed, Node 18+, Deno, Bun and modern browsers.

Install

npm install cryptoetf

Get an API key

Sign in at cryptoetf.today and create a key in Profile → For developers. It is free.

Quick start

import { CryptoETF } from "cryptoetf";

const etf = new CryptoETF({ apiKey: process.env.CRYPTOETF_API_KEY });

// Latest daily net flow for every asset, US$ millions
const { assets } = await etf.flows.summary();
for (const a of assets) console.log(a.symbol, a.date, a.netFlowUsdM);

// Bitcoin ETFs fund by fund
const btc = await etf.flows.funds("btc");
const lastDay = btc.days.at(-1);
console.log(lastDay?.funds.map((f) => `${f.ticker} ${f.netFlowUsdM}`));

If apiKey is omitted, the client reads CRYPTOETF_API_KEY from the environment.

Methods

| Method | Endpoint | Returns | |---|---|---| | flows.summary() | GET /v1/flows/summary | Latest net flow per asset | | flows.asset(asset) | GET /v1/flows/{asset} | Daily net flows of one asset | | flows.funds(asset) | GET /v1/flows/{asset}/funds | Daily net flows of one asset, per fund | | funds(asset?) | GET /v1/funds | Fund directory with AUM, fees, coins held | | cefi() | GET /v1/index/cefi | CEFI sentiment index (0–100) and its history | | tickers() | GET /v1/tickers | Tracked assets | | prices() | GET /v1/prices | Spot prices of the 16 coins | | weekly() | GET /v1/analytics/weekly | Seven-day totals per asset |

Paid datasets

These need a paid API plan; a free key gets 403 with code: "plan_required".

| Method | Endpoint | Returns | |---|---|---| | holdings(asset?) | GET /v1/holdings | Coins held by the ETFs, share of circulating supply, per fund, with daily history | | metrics.costBasis(asset?) | GET /v1/metrics/cost-basis | Estimated average entry price of holders, unrealised P&L, streak above/below entry | | metrics.issuerRevenue(asset?) | GET /v1/metrics/issuer-revenue | Estimated sponsor fee revenue per fund, issuer and market | | metrics.staking(asset?) | GET /v1/metrics/staking | Staking status, share staked, disclosed yields and providers per fund | | metrics.vsMiners() | GET /v1/metrics/vs-miners | Bitcoin ETF net creations in BTC against newly mined bitcoin | | fundSnapshots(ticker) | GET /v1/funds/{ticker}/snapshots | Daily shares outstanding, NAV, net assets, coins and premium of one fund | | etfPrices(ticker) | GET /v1/etf-prices/{ticker} | Daily OHLCV of one ETF, regular session | | filings.list() | GET /v1/filings | Crypto ETF applications at the SEC with stage and dates | | filings.get(slug) | GET /v1/filings/{slug} | One application with its document history | | institutions.overview(period?) | GET /v1/institutions | 13F institutional holders for a quarter | | institutions.fund(ticker, { period?, limit? }) | GET /v1/institutions/funds/{ticker} | Largest 13F holders of one fund |

asset is a code such as btc, eth, sol, hype or a full name such as bitcoin. All values are net US$ millions: positive = inflow, negative = outflow. Full field reference: docs.cryptoetf.today.

Errors and limits

Every failed call throws CryptoETFError with status, an optional code and, on HTTP 429, retryAfter in seconds:

import { CryptoETFError } from "cryptoetf";

try {
  await etf.prices();
} catch (e) {
  if (e instanceof CryptoETFError && e.status === 429) {
    console.log(`rate limited, retry in ${e.retryAfter}s`);
  }
}
  • Rate limit: 120 requests per minute per key. The latest limit headers are available as etf.rateLimit.
  • History: the free tier covers the last 30 days. Full history will be available on a paid plan.
  • Freshness: a trading day appears the next morning (UTC), before the US open. The newest day can be revised once later that day. SUI funds arrive a day later.

Options

new CryptoETF({
  apiKey: "…",       // default: process.env.CRYPTOETF_API_KEY
  timeoutMs: 15000,  // per request
  baseUrl: "https://api.cryptoetf.today/v1",
  fetch: customFetch,
});

Related

Not investment advice. MIT licensed.