# project_trash

> Trash or restore project. Move a project to the trash, or restore it with restore=true.

Source: https://stuarty.com/docs/mcp/tools/project_trash/

Move a project to the trash, or restore it with restore=true.

## Behaviour

These are the annotations of the tool definition, the hints a client uses to decide whether to ask before a call. `project_trash` is listed by `tools/list`.

| Property | Value |
| --- | --- |
| Read only | no |
| Destructive | no |
| Idempotent | yes |
| Reaches outside the workspace | no |

## Input

| Argument | Type | Required | Notes |
| --- | --- | --- | --- |
| `project_id` | `string` | yes | pattern `^prj_[0-9a-hjkmnp-tv-z]{10}$` |
| `restore` | `boolean` | no | default `false` |

## Output

A result has a text block, written for the model, and structured content with these members.

| Member | Type | Always present | Notes |
| --- | --- | --- | --- |
| `project_id` | `string` | yes |  |
| `state` | `active`, `trashed` | yes |  |

## Errors

- [`E_VALIDATION`](/docs/reference/error-codes#e_validation)
- [`E_NOT_FOUND`](/docs/reference/error-codes#e_not_found)

A call over HTTP without credentials fails with `E_UNAUTHORIZED`, and too many calls with `E_RATE_LIMITED`. Both are in the [error codes](/docs/reference/error-codes).

## Safety

- Nothing is deleted for good: the project and its history stay intact, and `restore` brings the project back.

## Next steps

- [Connect a client](/docs/mcp/connect)
- [The MCP tools](/docs/mcp/tools)

**Ask the agent**

> Move the project Launch teaser to the trash.

**The call**

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "project_trash",
    "arguments": {
      "project_id": "prj_7k2m9x4q1b"
    }
  }
}
```

**The result**

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "content": [
      {
        "type": "text",
        "text": "…"
      }
    ],
    "structuredContent": {
      "project_id": "prj_7k2m9x4q1b",
      "state": "trashed"
    }
  }
}
```

The values are illustrative. The text block holds the same result written for the model; its wording is left out here.
