Lookup API: Event Types
This page documents the lookup endpoints for event types and class definitions.
Authentication
These endpoints use BASIC_AUTH_POLICY.
That policy accepts either:
- HTTP Basic auth (
Authorization: Basic base64(username:password)), or - JWT authentication fallback when basic auth is not provided
See: API Authentication and Access
Endpoints
Get all event types
- Route:
GET /external/lookup/event-types - Auth policy:
BASIC_AUTH_POLICY
Returns all supported event types sorted by name.
Response item shape:
id(int)name(string)
Example:
[
{ "id": 1, "name": "Baseball" },
{ "id": 3, "name": "Basketball" },
{ "id": 8, "name": "Soccer" }
]
Get class definition by event type
- Route:
GET /external/lookup/event-types/{eventTypeId}/class-definition - Path params:
eventTypeId(int)
- Auth policy:
BASIC_AUTH_POLICY
Returns a property/type definition object for the requested event type.
Response shape:
eventTypeId(int)eventTypeName(string)properties(array)name(string)type(string)
Example:
{
"eventTypeId": 8,
"eventTypeName": "Soccer",
"properties": [
{ "name": "Clock", "type": "string" },
{ "name": "HomeScore", "type": "string" }
]
}
Error behavior
For GET /external/lookup/event-types/{eventTypeId}/class-definition:
- Invalid
eventTypeIdreturns400 Bad Requestwith message:Invalid EventType ID: {eventTypeId}
- Unhandled errors return
500 Internal Server Error
For GET /external/lookup/event-types:
- Unhandled errors return
500 Internal Server Error
Notes
- This lookup endpoint returns class definitions for standard contract types.
- For ingress-specific contracts, use ingress event-type schema endpoints described in MQTT Ingress.