create_env_var
Set environment variables on a Vercel project, targeting specific deployment environments such as production, preview, or development.
Instructions
Create an environment variable on a project. target is which environments it applies to (production/preview/development). type defaults to 'encrypted'.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"projectId": "<projectId>",
"key": "<key>",
"value": "<value>",
"target": "<target>"
},
"name": "create_env_var"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| projectId | Yes | Project id or name. | |
| key | Yes | Variable name, e.g. API_KEY. | |
| value | Yes | Variable value. | |
| target | Yes | Environments this var applies to. | |
| type | No | Variable type. Default encrypted. | |
| gitBranch | No | Limit to a specific preview branch. | |
| comment | No | Optional note. | |
| teamId | No | Team ID to scope the request. Falls back to VERCEL_TEAM_ID when omitted. | |
| slug | No | Team slug to scope the request (alternative to teamId). |