CorefinityCorefinityDocs
Open the Control PanelControl Panel
Varnish · 11 of 19

Get the platform's part of the VCL

Answers the VCL the platform runs for the site, read only, and where each of your snippets is inserted into it.

GET/api/corestack/sites/{site}/varnish/vcl/platform

Path parameters

siteintegerRequired

The id of a site row. A website's production site and each of its environments has its own id. Digits only. At least 1.

Returns

200 The platform's VCL.

Fields of the 200 answer
contentstring or nullRequired

The platform's VCL.

insertionobjectRequired

The line of the platform's VCL where each snippet is inserted. Null where it is not known.

Fields
backend_responseinteger or null
deliverinteger or null
recvinteger or null

If it is refused

StatusReasonWhat to do
401noneSend a valid token as Authorization: Bearer <token>.
403company_unavailableYour company is unavailable.
403scope_requiredUse a token with the scope named in scope.
403two_factor_requiredTurn on two-factor on your account, then send again.
404feature_offThis feature is not on for your organisation yet.
409varnish_not_offeredVarnish is available for Magento 2 sites only. Nothing to change here.
429rate_limitedWait for the seconds in Retry-After.

Reasons are listed by name in Errors and refusals.

The same task elsewhere

curl https://manage.corefinity.com/api/corestack/sites/1042/varnish/vcl/platform \
  -H "Authorization: Bearer $COREFINITY_TOKEN" \
  -H "Accept: application/json"
{
  "content": "vcl 4.1;\n\nimport std;\n\nsub vcl_recv {\n    # ...\n}\n",
  "insertion": {
    "backend_response": 212,
    "deliver": 264,
    "recv": 118
  }
}
Try it
Held in this tab's memory only. Never stored or sent to us.

Use a token with only the read scope. How to make one

Was this helpful?
Open in ClaudeOpen in ChatGPT