Seat classes
These events are emitted by the Inventory API (btrz-api-inventory) when seat classes are created, updated, or deleted.
Events
| Action | Event name | Endpoint |
|---|---|---|
| Create a seat class | seatclass.created | POST /seat-classes |
| Update a seat class | seatclass.updated | PUT /seat-classes/:seatClassId |
| Delete a seat class | seatclass.deleted | DELETE /seat-classes/:seatClassId |
Payload example created / updated
The data object contains the full seat class (for seatclass.created and seatclass.updated). Type: object with properties from the SeatClass model.
{
"attemptId": "uuid",
"created": 1628024835,
"data": {
"_id": "24 hex character id",
"name": "string",
"description": "string",
"deleted": false,
"bgcolor": "#d4eaf0",
"lexiconKeys": { "name": { "key": "...", "values": {} }, "description": { "key": "...", "values": {} } },
"createdBy": "24 hex user id",
"updatedBy": "24 hex user id",
"createdAt": { "offset": 0, "value": "ISO date string" },
"updatedAt": { "offset": 0, "value": "ISO date string" }
},
"event": "seatclass.created",
"id": "uuid",
"livemode": true
}
Payload example deleted
For seatclass.deleted, data contains only the deleted seat class id.
{
"attemptId": "uuid",
"created": 1628024836,
"data": {
"seatClassId": "24 hex character id"
},
"event": "seatclass.deleted",
"id": "uuid",
"livemode": true
}
Field descriptions — payload (seat class events)
| Field | Type | Description |
|---|---|---|
| attemptId | string | UUID of the attempt that triggered the event. |
| created | number | Unix timestamp when the event was created. |
| event | string | Event name (seatclass.created, seatclass.updated, seatclass.deleted). |
| id | string | UUID of the webhook event. |
| livemode | boolean | Whether the event occurred in live mode. |
| data._id | string | Seat class id (24 hex characters). Only present for created/updated. |
| data.name | string | Class name of the seat. |
| data.description | string | Class description of the seat. |
| data.deleted | boolean | Indicates if the class is deleted. |
| data.bgcolor | string | Seat class background colour (e.g. hex). |
| data.lexiconKeys | object | Lexicon keys for name and description (key/values per language). |
| data.createdBy | string | User id that created this resource (24 hex). |
| data.updatedBy | string | User id that last updated this resource (24 hex). |
| data.createdAt | object | BzDate: creation date. |
| data.updatedAt | object | BzDate: last update date. |
| data.seatClassId | string | Seat class id (24 hex). Only present for seatclass.deleted. |