# Issue routes: schedule, triage

URL: /code/api/issue/verbs-schedule · Id: `page:code/api/issue/verbs-schedule`

> The Issue Verbs schedule, triage as api.sb routes, with inputs, result, refusals and an example.

Reference for [Issue](/business/nouns/issue), one group of [Issue routes](/code/api/issue).

### Issue.schedule
Schedule commits an Issue to a week of work and records each scope change after the week starts. [Verb page](/business/nouns/issue/schedule?interface=api).

```text
POST /{namespace}/issues/{issue}/schedule
```

Path: `issue`. Body, as JSON: the other inputs. Emits [`Issue.scheduled`](/business/events/Issue.scheduled).

**Inputs**

| Input | Type | Required | Description |
| --- | --- | --- | --- |
| `issue` | [Issue](/business/nouns/issue) | Yes | The Issue to commit. |
| `week` | `date` | Yes | The first day of the week it is committed to. |

**Returns**

| Output | Type | Required | Description |
| --- | --- | --- | --- |
| `issue` | [Issue](/business/nouns/issue) | Yes | The scheduled Issue. |

**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**

```bash
curl -X POST https://api.sb/leaseline.app/issues/issue_vWekeqrXCN/schedule \
  -H "Authorization: Bearer $STARTUP_BUILDER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"week":"2026-10-22"}'
```

```json
{
  "api": "https://api.sb/leaseline.app",
  "issue": {
    "$id": "https://api.sb/leaseline.app/issues/issue_vWekeqrXCN",
    "$type": "Issue",
    "status": "pending",
    "mode": "try"
  },
  "action": {
    "$id": "https://api.sb/leaseline.app/actions/act_br07HsG8MG",
    "operation": "Issue.schedule",
    "status": "done"
  },
  "links": {
    "self": "https://api.sb/leaseline.app/actions/act_br07HsG8MG"
  }
}
```

### Issue.triage
Triage sets an Issue’s severity and owning Role from its content and the Customer it affects. [Verb page](/business/nouns/issue/triage?interface=api).

```text
POST /{namespace}/issues/{issue}/triage
```

Path: `issue`. Emits [`Issue.triaged`](/business/events/Issue.triaged).

**Inputs**

| Input | Type | Required | Description |
| --- | --- | --- | --- |
| `issue` | [Issue](/business/nouns/issue) | Yes | The new Issue. |

**Returns**

| Output | Type | Required | Description |
| --- | --- | --- | --- |
| `issue` | [Issue](/business/nouns/issue) | Yes | The triaged Issue. |

**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. |
| The record is not in a state that allows this Verb, so the call is refused. | [`refused`](/code/api/errors/refused) | Read the record, run the Verb that moves it to an allowed state, then retry. | None. |

**Example**

```bash
curl -X POST https://api.sb/leaseline.app/issues/issue_vWekeqrXCN/triage \
  -H "Authorization: Bearer $STARTUP_BUILDER_API_KEY"
```

```json
{
  "api": "https://api.sb/leaseline.app",
  "issue": {
    "$id": "https://api.sb/leaseline.app/issues/issue_vWekeqrXCN",
    "$type": "Issue",
    "status": "pending",
    "mode": "try"
  },
  "action": {
    "$id": "https://api.sb/leaseline.app/actions/act_br07HsG8MG",
    "operation": "Issue.triage",
    "status": "done"
  },
  "links": {
    "self": "https://api.sb/leaseline.app/actions/act_br07HsG8MG"
  }
}
```