Delete an existing instance-level variable

DELETE /admin/ci/variables/{key}

Delete an existing instance-level variable

Path parameters

  • key string Required

    The key of a variable

Responses

  • 204 application/json

    Delete an existing instance-level variable

    Hide response attributes Show response attributes object
    • variable_type string
    • key string
    • value string
    • protected boolean
    • masked boolean
    • raw boolean
    • environment_scope string
  • 404

    Instance Variable Not Found

DELETE /admin/ci/variables/{key}
curl \
 --request DELETE 'https://www.gitlab.com/api/v4/admin/ci/variables/{key}' \
 --header "Private-Token: $API_KEY"
Response examples (204)
{
  "variable_type": "env_var",
  "key": "TEST_VARIABLE_1",
  "value": "TEST_1",
  "protected": true,
  "masked": true,
  "raw": true,
  "environment_scope": "*"
}