API parameter reference
Create different overrides by including different action parameters in the action_parameters
field:
Override type | What to include |
---|---|
Host header override | host_header parameter |
SNI override | sni object |
DNS record override / Destination port override | origin object |
The full syntax of the action_parameters
field for overriding the HTTP Host
header is the following:
"action_parameters": { "host_header": "<HOST_HEADER_VALUE>"}
The full syntax of the action_parameters
field for overriding the SNI value of incoming requests is the following:
"action_parameters": { "sni": { "value": "<SNI_VALUE>" }}
The full syntax of the action_parameters
field for overriding both the hostname and the destination port of incoming requests is the following:
"action_parameters": { "origin": { "host": "<HOSTNAME>", "port": <PORT> }}
If you are only overriding the hostname or the port, omit the port
or host
parameter, respectively.
The same origin rule can have different types of overrides. For example, a single origin rule can perform an HTTP Host
header override and a destination port override. The syntax of such a rule would be the following:
"action_parameters": { "host_header": "<HOST_HEADER_VALUE>", "origin": { "port": <PORT> }}
Was this helpful?
- Resources
- API
- New to Cloudflare?
- Products
- Sponsorships
- Open Source
- Support
- Help Center
- System Status
- Compliance
- GDPR
- Company
- cloudflare.com
- Our team
- Careers
- 2025 Cloudflare, Inc.
- Privacy Policy
- Terms of Use
- Report Security Issues
- Trademark