Add Schedule type for Darwin PushPort
Some checks failed
Generate and Release Protos / release (push) Failing after 25s

This commit is contained in:
2026-02-23 19:07:31 +00:00
parent 87ed1d01d5
commit 776263c068
2 changed files with 40 additions and 1 deletions

View File

@@ -23,7 +23,7 @@
},
"data_kind": {
"type": "string",
"enum": ["pis", "timetable", "knowledgebase"],
"enum": ["pis", "timetable", "knowledgebase", "darwin_schedule", "darwin_ts", "darwin_ref"],
"description": "The data type contained in the message. Currently supported PIS: PIS Data, Timetable: CIF or VSTP Data, Knowledgebase: Station Data"
}
},

View File

@@ -0,0 +1,39 @@
{
"$id": "https://schema.owlboard.info/data-ingress/pushport-schedule.schema.json",
"$schema": "https://json-schema.org/draft-07/schema#",
"title": "PushPortSchedule",
"type": "object",
"required": ["rid", "uid", "trainId", "ssd", "toc", "locations"],
"properties": {
"rid": {"type": "string", "description": "Unique service ID"},
"uid": {"type": "string", "description": "Unique schedule ID - maps to NR CIF"},
"trainId": {"type": "string", "description": "Train Headcode"},
"ssd": {"type": "string", "format": "date", "description": "Schedule Start Date (When the service commences)"},
"toc": {"type": "string", "minLength": 2, "maxLength": 2, "description": "TOC Code"},
"isPassenger": {"type": "boolean", "description": "If service is for passengers", "default": true},
"isCharter": {"type": "boolean", "description": "If train is charter service", "default": false},
"status": {"type": "string", "enum": ["train", "bus", "ship"], "default": "train"},
"isDelayedDelivery": {"type": "boolean", "description": "If message is sent as part of Darwin service recovery"},
"cancelReason": {"type": ["string", "null"], "description": "Reason code for cancellation"},
"isDeleted": {"type": "boolean", "description": "Whether schedule should be deleted", "default": false},
"locations": {
"type": "array",
"items": {
"type": "object",
"required": ["tpl", "seq"],
"properties": {
"tpl": {"type": "string", "description": "TIPLOC of location"},
"seq": {"type": "integer", "description": "The order of the stop for sorting and handling repeated TIPLOCs"},
"wta": { "type": ["string", "null"] },
"wtd": { "type": ["string", "null"] },
"wtp": { "type": ["string", "null"] },
"pta": { "type": ["string", "null"] },
"ptd": { "type": ["string", "null"] },
"plat": { "type": ["string", "null"] },
"isCancelled": { "type": "boolean", "default": false },
"activities": { "type": "string" }
}
}
}
}
}