# linear_workflow_state (Resource)

Manages a workflow state (issue status) of a Linear team.

Destroying the resource archives the state — Linear has no hard delete for workflow states. A state that still holds issues cannot be archived until they are moved.

## Example Usage

```terraform
resource "linear_workflow_state" "in_review" {
  team_id  = linear_team.engineering.id
  name     = "In Review"
  color    = "#0f7488"
  type     = "started"
  position = 2
}

# `type` is a plain string, not an enum — which is what makes `duplicate`
# manageable here.
resource "linear_workflow_state" "duplicate" {
  team_id = linear_team.engineering.id
  name    = "Duplicate"
  color   = "#95a2b3"
  type    = "duplicate"
}
```

<!-- schema generated by tfplugindocs -->
## Schema

### Required

- `color` (String) Colour of the state as a hex string, e.g. `#f2c94c`.
- `name` (String) Name of the state, e.g. `In Review`.
- `team_id` (String) UUID of the team the state belongs to. Changing it replaces the state — `workflowStateUpdate` has no `teamId`.
- `type` (String) Category the state belongs to — one of `triage`, `backlog`, `unstarted`, `started`, `completed`, `canceled`, `duplicate`. Changing it replaces the state, since `workflowStateUpdate` has no `type`.

### Optional

- `description` (String) Description of the state.
- `position` (Number) Sort position of the state within its category. Linear assigns one when unset.

### Read-Only

- `id` (String) UUID of the workflow state.

## Import

Import is supported using the following syntax:

The [`terraform import` command](https://developer.hashicorp.com/terraform/cli/commands/import) can be used, for example:

```shell
# Import by UUID.
terraform import linear_workflow_state.example a1b2c3d4-0000-0000-0000-000000000000
```