CorefinityCorefinityDocs
Open the Control PanelControl Panel
Environment variables · 4 of 4

Reveal a variable's value

Answers the variable's stored value, the only endpoint that does. It needs a token with the exec scope, and the answer is never cached.

POST/api/environments/{environment}/variables/{name}/reveal

Path parameters

environmentintegerRequired

The id of a CoreStack Enterprise environment. Not the same number as a site row id. At least 1.

namestringRequired

The variable's name, without the CF_ prefix builds see it with. A new name is letters, digits and underscores, starting with a letter or underscore, at most 64 characters; a variable the environment already has is found by its stored name as it is, whatever the rules were when it was saved.

Returns

200 The variable's name and its value.

Fields of the 200 answer
namestringRequired
valuestringRequired

The stored value. An empty string for a cleared variable.

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.
404noneCheck the id. You see only what your account can reach.
409not_availableThe tool does not apply to this object.
422invalidFix the field named in field; errors says why.
429rate_limitedWait for the seconds in Retry-After.

Reasons are listed by name in Errors and refusals.

The same task elsewhere

curl -X POST https://manage.corefinity.com/api/environments/1311/variables/API_TOKEN/reveal \
  -H "Authorization: Bearer $COREFINITY_TOKEN" \
  -H "Accept: application/json"
{
  "name": "API_TOKEN",
  "value": "example-value-not-a-real-secret"
}
Try it

Try it is off for this endpointIt reveals a secret. Copy the request and run it yourself when you are sure.

Was this helpful?
Open in ClaudeOpen in ChatGPT