# Backblaze B2 MCP MCP

> Backblaze B2 MCP lets your AI client manage entire cloud storage architectures via natural conversation. You can list all buckets, adjust access rules, find failed multipart uploads, or deeply inspect file metadata and versions without leaving your IDE.

## Overview
- **Category:** cloud-infrastructure
- **Price:** Free
- **Tags:** s3-compatible, object-storage, file-management, data-archiving, bucket-management, cloud-backup

## Description

Managing object storage often means jumping between a clunky web console, running shell commands, and manually checking logs for broken transfers. This MCP lets you run those complex tasks directly through your agent. Need to audit which buckets exist, check if an old version of a file is still taking up space, or create a new private domain? Just ask. It handles the orchestration of secure object storage so you don't have to live in the cloud provider's UI. With this MCP connected via Vinkius, your agent can treat Backblaze B2 like another service endpoint, giving you full control over buckets, file versions, and access policies right inside your editor.

## Tools

### authorize_account
Gets the specific API endpoint needed to connect your agent to your unique B2 billing account region.

### create_bucket
Provisions a brand new, empty logical storage bucket partition within Backblaze.

### delete_bucket
Irreversibly deletes an entirely empty B2 Storage Bucket after confirming no files remain inside.

### delete_file_version
Permanently removes a specific, absolute historical chunk of data from the storage arrays.

### get_file_info
Retrieves detailed metadata about a file, including its size, content type, and calculated SHA1 checksum.

### hide_file
Marks an active B2 file as hidden without deleting the binary payload, useful for safe soft deletion logic.

### list_buckets
Retrieves a complete list of every storage bucket currently existing globally on your account.

### list_file_names
Paginates the primary surface-level object metadata, showing visible files within a specified bucket.

### list_unfinished_large_files
Scans B2 nodes to locate and report on stalled multipart upload chunk aggregates that failed completion.

### update_bucket
Changes the global access control list (ACL) privacy settings for a defined storage bucket.

## Prompt Examples

**Prompt:** 
```
What buckets do we have enabled in Backblaze B2 right now?
```

**Response:** 
```
You have 3 active storage buckets: `production-assets-22` (allPublic), `backup-logs-internal` (allPrivate), and `db-dumps` (allPrivate). Should I query the unfinished large files stream to check for ghost chunks on the database dumps bucket?
```

**Prompt:** 
```
Create a new private bucket named 'ai-crawler-logs-2026' and make it private.
```

**Response:** 
```
The bucket `ai-crawler-logs-2026` has been successfully created and partitioned via the Backblaze B2 node. Its status is strictly set to `allPrivate` preventing public reads.
```

**Prompt:** 
```
Get the file details and SHA1 for the object 'index.html' in the public bucket.
```

**Response:** 
```
File Details for `index.html`: The file uses `text/html`, is 34.2 KB globally, with an active unique ID of 4_zX... and the explicitly computed SHA1 trace is `2f8bX...`. It is fully accessible via the B2 friendly download URL.
```

## Capabilities

### Audit storage containers
List all existing global storage buckets and verify the necessary API endpoints for your account.

### Manage bucket structure
Create, update access rules on, or permanently delete entire storage buckets.

### Inspect file metadata
Retrieve granular details for any object, including its size, content type, and unique SHA1 checksum.

### Control file lifecycle
Soft-delete files by marking them hidden or hard-delete specific historical versions to free up space.

### Debug uploads
Scan for stalled, incomplete large file chunks left over from failed multipart uploads.

## Use Cases

### Debugging a corrupted asset pipeline
A DevOps engineer suspects that some large video files are failing to complete upload. Instead of manually checking logs, they ask their agent to run `list_unfinished_large_files`. The agent finds the broken chunks and reports exactly which bucket needs attention.

### Setting up a secure staging environment
A Backend Developer needs a dedicated area for testing public assets. They instruct their agent to use `create_bucket` with specific ACL rules, ensuring the new container is provisioned correctly and immediately.

### Auditing old data compliance
A System Administrator must ensure that a sensitive bucket only contains files marked as private. They run `list_buckets` to verify the structure, then use `update_bucket` to enforce strict ACLs across all containers.

### Recovering from accidental public exposure
A developer accidentally uploaded a temporary file that was visible globally. They ask their agent to first run `list_file_names` to confirm the object name, and then use `hide_file` to immediately remove its visibility without deleting the underlying data.

## Benefits

- Don't waste time in the console checking for failed uploads. Use `list_unfinished_large_files` to scan your entire account for stalled multipart upload chunks, immediately pointing you toward pipeline failures.
- Need to provision a secure area fast? Simply ask your agent to use `create_bucket` and specify if it needs to be allPublic or allPrivate; the setup is instant.
- Tired of worrying about old data versions cluttering up costs? You can run `delete_file_version` to vaporize specific historical chunks, giving you granular control over your storage footprint.
- File auditing used to mean running complex CLI commands. Now, `get_file_info` lets your agent pull the SHA1 checksum and content type for any file in plain language.
- When a client needs temporary access to a document but it shouldn't be permanently listed, use `hide_file`. It enforces safe soft deletion logic without losing the data itself.

## How It Works

The bottom line is you talk to your agent; it talks to Backblaze B2 for you.

1. First, subscribe to this MCP and enter your Backblaze B2 Application Key ID and Key.
2. Next, run a command through your AI client asking it to perform a storage task (e.g., 'List all buckets' or 'Create a new private bucket').
3. The agent executes the necessary calls against B2, returning structured data about the status of the bucket, file, or upload stream.

## Frequently Asked Questions

**How do I list every bucket using the `list_buckets` tool?**
You simply ask your agent to run `list_buckets`. It returns a structured report of every bucket ID on your account, letting you see everything at once.

**What is SHA1 and why do I need the `get_file_info` tool?**
SHA1 is a unique digital fingerprint (checksum) for a file. You use `get_file_info` to generate this checksum, which lets you verify that an object hasn't been corrupted or tampered with since it was uploaded.

**Can I delete a bucket using the `delete_bucket` tool if files are inside?**
No. The `delete_bucket` tool will fail if any standard files persist inside. You must first use tools like `hide_file` or ensure all data is cleared before attempting deletion.

**What does the `list_unfinished_large_files` tool check for?**
This tool scans B2 nodes specifically looking for stalled Multipart Upload chunk aggregates. It helps you debug failed large file transfers that didn't finish uploading correctly.

**How do I find my specific regional data ingress point using the `authorize_account` tool?**
It uncovers your dynamically assigned, region-specific API URL. This is critical because it guarantees you're hitting the correct global session routing endpoint for accurate performance and billing.

**What does the `hide_file` tool do, and how is that different from deleting a file?**
It doesn't delete the binary payload; it injects a null-marker that makes the file invisible to standard listing tools. You can safely mark an active B2 file as hidden while keeping the data intact for later recovery.

**How do I change if my bucket is public or private using `update_bucket`?**
You mutate the global Access Control List (ACL) privacy settings for an entire storage bucket. This lets you switch between allPrivate and allPublic statuses without having to recreate the partition.

**When should I use `delete_file_version` instead of just listing files?**
Use this when you need to permanently remove a specific version of data, avoiding long-term retention costs. It vaporizes an absolute chunk data footprint from disk arrays.