---
title: "Get environment variable"
method: GET
path: "/v1/vaults/{vault_id}/env-vars/{key}"
tags: ["Environment Variables"]
---

# Get environment variable

`GET /v1/vaults/{vault_id}/env-vars/{key}`

## Request

- Base URL: `https://api.1claw.co`
- URL: `https://api.1claw.co/v1/vaults/{vault_id}/env-vars/{key}`
- Auth: HTTP bearer

## Path parameters

- `vault_id` string, uuid, required
- `key` string, required

## Query parameters

- `environment` string

## Response `200`

Environment variable

- EnvVar
  - `id` string, uuid
  - `key` string
  - `environments` string[]
  - `git_branch` string, nullable
  - `sensitive` boolean
  - `comment` string, nullable
  - `value` string, nullable: Null for sensitive vars in list responses
  - `version` integer
  - `created_by` string, nullable
  - `created_at` string, date-time
  - `updated_at` string, date-time

## Other responses

- `404`: Resource not found

---

[API](https://skmtc.dev/1claw/apis/1claw-api.md) · [All operations](https://skmtc.dev/1claw/apis/1claw-api/llms.txt) · [OpenAPI document](https://skmtc.dev/1claw/apis/1claw-api/revisions/5fa0918f3b41?raw)
