
Research
Security News
The Growing Risk of Malicious Browser Extensions
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
@squarecloud/blob
Advanced tools
Official Square Cloud Blob SDK for NodeJS.
npm install @squarecloud/blob
// or
yarn add @squarecloud/blob
// or
pnpm add @squarecloud/blob
Visit our official API documentation for more information about this service.
import { SquareCloudBlob } from "@squarecloud/blob"
// CommonJS => const { SquareCloudBlob } = require("@squarecloud/blob");
const blob = new SquareCloudBlob("Your API Key")
const objects = await blob.objects.list()
const blobObject = await blob.objects.create({
file: "path/to/file.png", // Absolute path to your file
name: "my_image", // File name without extension
})
console.log(blobObject.url)
import { MimeTypes } from "@squarecloud/blob"
// CommonJS => const { MimeTypes } = require("@squarecloud/blob")
const blobObject = await blob.objects.create({
file: Buffer.from("content"),
name: "my_image",
mimeType: MimeTypes.IMAGE_JPEG, // Also accepts an string "image/jpeg"
})
console.log(blobObject.url)
// List of objects to delete (Limit of 100 per request)
const objectsToDelete = [
"ID/prefix/name1_xxx-xxx.mp4",
"ID/prefix/name_xxx-xxx-xxx.png"
]
await blob.objects.delete(objectsToDelete)
import { MimeTypeUtil } from "@squarecloud/blob"
// Get a supported mime type from a file extension
console.log(MimeTypeUtil.fromExtension("jpeg")) // "image/jpeg" | Supported
console.log(MimeTypeUtil.fromExtension("json")) // "application/json" | Supported
console.log(MimeTypeUtil.fromExtension("potato")) // "text/plain" | Unsupported, defaults to text/plain
Feel free to contribute with suggestions or bug reports at our GitHub repository.
1.4.0
FAQs
Official Square Cloud Blob SDK for NodeJS
The npm package @squarecloud/blob receives a total of 20 weekly downloads. As such, @squarecloud/blob popularity was classified as not popular.
We found that @squarecloud/blob demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 3 open source maintainers 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.
Research
Security News
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
Research
Security News
An in-depth analysis of credential stealers, crypto drainers, cryptojackers, and clipboard hijackers abusing open source package registries to compromise Web3 development environments.
Security News
pnpm 10.12.1 introduces a global virtual store for faster installs and new options for managing dependencies with version catalogs.