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

# Event types

> Read your catalog: categories, event types and the equipment that resolves them.

The `type` of an event is an active event type of your catalog for the event's vertical, for example `cardiac_arrest`. Anything else returns `422 unknown_event_type`, with the accepted codes in `known_types`.

Your catalog is organised by vertical: each vertical has categories, each category has event types, and each type says whether it sends a field team and which equipment or qualifications resolve it. wede pre-loads a starting catalog for every vertical of your organisation; your administrators keep what fits, add their own and deactivate what they do not use, in the dashboard (Catalog) or with a session token. API keys can read it.

> [!NOTE]
>
> Before 8 October 2026 an event could also carry a wede category (`EMERGENCY`, `PAYMENT`, `OTHER` and others) as its `type`. Those codes are no longer accepted: send a type of your catalog. `GET /v1/event-categories` now returns an empty list and will be removed.

## Read your catalog

```text theme={null}
GET /v1/catalog
```

### Authentication

API key, or session token with the `teams:view` permission. API keys have `catalog:view`, which allows this call.

### Query parameters

**vertical** `string`

Return only this vertical, for example `healthcare`.

### Example

```bash theme={null}
curl "https://api.wede.pt/v1/catalog?vertical=healthcare" \
  -H "x-wede-api-key: wede_live_YOUR_KEY"
```

### Response

`200 OK`. One entry per vertical of your organisation, with its categories and their types, active and inactive.

```json theme={null}
{
  "data": [
    {
      "vertical": "healthcare",
      "categories": [
        {
          "id": "1c7d2a0e-5b3f-4e8a-9d61-2f4b7c9e0a13",
          "vertical": "healthcare",
          "code": "pre",
          "name": "Pre-hospital emergency",
          "description": "Emergency calls and medical teams in the field",
          "is_active": true,
          "seeded": true,
          "sort_order": 0,
          "types": [
            {
              "id": "6f8a0c2e-4b6d-4f1a-8c3e-5a7c9e1b3d5f",
              "vertical": "healthcare",
              "category_id": "1c7d2a0e-5b3f-4e8a-9d61-2f4b7c9e0a13",
              "code": "cardiac_arrest",
              "name": "Cardiac arrest",
              "description": null,
              "requires_teams": true,
              "required_equipment": ["defibrillator", "ambulance"],
              "default_priority": "critical",
              "is_active": true,
              "seeded": true,
              "coverage": { "event_type_id": "6f8a0c2e-4b6d-4f1a-8c3e-5a7c9e1b3d5f", "teams_covering": 3, "teams_total": 3, "gaps": [] }
            }
          ]
        }
      ]
    }
  ]
}
```

**data** `object[]`

**properties**

**vertical** `string`

Vertical code.

**categories** `object[]`

Categories of this vertical, in `sort_order`. Each has `id`, `code` (lowercase letters, digits and `_`), `name`, `description`, `is_active`, `seeded` (pre-loaded by wede) and `types`.

**categories\[].types\[].code** `string`

The value to send as `type`. Lowercase letters, digits and `_`, up to 50 characters. Unique per vertical.

**categories\[].types\[].requires\_teams** `boolean`

`true`: the event enters dispatch and a field team is sent. `false`: the event is delivered and recorded, nobody is sent.

**categories\[].types\[].required\_equipment** `string[]`

Codes of the equipment and qualifications that resolve this type (see below). They count in the team score and never block a dispatch.

**categories\[].types\[].default\_priority** `string | null`

Priority used when an event of this type is sent without `priority`. `null` means `normal`.

**categories\[].types\[].is\_active** `boolean`

Only active types are accepted on new events.

**categories\[].types\[].coverage** `object | null`

For types that send a team: how many of your teams cover it (`teams_covering` of `teams_total`) and, in `gaps`, the covering teams that lack equipment or members. `null` for types that send nobody.

### Errors

| Status | Code | When |
| - | - | - |
| 401 | `unauthorized` | Credential missing, malformed, revoked or expired |
| 403 | `forbidden` | The credential lacks the permission, or the session belongs to wede staff |
| 500 | `internal_error` | Unexpected error. Retry |
| 503 | `service_unavailable` | The API key could not be validated right now. Retry |

## Equipment and qualifications

```text theme={null}
GET /v1/catalog/equipment
```

One list for the whole organisation, used by event types (what resolves them) and by teams (what they have). Same authentication as above.

```json theme={null}
{
  "data": [
    { "id": "7a1b...", "code": "defibrillator", "name": "Defibrillator (AED)", "kind": "equipment", "is_active": true, "seeded": true },
    { "id": "8c2d...", "code": "paramedic", "name": "Paramedic", "kind": "qualification", "is_active": true, "seeded": true }
  ]
}
```

`kind` is `equipment` or `qualification`. Pass `active=true` to get only active items.

## Managing the catalog

Administrators manage the catalog in the dashboard. The same operations are available with a session token that has the `teams:manage` permission: `POST`, `PATCH` and `DELETE` on `/v1/catalog/categories/:id`, `/v1/catalog/types/:id` and `/v1/catalog/equipment/:id`, and `POST /v1/catalog/reseed` to add back any wede default that was deleted (it never changes what you have). A type cannot be deleted while it has open events (`409 type_has_open_events`) or a parser points to it (`409 type_used_by_parser`); deactivate it instead. A type can only require equipment that exists in your list (`422 unknown_equipment`).

## Types, parsers and teams

Each value of the type field of a [parser](/concepts/parsers.md) points to a type of your catalog, so a message that arrives by SMS or another degraded channel creates an event with the same type as one sent online. A parser cannot be activated while one of its values points to a type that does not exist.

Teams cover a whole category or specific types. Only teams that cover the type of an event are candidates for its dispatch; a type's `required_equipment` lowers the score of teams that lack it and never excludes them. See [Score engine](/concepts/score-engine.md).


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