Request headers

Read connecting IPs, forwarded request details, and client certificates in your server.

Manufact forwards request headers to your server and sets the following connection details automatically.

HeaderWhat your server receives
Manufact-Connecting-IPThe IP connecting to Manufact. Replaces caller-supplied values; omitted if unavailable. If another proxy is in front of Manufact, this can be that proxy's IP.
CF-Connecting-IPThe Cloudflare-provided connecting IP, preserved by Manufact. Normally matches Manufact-Connecting-IP.
X-Forwarded-ForThe value received by Manufact, preserved without adding or replacing addresses. May be absent or empty at ingress. Later proxies may add or append addresses before the request reaches your server.
X-Forwarded-HostThe public hostname used to reach your hosted server. Set by Manufact; may be omitted for external servers.
X-Forwarded-ProtoThe public request protocol, usually https. Set by Manufact.
Client-CertThe TLS client's leaf certificate, when available. Replaces caller-supplied values.
Client-Cert-ChainThe TLS client's intermediate certificates, when available. Replaces caller-supplied values.

Read these headers in your request handler:

const connectingIp = request.headers.get('Manufact-Connecting-IP');
const forwardedFor = request.headers.get('X-Forwarded-For');

Use Manufact-Connecting-IP for the connecting address on requests routed through Manufact. The contents of X-Forwarded-For can be caller-supplied; they do not prove a client's identity.

For certificate encoding, validation, and an OpenAI example, see Client certificates (mTLS). These headers work with your slug URL and custom domains.