Skip to main content
GET
/
cdn
/
presets
/
{preset_id}
Get preset details
curl --request GET \
  --url https://api.gcore.com/cdn/presets/{preset_id} \
  --header 'Authorization: <api-key>'
{
  "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
      }
    }
  }
}

Authorizations

Authorization
string
header
required

API key for authentication. Make sure to include the word apikey, followed by a single space and then your token. Example: apikey 1234$abcdef

Path Parameters

preset_id
integer
required

Preset ID.

Response

Successful.

id
integer
read-only

Preset ID.

Example:

42

name
string

Preset name.

Example:

"Static content acceleration"

service
enum<string>

Service the preset belongs to.

Available options:
cdn
Example:

"cdn"

object_type
enum<string>

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.
Available options:
CDNResource,
Rule
Example:

"CDNResource"

preset_settings
object

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:
{
"options": {
"browser_cache_settings": { "enabled": true, "value": "3600s" },
"gzipOn": { "enabled": true, "value": true }
}
}