
Security News
CVE Volume Surges Past 48,000 in 2025 as WordPress Plugin Ecosystem Drives Growth
CVE disclosures hit a record 48,185 in 2025, driven largely by vulnerabilities in third-party WordPress plugins.
@humanwhocodes/s3bucket
Advanced tools
If you find this useful, please consider supporting my work with a donation.
Lightweight JavaScript helper for making signed S3 requests using aws4fetch. Provides a
small S3Bucket class with convenience methods for common object operations
(head, get, put, delete).
Install from npm:
npm install @humanwhocodes/s3bucket
Import and create an S3Bucket instance. The constructor requires a
baseUrl and bucket and accepts AWS credentials or the usual
environment-based mechanisms.
import { S3Bucket } from "@humanwhocodes/s3bucket";
const s3 = new S3Bucket({
baseUrl: "https://s3.amazonaws.com",
bucket: "my-bucket",
accessKeyId: process.env.AWS_ACCESS_KEY_ID,
secretAccessKey: process.env.AWS_SECRET_ACCESS_KEY,
region: "us-east-1", // optional
pathStyle: true, // optional
});
// Head an object
await s3.head("path/to/object.txt");
// Get object
const res = await s3.get("path/to/object.txt");
const body = await res.text();
// Put object
await s3.put("path/to/new.txt", "hello world", {
headers: { "Content-Type": "text/plain" },
});
// Delete object
await s3.delete("path/to/new.txt");
Constructor options (partial):
baseUrl (string, required): Base endpoint used to build request URLs.bucket (string, required): Bucket name.pathStyle (boolean, optional, default false): When true use
path-style URLs (baseUrl/<bucket>/<path>), otherwise use baseUrl/<path>.accessKeyId, secretAccessKey, sessionToken, region — forwarded to
aws4fetch.This library is built on top of the excellent aws4fetch package.
Copyright 2025 Nicholas C. Zakas
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
FAQs
Lightweight client for interacting with S3 buckets
We found that @humanwhocodes/s3bucket demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
CVE disclosures hit a record 48,185 in 2025, driven largely by vulnerabilities in third-party WordPress plugins.

Security News
Socket CEO Feross Aboukhadijeh joins Insecure Agents to discuss CVE remediation and why supply chain attacks require a different security approach.

Security News
Tailwind Labs laid off 75% of its engineering team after revenue dropped 80%, as LLMs redirect traffic away from documentation where developers discover paid products.