Skip to content

OpenFeature SDKs

Evaluate Flagship feature flags using OpenFeature.

OpenFeature is the CNCF standard for feature flag interfaces. It provides a vendor-neutral API so you can switch between flag providers without changing evaluation code.

Flagship provides official OpenFeature-compatible SDKs for TypeScript and Python. The source code is available on GitHub.

For Cloudflare Workers, use the Workers binding when possible. Use an SDK when you need OpenFeature compatibility, are running outside Workers, or need browser-side flag evaluation.

SDKPackageRuntimeEvaluation modes
TypeScript@cloudflare/flagshipWorkers, Node.js, browsersWorkers binding, HTTP, browser prefetch cache
Pythoncloudflare-flagshipPython server applicationsHTTP

SDKs

Flagship SDKs are organized by language. The TypeScript SDK has separate setup guides for server-side and browser usage because they use different OpenFeature packages and runtime behavior.

TypeScript installation

For server-side usage:

npm i @cloudflare/flagship @openfeature/server-sdk

For browser usage:

npm i @cloudflare/flagship @openfeature/web-sdk

Python installation

Install the Python SDK with uv or pip:

Terminal window
uv add cloudflare-flagship
Terminal window
pip install cloudflare-flagship

The Python SDK provides FlagshipServerProvider for server-side applications. It supports HTTP evaluation, sync and async APIs, all OpenFeature flag types, retries, timeouts, and optional response caching.

Next steps