origin_max_http_version
Creates, updates, deletes, gets or lists an origin_max_http_version resource.
Overview
| Name | origin_max_http_version |
| Type | Resource |
| Id | cloudflare.zones.origin_max_http_version |
Fields
The following fields are returned by SELECT queries:
- list
Get Origin Max HTTP Version setting response.
| Name | Datatype | Description |
|---|---|---|
id | string | The identifier of the caching setting. (origin_max_http_version) |
editable | boolean | Whether the setting is editable. |
modified_on | string (date-time) | Last time this setting was modified. (example: 2014-01-01T05:20:00.12345Z) |
value | string | Value of the Origin Max HTTP Version Setting. (2, 1) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
list | select | zone_id | Origin Max HTTP Setting Version sets the highest HTTP version Cloudflare will attempt to use with your origin. This setting allows Cloudflare to make HTTP/2 requests to your origin. (Refer to Enable HTTP/2 to Origin, for more information.). The default value is "2" for all plan types except Enterprise where it is "1". | |
zone_cache_settings_change_origin_max_http_version_setting | update | zone_id, value | Origin Max HTTP Setting Version sets the highest HTTP version Cloudflare will attempt to use with your origin. This setting allows Cloudflare to make HTTP/2 requests to your origin. (Refer to Enable HTTP/2 to Origin, for more information.). The default value is "2" for all plan types except Enterprise where it is "1". |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
zone_id | string | The Cloudflare zone ID. |
SELECT examples
- list
Origin Max HTTP Setting Version sets the highest HTTP version Cloudflare will attempt to use with your origin. This setting allows Cloudflare to make HTTP/2 requests to your origin. (Refer to Enable HTTP/2 to Origin, for more information.). The default value is "2" for all plan types except Enterprise where it is "1".
SELECT
id,
editable,
modified_on,
value
FROM cloudflare.zones.origin_max_http_version
WHERE zone_id = '{{ zone_id }}' -- required
;
UPDATE examples
- zone_cache_settings_change_origin_max_http_version_setting
Origin Max HTTP Setting Version sets the highest HTTP version Cloudflare will attempt to use with your origin. This setting allows Cloudflare to make HTTP/2 requests to your origin. (Refer to Enable HTTP/2 to Origin, for more information.). The default value is "2" for all plan types except Enterprise where it is "1".
UPDATE cloudflare.zones.origin_max_http_version
SET
value = '{{ value }}'
WHERE
zone_id = '{{ zone_id }}' --required
AND value = '{{ value }}' --required
RETURNING
errors,
messages,
result,
success;