New

Just launched: Vueblocks, a brand-new search engine for Vue packages! Explore Vueblocks →

foodticket/laravel-filesystem-cloudflare-images

A Laravel filesystem driver for Cloudflare Images
12,576 6
Install
composer require foodticket/laravel-filesystem-cloudflare-images
Latest Version:v0.1.0
PHP:^8.3
Laravel:12 · 13
Older releases:8 – 11
License:MIT
Last Updated:Sep 7, 2026
Links: GitHub  ·  Packagist
Maintainer: rikmorskate

Cloudflare Images Filesystem Driver

This package provides a filesystem driver for Cloudflare Images. If you need more control or want to want to implement more Cloudflare API endpoints have a look at our Laravel wrapper for Cloudflare which is also used by this packages.

The full documentation of the Cloudflare Images API can be found here.

Requirements

  • PHP >= 8.3
  • Laravel >= 12.0

Installation

To start using the package, you need to install it via Composer:

composer require foodticket/laravel-filesystem-cloudflare-images

Confuguration

Add the following to your config/filesystems.php file:

'cloudflare-images' => [
    'driver' => 'cloudflare-images',
    'account_id' => env('CLOUDFLARE_IMAGES_ACCOUNT_ID'),
    'api_email' => env('CLOUDFLARE_IMAGES_API_EMAIL', env('CLOUDFLARE_API_EMAIL')),
    'api_key' => env('CLOUDFLARE_IMAGES_API_KEY', env('CLOUDFLARE_API_KEY')),
],

Add the following environment variables to your .env file:

CLOUDFLARE_IMAGES_ACCOUNT_ID=<account id>

If you did not have our Laravel-Cloudflare wrapper yet you also need to add the following environment variables to your .env file:

CLOUDFLARE_IMAGES_API_EMAIL=<API email>
CLOUDFLARE_IMAGES_API_KEY=<API key>

Getting started

The Cloudflare Images filesystem driver can be used as you would use another filesystem driver. The documentation for the Laravel filesystem can be found here.

The following example shows how to use the Cloudflare Images filesystem driver to store a file.

use Illuminate\Support\Facades\Storage;

Storage::disk('cloudflare-images')->put('example.png', 'Contents');

Notes

Cloudflare Images doesnot support directories so not all filesystem methods are available. The following methods are supported:

  • fileExists
  • write
  • read
  • delete
  • visibility
  • mimeType
  • lastModified
  • fileSize
  • move
  • copy

The following methods are not supported:

  • directoryExists
  • writeStream
  • readStream
  • deleteDirectory
  • createDirectory
  • listContents

The following methods still need to be implemented:

  • setVisibility

Security Vulnerabilities

If you discover a security vulnerability within this project, please email me via developer@foodticket.nl.

Related Packages

dedmytro/laravel-cloudflare-images

Cloudflare API client and filesystem for Laravel

92,906 41
anakadote/laravel-5-image-manager

Image resizing and cropping package for Laravel.

8,953 14
suitmedia/laravel-cloudflare

Simple and easy cloudflare cache purging in Laravel

9,496 9
kwaadpepper/image-resizer

Resize images on the fly and cache them

8,484 5
sergkeim/php-cloudflare-api

PHP Client for Cloudflare API.

7,761 19

Version History

Version Released PHP Laravel License
v0.1.0 ^8.3 ^12.0|^13.0 MIT
v0.0.16 ^8.3 ^12.0|^13.0 MIT
v0.0.15 ^8.2 ^11.0|^12.0 MIT
v0.0.14 ^8.0|^8.1|^8.2|^8.3 ^8.0|^9.0|^10.0|^11.0 MIT
v0.0.13 ^8.0|^8.1|^8.2|^8.3 ^8.0|^9.0|^10.0|^11.0 MIT
Pre-releases (1)
Version Released PHP Laravel License
v0.0.1-alpha ^8.0 ^8.0|^9.0 MIT