# cloudflare/cloudflare-go

The official Go library for the Cloudflare API

Repository: https://github.com/cloudflare/cloudflare-go
Canonical: https://ross.abutalabs.com/products/cloudflare-go
Homepage: https://developers.cloudflare.com/api
Language: Go
License: Apache-2.0
License Family: permissive
Topics: api, cloudflare, sdk, sdk-go, sdk-golang
Last push: 2026-08-20T18:58:02+00:00

## Health v2 (maintenance only)
Score: 98/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 98, release rhythm 98, longevity 100
- inputs: {"age_days": 3926, "days_push": 13, "days_rel": 13, "gap_med": 13.0, "n_releases_24m": 49}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2075, forks 776 (observed 2026-08-28T04:06:10.735721+00:00)

## What it is
The official Go SDK for the Cloudflare REST API, generated with Stainless and covering Cloudflare products such as zones, DNS, and Zero Trust. It provides typed clients, request field helpers, and structured response objects for Go applications.

## Use cases
- manage cloudflare dns records from go
- create and configure cloudflare zones programmatically
- automate cloudflare zero trust device posture integrations
- provision cloudflare resources via the rest api in a go service
- script cloudflare infrastructure automation in golang

## When to choose
- you are building Go applications or tooling that needs to call the Cloudflare API
- you want an officially maintained, typed SDK instead of hand-rolled HTTP calls
- you need access to the full breadth of Cloudflare API resources including Zero Trust

## When to avoid
- you use a language other than Go (use the official SDK for your language instead)
- you only need simple DNS updates and prefer a lightweight untyped client
- you target an older Go version than 1.22

## Facets
- artifact type: library
- maturity: active
- function: http-client, sdk, api-framework
- domain: developer-tools, apis, cloud-computing, networking, security
- platform: go, cross-platform
- tags: cloudflare, api-client, rest-api, generated-sdk, stainless, dns, cdn, zero-trust

## Member repositories
- cloudflare/cloudflare-go (main) score 98

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:06:10.735721+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T02:56:16.914135+00:00, confidence not recorded.
  - readme: https://github.com/cloudflare/cloudflare-go (fetched 2026-08-28T04:06:10.735721+00:00, sha fe253b984b03)
  - homepage: https://developers.cloudflare.com/api (fetched 2026-08-29T10:36:33.666823+00:00, sha 4bd7f498d8d4)
  - site_page: https://developers.cloudflare.com/api/resources/zero_trust/subresources/devices/subresources/posture/subresources/integrations (fetched 2026-08-29T10:36:33.675739+00:00, sha 6ba335b38239)
  - site_page: https://developers.cloudflare.com/api/resources/zero_trust/subresources/devices/subresources/posture/subresources/integrations/methods/list (fetched 2026-08-29T10:36:33.677731+00:00, sha 3dc4b6e97830)
  - site_page: https://developers.cloudflare.com/api/resources/zero_trust/subresources/devices/subresources/posture/subresources/integrations/methods/get (fetched 2026-08-29T10:36:33.679623+00:00, sha 6f09130e1b73)
  - site_page: https://developers.cloudflare.com/api/resources/zero_trust/subresources/devices/subresources/posture/subresources/integrations/methods/create (fetched 2026-08-29T10:36:33.681543+00:00, sha cda1fde59613)
  - site_page: https://developers.cloudflare.com/api/resources/zero_trust/subresources/devices/subresources/posture/subresources/integrations/methods/edit (fetched 2026-08-29T10:36:33.683234+00:00, sha 497756af6183)
  - site_page: https://developers.cloudflare.com/api/resources/zero_trust/subresources/devices/subresources/posture/subresources/integrations/methods/delete (fetched 2026-08-29T10:36:33.685510+00:00, sha a9975cba7c47)
  - site_page: https://developers.cloudflare.com/api/resources/zero_trust/subresources/casb/subresources/integrations (fetched 2026-08-29T10:36:33.687504+00:00, sha b4e1d7e82f8a)
  - site_page: https://developers.cloudflare.com/api/resources/zero_trust/subresources/casb/subresources/integrations/methods/list (fetched 2026-08-29T10:36:33.689472+00:00, sha 2cf93e6c3331)
- Data as of 2026-08-30T08:39:29.467469+00:00.
