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

increase-sdk

v1.0.0

Published

A complete, independent TypeScript client for the Increase API (https://increase.com) -- banking-as-a-service for accounts, ACH/wire/check/RTP/FedNow transfers, cards, entities, and more.

Readme

increase-sdk

A production-grade, independent TypeScript client for the Increase API — banking-as-a-service for accounts, ACH/wire/check/RTP/FedNow transfers, cards, entities, and more.

Covers Increase's full API surface (~90 resource groups, ~240 operations). Zero runtime dependencies — built entirely on the platform fetch, Headers, AbortController, and Web Crypto APIs, so it runs unmodified on Node ≥18, Deno, Bun, Cloudflare Workers, and in the browser.

Install

npm install increase-sdk

Usage

import { Increase } from "increase-sdk";

const client = new Increase({
  apiKey: process.env.INCREASE_API_KEY,
  environment: "sandbox", // or "production"
});

const account = await client.accounts.create({ name: "My First Account" });
console.log(account.id);

// Lazy, cursor-based pagination -- pages are fetched on demand as you
// iterate, not all up front.
for await (const account of await client.accounts.list()) {
  console.log(account.id, account.name);
}

// Sandbox-only simulations let you drive objects through their
// lifecycle without waiting on real banking rails.
const transfer = await client.achTransfers.create({
  account_id: account.id,
  amount: 1000,
  statement_descriptor: "Test payment",
});
await client.simulations.achTransfers.submit(transfer.id);

Error handling

import { IncreaseError } from "increase-sdk";

try {
  await client.accounts.retrieve("account_does_not_exist");
} catch (err) {
  if (err instanceof IncreaseError) {
    console.log(err.status, err.type, err.detail);
    if (err.isNotFound) {
      // ...
    }
  }
}

Webhooks

import { verifyWebhookSignature } from "increase-sdk";

// Express/Node example -- use whatever gives you the *raw* request body.
app.post("/webhooks/increase", express.text({ type: "*/*" }), async (req, res) => {
  try {
    await verifyWebhookSignature(req.body, req.headers, signingSecret);
  } catch {
    return res.status(400).send("invalid signature");
  }
  const event: unknown = JSON.parse(req.body);
  res.status(200).end();
});

Retries and idempotency

maxRetries (default 2) retries rate-limited (429) and server-error (5xx/408/409) responses with exponential backoff and jitter, honoring Retry-After when present. Because retrying a POST/PATCH naively could double-create something, the transport generates an Idempotency-Key once before the first attempt and reuses it across every retry of that request — Increase guarantees replaying the same key returns the original result.

Per-call options

Every method accepts a trailing options object for one-off overrides:

await client.accounts.create(
  { name: "My Account" },
  { idempotencyKey: "my-own-key", timeoutMs: 10_000, signal: myAbortSignal },
);

Logging

const client = new Increase({
  apiKey,
  logger: (event) => console.log(event.type, event),
});

Emits structured events for request start, completion (status, duration, attempt count), retries, and terminal failures.

Architecture

increase-sdk/
├── src/
│   ├── index.ts           Package entry point (re-exports everything below)
│   ├── client.ts           The Increase client class, wiring every resource
│   ├── version.ts
│   ├── core/
│   │   ├── request.ts      Transport: fetch + retries + idempotency + logging
│   │   ├── pagination.ts   Generic, lazy, async-iterable Page<T>
│   │   ├── resource.ts     BaseResource every generated resource extends
│   │   ├── error.ts        IncreaseError / IncreaseConnectionError
│   │   ├── webhook.ts      Standard Webhooks signature verification
│   │   └── qs.ts           Query parameter encoding
│   └── resources/          One file per resource: types + a *Resource class
│                            (account.ts, ach-transfer.ts, card.ts, ...)
└── test/                    Vitest suite: transport, pagination, webhook,
                             error decoding, and end-to-end client tests
  • Field names match the wire format (created_at, account_id, not createdAt/accountId) rather than being converted to camelCase — the same convention Stripe's, OpenAI's, and Anthropic's own TypeScript SDKs use. This means there's no naming-translation layer that could introduce bugs or drift from Increase's own API documentation; what you see in the docs is exactly what you type.
  • Enums are string-literal unions ("open" | "closed"), not runtime enum objects, matching modern TypeScript convention and keeping the compiled output small.
  • Nullable response fields are typed T | null; optional request parameters are field?: T.
  • Pagination: every list() method returns a Promise<Page<T>>. Page implements AsyncIterable, so for await (const item of await resource.list()) walks every item across every page, fetching each subsequent page only when the current one is exhausted.
  • File uploads: client.files.create is the one method that sends multipart/form-data (via the platform FormData) instead of JSON, since it uploads raw bytes. Its response type is named IncreaseFile rather than File to avoid shadowing the platform's built-in File/Blob API type.

Provenance

Domain models and endpoint definitions were derived from Increase's published API surface (cross-referenced against Increase's official Go SDK for field-level accuracy) and reimplemented from scratch as an independent, generated TypeScript client — not a fork or a port of any existing package.

Development

npm run build          # tsup -> dist/ (ESM + CJS + .d.ts)
npm run typecheck      # tsc --noEmit
npm run lint            # eslint .
npm run format:check    # prettier --check .
npm test                 # vitest run
npm run test:coverage    # vitest run --coverage