# Team programs: update, delete

URL: /code/mcp/team/records-update · Id: `page:code/mcp/team/records-update`

> The Team Verbs update, delete as MCP do programs, with inputs, result, refusals and an example.

Reference for [Team](/business/nouns/team), one group of [Team programs](/code/mcp/team).

### Team.update
Changes the given properties of a Team. [Verb page](/business/nouns/team/update?interface=mcp).

```text
do: return await $.Team.update(input)
```

Emits `Team.updated`.

**Inputs**

| Input | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | `string` | Yes | The id of the Team. |
| `mission` | `text` | No | What the Team is for, in one sentence. |

**Returns**

| Output | Type | Required | Description |
| --- | --- | --- | --- |
| `team` | [Team](/business/nouns/team) | Yes | The Team. |

**Refuses when**

| Check | Error | Fix | Then call |
| --- | --- | --- | --- |
| The key is valid, but its scopes do not allow this operation. | [`forbidden`](/code/api/errors/forbidden) | Use a key whose scopes cover the operation, or ask an owner of the namespace to grant them. | None. |

**Example**

```json
{
  "name": "do",
  "arguments": {
    "code": "return await $.Team.update({ id: 'team_v8KkFBrXCN', mission: 'Example mission' })"
  }
}
```

### Team.delete
Deletes a Team: a soft delete that keeps its history, undone by `Thing.restore`. [Verb page](/business/nouns/team/delete?interface=mcp).

```text
do: return await $.Team.delete(input)
```

Emits `Team.deleted`.

**Inputs**

| Input | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | `string` | Yes | The id of the Team. |

**Returns**

| Output | Type | Required | Description |
| --- | --- | --- | --- |
| `team` | [Team](/business/nouns/team) | Yes | The Team. |

**Refuses when**

| Check | Error | Fix | Then call |
| --- | --- | --- | --- |
| The key is valid, but its scopes do not allow this operation. | [`forbidden`](/code/api/errors/forbidden) | Use a key whose scopes cover the operation, or ask an owner of the namespace to grant them. | None. |

**Example**

```json
{
  "name": "do",
  "arguments": {
    "code": "return await $.Team.delete({ id: 'team_v8KkFBrXCN' })"
  }
}
```