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

files-sdk

v1.5.0

Published

Unified storage SDK for object/blob backends.

Readme

Files SDK

A unified storage SDK for object and blob backends. One small, honest API. Web-standards I/O. An escape hatch when you need the native client.

Install

npm install files-sdk

Each provider's native SDK is an optional peer dependency — install only the ones you actually use, alongside files-sdk itself. A few examples:

# S3 (and any S3-compatible: R2, MinIO, DigitalOcean Spaces, Backblaze B2, Wasabi, …)
npm install files-sdk @aws-sdk/client-s3 @aws-sdk/s3-presigned-post @aws-sdk/s3-request-presigner

# Google Cloud Storage
npm install files-sdk @google-cloud/storage google-auth-library

# Azure Blob Storage
npm install files-sdk @azure/storage-blob @azure/core-auth @azure/identity

# Vercel Blob
npm install files-sdk @vercel/blob

See files-sdk.dev for the per-adapter install command. If you import an adapter without its peer installed, Node will throw ERR_MODULE_NOT_FOUND naming the missing package.

Quick start

import { Files } from "files-sdk";
import { s3 } from "files-sdk/s3";

const files = new Files({
  adapter: s3({ bucket: "uploads" }),
});

await files.upload("avatars/abc.png", file, { contentType: "image/png" });
const got = await files.download("avatars/abc.png");
const exists = await files.exists("avatars/abc.png");

Swap the adapter import (files-sdk/r2, files-sdk/gcs, files-sdk/azure, …) and the rest of your code stays the same.

File handles

Use files.file(key) when your application code works with the same object repeatedly:

const avatar = files.file("avatars/abc.png");

await avatar.upload(file, { contentType: "image/png" });

if (await avatar.exists()) {
  const meta = await avatar.head();
  const url = await avatar.url({ expiresIn: 300 });
}

await avatar.delete();

File handles are a thin layer over the same adapter methods, so adapters do not need to implement anything extra.

What you get

  • One API across providersupload, download, head, exists, delete, copy, list, url, signedUploadUrl, plus file(key) for a key-scoped handle. The shape is the same on S3, GCS, Azure, Vercel Blob, the local filesystem, and consumer providers like Dropbox. exists returns false only when the provider reports NotFound; auth, permission, and transport failures still throw.
  • Web-standard I/O — bodies are Blob, File, ReadableStream, Uint8Array, ArrayBuffer, or string. No provider-specific types leak into your code.
  • Escape hatch — every adapter exposes its native client at files.raw, so provider-specific features are one property access away.
  • Tree-shakeable — each adapter is a separate entry point. You only bundle what you import.

Adapters

A growing catalog covering S3 and S3-compatible stores, the major cloud blob platforms, edge/serverless blob services, the local filesystem, and consumer file providers. See files-sdk.dev for the current list and per-adapter setup.

AI tools

A growing set of subpaths wrap a configured Files instance as ready-made tools for popular AI SDKs — currently the Vercel AI SDK (files-sdk/ai-sdk), OpenAI's Responses API and Agents SDK (files-sdk/openai), and Anthropic's Claude Agent SDK (files-sdk/claude). All share the same file operations and approval-gating defaults, so models can browse, read, and (optionally) mutate your bucket through the same unified surface as your application code. See files-sdk.dev for the current list and per-SDK setup.

License

MIT