Change Cache Reserve setting

Increase cache lifetimes by automatically storing all cacheable files into Cloudflare's persistent object storage buckets. Requires Cache Reserve subscription. Note: using Tiered Cache with Cache Reserve is highly recommended to reduce Reserve operations costs. See the [developer docs](https://developers.cloudflare.com/cache/about/cache-reserve) for more information.

/zones/{zone_identifier}/cache/cache_reserve

patch

Zone Cache Settings

zone-cache-settings-change-cache-reserve-setting

Debug "planAvailability"

{
  "business": true,
  "enterprise": true,
  "free": true,
  "pro": true
}

Debug "tokenPermissions"

{
  "enum": [
    "#zone_settings:edit"
  ]
}

Debug "parameters"

[
  {
    "in": "path",
    "name": "zone_identifier",
    "required": true,
    "schema": {
      "description": "Identifier",
      "example": "023e105f4ecef8ad9ca31a8372d0c353",
      "maxLength": 32,
      "readOnly": true,
      "type": "string"
    }
  }
]

Debug "requestBody"

{
  "content": {
    "application/json": {
      "schema": {
        "properties": {
          "value": {
            "default": "off",
            "description": "Value of the Cache Reserve zone setting.",
            "enum": [
              "on",
              "off"
            ],
            "type": "string"
          }
        },
        "required": [
          "value"
        ]
      }
    }
  },
  "required": true
}

Debug "responses"

{
  "200": {
    "content": {
      "application/json": {
        "examples": {
          "off": {
            "value": {
              "errors": [],
              "messages": [],
              "result": {
                "editable": true,
                "id": "cache_reserve",
                "value": "off"
              },
              "success": true
            }
          }
        },
        "schema": {
          "allOf": [
            {
              "allOf": [
                {
                  "allOf": [
                    {
                      "properties": {
                        "errors": {
                          "example": [],
                          "items": {
                            "properties": {
                              "code": {
                                "minimum": 1000,
                                "type": "integer"
                              },
                              "message": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "code",
                              "message"
                            ],
                            "type": "object",
                            "uniqueItems": true
                          },
                          "type": "array"
                        },
                        "messages": {
                          "example": [],
                          "items": {
                            "properties": {
                              "code": {
                                "minimum": 1000,
                                "type": "integer"
                              },
                              "message": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "code",
                              "message"
                            ],
                            "type": "object",
                            "uniqueItems": true
                          },
                          "type": "array"
                        },
                        "result": {
                          "anyOf": [
                            {
                              "type": "object"
                            },
                            {
                              "items": {},
                              "type": "array"
                            },
                            {
                              "type": "string"
                            }
                          ]
                        },
                        "success": {
                          "description": "Whether the API call was successful",
                          "enum": [
                            true
                          ],
                          "example": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "success",
                        "errors",
                        "messages",
                        "result"
                      ],
                      "type": "object"
                    },
                    {
                      "properties": {
                        "result": {
                          "anyOf": [
                            {
                              "nullable": true,
                              "type": "object"
                            },
                            {
                              "nullable": true,
                              "type": "string"
                            }
                          ]
                        }
                      }
                    }
                  ],
                  "type": "object"
                },
                {
                  "properties": {
                    "result": {
                      "type": "object"
                    }
                  }
                }
              ]
            },
            {
              "properties": {
                "result": {
                  "allOf": [
                    {
                      "allOf": [
                        {
                          "properties": {
                            "id": {
                              "description": "Identifier of the zone setting.",
                              "type": "string"
                            },
                            "modified_on": {
                              "description": "last time this setting was modified.",
                              "example": "2014-01-01T05:20:00.12345Z",
                              "format": "date-time",
                              "nullable": true,
                              "readOnly": true,
                              "type": "string"
                            }
                          },
                          "required": [
                            "id",
                            "modified_on"
                          ]
                        },
                        {
                          "properties": {
                            "id": {
                              "description": "ID of the zone setting.",
                              "enum": [
                                "cache_reserve"
                              ],
                              "example": "cache_reserve"
                            }
                          }
                        }
                      ],
                      "description": "Increase cache lifetimes by automatically storing all cacheable files into Cloudflare's persistent object storage buckets. Requires Cache Reserve subscription. Note: using Tiered Cache with Cache Reserve is highly recommended to reduce Reserve operations costs. See the [developer docs](https://developers.cloudflare.com/cache/about/cache-reserve) for more information.",
                      "title": "Cache Reserve"
                    },
                    {
                      "properties": {
                        "value": {
                          "default": "off",
                          "description": "Value of the Cache Reserve zone setting.",
                          "enum": [
                            "on",
                            "off"
                          ],
                          "type": "string"
                        }
                      },
                      "required": [
                        "value"
                      ]
                    }
                  ]
                }
              }
            }
          ]
        }
      }
    },
    "description": "Change Cache Reserve setting response"
  },
  "4XX": {
    "content": {
      "application/json": {
        "examples": {
          "Denied": {
            "value": {
              "errors": [
                {
                  "code": 1153,
                  "message": "Cache Reserve cannot be enabled because a deletion is already in progress."
                }
              ],
              "messages": [],
              "result": null,
              "success": false
            }
          }
        },
        "schema": {
          "allOf": [
            {
              "allOf": [
                {
                  "allOf": [
                    {
                      "allOf": [
                        {
                          "properties": {
                            "errors": {
                              "example": [],
                              "items": {
                                "properties": {
                                  "code": {
                                    "minimum": 1000,
                                    "type": "integer"
                                  },
                                  "message": {
                                    "type": "string"
                                  }
                                },
                                "required": [
                                  "code",
                                  "message"
                                ],
                                "type": "object",
                                "uniqueItems": true
                              },
                              "type": "array"
                            },
                            "messages": {
                              "example": [],
                              "items": {
                                "properties": {
                                  "code": {
                                    "minimum": 1000,
                                    "type": "integer"
                                  },
                                  "message": {
                                    "type": "string"
                                  }
                                },
                                "required": [
                                  "code",
                                  "message"
                                ],
                                "type": "object",
                                "uniqueItems": true
                              },
                              "type": "array"
                            },
                            "result": {
                              "anyOf": [
                                {
                                  "type": "object"
                                },
                                {
                                  "items": {},
                                  "type": "array"
                                },
                                {
                                  "type": "string"
                                }
                              ]
                            },
                            "success": {
                              "description": "Whether the API call was successful",
                              "enum": [
                                true
                              ],
                              "example": true,
                              "type": "boolean"
                            }
                          },
                          "required": [
                            "success",
                            "errors",
                            "messages",
                            "result"
                          ],
                          "type": "object"
                        },
                        {
                          "properties": {
                            "result": {
                              "anyOf": [
                                {
                                  "nullable": true,
                                  "type": "object"
                                },
                                {
                                  "nullable": true,
                                  "type": "string"
                                }
                              ]
                            }
                          }
                        }
                      ],
                      "type": "object"
                    },
                    {
                      "properties": {
                        "result": {
                          "type": "object"
                        }
                      }
                    }
                  ]
                },
                {
                  "properties": {
                    "result": {
                      "allOf": [
                        {
                          "allOf": [
                            {
                              "properties": {
                                "id": {
                                  "description": "Identifier of the zone setting.",
                                  "type": "string"
                                },
                                "modified_on": {
                                  "description": "last time this setting was modified.",
                                  "example": "2014-01-01T05:20:00.12345Z",
                                  "format": "date-time",
                                  "nullable": true,
                                  "readOnly": true,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "id",
                                "modified_on"
                              ]
                            },
                            {
                              "properties": {
                                "id": {
                                  "description": "ID of the zone setting.",
                                  "enum": [
                                    "cache_reserve"
                                  ],
                                  "example": "cache_reserve"
                                }
                              }
                            }
                          ],
                          "description": "Increase cache lifetimes by automatically storing all cacheable files into Cloudflare's persistent object storage buckets. Requires Cache Reserve subscription. Note: using Tiered Cache with Cache Reserve is highly recommended to reduce Reserve operations costs. See the [developer docs](https://developers.cloudflare.com/cache/about/cache-reserve) for more information.",
                          "title": "Cache Reserve"
                        },
                        {
                          "properties": {
                            "value": {
                              "default": "off",
                              "description": "Value of the Cache Reserve zone setting.",
                              "enum": [
                                "on",
                                "off"
                              ],
                              "type": "string"
                            }
                          },
                          "required": [
                            "value"
                          ]
                        }
                      ]
                    }
                  }
                }
              ]
            },
            {
              "properties": {
                "errors": {
                  "allOf": [
                    {
                      "example": [],
                      "items": {
                        "properties": {
                          "code": {
                            "minimum": 1000,
                            "type": "integer"
                          },
                          "message": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "code",
                          "message"
                        ],
                        "type": "object",
                        "uniqueItems": true
                      },
                      "type": "array"
                    }
                  ],
                  "example": [
                    {
                      "code": 7003,
                      "message": "No route for the URI"
                    }
                  ],
                  "minLength": 1
                },
                "messages": {
                  "allOf": [
                    {
                      "example": [],
                      "items": {
                        "properties": {
                          "code": {
                            "minimum": 1000,
                            "type": "integer"
                          },
                          "message": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "code",
                          "message"
                        ],
                        "type": "object",
                        "uniqueItems": true
                      },
                      "type": "array"
                    }
                  ],
                  "example": []
                },
                "result": {
                  "enum": [
                    null
                  ],
                  "nullable": true,
                  "type": "object"
                },
                "success": {
                  "description": "Whether the API call was successful",
                  "enum": [
                    false
                  ],
                  "example": false,
                  "type": "boolean"
                }
              },
              "required": [
                "success",
                "errors",
                "messages",
                "result"
              ],
              "type": "object"
            }
          ]
        }
      }
    },
    "description": "Change Cache Reserve setting response failure"
  }
}

Debug "security"

[
  {
    "api_email": [],
    "api_key": []
  }
]