> ## Documentation Index
> Fetch the complete documentation index at: https://docs.veadk.xyz/llms.txt
> Use this file to discover all available pages before exploring further.

# Manage environment resources

Use environment-resource, env-resource or er with a Volcengine account to manage a standalone EnvironmentResource for an agentkit or ark target. Create from a JSON or YAML specification and update with a patch. Supply the Ark Environment Key through an environment variable. Read the revision with show before updating. On conflict, reconcile against the latest state. Reuse the client token when retrying the same uncertain request.

> [!WARNING]
>
> Creation provisions cloud resources and may incur charges. For Ark, omitting role\_name allows the CLI to select or create a runtime role. Deletion reclaims the resource and retains a deletion record.

For an Ark target, put its environment ID and service base URL in resource.yaml and supply the key in the ANTHROPIC\_ENVIRONMENT\_KEY environment variable.

```yaml theme={null}
name: support-environment
target:
  type: ark
  environment_id: your-environment-id
  base_url: https://ark.example.com/api/v3
runtime: {}
```

The following patch.yaml changes only runtime capacity. Use the resource ID and revision returned by your environment.

```yaml theme={null}
runtime:
  resources:
    cpu_milli: 2000
    memory_mb: 4096
```

## environment-resource create

| Option | Description | Default |
| - | - | - |
| `--file <path>` | JSON or YAML resource specification without credentials | — |
| `--client-token <token>` | idempotency token (default: generated UUID) | — |
| `--environment-key-env <name>` | environment variable containing the Ark Environment key (default: ANTHROPIC\_ENVIRONMENT\_KEY) | — |
| `--wait` | wait until the resource leaves its active state | Off |
| `--timeout <seconds>` | wait timeout in seconds | 900 |
| `-r, --region <region>` | cloud region | — |
| `--json` | output raw JSON | Off |

```bash theme={null}
agentkit environment-resource create --file resource.yaml --wait
```

## environment-resource list

| Option | Description | Default |
| - | - | - |
| `--target-type <type>` | target type: agentkit or ark | — |
| `--environment-id <id>` | filter by target environment id | — |
| `--status <status>` | filter by resource status | — |
| `--include-deleted` | include deleted tombstones | Off |
| `--all` | fetch every page | Off |
| `--limit <number>` | page size, from 1 to 100 | 20 |
| `--page <token>` | opaque page token | — |
| `-r, --region <region>` | cloud region | — |
| `--json` | output raw JSON | Off |

```bash theme={null}
agentkit environment-resource list --target-type ark --json
```

## environment-resource show

`agentkit environment-resource show <resource-id>`

| Option | Description | Default |
| - | - | - |
| `-r, --region <region>` | cloud region | — |
| `--json` | output raw JSON | Off |

```bash theme={null}
agentkit environment-resource show "$RESOURCE_ID" --json
```

## environment-resource update

`agentkit environment-resource update <resource-id>`

| Option | Description | Default |
| - | - | - |
| `--file <path>` | JSON or YAML patch without operation fields or credentials | — |
| `--expected-revision <number>` | revision returned by the latest read | — |
| `--client-token <token>` | idempotency token (default: generated UUID) | — |
| `--environment-key-env <name>` | environment variable containing the Ark Environment key (default: ANTHROPIC\_ENVIRONMENT\_KEY) | — |
| `--wait` | wait until the resource leaves its active state | Off |
| `--timeout <seconds>` | wait timeout in seconds | 900 |
| `-r, --region <region>` | cloud region | — |
| `--json` | output raw JSON | Off |

```bash theme={null}
agentkit environment-resource update "$RESOURCE_ID" --file patch.yaml --expected-revision "$REVISION" --wait
```

## environment-resource delete

`agentkit environment-resource delete <resource-id>`

| Option | Description | Default |
| - | - | - |
| `--client-token <token>` | idempotency token (default: generated UUID) | — |
| `-y, --yes` | skip the confirmation prompt | Off |
| `--wait` | wait until deletion reaches a terminal state | Off |
| `--timeout <seconds>` | wait timeout in seconds | 900 |
| `-r, --region <region>` | cloud region | — |
| `--json` | output raw JSON | Off |

```bash theme={null}
agentkit environment-resource delete "$RESOURCE_ID" --wait
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.