Presets

Get preset details

Changed on

Get information about a preset.

get/cdn/presets/{preset_id}

Request

  • Base URL
    https://api.gcore.com
  • URL
    https://api.gcore.com/cdn/presets/{preset_id}
  • Auth
    HTTP apikey

Path parameters

preset_idinteger required

Preset ID.

Response

Successful.

idinteger

Preset ID.

namestring

Preset name.

service'cdn'

Service the preset belongs to.

object_type'CDNResource' | 'Rule'

Type of object the preset can be applied to.

Possible values:

  • CDNResource - Preset is applied to a CDN resource.
  • Rule - Preset is applied to a rule.
preset_settingsPresetSettings

CDN resource or rule settings that the preset applies to the target object, including the options object.

The available keys match the writable fields of the object type the preset targets (object_type). Options included in the preset cannot be edited on the object while the preset is applied.

Example response

{
  "id": 42,
  "name": "Static content acceleration",
  "service": "cdn",
  "object_type": "CDNResource",
  "preset_settings": {
    "options": {
      "browser_cache_settings": {
        "enabled": true,
        "value": "3600s"
      },
      "gzipOn": {
        "enabled": true,
        "value": true
      }
    }
  }
}

Changes