create_workspace_variable
Create and configure Terraform or environment variables within a workspace, allowing customization of HCL code, descriptions, and sensitive value flags for enhanced infrastructure management.
Instructions
Create a new variable in a workspace.
Creates a new Terraform or environment variable within a workspace. Variables can be marked as sensitive to hide their values.
API endpoint: POST /workspaces/{workspace_id}/vars
Args: workspace_id: The ID of the workspace (format: "ws-xxxxxxxx") key: The variable name/key category: Variable category ("terraform" or "env")
Returns: The created variable with its configuration and metadata
See: docs/tools/variables.md#create-workspace-variable for reference documentation
Input Schema
Name | Required | Description | Default |
---|---|---|---|
category | Yes | ||
key | Yes | ||
params | No | ||
workspace_id | Yes |