# veryfront__update_environment

Update an environment. Requires project.environments.manage.

Risk: mutating.

## Arguments

| Name                | Type    | Required | Description                                                                                                                                                                                        |
| ------------------- | ------- | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `project_reference` | string  |          | Project ID or slug                                                                                                                                                                                 |
| `environment_id`    | string  | Yes      | Environment ID                                                                                                                                                                                     |
| `name`              | string  |          | New environment name                                                                                                                                                                               |
| `protected`         | boolean |          | Whether the environment is protected                                                                                                                                                               |
| `variables`         | array   |          | Atomic variable upserts in this environment. Existing keys retain their IDs; omitted keys remain unchanged and returned values are masked. A non-empty list also requires project.env\_vars.write. |

## Call it

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "veryfront__update_environment",
    "arguments": {
      "environment_id": "<environment_id>"
    }
  }
}
```
