pub struct Cf { /* private fields */ }
Expand description
In addition to the methods on the Request
struct, the Cf
struct on an inbound Request contains information about the request provided by Cloudflare’s edge.
Implementations
The three-letter airport code (e.g. ATX
, LUX
) representing
the colocation which processed the request
The two-letter country code of origin for the request.
This is the same value as that provided in the CF-IPCountry header, e.g. "US"
The HTTP Protocol (e.g. “HTTP/2”) used by the request
The browser-requested prioritization information in the request object,
See this blog post for details.
The cipher for the connection to Cloudflare, e.g. “AEAD-AES128-GCM-SHA256”.
Information about the client’s authorization. Only set when using Cloudflare Access or API Shield.
The TLS version of the connection to Cloudflare, e.g. TLSv1.3.
Latitude and longitude of the incoming request, e.g. (30.27130, -97.74260)
Postal code of the incoming request, e.g. “78701”
Metro code (DMA) of the incoming request, e.g. “635”
If known, the ISO 3166-2 name for the first level region associated with the IP address of the incoming request, e.g. “Texas”.
If known, the ISO 3166-2 code for the first level region associated with the IP address of the incoming request, e.g. “TX”.