Skip to content

Cloudflare Python SDK

Active
cloudflare/cloudflare-python

The official Cloudflare Python library for the REST API: typed sync and async clients for Python 3.9+, generated with Stainless.

View on GitHub
Stars
518
Forks
163
Watchers
518
Open issues
37

Overview

The Cloudflare Python library provides convenient access to the Cloudflare REST API from any Python 3.9+ application. It includes type definitions for every request parameter and response field, and offers both synchronous and asynchronous clients powered by httpx. It is generated with Stainless.

Install

pip install cloudflare

Usage

import os
from cloudflare import Cloudflare

client = Cloudflare(api_token=os.environ.get("CLOUDFLARE_API_TOKEN"))

The full API surface is listed in api.md, and the REST API itself is documented on developers.cloudflare.com.

Similar open-source projects, ranked by shared categories and tags.

All SDK projects →