create_project_variable
Create a new CI/CD project variable of env_var or file type, with masking, protection, and environment scope options to configure pipeline secrets.
Instructions
Create a new CI/CD project variable (env_var or file)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | Yes | Variable key/name (e.g. 'DATABASE_URL') | |
| raw | Yes | If true, variable value is not expanded | |
| value | Yes | Variable value | |
| masked | Yes | If true, variable value is masked in job logs | |
| protected | Yes | If true, variable is only passed to pipelines running on protected branches/tags | |
| project_id | Yes | Project numeric ID (e.g. 31) or namespace path (e.g. 'group/project-name'). URL-encoding is handled automatically. | |
| description | No | Optional description of the variable purpose | |
| variable_type | Yes | Variable type: 'env_var' or 'file' (default: env_var) | env_var |
| environment_scope | Yes | Environment scope for the variable (default: '*') | * |