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

# Update Stack

> Renames a stack or changes its description.

Changes the name or the description of a stack. At least one field is required. Needs the `stacks:write` scope when called with an API key.

**stack\_id** `string` *required*

The stack ID.

**workspace\_id** `string`

The workspace the stack belongs to, when you act on it as the workspace owner.

**name** `string`

The new name.

**description** `string | null`

The new description. `null` removes it.

### Response

**response** `object`

The updated stack, with the same fields as [Get Stack](https://docs.vertracloud.app/api-reference/endpoint/stacks/get.md).

```bash cURL theme={null}
curl -X PATCH https://api.vertracloud.app/v1/stacks/stk-abc123def456 \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ "name": "shop-prod" }'
```

### Errors

| Status | Code | When |
| - | - | - |
| 400 | `VALIDATION_ERROR` | No field was sent, or a value is invalid. |
| 403 | `WORKSPACE_OWNER_ONLY` | You are a workspace member, not the owner. |
| 404 | `STACK_NOT_FOUND` | The stack does not exist or belongs to another account. |


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