PHP BSD-3-Clause

cloudflare-php

PHP library for the Cloudflare v4 API

C

cloudflare

Dernière activité 18 juin 2026
cloudflare/cloudflare-php

674

étoiles

268

forks

90

issues ouvertes

Ce README est souvent en anglais.

Cloudflare SDK (v4 API Binding for PHP)

Note: This is a community-maintained PHP SDK covering a subset of the Cloudflare API. A comprehensive, auto-generated PHP SDK is planned for the future. In the meantime, for full API coverage consider using the Cloudflare API directly.

Requirements

  • PHP 8.1 or later

Installation

Install via Composer (cloudflare/sdk):

composer require cloudflare/sdk

Cloudflare API version 4

The Cloudflare API can be found here. Each API call is provided via a similarly named function within various classes in the Cloudflare\API\Endpoints namespace:

Getting Started

$key     = new Cloudflare\API\Auth\APIKey('user@example.com', 'apiKey');
$adapter = new Cloudflare\API\Adapter\Guzzle($key);
$user    = new Cloudflare\API\Endpoints\User($adapter);

echo $user->getUserID();

Contributions

We welcome community contribution to this repository. CONTRIBUTING.md will help you start contributing.

Licensing

Licensed under the 3-clause BSD license. See the LICENSE file for details.

Projets similaires

A PHP client library for accessing Google APIs

PHP
Ggoogleapis
9,8 k étoiles3,5 k

The official Python library for the Cloudflare API

Pythonapicloudflaresdk
Ccloudflare
512 étoiles154

The official Go library for the Cloudflare API

Goapicloudflaresdk
Ccloudflare
2,1 k étoiles782