---
title: "Generate Terraform Variables from Repository"
method: GET
path: "/blueprints/variables-from-repository"
tags: ["Templates"]
---

# Generate Terraform Variables from Repository

`GET /blueprints/variables-from-repository`

Clones and searches through a Template git repository for any Terraform variable blocks and returns a set of env0 Terraform Configuration Variables that may be added to env0 via the Configuration API

## Query parameters

- `repository` string, required
- `revision` string
- `path` string
- `tokenId` string
- `sshKeyIds` string
- `githubInstallationId` string
- `bitbucketClientKey` string
- `vcsConnectionId` string

## Response `200`

- ConfigurationApiRepositoryVariable[]
  - `name` string, required
  - `value` string
  - `id` string — The ID of the configuration property. If provided, will act as an update. Otherwise, a new configuration property will be created.
  - `isSensitive` boolean
  - `isReadonly` boolean
  - `isRequired` boolean
  - `regex` string
  - `scope` 'SET' | 'GLOBAL' | 'BLUEPRINT' | 'SUB_ENVIRONMENT_BLUEPRINT' | 'PROJECT' | 'WORKFLOW' | 'ENVIRONMENT' | 'DEPLOYMENT' | 'SET' | 'GLOBAL' | 'BLUEPRINT' | 'SUB_ENVIRONMENT_BLUEPRINT' | 'PROJECT' | 'WORKFLOW' | 'ENVIRONMENT' | 'DEPLOYMENT' | 'SET' | 'GLOBAL' | 'BLUEPRINT' | 'SUB_ENVIRONMENT_BLUEPRINT' | 'PROJECT' | 'WORKFLOW' | 'ENVIRONMENT' | 'DEPLOYMENT' | 'SET' | 'GLOBAL' | 'BLUEPRINT' | 'SUB_ENVIRONMENT_BLUEPRINT' | 'PROJECT' | 'WORKFLOW' | 'ENVIRONMENT' | 'DEPLOYMENT' | 'SET' | 'GLOBAL' | 'BLUEPRINT' | 'SUB_ENVIRONMENT_BLUEPRINT' | 'PROJECT' | 'WORKFLOW' | 'ENVIRONMENT' | 'DEPLOYMENT', required
  - `type` 0 | 1 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 1, required
  - `toDelete` boolean
  - `projectId` string
  - `schema` PartialJSONSchema7
    - `type` 'string' | 'array' | 'string' | 'array' | 'string' | 'array' | 'string' | 'array' | 'string' | 'array'
    - `enum` string[]
    - `format` 'HCL' | 'JSON' | 'ENVIRONMENT_OUTPUT' | 'HCL' | 'JSON' | 'ENVIRONMENT_OUTPUT' | 'HCL' | 'JSON' | 'ENVIRONMENT_OUTPUT' | 'HCL' | 'JSON' | 'ENVIRONMENT_OUTPUT' | 'HCL' | 'JSON' | 'ENVIRONMENT_OUTPUT'
  - `description` string
  - `isOutput` boolean

---

[API](https://skmtc.dev/envzero/apis/env0-api.md) · [All operations](https://skmtc.dev/envzero/apis/env0-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/envzero/env0-api/revisions/513441cbe9dc/schema)
