Skip to content
Start here

Pools

List Pools
client.LoadBalancers.Pools.List(ctx, params) (*SinglePage[Pool], error)
GET/accounts/{account_id}/load_balancers/pools
Pool Details
client.LoadBalancers.Pools.Get(ctx, poolID, query) (*Pool, error)
GET/accounts/{account_id}/load_balancers/pools/{pool_id}
Create Pool
client.LoadBalancers.Pools.New(ctx, params) (*Pool, error)
POST/accounts/{account_id}/load_balancers/pools
Update Pool
client.LoadBalancers.Pools.Update(ctx, poolID, params) (*Pool, error)
PUT/accounts/{account_id}/load_balancers/pools/{pool_id}
Patch Pool
client.LoadBalancers.Pools.Edit(ctx, poolID, params) (*Pool, error)
PATCH/accounts/{account_id}/load_balancers/pools/{pool_id}
Delete Pool
client.LoadBalancers.Pools.Delete(ctx, poolID, body) (*PoolDeleteResponse, error)
DELETE/accounts/{account_id}/load_balancers/pools/{pool_id}
Patch Pools
client.LoadBalancers.Pools.BulkEdit(ctx, params) (*SinglePage[Pool], error)
PATCH/accounts/{account_id}/load_balancers/pools
ModelsExpand Collapse
type Pool struct{…}
ID stringoptional
CheckRegions []CheckRegionoptional

A list of regions from which to run health checks. Null means every Cloudflare data center.

One of the following:
const CheckRegionWnam CheckRegion = "WNAM"
const CheckRegionEnam CheckRegion = "ENAM"
const CheckRegionWeu CheckRegion = "WEU"
const CheckRegionEeu CheckRegion = "EEU"
const CheckRegionNsam CheckRegion = "NSAM"
const CheckRegionSsam CheckRegion = "SSAM"
const CheckRegionOc CheckRegion = "OC"
const CheckRegionMe CheckRegion = "ME"
const CheckRegionNaf CheckRegion = "NAF"
const CheckRegionSaf CheckRegion = "SAF"
const CheckRegionSas CheckRegion = "SAS"
const CheckRegionSeas CheckRegion = "SEAS"
const CheckRegionNeas CheckRegion = "NEAS"
const CheckRegionAllRegions CheckRegion = "ALL_REGIONS"
CreatedOn stringoptional
Description stringoptional

A human-readable description of the pool.

DisabledAt Timeoptional

This field shows up only if the pool is disabled. This field is set with the time the pool was disabled at.

formatdate-time
Enabled booloptional

Whether to enable (the default) or disable this pool. Disabled pools will not receive traffic and are excluded from health checks. Disabling a pool will cause any load balancers using it to failover to the next pool (if any).

Latitude float64optional

The latitude of the data center containing the origins used in this pool in decimal degrees. If this is set, longitude must also be set.

LoadShedding LoadSheddingoptional

Configures load shedding policies and percentages for the pool.

Longitude float64optional

The longitude of the data center containing the origins used in this pool in decimal degrees. If this is set, latitude must also be set.

MinimumOrigins int64optional

The minimum number of origins that must be healthy for this pool to serve traffic. If the number of healthy origins falls below this number, the pool will be marked unhealthy and will failover to the next available pool.

ModifiedOn stringoptional
Monitor stringoptional

The ID of the Monitor to use for checking the health of origins within this pool.

MonitorGroup stringoptional

The ID of the Monitor Group to use for checking the health of origins within this pool.

Name stringoptional

A short name (tag) for the pool. Only alphanumeric characters, hyphens, and underscores are allowed.

Networks []stringoptional

List of networks where Load Balancer or Pool is enabled.

NotificationEmail stringoptional

This field is now deprecated. It has been moved to Cloudflare's Centralized Notification service https://developers.cloudflare.com/fundamentals/notifications/. The email address to send health status notifications to. This can be an individual mailbox or a mailing list. Multiple emails can be supplied as a comma delimited list.

NotificationFilter NotificationFilteroptional

Filter pool and origin health notifications by resource type or health status. Use null to reset.

OriginSteering OriginSteeringoptional

Configures origin steering for the pool. Controls how origins are selected for new sessions and traffic without session affinity.

Origins []Originoptional

The list of origins within this pool. Traffic directed at this pool is balanced across all currently healthy origins, provided the pool itself is healthy.

Address stringoptional

The IP address (IPv4 or IPv6) of the origin, or its publicly addressable hostname. Hostnames entered here should resolve directly to the origin, and not be a hostname proxied by Cloudflare. To set an internal/reserved address, virtual_network_id must also be set.

DisabledAt Timeoptional

This field shows up only if the origin is disabled. This field is set with the time the origin was disabled.

formatdate-time
Enabled booloptional

Whether to enable (the default) this origin within the pool. Disabled origins will not receive traffic and are excluded from health checks. The origin will only be disabled for the current pool.

Header Headeroptional

The request header is used to pass additional information with an HTTP request. Currently supported header is 'Host'.

Name stringoptional

A human-identifiable name for the origin.

Port int64optional

The port for upstream connections. A value of 0 means the default port for the protocol will be used.

VirtualNetworkID stringoptional

The virtual network subnet ID the origin belongs in. Virtual network must also belong to the account.

Weight float64optional

The weight of this origin relative to other origins in the pool. Based on the configured weight the total traffic is distributed among origins within the pool.

  • origin_steering.policy="least_outstanding_requests": Use weight to scale the origin's outstanding requests.
  • origin_steering.policy="least_connections": Use weight to scale the origin's open connections.
maximum1
minimum0
multipleOf0.01

PoolsHealth

Pool Health Details
client.LoadBalancers.Pools.Health.Get(ctx, poolID, query) (*PoolHealthGetResponse, error)
GET/accounts/{account_id}/load_balancers/pools/{pool_id}/health
Preview Pool
client.LoadBalancers.Pools.Health.New(ctx, poolID, params) (*PoolHealthNewResponse, error)
POST/accounts/{account_id}/load_balancers/pools/{pool_id}/preview

PoolsReferences

List Pool References
client.LoadBalancers.Pools.References.Get(ctx, poolID, query) (*SinglePage[PoolReferenceGetResponse], error)
GET/accounts/{account_id}/load_balancers/pools/{pool_id}/references