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

@devly-cl/flow-client

v0.1.0

Published

Framework-independent Flow wire client with request signing and safe protocol errors.

Readme

@devly-cl/flow-client

Flow wire protocol for Node 24 or newer. Zero runtime npm dependencies; emits CommonJS and TypeScript declarations and supports require and named ESM imports. Published releases are installed from npm; local npm pack only creates a candidate tarball.

Install

npm install @devly-cl/flow-client
import { FlowHttpClient, FlowClientError, type FlowCustomer } from '@devly-cl/flow-client';

const client = new FlowHttpClient({
  environment: 'test',
  getCredentials: () => secretStore.readFlowCredentials(),
  // Optional: transport with the native fetch signature, for interception/testing.
});
client.assertConfigured(); // Validates without network I/O or returning credentials.
const customer = await client.request<FlowCustomer>('GET', '/customer/get', { customerId });

getCredentials supplies { apiKey, secretKey } synchronously and is called for every request. The client never reads environment variables. Credentials stay bound to the chosen test or live host. Signatures use raw sorted UTF-8 values before form encoding. Requests reject redirects, time out after 15 seconds and cap response bodies at 1 MiB. Each call makes exactly one transport attempt; there is no automatic retry or provider idempotency key.

FlowClientError exposes only code, uncertain and optional httpStatus; transport messages, causes and provider rejection bodies are discarded. An uncertain mutation requires reconciliation before retrying. The non-mutating changePlanPreview POST follows read semantics. Successful request<T> results still require caller validation of identity, ownership and financial state: the generic type is a wire description, not a runtime guarantee. Host policy must handle uncertainty raised by validation after a successful POST.

Public exports: FlowHttpClient, FlowClientError, flowObject, flowString, flowInteger, flowClpAmount, flowCalendarDate, flowLocalDateTime; types for environment/options/credentials/transport/error codes and Flow wire DTOs. Calendar parsers preserve dates and wall-clock strings without inferring a timezone. Fetch transport declarations reference TypeScript's standard DOM library; consumers need no Nest, TypeORM or Node type package to resolve this API.

Sales gates, tenant authorization, checkout, callbacks, journals, retries, billing rules and environment-variable selection belong to the application. The integrating application preserves those responsibilities and translates SDK errors into its existing billing contract.

From this repository root, run npm run build:packages, npm run test:packages, npm run test:package-boundaries and npm run test:package-artifacts. The artifact test installs the SDK alone offline outside the repository and signs an intercepted request without framework dependencies or .env. It does not contact Flow. Rebuild packages and restart Nest after changing package sources; automatic package hot reload is not provided.