Cloudflare R2 Integration for Openclaw

A powerful integration for managing decentralized Cloudflare R2 object storage with automated authentication and streamlined CLI actions.

gora050
v1.0.2
May 1, 2026
0
411
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install cloudflare-r2-integration

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install cloudflare-r2-integration using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is Cloudflare R2 Integration?

Cloudflare R2 is an S3-compatible, decentralized object storage service designed to store and serve massive amounts of unstructured data—such as images, videos, and backups—without the heavy egress fees of traditional providers. This Openclaw Skills integration bridges the gap between your development environment and R2, providing a unified interface for data management.

By leveraging the Membrane framework, this skill removes the complexity of manual credential management. It provides a secure, server-side authentication lifecycle, allowing developers and AI agents to focus on building robust data pipelines rather than debugging authentication headers or managing local secrets.

Cloudflare R2 Integration Use Cases

  • Automating backups and data migration to Cloudflare R2 storage.
  • Programmatic management of storage buckets and individual objects.
  • Cost-effective media hosting for web and mobile applications with zero egress fees.
  • Integrating cloud storage triggers into multi-agent AI development workflows.
  • Securely accessing R2 data in headless environments without local API keys.

How Cloudflare R2 Integration Works

  1. Installation: The Membrane CLI is installed globally to provide a communication bridge between the local agent and the Cloudflare infrastructure.
  2. Authentication: Users log in via a tenant-specific client name (e.g., openclaw), which handles OAuth or API key exchange securely in the browser.
  3. Connection Establishment: A connection is ensured using the Cloudflare R2 product URL, which triggers the Membrane backend to prepare the necessary drivers.
  4. Action Discovery: The agent uses natural language intent to search for specific R2 actions, such as 'list buckets' or 'upload file'.
  5. Execution & Proxying: Actions are executed directly via the CLI, or the proxy command is used to send raw authenticated requests to the Cloudflare API.

Cloudflare R2 Integration Setup

1. Install the Membrane CLI

Ensure you have Node.js installed, then run:

npm install -g @membranehq/cli@latest

2. Authenticate the Agent

Replace <agentType> with openclaw to optimize the tooling for your current setup:

membrane login --tenant --clientName=openclaw

3. Create the R2 Connection

Establish a link to your Cloudflare account:

membrane connection ensure "https://www.cloudflare.com/products/r2/" --json

4. Verify Readiness

If the connection state is BUILDING, poll until it is READY:

membrane connection get <connection_id> --wait --json

Cloudflare R2 Integration Data Schema & Taxonomy

The skill interacts with Cloudflare's hierarchical object storage model, mapped through Membrane's action system:

Entity Description Key Metadata
Account The top-level Cloudflare entity Account ID, API Credentials
Bucket Logical containers for objects Name, Region, Creation Date
Object The actual files stored in R2 Key (path), ETag, Size, Content-Type
Connection The Membrane-specific link Connection ID, State (READY/BUILDING)

All CLI outputs are available in machine-readable JSON format using the --json flag, making it easy to parse the inputSchema and outputSchema of every action.

Cloudflare R2 Integration Advanced Features

  • Intelligent Action Discovery: Search for capabilities using natural language queries via the --intent flag.
  • Transparent Proxying: Send authenticated requests to any R2 API endpoint using membrane request without manual header injection.
  • Automated Credential Refresh: Membrane manages the full lifecycle of access tokens, ensuring long-running automations never fail due to expired keys.
  • Headless Mode Support: Complete authentication in remote or server environments using code-based login completion.
  • Cross-Agent Compatibility: Tailors output formatting for specific harnesses like openclaw, claude, or windsurf.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*